ver228 / tierpsy-tracker

Multi-Worm Behaviour Tracker
http://ver228.github.io/tierpsy-tracker/
MIT License
24 stars 40 forks source link

tensorflow, conda-forge, multithread #60

Closed luigiferiani closed 5 years ago

luigiferiani commented 5 years ago

Tensorflow and conda-forge

The pinned keras=2.1.5 in the general channel comes with tensorflow=1.10.0=eigen..., with abysmal performances (at least on MacOS). keras=2.1.5 via conda-forge comes with tensorflow=1.0.0=py36_0, with better performance. Solution Updated the installation instructions so that conda-forge will be the natural choice for users. Also updated the requirements.txt file so installing from source also uses conda-forge.

Multithreading

Enforced OMP_NUM_THREADS='1' when launching a subprocess. This will improve performances when analysing in parallel a number of videos close to the number of cores available. However performance will be degraded if only a few files are analysed in parallel, so we should think about using a parameter for this.

Other installation issues

Updated the installation instruction with steps to deal with an error I've encountered while installing tierpsy recently. Also suggesting a version of opencv via conda that works on MacOS.

luigiferiani commented 5 years ago

Please double-check I haven't messed up anything before merging!

ver228 commented 5 years ago

Hey, this looks good but I remember having a problems with the conda-forge packages and Windows. I think conda-forge works better for macos/linux but some packages maybe not up to day for Windows, while I think anaconda might have the opposite.

I suggest to rather than enforce the channel in requirements.txt to state it in the installation instructions like:

For OSX:

conda install --file requirements.txt -c conda-forge

For Windows

conda install --file requirements.txt -c anaconda 

Additionally, somebody might want to use pip so that opens the possibility. Although i am not sure if all the packages are there...

luigiferiani commented 5 years ago

Yep, that makes sense. At this moment we are without a Windows 10 machine, but we're planning to get one exactly for tierpsy testing purposes.