opticspy / lightpipes

LightPipes for Python, "Pure Python version"
https://opticspy.github.io/lightpipes/
BSD 3-Clause "New" or "Revised" License
227 stars 52 forks source link

Installation of LightPipes for Python on a Raspberry Pi #44

Open FredvanGoor opened 3 years ago

FredvanGoor commented 3 years ago

Cannot install LightPipes (version 2.0.0 and higher) on a Raspberry Pi vs 4.0 (Solved)

This is caused by the fact that the required pyFFTW package cannot be installed on a Raspberry Pi (ARM processor) Maybe this will be solved in the future. In the mean time you can install pyFFTW on a Raspberry Pi as follows:

Step1, download FFTW:

Download from the FFTW Download page http://www.fftw.org/download.html the file fftw-3.3.8.tar.gz or newer. At a terminal prompt goto your Downloads directory and type:

cd ~/Downloads
tar xzf fftw-3.3.8.tar.gz

Step 2, install FFTW:

cd fftw-3.3.8
./configure --enable-threads --enable-shared
make
sudo make install

Step 3, install the cython compiler and ATLAS:

sudo pip3 install cython
sudo apt-get install libatlas-base-dev

If an error pops up that says something like: “E: Encountered a section with no package header” and/or: “E: The package lists or status file could not be parsed or opened”, try:

sudo rm -vf /var/lib/apt/lists/*
sudo apt-get update

Step 4, install LightPipes for Python:

sudo pip3 install lightpipes

The installation of LightPipes for Python described above has been tested on a Raspberry Pi 4 model B with 8Gbyte memory and with NOOBS 3.5.0 operating system.

It has also been tested with the recommended Raspberry Pi OS (32-bit) operating system installed using the Raspberry Pi Imager v1.4. See: Raspberry Pi OS (previously called Raspbian) https://www.raspberrypi.org/downloads/raspberry-pi-os/