pyspi: Statistics for Pairwise Interactions
pyspi GitHub
  • Welcome to pyspi
    • Citing pyspi
  • Installing and using pyspi
    • Installation
      • Alternative Installation Options
      • Troubleshooting
    • Usage
      • Walkthrough Tutorials
        • Getting Started: A Simple Demonstration
        • Neuroimaging: fMRI Time Series
        • Finance: Stock Price Time Series
        • Distributing Calculations
      • Advanced Usage
        • Creating a reduced SPI set
        • Distributing calculations on a cluster
      • FAQ
  • Information about pyspi
    • SPIs
      • Glossary of Terms
      • Table of SPIs
      • SPI Descriptions
        • Basic Statistics
        • Distance Similarity
        • Causal Inference
        • Information Theory
        • Spectral
        • Miscellaneous
      • SPI Subsets
    • API Reference
      • pyspi.calculator.CorrelationFrame
      • pyspi.calculator.Calculator
      • pyspi.data.Data
      • pyspi.calculator.CalculatorFrame
      • pyspi.utils.filter_spis
    • Publications using pyspi
    • Related Packages
  • Development
    • Development
      • Incorporating new SPIs
      • Contributing to pyspi
      • Code of Conduct
    • License
Powered by GitBook

All page cover images on this wiki are created with the help of DALL-E, an AI program developed by OpenAI, or stock images from Unsplash.

On this page
  • Operating System-Specific Troubleshooting
  • Windows Related Issues
  • MacOS Related Issues
  • Linux Related Issues
  1. Installing and using pyspi
  2. Installation

Troubleshooting

PreviousAlternative Installation OptionsNextUsage

Last updated 1 year ago

Welcome to the troubleshooting page for pyspi. This section is dedicated to helping you resolve common issues and challenges you might encounter while installing our package. Here, we provide detailed solutions and guidance for a variety of scenarios that new users may face. Our aim is to make your experience with pyspi as smooth and efficient as possible.

Please note that this document is continually updated with new information and solutions. If you encounter a problem that is not covered in this documentation, we encourage you to raise an issue on our . Your feedback is invaluable to us, and we will gladly incorporate new resolutions and updates into this documentation to assist others. We are committed to maintaining a comprehensive and user-friendly troubleshooting guide.


Operating System-Specific Troubleshooting

We have sorted the troubleshooting guide by operating system. Select your operating system to receive relevant troubleshooting advice.


Windows Related Issues


Unable to Locate Octave and/or Java Paths

If you are using Windows and you get an error that pyspi cannot locate your system's Octave and/or Java paths, you can manually set these paths prior to importing pyspi:

import os
pathToExecutable = "C:/ProgramFiles/GNU Octave/Octave-8.4.0/mingw64/bin/octave-cli-8.4.0.exe" # change if your octave client is installed elsewhere
pathToJAVA_HOME = "C:/Program Files/Java/jdk-20" # Change if you use a different Java JDK
os.environ['OCTAVE_EXECUTABLE'] = pathToExecutable
os.environ['JAVA_HOME'] = pathToJAVA_HOME

python setup.py egg_info did not run successfully

A few users have reported encountering this issue during the installation process (particularly those on Windows OS). This appears to be related to a compatibility conflict between Python version 3.9.0 and sktime version 0.8.0. The current workaround is to re-install pyspi (either in a new conda environment or on your system) using python-3.8.0:

$ conda create --name pyspi python=3.8.0
$ conda activate pyspi
# navigate to your pyspi directory
$ pip install .

Pandas Int64Index error

A few users have noted the following error when instantiating the Calculator object:

ImportError: cannot import name 'Int64Index' from 'pandas'

You can fix this error by manually removing numpy and pandas, and manually reinstalling the below versions with the following code:

pip uninstall numpy
pip uninstall pandas
pip install numpy==1.22
pip install pandas==1.3.3

MacOS Related Issues


Java JVM DLL not found

OSError: [Errno 0] JVM DLL not found /Library/Java/JavaVirtualMachines/jdk-19.jdk/Contents/Home/lib/libjli.dylib
  • Install homebrew if you haven't already

$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  • Install jenv as your Java version manager

$ brew install jenv
  • Add jenv to your shell's configuration file (e.g. .bashrc if you use bash, .zshrc if you use zsh)

$ export PATH="$HOME/.jenv/bin:$PATH"
$ eval "$(jenv init -)"
  • Source your shell's configuration file:

$ source ~/.bashrc # If you use bash; OR
$ source ~/.zshrc # If you use zsh
  • Confirm proper installation of jenv

$ jenv doctor

Even if this returns some errors, as long as you see jenv is correctly loaded, you're all set. We recommend using AdoptOpenJDK version 11. Note that AdoptOpenJDK has recently transitioned to Eclipse Adoptium, but in some cases, the Adoptium versions might not resolve specific issues. We suggest downloading an older version of AdoptOpenJDK. Here's how you can proceed:

  • Look for the version of AdoptOpenJDK for your OS. For Apple Silicon (M1/M2), the OpenJDK11U-jdk_x64_mac_hotspot_11.0.9.1_1.pkg, while not specifically designed for the Apple ARM architecture, has been found to resolve certain issues.

  • Follow the installation instructions for your specific operating system to install the JDK. Make note of the location in which the JDK was installed.

Now you will need to add your AdoptOpenJDK path to your jenv environments. First, you can find where your jdk files are installed with the following command:

$ /usr/libexec/java_home -V

This will list all your installed java JDK versions. Locate the one for AdoptOpenJDK version 11 and paste the path:

$ jenv add <path_to_adopt_open_jdk_11>

Confirm AdoptOpenJDK version 11 was added to jenv:

$ jenv versions

You can set AdoptOpenJDK version 11 as your global Java version with the following:

$ jenv global <AdoptOpenJDK version>
$ # example:
$ jenv global 11.0

Pandas Int64Index error

A few users have noted the following error when instantiating the Calculator object on MacOS:

ImportError: cannot import name 'Int64Index' from 'pandas'

You can fix this error by manually removing numpy and pandas, and manually reinstalling the below versions with the following code:

pip uninstall numpy
pip uninstall pandas
pip install numpy==1.22
pip install pandas==1.3.3

Linux Related Issues


Missing pyEDM (Linux)

Some operating systems/pip versions may be unable to locate pyEDM. In this case, the workaround is to download and install the wheel locally as follows:

  1. Install the wheel package if you don't have it already using pip install wheel.

  2. Navigate in your terminal to where you've downloaded the wheel file.

  3. Install the wheel file directly with the command pip install [file.whl]. For example, that might look like pip install pyEDM-1.9.3.0-cp39-cp39-manylinux2010_x86_64.whl.


Thank you to GitHub user for reporting this issue and providing the solution.

Thank you to GitHub user for reporting this issue and providing the solution.

This issue is similar to those reported and ; it can arise from the version of OpenJDK identified as the system default. Some Java versions don't include all of the binary (DLL) files that pyspi looks for. We recommend following this helpful by Chamika Kasun to install AdoptOpenJDK. In a nutshell, here are the steps you should follow:

Go to the .

Download the wheel file (.whl) from the for version 1.9.3 (one of the two Linux versions depending on whether you are running i686 or x86_64 architecture).

rmzargar
rmzargar
here
here
tutorial
AdoptOpenJDK GitHub releases page
pyEDM repository
GitHub repository
Page cover image
Cover

Windows

Cover

Linux

Cover

MacOS