Open SHADJIA opened 2 years ago
Hi @SHADJIA,
Thank you for using our software. The error occurred because the run_regression
function uses GPU by default but the installed PyTorch on your local machine is the one that does not support GPU; therefore, the solutions are as below.
device
parameter of the run_regression
function from "cuda:0"
to "cpu"
. However, the execution of MarcoPolo would be much slower.Please let me know if you have any other questions.
Best, Chanwoo
Hello @chanwkimlab ,
Thanks for your reply.
I don't have GPU in my computer. I execute the code by using CPU as device. It's still working since 2 hours. LIke in colab, I can't see the progression bar with jupyter. And since the code is running for regression, "size factor was calculated" is not printed. I just have : The numbers of clusters to test: [1, 2] Y: (22748, 16656) X: (22748, 1) s: (22748,) Is this normal or there is a problem in the execution?
Thanks once again. Regards, Sha
Hi @SHADJIA,
As you use CPU instead of GPU and your input data is very large, it is very normal that the regression takes longer than 2 hours. Also, It's possible that you don't see "size factor was calculated" if your input data already contains "size_factor" column. However, it is interesting that you don't see a progress bar. When I changed the device parameter from "cuda:0" to "cpu" in the colab environment, I was still able to see the progress bar. For debugging purposes, you can manually edit the regression/trainer.py
file to add the following lines to the fit_multiple_genes
function. You can retrieve the path where MarcoPolo was installed by running MarcoPolo.__file__
after executing import MarcoPolo
.
for iter_idx, exp_data_idx in enumerate(pbar):
+ if iter_idx%10==0:
+ print(iter_idx)
cell_dataset = CellDataset(Y_select[:, iter_idx:iter_idx + 1], X, s)
Best, Chanwoo
Hello @chanwkimlab ,
I'm a beginner for Python world. I would like to test your tool for my dataset and from my local machine with Jupyter Notebook. Can you help me with your code? Actually when I try your vignette, I get this error :
Do you have any idea to resolve this issue?
Thanks a lot in advance.
Regards, Sha