juglab / cryoCARE_pip

PIP package of cryoCARE
BSD 3-Clause "New" or "Revised" License
25 stars 14 forks source link

installation issue? #27

Open jychoi0616 opened 1 year ago

jychoi0616 commented 1 year ago

Hi the cryoCARE team,

I recently installed the v.0.2. and encountered to two issues.

The first one is I cannot call the built in python-scripts even after doing conda activate cryocare_11. So I had to copy all the python script to each directory that I wanted to run. I did install using miniconda & pip install cryoCARE described in read.me. Is there another step I have to do for proper installation?

Also, the predict_config.json file included in the v.0.2. release folder seemed to not compatible with v.0.2 yet (Or I must have done something wrong). When I run the cryoCARE_predict with the provided predict_config.json, I get this following error:

"Your config is not in the format that cryoCARE >=0.2 requires. Fallback to cryoCARE 0.1 format. Invalid config format."

For your reference, the .json file I used was: { "path": "cryocare_model", "even": "TS_04_EVN_volume_b6_wbp/tomogram.mrc", "odd": "TS_04_ODD_volume_b6_wbp/tomogram.mrc", "n_tiles": [1, 1, 1], "output": "cryocare_model/denoised", "overwrite": false }

Best wishes, Joy

EuanPyle commented 1 year ago

Hi Joy, for the "Your config is not in the format that cryoCARE >=0.2 requires. Fallback to cryoCARE 0.1 format. Invalid config format." message, it is probably because "path" is set to cryocare_model. "path" needs to point to the tar.gz file created by the training step. To double check this is correct, in the directory you are entering the cryoCARE_predict.py command, try: ls [whatever the path you enter in the json file is] If it says 'no such file' or similar then the path is incorrect.

Regarding the install, did you have the earlier version of cryoCARE working? Maybe create a fresh environment (just re-do the install but call it 'cryocare_11_b' or something). if you did.

jychoi0616 commented 1 year ago

Hi Euan,

Thanks for the quick reply! The path I wrote was the correct path including the tar.gz file. I actually found it worked when I specify the tar.gz file name (not just path itself). Thanks!

The earlier versions of cryoCARE used to work to call the built-in python script, but actually I found it doesn't do anymore either. I tried creating a fresh environment and re-installing, but it still didn't call the built-in python script. Do you know where the python script should be located in order to be called? I could manually locate the scripts to the directory?

Thank you, Joy

EuanPyle commented 1 year ago

If installed correctly, you really shouldn't need to move the scripts. One thing you could try is making sure the scripts (where they were installed) are on your PATH via: export PATH="path/to/the/scripts:$PATH" Note this will only work on a bash shell. If using tcsh or csh try: set path = ( path/to/the/scripts $path )

jychoi0616 commented 1 year ago

Hi Euan,

Thank you for reply. The export PATH still didn't help (I restarted the terminal after changing the bashrc). I now have a feeling that this might be an issue specific to my workstation (rather than cryoCARE).

Thanks for helping, Joy