getkeops / keops

KErnel OPerationS, on CPUs and GPUs, with autodiff and without memory overflows
https://www.kernel-operations.io
MIT License
1.02k stars 65 forks source link

Cannot import pykeops v2.2.1 #356

Closed geraseva closed 4 months ago

geraseva commented 4 months ago
>>> import pykeops
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/domain/data/prog/miniconda3/envs/dmasif/lib/python3.7/site-packages/pykeops/__init__.py", line 77, in <module>
    from .torch.test_install import test_torch_bindings
  File "/home/domain/data/prog/miniconda3/envs/dmasif/lib/python3.7/site-packages/pykeops/torch/__init__.py", line 17, in <module>
    from .generic.generic_red import Genred
  File "/home/domain/data/prog/miniconda3/envs/dmasif/lib/python3.7/site-packages/pykeops/torch/generic/generic_red.py", line 259
    return None, *grads
                 ^
SyntaxError: invalid syntax
jeanfeydy commented 4 months ago

Hi @geraseva,

This syntax was introduced by Python 3.8, but you are using Python 3.7, which is now officially deprecated. Creating a conda environment with a recent version of Python should fix your issue.

Best regards, Jean

geraseva commented 4 months ago

Thank you.