[med-svn] [Git][med-team/python-biom-format][upstream] New upstream version 2.1.17
Étienne Mollier (@emollier)
gitlab at salsa.debian.org
Tue Nov 4 20:43:10 GMT 2025
Étienne Mollier pushed to branch upstream at Debian Med / python-biom-format
Commits:
5a325f7c by Étienne Mollier at 2025-11-04T21:06:25+01:00
New upstream version 2.1.17
- - - - -
14 changed files:
- .github/workflows/python-package-conda.yml
- .github/workflows/release.yml
- + .github/workflows/wheels.yml
- ChangeLog.md
- Makefile
- − aarch64.Dockerfile
- biom/table.py
- biom/util.py
- − ci/aarch64.conda_requirements.txt
- doc/conf.py
- pyproject.toml
- − pytest.ini
- − setup.cfg
- setup.py
Changes:
=====================================
.github/workflows/python-package-conda.yml
=====================================
@@ -9,9 +9,9 @@ on:
branches: [ master ]
env:
- latest_python: "3.12"
- supported_pythons: '["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]'
- miniforge_version: "22.9.0-2"
+ latest_python: "3.13"
+ supported_pythons: '["3.9", "3.10", "3.11", "3.12", "3.13"]'
+ miniforge_version: "23.11.0-0"
miniforge_variant: "Mambaforge"
jobs:
@@ -35,7 +35,7 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout at v4
- - uses: conda-incubator/setup-miniconda at v2
+ - uses: conda-incubator/setup-miniconda at v3
with:
auto-update-conda: true
python-version: ${{ env.latest_python }}
@@ -57,7 +57,7 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout at v4
- - uses: conda-incubator/setup-miniconda at v2
+ - uses: conda-incubator/setup-miniconda at v3
with:
auto-update-conda: true
python-version: ${{ env.latest_python }}
@@ -81,12 +81,12 @@ jobs:
strategy:
fail-fast: true
matrix:
- os: ["ubuntu-latest", "macos-latest", "windows-latest"]
+ os: [ubuntu-latest, macos-latest, windows-latest, ubuntu-24.04-arm, macos-13]
python_version: ${{ fromJSON(needs.conf.outputs.supported_pythons) }}
use_conda: [true, false]
steps:
- uses: actions/checkout at v4
- - uses: conda-incubator/setup-miniconda at v2
+ - uses: conda-incubator/setup-miniconda at v3
with:
auto-update-conda: true
python-version: ${{ matrix.python_version }}
@@ -98,39 +98,14 @@ jobs:
shell: bash -l {0}
run: |
conda install -q --yes -c conda-forge --file ci/conda_requirements.txt
- pip install . --no-deps
+ pip install -e . --no-deps
conda list
- name: Install dependencies (pip)
if: ${{ !matrix.use_conda }}
shell: bash -l {0}
run: |
- pip install .
+ pip install -e .
conda list
- name: Run unit tests
shell: bash -l {0}
run: make test
-
- test-aarch64:
- name: Test (${{ needs.conf.outputs.latest_python }}, qemu::aarch64-centos)
- needs: ["conf", "lint", "doc", "test-all"]
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout at v4
- # setup-buildx-action uses the git context directly
- # but checklist wants the .git directory
- - name: Set up QEMU
- id: qemu
- uses: docker/setup-qemu-action at v1
- - name: Set up Docker Buildx
- uses: docker/setup-buildx-action at v1
- - name: Build and test for linux-aarch64
- id: docker_build
- uses: docker/build-push-action at v2
- with:
- context: .
- # ^ to use the local checkout, not the git context
- file: aarch64.Dockerfile
- cache-from: type=gha
- cache-to: type=gha,mode=max
- build-args: |
- PYTHON_VERSION=${{ env.latest_python }}
=====================================
.github/workflows/release.yml
=====================================
@@ -5,124 +5,8 @@ on:
tags:
- '*'
-env:
- earliest_python: "3.8"
- latest_python: "3.12"
- miniforge_version: "23.11.0-0"
- miniforge_variant: "Mambaforge"
-
jobs:
- release:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout at v2
- - name: Set up Python 3.8
- uses: actions/setup-python at v2
- with:
- python-version: 3.8
- - name: Build distribution
- run: |
- # set version from '${{ github.ref_name }}'
- export RELEASE_VERSION=${{ github.ref_name }}
- pip install numpy cython
- python setup.py sdist
-
- - name: Publish a Python distribution to PyPI
- if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
- uses: pypa/gh-action-pypi-publish at release/v1
- with:
- user: __token__
- password: ${{ secrets.PYPI_API_TOKEN }}
-
-# wheels are not working
-# cutting them out did not "just" work
-# getting a release out right now is more important than
-# precompiled builds.
- #jobs:
- # build_sdist:
- # name: Build sdist
- # runs-on: ubuntu-latest
- # steps:
- # - uses: actions/checkout at v4
- #
- # - name: Build distribution
- # run: |
- # pip install numpy cython
- # pipx run build --sdist
- #
- # - uses: actions/upload-artifact at v4
- # with:
- # name: cibw-sdist
- # path: dist/*.tar.gz
- #
- # # adapted from
- # # https://github.com/pypa/cibuildwheel/blob/main/examples/github-deploy.yml
- # build_wheels:
- # name: Build wheels (py ${{ matrix.pyver }}) ${{ matrix.os }}
- # runs-on: ${{ matrix.os }}
- # strategy:
- # matrix:
- # os: [ubuntu-latest, macos-13, macos-14]
- # pyver: ["37", "38", "39", "310", "311", "312"]
- #
- # steps:
- # - uses: actions/checkout at v4
- #
- # - name: Install Python packaging tools
- # run: |
- # pip install numpy cython
- # python -m pip install --upgrade pip setuptools wheel
- #
- # - name: Build wheels (py ${{ matrix.pyver }}) Linux
- # if: matrix.os == 'ubuntu-latest'
- # env:
- # CIBW_ARCHS_LINUX: "x86_64 aarch64"
- # CIBW_SKIP: "*-musllinux*"
- # CIBW_BUILD: "cp${{ matrix.pyver }}-*"
- #
- # uses: pypa/cibuildwheel at v2.17.0
- #
- # - name: Build wheels (py ${{ matrix.pyver }}) MacOS
- # if: matrix.os == 'macos-latest'
- # env:
- # CIBW_ARCHS_MACOS: "x86_64 arm64 universal2"
- # CIBW_BUILD: "cp${{ matrix.pyver }}-*"
- #
- # uses: pypa/cibuildwheel at v2.17.0
- #
- # - name: Build wheels (py ${{ matrix.pyver }}) Windows
- # if: matrix.os == 'windows-latest'
- # env:
- # CIBW_ARCHS_WINDOWS: "amd64 win32"
- # CIBW_BUILD: "cp${{ matrix.pyver }}-*"
- #
- # uses: pypa/cibuildwheel at v2.17.0
- #
- # - uses: actions/upload-artifact at v4
- # with:
- # name: cibw-wheels-${{ matrix.os }}-${{ matrix.pyver }}-${{ strategy.job-index }}
- # path: ./wheelhouse/*.whl
- #
- # release:
- # needs: [build_wheels, build_sdist]
- # runs-on: ubuntu-latest
- # environment: pypi
- # permissions:
- # id-token: write
- #
- # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
- # steps:
- # - uses: actions/download-artifact at v4
- # with:
- # name: cibw-*
- # path: dist
- # merge-multiple: true
- #
- # - name: Check artifacts
- # run: ls -lrt dist/
- #
- # - name: Publish Distribution
- # uses: pypa/gh-action-pypi-publish at v1.5.0
- # with:
- # user: __token__
- # password: ${{ secrets.PYPI_API_TOKEN }}
+ build_and_publish:
+ name: Build and publish to PyPI
+ uses: ./.github/workflows/wheels.yml
+ secrets: inherit
=====================================
.github/workflows/wheels.yml
=====================================
@@ -0,0 +1,97 @@
+name: Build Wheels
+
+on:
+ pull_request:
+ branches: [ master ]
+ paths:
+ - 'setup.py'
+ - 'pyproject.toml'
+ - 'biom/*.pyx'
+ - '.github/workflows/wheels.yml'
+ - '.github/workflows/release.yml'
+ workflow_call:
+ workflow_dispatch:
+
+jobs:
+ build_wheels:
+ name: Build wheels on ${{ matrix.os }}
+ runs-on: ${{ matrix.os }}
+ strategy:
+ matrix:
+ os: [ubuntu-latest, ubuntu-24.04-arm, windows-latest, macos-13, macos-14]
+ # The 5 runners correspond to 5 architectures. Details:
+ # https://cibuildwheel.pypa.io/en/stable/options/#archs
+ # The runners and architectures should be automatically associated. However, in
+ # case not in the future, they can be manually specified as follows:
+ # include:
+ # - os: ubuntu-latest
+ # cibw_archs: 'x86_64'
+ # - os: ubuntu-24.04-arm
+ # cibw_archs: 'aarch64'
+ # - os: windows-latest
+ # cibw_archs: 'AMD64'
+ # - os: macos-13
+ # cibw_archs: 'x86_64'
+ # - os: macos-latest
+ # cibw_archs: 'arm64'
+
+ steps:
+ - uses: actions/checkout at v4
+ with:
+ submodules: true
+
+ - name: Build wheels
+ uses: pypa/cibuildwheel at v2.23.3
+
+ - uses: actions/upload-artifact at v4
+ with:
+ name: wheels-${{ matrix.os }}-${{ strategy.job-index }}
+ path: ./wheelhouse/*.whl
+
+ build_sdist:
+ name: Build source distribution
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout at v4
+ with:
+ submodules: true
+
+ - name: Set up Python
+ uses: actions/setup-python at v5
+ with:
+ python-version: '3.9'
+
+ - name: Install build dependencies
+ run: |
+ pip install numpy cython build
+
+ - name: Build sdist
+ run: python -m build --sdist
+
+ - uses: actions/upload-artifact at v4
+ with:
+ name: sdist
+ path: dist/*.tar.gz
+
+ upload_pypi:
+ needs: [build_wheels, build_sdist]
+ runs-on: ubuntu-latest
+ # Only upload to PyPI on tagged commits
+ if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
+ steps:
+ - uses: actions/download-artifact at v4
+ with:
+ pattern: wheels-*
+ path: dist
+ merge-multiple: true
+
+ - uses: actions/download-artifact at v4
+ with:
+ name: sdist
+ path: dist
+
+ - name: Publish to PyPI
+ uses: pypa/gh-action-pypi-publish at release/v1
+ with:
+ user: __token__
+ password: ${{ secrets.PYPI_API_TOKEN }}
=====================================
ChangeLog.md
=====================================
@@ -1,6 +1,20 @@
BIOM-Format ChangeLog
=====================
+biom-2.1.17
+-----------
+
+Maintenance and build release, July 10th 2025.
+
+General Maintenance:
+
+* Python 3.7 and 3.8 removed from CI as they are [end-of-life](https://devguide.python.org/versions/). Python 3.13 added to CI. See PR[#986](https://github.com/biocore/biom-format/pull/986).
+* Construct wheels for pypi, see PR[#996](https://github.com/biocore/biom-format/pull/996)
+
+Performance improvements:
+
+* Decreased execution time of `import biom` by half with lazy imports. See PR[#987](https://github.com/biocore/biom-format/pull/987)
+
biom 2.1.16
-----------
=====================================
Makefile
=====================================
@@ -7,9 +7,9 @@
# ----------------------------------------------------------------------------
ifeq ($(WITH_DOCTEST), TRUE)
- TEST_COMMAND = python setup.py test -a --doctest-modules --doctest-glob='*.pyx'
+ TEST_COMMAND = pytest --doctest-modules --doctest-glob='*.pyx'
else
- TEST_COMMAND = python setup.py test
+ TEST_COMMAND = pytest
endif
.PHONY: doc lint test
@@ -19,7 +19,7 @@ test:
sh usage_tests.sh
lint:
- flake8 biom setup.py
+ flake8 biom setup.py --exclude=biom/tests/long_lines.py
doc:
$(MAKE) -C doc clean html
=====================================
aarch64.Dockerfile deleted
=====================================
@@ -1,15 +0,0 @@
-# this Dockerfile is directly adapted from
-# https://github.com/biocore/scikit-bio/blob/31123c6471dc62f45a55bfdff59c61a4850be367/aarch64.Dockerfile#LL1C1-L16C89
-FROM --platform=linux/arm64 condaforge/linux-anvil-aarch64
-RUN sudo yum update -y && \
- sudo yum install -y make git && \
- sudo yum clean all
-ARG PYTHON_VERSION
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate base && conda create -n testing -c conda-forge --yes python=$PYTHON_VERSION gxx_linux-aarch64"
-COPY . /work
-WORKDIR /work
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate testing && conda env update -q -f ci/conda_host_env.yml"
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate testing && conda install -q --yes --file ci/aarch64.conda_requirements.txt"
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate testing && pip install . --no-deps"
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate testing && conda list"
-RUN bash -c ". /opt/conda/etc/profile.d/conda.sh && conda activate testing && make test"
=====================================
biom/table.py
=====================================
@@ -172,8 +172,6 @@ Bacteria; Bacteroidetes 1.0 1.0 0.0 1.0
# -----------------------------------------------------------------------------
import numpy as np
-import scipy.stats
-import h5py
from copy import deepcopy
from datetime import datetime
from json import dumps as _json_dumps, JSONEncoder
@@ -184,7 +182,6 @@ from collections.abc import Hashable, Iterable
from numpy import ndarray, asarray, zeros, newaxis
from scipy.sparse import (coo_matrix, csc_matrix, csr_matrix, isspmatrix,
vstack, hstack, dok_matrix)
-import pandas as pd
import re
from biom.exception import (TableException, UnknownAxisError, UnknownIDError,
DisjointIDError)
@@ -398,7 +395,7 @@ class Table:
versions 2.0 and 2.1 are based on HDF5. For more information see [1]_
and [2]_
- Paramaters
+ Parameters
----------
data : array_like
An (N,M) sample by observation matrix represented as one of these
@@ -3234,6 +3231,8 @@ class Table:
o4 1.0 4.0 1.0
"""
+ import scipy.stats
+
def f(val, id_, _):
return scipy.stats.rankdata(val, method=method)
return self.transform(f, axis=axis, inplace=inplace)
@@ -4108,6 +4107,7 @@ html
>>> t = Table.from_hdf5(f, ids=["GG_OTU_1"],
... axis='observation') # doctest: +SKIP
"""
+ import h5py
if not isinstance(h5grp, (h5py.Group, h5py.File)):
raise ValueError("h5grp does not appear to be an HDF5 file or "
"group")
@@ -4341,6 +4341,7 @@ html
index = self.ids(axis='observation')
columns = self.ids()
+ import pandas as pd
if dense:
mat = self.matrix_data.toarray()
constructor = pd.DataFrame
@@ -4442,6 +4443,7 @@ html
O1 Bacteria Firmicutes
O2 Bacteria Bacteroidetes
"""
+ import pandas as pd
md = self.metadata(axis=axis)
if md is None:
raise KeyError("%s does not have metadata" % axis)
=====================================
biom/util.py
=====================================
@@ -41,7 +41,7 @@ __url__ = "http://biom-format.org"
__maintainer__ = "Daniel McDonald"
__email__ = "daniel.mcdonald at colorado.edu"
__format_version__ = (2, 1)
-__version__ = "2.1.16"
+__version__ = "2.1.17"
def generate_subsamples(table, n, axis='sample', by_id=False):
=====================================
ci/aarch64.conda_requirements.txt deleted
=====================================
@@ -1,7 +0,0 @@
-numpy >= 1.9.2
-pandas >= 0.20.0
-scipy >= 1.3.1
-h5py >= 2.2.0
-anndata
-click
-cython
=====================================
doc/conf.py
=====================================
@@ -57,15 +57,15 @@ master_doc = 'index'
# General information about the project.
project = 'biom-format'
-copyright = '2011-2024 The BIOM Format Development Team'
+copyright = '2011-2025 The BIOM Format Development Team'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#
# The full version, including alpha/beta/rc tags.
-version = "2.1.16"
-release = "2.1.16"
+version = "2.1.17"
+release = "2.1.17"
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
=====================================
pyproject.toml
=====================================
@@ -1,2 +1,91 @@
[build-system]
requires = ["setuptools","wheel", "numpy", "cython"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "biom_format"
+dynamic = ["version"]
+description = "Biological Observation Matrix (BIOM) format"
+requires-python = ">= 3.9"
+readme = "README.md"
+authors = [
+ {name = "Daniel McDonald", email = "damcdonald at ucsd.edu"},
+ {name = "Greg Caporaso"},
+ {name = "Jai Ram Rideout"},
+ {name = "Jose Clemente"},
+ {name = "Jorge Cañardo Alastuey"},
+ {name = "Michael Hall"},
+ {name = "Justin Kuczynski"},
+ {name = "Jesse Stombaugh"},
+ {name = "Doug Wendel"},
+ {name = "Andreas Wilke"},
+ {name = "Susan Huse"},
+ {name = "John Hufnagle"},
+ {name = "Folker Meyer"},
+ {name = "Rob Knight"}
+]
+license = { text = "BSD" }
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "License :: OSI Approved :: BSD License",
+ "Topic :: Scientific/Engineering :: Bio-Informatics",
+ "Topic :: Software Development :: Libraries :: Application Frameworks",
+ "Topic :: Software Development :: Libraries :: Python Modules",
+ "Programming Language :: Python",
+ "Programming Language :: Python :: 3",
+ "Programming Language :: Python :: 3 :: Only",
+ "Programming Language :: Python :: 3.9",
+ "Programming Language :: Python :: 3.10",
+ "Programming Language :: Python :: 3.11",
+ "Programming Language :: Python :: 3.12",
+ "Programming Language :: Python :: 3.13",
+ "Programming Language :: Python :: Implementation :: CPython",
+ "Operating System :: OS Independent",
+ "Operating System :: POSIX :: Linux",
+ "Operating System :: MacOS :: MacOS X",
+ "Operating System :: Microsoft :: Windows",
+]
+dependencies = [
+ "click",
+ "numpy >= 1.9.2",
+ "scipy >= 1.3.1",
+ "pandas >= 0.20.0",
+ "h5py",
+]
+
+[project.optional-dependencies]
+# Corresponds to the old `extras_require`
+test = [
+ "pytest>=6.2.4",
+ "pytest-cov",
+ "flake8",
+]
+hdf5 = ["h5py >= 2.2.0"]
+anndata = ["anndata"]
+
+[project.urls]
+Homepage = "http://www.biom-format.org"
+
+[project.scripts]
+biom = "biom.cli:cli"
+
+[tool.setuptools.packages.find]
+where = ["."]
+
+[tool.setuptools.dynamic]
+version = {attr = "biom.util.__version__"}
+
+[tool.cibuildwheel]
+test-command = "pytest --pyargs biom.tests"
+test-requires = ["pytest", "numpy"]
+
+# Skip 32-bit builds, PyPy, and musllinux
+skip = ["*-win32", "*-manylinux_i686", "pp*", "*-musllinux*"]
+
+# Python versions to build
+build = "cp39-* cp310-* cp311-* cp312-* cp313-*"
+
+[tool.pytest.ini_options]
+addopts = ["--ignore=biom/assets/exercise_api.py "]
+doctest_optionflags = [ "NORMALIZE_WHITESPACE", "IGNORE_EXCEPTION_DETAIL" ]
+testpaths = ["biom"]
=====================================
pytest.ini deleted
=====================================
@@ -1,4 +0,0 @@
-[pytest]
-addopts = --ignore=biom/assets/exercise_api.py
-doctest_optionflags = NORMALIZE_WHITESPACE IGNORE_EXCEPTION_DETAIL
-testpaths = biom
=====================================
setup.cfg deleted
=====================================
@@ -1,8 +0,0 @@
-[aliases]
-test=pytest
-
-[flake8]
-exclude=biom/tests/long_lines.py
-
-[options]
-python_requires = >=3.6
=====================================
setup.py
=====================================
@@ -8,65 +8,8 @@
# The full license is in the file COPYING.txt, distributed with this software.
# ----------------------------------------------------------------------------
-import sys
-
-from setuptools import setup, find_packages
+from setuptools import setup
from setuptools.extension import Extension
-from setuptools.command.test import test as TestCommand
-import numpy as np
-from Cython.Build import cythonize
-
-# Hack to prevent stupid "TypeError: 'NoneType' object is not callable" error
-# in multiprocessing/util.py _exit_function when running `python
-# setup.py test` (see
-# http://www.eby-sarna.com/pipermail/peak/2010-May/003357.html),
-# borrowed from https://github.com/getsentry/sentry/blob/master/setup.py
-for m in ('multiprocessing', 'logging'):
- try:
- __import__(m)
- except ImportError:
- pass
-
-__author__ = "Daniel McDonald"
-__copyright__ = "Copyright 2011-2020, The BIOM Format Development Team"
-__credits__ = ["Greg Caporaso", "Daniel McDonald", "Jose Clemente",
- "Jai Ram Rideout", "Jorge Cañardo Alastuey", "Michael Hall"]
-__license__ = "BSD"
-__version__ = "2.1.16"
-__maintainer__ = "Daniel McDonald"
-__email__ = "mcdonadt at colorado.edu"
-
-
-# derived from https://docs.pytest.org/en/3.8.0/goodpractices.html
-class PyTest(TestCommand):
- user_options = [("pytest-args=", "a", "Arguments to pass to pytest")]
-
- def initialize_options(self):
- TestCommand.initialize_options(self)
- self.pytest_args = ""
-
- def run_tests(self):
- try:
- import numpy
- try:
- # NumPy 1.14 changed repr output breaking our doctests,
- # request the legacy 1.13 style
- numpy.set_printoptions(legacy="1.13")
- except TypeError:
- # Old Numpy, output should be fine as it is :)
- # TypeError: set_printoptions() got an unexpected
- # keyword argument 'legacy'
- pass
- except ImportError:
- numpy = None
-
- import shlex
-
- # import here, cause outside the eggs aren't loaded
- import pytest
- errno = pytest.main(shlex.split(self.pytest_args))
- sys.exit(errno)
-
long_description = """BIOM: Biological Observation Matrix
http://www.biom-format.org
@@ -79,81 +22,23 @@ Folker Meyer, Rob Knight, J Gregory Caporaso
GigaScience 2012, 1:7.
"""
-classes = """
- Development Status :: 4 - Beta
- License :: OSI Approved :: BSD License
- Topic :: Scientific/Engineering :: Bio-Informatics
- Topic :: Software Development :: Libraries :: Application Frameworks
- Topic :: Software Development :: Libraries :: Python Modules
- Programming Language :: Python
- Programming Language :: Python :: 3
- Programming Language :: Python :: 3 :: Only
- Programming Language :: Python :: 3.6
- Programming Language :: Python :: 3.7
- Programming Language :: Python :: 3.8
- Programming Language :: Python :: 3.9
- Programming Language :: Python :: 3.10
- Programming Language :: Python :: 3.11
- Programming Language :: Python :: 3.12
- Programming Language :: Python :: Implementation :: CPython
- Operating System :: OS Independent
- Operating System :: POSIX :: Linux
- Operating System :: MacOS :: MacOS X
- Operating System :: Microsoft :: Windows
-"""
-classifiers = [s.strip() for s in classes.split('\n') if s]
-
-# Dealing with Cython
-ext = '.pyx'
-extensions = [Extension("biom._filter",
- ["biom/_filter" + ext],
- include_dirs=[np.get_include()]),
- Extension("biom._transform",
- ["biom/_transform" + ext],
- include_dirs=[np.get_include()]),
- Extension("biom._subsample",
- ["biom/_subsample" + ext],
- include_dirs=[np.get_include()])]
-extensions = cythonize(extensions)
-install_requires = [
- "click",
- "numpy >= 1.9.2",
- "scipy >= 1.3.1",
- 'pandas >= 0.20.0',
- "h5py",
-]
+def get_extensions():
+ import numpy as np
+ from Cython.Build import cythonize
-if sys.version_info[0] < 3:
- raise SystemExit("Python 2.7 is no longer supported")
+ extensions = [
+ Extension("biom._filter",
+ ["biom/_filter.pyx"],
+ include_dirs=[np.get_include()]),
+ Extension("biom._transform",
+ ["biom/_transform.pyx"],
+ include_dirs=[np.get_include()]),
+ Extension("biom._subsample",
+ ["biom/_subsample.pyx"],
+ include_dirs=[np.get_include()]),
+ ]
+ return cythonize(extensions, force=True)
-setup(name='biom-format',
- version=__version__,
- description='Biological Observation Matrix (BIOM) format',
- long_description=long_description,
- license=__license__,
- author=__maintainer__,
- author_email=__email__,
- maintainer=__maintainer__,
- maintainer_email=__email__,
- url='http://www.biom-format.org',
- packages=find_packages(),
- tests_require=[
- 'pytest>=6.2.4',
- 'pytest-cov',
- 'flake8',
- ],
- include_package_data=True,
- ext_modules=extensions,
- include_dirs=[np.get_include()],
- install_requires=install_requires,
- extras_require={'hdf5': ["h5py >= 2.2.0"],
- 'anndata': ["anndata"],
- },
- classifiers=classifiers,
- cmdclass={"pytest": PyTest},
- entry_points='''
- [console_scripts]
- biom=biom.cli:cli
- ''')
+setup(ext_modules=get_extensions())
View it on GitLab: https://salsa.debian.org/med-team/python-biom-format/-/commit/5a325f7c1bfa8e2f167862e69de570f750bbbc39
--
View it on GitLab: https://salsa.debian.org/med-team/python-biom-format/-/commit/5a325f7c1bfa8e2f167862e69de570f750bbbc39
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20251104/1d61b7ab/attachment-0001.htm>
More information about the debian-med-commit
mailing list