Skip to content

Commit

Permalink
add h5py to setup.py's extra_requires (#3711)
Browse files Browse the repository at this point in the history
* add h5py to setup.py's extra_requires
  - fix #3701
  - new 'extra_coordinates' target in extra_requires where we can
    add pip-installable packages for additional formats that are not
    installed by default
  - keep minimum version of h5py at >= 2.1.0
* minimum h5py >= 2.10
  - GitHub actions
  - maintainer/conda/environment.yml for readthedocs
  - Azure pipelines
* update extra_deps in setup.py
  - include chemfiles>=0.10 in extra_formats
  - added comment to remove AMBER in 3.0.0
* updated CHANGELOG
* updated sklearn --> scikit-learn in setup.py
* deprecate extras_require "AMBER" target for 2.4

Co-authored-by: Irfan Alibay <[email protected]>
  • Loading branch information
orbeckst and IAlibay authored Jul 6, 2022
1 parent cf17d42 commit 2c32ed1
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/actions/setup-deps/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ inputs:
clustalw:
default: 'clustalw=2.1'
h5py:
default: 'h5py'
default: 'h5py>=2.10'
joblib:
default: 'joblib>=0.12'
netcdf4:
Expand Down
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ jobs:
pytest-xdist
scikit-learn
scipy
h5py
h5py>=2.10
tqdm
threadpoolctl
fasteners
Expand Down
2 changes: 1 addition & 1 deletion maintainer/conda/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies:
- fasteners
- griddataformats
- gsd
- h5py
- h5py>=2.10
- hypothesis
- joblib>=0.12
- matplotlib==3.2.2
Expand Down
5 changes: 5 additions & 0 deletions package/CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,17 @@ Enhancements
(CZI Performance track, PR #3683)

Changes
* To add additional optional packages for different file formats when
using `pip` use the new "extra_formats" extras_require target as in
`pip install ./package[extra_formats]` (Issue #3701, PR #3711)
* Minimum supported NumPy version is now 1.20 (1.21 for macosx-arm64)
as per NEP29 (PR #3737)
* Narrowed variable scope to reduce use of OpenMP `private` clause (PR #3706, PR
#3728)

Deprecations
* The extras_requires target "AMBER" for `pip install ./package[AMBER]`
will be removed in 2.4. Use "extra_formats". (Issue #3701, PR #3711)
* Deprecate `density` parameter in favor of `norm` in InterRDF_s
(Issue #3687)

Expand Down
22 changes: 10 additions & 12 deletions package/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,8 @@
print('Please upgrade your version of Python.')
sys.exit(-1)

if sys.version_info[0] < 3:
import ConfigParser as configparser
else:
import configparser

if sys.version_info[0] >= 3:
from subprocess import getoutput
else:
from commands import getoutput
import configparser
from subprocess import getoutput

# NOTE: keep in sync with MDAnalysis.__version__ in version.py
RELEASE = "2.3.0-dev0"
Expand Down Expand Up @@ -654,14 +647,19 @@ def long_description(readme):
# you might prefer to use the version available through your
# packaging system
extras_require={
'AMBER': [
'AMBER': [ # REMOVE for 2.4.0, use 'extra_formats'
'netCDF4>=1.0', # for fast AMBER writing, also needs HDF5
],
'extra_formats': [ # additional file formats
'netCDF4>=1.0', # for fast AMBER writing, also needs HDF5
'h5py>=2.10', # H5MD
'chemfiles>=0.10', # multiple formats supported by chemfiles
],
'analysis': [
'seaborn', # for annotated heat map and nearest neighbor
# plotting in PSA
'sklearn', # For clustering and dimensionality reduction
# functionality in encore
'scikit-learn', # For clustering and dimensionality
# reduction functionality in encore
'tidynamics>=1.0.0', # For MSD analysis method
],
},
Expand Down

0 comments on commit 2c32ed1

Please sign in to comment.