You need to make sure git, virtualenv, and python3 are installed and are in the $PATH (you can type those command names on the commandline and your computer finds them).
Note that I have mostly used python 3.9.6 for mac. It seems that 3.12.2 may be causing problems with the dependencies.
For usage on a Mac, do the following in a terminal.
git clone https://github.com/BrentLagesse/YeastAnalysisTool.git
cd YeastAnalysisTool
virtualenv venv
source venv/bin/activate
sh init.sh
You can do this while the other script is still running -- Download this link https://drive.google.com/file/d/1moUKvWFYQoWg0z63F0JcSd3WaEPa4UY7/view?usp=sharing and put it in the weights directory the previous script just made.
python3 display.py
This starts the program. Change the Input directory to one of your picture directories like M2210
click start analysis and it should start going (the button will probably turn blue and stay that way a while.
After that runs (it'll take a few minutes or so, probably), you should see the images and the cells.
###########################################################################################################################################################
Running on Windows Having the same assumptions that Python(3.10) is installed in the machine
Git clone https://github.com/BrentLagesse/YeastAnalysisTool.git #Clone github Repo using
cd YeastAnalysisTool
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py #Download pip
python get-pip.py
py -m pip install --upgrade pip
py -m pip install --user virtualenv #install virtual environment
py -m venv venv #create venv folder
.\venv\Scripts\activate #activate venv
pip install -r requirementsWindows.txt #install all windows requirements
Run init.bat
Download this file https://drive.google.com/file/d/1moUKvWFYQoWg0z63F0JcSd3WaEPa4UY7/view Save the downloaded .h5 file to the “.\weights” directory created by running init.bat (for windows) Create output Folders within the YeastAnalysisTool folder, and create a folder: “.\output\segmented”
!!! Important !!!
Windows and Mac might have some conflicting issues, so follow the terminal and fix those issues. Some issues below for windows maybe:
Change foreground parameters to fg_color
Change text_font parameters to font
In main.py:
Look for
csvwriter = csv.writer(csvfile)
Change to
csvwriter = csv.writer(csvfile, lineterminator='\n')
image.astype(np.float32)
becomes,
np.float32(image)
# puts all personal packages into deleteRequirements.txt
1. pip freeze --all > deleteRequirements.txt
# uninstalls all packages
2. pip uninstall -r deleteRequirements.txt
# installs repo's pip packages
3. pip install -r ./requirements.txt --no-cache-dir
#deletes temporary Requirements
4. del deleteRequirements.txt