You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am on a MacBook M2. I followed religiously the installation instructions:
conda env create -f ~/.../environment.yml # edited to create environment 'stytra', not 'stytra_env'
conda activate stytra
pip install stytra
But running python -m stytra.examples.looming_exp crashes:
ImportError: dlopen(/Users/francoiskroll/miniconda3/envs/stytra/lib/python3.12/site-packages/PyQt5/QtCore.abi3.so, 0x0002): Library not loaded: @rpath/QtCore.framework/Versions/5/QtCore
etc.
I did notice pip install stytra does suspicious things around PyQt, like:
I tried a bunch of other things including the "Editable installation". No success, sadly.
I also tried starting from scatch, removing - pyqt from environment.yml, and letting pip install stytra do it (as it's so keen on installing PyQt even if it's already there!). In that case, python -m stytra.examples.looming_exp gives a different error, maybe useful for you to diagnose?
File "/Users/francoiskroll/miniconda3/envs/stytra/lib/python3.12/site-packages/stytra/gui/fishplots.py", line 16, in
class StreamingPositionPlot(pg.GraphicsWindow):
^^^^^^^^^^^^^^^^^
AttributeError: module 'pyqtgraph' has no attribute 'GraphicsWindow'. Did you mean: 'GraphicsView'?
So it's still PyQt being a pain, but at least stytra found it, I guess.
What am I missing?
The text was updated successfully, but these errors were encountered:
EDIT: But now I'm facing an issue with offline tracking... All goes well, then "Track video" crashes to:
File "/Users/francoiskroll/miniconda3/envs/stytra/lib/python3.12/site-packages/imageio_ffmpeg/_io.py", line 187, in count_frames_and_secs
raise RuntimeError("Could not get number of frames") # pragma: no cover
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: Could not get number of frames
I get this error with a video which was analysed on another machine where stytra is installed. So my installation must be to blame?
EDIT2: Yes, my installation was to blame. I found that downgrading ffmpeg from 6.1 to 6.0 solved the issue, which itself was not straightforward on my machine. In summary:
– Removing old ffmpeg (not sure if necessary): conda remove ffmpeg.
– The 'strict' channel_priority setting was blocking me from installing an old ffmpeg, I had to conda config --set channel_priority flexible.
– conda install conda-forge::ffmpeg=6.0
– Looks like conda remove inadvertently removed PyAV, so conda install av -c conda-forge
Great to hear it worked out in the end! AttributeError: module 'pyqtgraph' has no attribute 'GraphicsWindow'. Did you mean: 'GraphicsView'?
Has been fixed already (see #87), but has not been released on pip yet.
Thank you for the impressive work!
I am on a MacBook M2. I followed religiously the installation instructions:
But running
python -m stytra.examples.looming_exp
crashes:I did notice
pip install stytra
does suspicious things around PyQt, like:But well, it concludes
And all seems present if I run
conda list
:I tried a bunch of other things including the "Editable installation". No success, sadly.
I also tried starting from scatch, removing
- pyqt
from environment.yml, and lettingpip install stytra
do it (as it's so keen on installing PyQt even if it's already there!). In that case,python -m stytra.examples.looming_exp
gives a different error, maybe useful for you to diagnose?So it's still PyQt being a pain, but at least stytra found it, I guess.
What am I missing?
The text was updated successfully, but these errors were encountered: