diff --git a/pyproject.toml b/pyproject.toml index c77e2fea..84233615 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,4 +1,62 @@ +[build-system] +requires = ["pdm-backend"] +build-backend = "pdm.backend" + +[project] +name = "timm" +authors = [ + {name = "Ross Wightman", email = "ross@huggingface.co"}, +] +description = "PyTorch Image Models" +readme = "README.md" +requires-python = ">=3.8" +keywords = ["pytorch", "image-classification"] +license = {text = "Apache-2.0"} +classifiers = [ + 'Development Status :: 4 - Beta', + 'Intended Audience :: Education', + 'Intended Audience :: Science/Research', + 'License :: OSI Approved :: Apache Software License', + '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', + 'Topic :: Scientific/Engineering', + 'Topic :: Scientific/Engineering :: Artificial Intelligence', + 'Topic :: Software Development', + 'Topic :: Software Development :: Libraries', + 'Topic :: Software Development :: Libraries :: Python Modules', +] +dependencies = [ + 'torch', + 'torchvision', + 'pyyaml', + 'huggingface_hub', + 'safetensors', +] +dynamic = ["version"] + +[project.urls] +homepage = "https://github.com/huggingface/pytorch-image-models" +documentation = "https://huggingface.co/docs/timm/en/index" +repository = "https://github.com/huggingface/pytorch-image-models" + +[tool.pdm.dev-dependencies] +test = [ + 'pytest', + 'pytest-timeout', + 'pytest-xdist', + 'pytest-forked', + 'expecttest', +] + +[tool.pdm.version] +source = "file" +path = "timm/version.py" + [tool.pytest.ini_options] +testpaths = ['tests'] markers = [ "base: marker for model tests using the basic setup", "cfg: marker for model tests checking the config", @@ -6,9 +64,4 @@ markers = [ "features: marker for model tests checking feature extraction", "fxforward: marker for model tests using torch fx (only forward)", "fxbackward: marker for model tests using torch fx (only backward)", -] - -[tool.black] -line-length = 120 -target-version = ['py37', 'py38', 'py39', 'py310', 'py311'] -skip-string-normalization = true +] \ No newline at end of file diff --git a/setup.cfg b/setup.cfg index 6289c6c3..55b106b0 100644 --- a/setup.cfg +++ b/setup.cfg @@ -3,3 +3,7 @@ conda_name_differences = 'torch:pytorch' channels = pytorch noarch = True + +[metadata] + +url = "https://github.com/huggingface/pytorch-image-models" \ No newline at end of file diff --git a/setup.py b/setup.py deleted file mode 100644 index f5148455..00000000 --- a/setup.py +++ /dev/null @@ -1,50 +0,0 @@ -""" Setup -""" -from setuptools import setup, find_packages -from codecs import open -from os import path - -here = path.abspath(path.dirname(__file__)) - -# Get the long description from the README file -with open(path.join(here, 'README.md'), encoding='utf-8') as f: - long_description = f.read() - -exec(open('timm/version.py').read()) -setup( - name='timm', - version=__version__, - description='PyTorch Image Models', - long_description=long_description, - long_description_content_type='text/markdown', - url='https://github.com/huggingface/pytorch-image-models', - author='Ross Wightman', - author_email='ross@huggingface.co', - classifiers=[ - # How mature is this project? Common values are - # 3 - Alpha - # 4 - Beta - # 5 - Production/Stable - 'Development Status :: 4 - Beta', - 'Intended Audience :: Education', - 'Intended Audience :: Science/Research', - 'License :: OSI Approved :: Apache Software License', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: 3.9', - 'Programming Language :: Python :: 3.10', - 'Programming Language :: Python :: 3.11', - 'Topic :: Scientific/Engineering', - 'Topic :: Scientific/Engineering :: Artificial Intelligence', - 'Topic :: Software Development', - 'Topic :: Software Development :: Libraries', - 'Topic :: Software Development :: Libraries :: Python Modules', - ], - - # Note that this is a string of words separated by whitespace, not a list. - keywords='pytorch pretrained models efficientnet mobilenetv3 mnasnet resnet vision transformer vit', - packages=find_packages(exclude=['convert', 'tests', 'results']), - include_package_data=True, - install_requires=['torch >= 1.7', 'torchvision', 'pyyaml', 'huggingface_hub', 'safetensors'], - python_requires='>=3.7', -) - diff --git a/timm/version.py b/timm/version.py index 350de40f..8a2d2f68 100644 --- a/timm/version.py +++ b/timm/version.py @@ -1 +1 @@ -__version__ = '0.9.15dev0' +__version__ = '0.9.16dev0'