Closed kimcdata closed 4 years ago
I use Python 3.7.5 and it works. But it looks like the problem with the compatibility with the last pytorch version. I used pytorch 1.3.1 for this code, because wrote the code about 2 years ago.
Thanks for the ultra fast reply!
I think I have it working.
Hi, thanks for releasing this method, it looks very useful. I'm trying to use it on our data. I am not an experienced python user so I'm having trouble getting all the dependencies in place.
What version of pytorch are you using, please?
I am getting the following error when running main.py:
Traceback (most recent call last): File "main.py", line 179, in
color_dict=color_dict)
File "/home/rstudio/ms_project/PoincareMaps/train.py", line 41, in train
loss = model.lossfn(model(inputs), targets)
File "/home/rstudio/miniconda3/envs/mspy/lib/python3.7/site-packages/torch/nn/modules/module.py", line 550, in __call_\
result = self.forward(*input, kwargs)
File "/home/rstudio/ms_project/PoincareMaps/model.py", line 131, in forward
dists = self.dist()(embs_inputs, embs_all).squeeze(-1)
File "/home/rstudio/miniconda3/envs/mspy/lib/python3.7/site-packages/torch/autograd/function.py", line 145, in __call_\
"Legacy autograd function with non-static forward method is deprecated. "
RuntimeError: Legacy autograd function with non-static forward method is deprecated. Please use new-style autograd function with static forward method. (Example: https://pytorch.org/docs/stable/autograd.html#torch.autograd.Function)**
python 3.7.7 on ubuntu 18.04 LTS
Thanks
results of pip freeze
> anndata==0.7.3 > annoy==1.16.3 > certifi==2020.4.5.2 > cffi==1.14.0 > cycler==0.10.0 > Cython==0.29.20 > decorator==4.4.2 > fastdtw==0.3.2 > get-version==2.1 > h5py==2.10.0 > imageio==2.8.0 > importlib-metadata==1.6.1 > joblib==0.15.1 > kiwisolver==1.2.0 > legacy-api-wrap==1.2 > leidenalg==0.8.0 > llvmlite==0.33.0 > matplotlib==3.1.3 > mkl-fft==1.0.15 > mkl-random==1.1.0 > mkl-service==2.3.0 > natsort==7.0.1 > networkx==2.4 > numba==0.50.0 > numexpr==2.7.1 > numpy==1.18.1 > packaging==20.4 > pandas==1.0.3 > patsy==0.5.1 > Pillow==7.1.2 > pycairo==1.18.0 > pycparser==2.20 > pyparsing==2.4.7 > python-dateutil==2.8.1 > python-igraph==0.7.1.post7 > pytz==2020.1 > PyWavelets==1.1.1 > scanpy==1.5.1 > scikit-image==0.17.2 > scikit-learn==0.23.1 > scipy==1.4.1 > scrublet==0.2.1 > seaborn==0.10.1 > setuptools-scm==4.1.2 > six==1.15.0 > statsmodels==0.11.1 > tables==3.6.1 > tbb==2020.0.133 > threadpoolctl==2.1.0 > tifffile==2020.6.3 > torch==1.5.0 > tornado==6.0.4 > tqdm==4.46.1 > umap-learn==0.4.4 > zipp==3.1.0