robinzyb / cp2kdata

cp2k postprocessing tools
https://robinzyb.github.io/cp2kdata/
GNU Lesser General Public License v3.0
52 stars 18 forks source link

Why is Python 3.7 No Longer Supported? #62

Closed Andy6M closed 1 month ago

Andy6M commented 1 month ago

Hi!

I noticed that the current version of cp2kdata does not support Python 3.7, as indicated by the requires-python = ">=3.8" in the pyproject.toml file. Previous versions did support Python 3.7. Could you please clarify why support for Python 3.7 was dropped?

Thank you!

robinzyb commented 1 month ago

Hello, I found numpy in python 3.7 has numerical instability for numpy Fast Fourier Transform used by macroaverage of hartree potential. The underlying reason is unknow. But this didn't occur for python >=3.8. If you need python=3.7, you can disable the python requirement, and git clone package from github then run the pytest to check the code works well. If the code passes the pytest, you can be rest assured for the code.

Andy6M commented 1 month ago

Hello, I found numpy in python 3.7 has numerical instability for numpy Fast Fourier Transform used by macroaverage of hartree potential. The underlying reason is unknow. But this didn't occur for python >=3.8. If you need python=3.7, you can disable the python requirement, and git clone package from github then run the pytest to check the code works well. If the code passes the pytest, you can be rest assured for the code.

Thank you for the explanation.

I only need the Plug in for dpdata functionality (reading from "cp2kdata/e_f" and "cp2kdata/md"). Can the previous versions of cp2kdata support dpdata and Python 3.7? I need to specify requirements in my own project, and it needs to be compatible with Python 3.7.

Thank you again!

robinzyb commented 1 month ago

I try to add the python 3.7 into test but it fails in the dpdata plugin test. Could you explain to me why the version 3.7 have to be used? will upgrading to python 3.8 crash your code?

Andy6M commented 1 month ago

I try to add the python 3.7 into test but it fails in the dpdata plugin test. Could you explain to me why the version 3.7 have to be used? will upgrading to python 3.8 crash your code?

I want to add cp2k support into dpgen2 https://github.com/deepmodeling/dpgen2/pull/238 In the unit test, it needs the python3.7 environment supports.

But it´s fine, I skip the 3.7 python version test in the current dpgen2 pull request.

Thank you for your answer!

robinzyb commented 1 month ago

Thank you for your understanding.