Skip to content

Commit

Permalink
Alternate Setup Cleanup (#182)
Browse files Browse the repository at this point in the history
* overhaul setup.py

* fix typos

* torch min version

* readd tensorboardx

* move envs to seperate extras

* turn off quiet

* whitespace

* make sure extras[all] includes everything

* add tensorboard require

* tweak comment

* move torch to core

* kinda back to the original-ish

* another try

* try 2020-resolver

* another attempt at getting CI to work

* simplify code for combining dependencies

* separate dependencies for environments

* fix major version numbers for some dependencies

Co-authored-by: Justin Terry <justinkterry@gmail.com>
  • Loading branch information
cpnota and jkterry1 committed Nov 4, 2020
1 parent 9c44d41 commit db2d1da
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 25 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ branches:
before_install:
- sudo apt-get install swig
install:
- pip install torch==1.5.1+cpu torchvision==0.6.1+cpu -f https://download.pytorch.org/whl/torch_stable.html
- pip install -q -e .["dev"]
- pip install torch==1.5.1+cpu -f https://download.pytorch.org/whl/torch_stable.html
- pip install -e .["dev"]
script:
- make lint
- make test
58 changes: 35 additions & 23 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,32 @@
from setuptools import setup, find_packages


extras = {
"atari": [
"atari_py~=0.2.0", # atari environments
"Pillow~=7.1.2", # rendering library
],
"box2d": [
"box2d-py~=2.3.5", # box3d physics environments
],
"pybullet": [
"pybullet>=3.0.6", # open-source robotics environments
],
"test": [
"pylint>=2.6.0", # code quality tool
"torch-testing>=0.0.2", # pytorch assertion library
],
"docs": [
"sphinx>=3.2.1", # documentation library
"sphinx-autobuild>=2020.9.1", # documentation live reload
"sphinx-rtd-theme>=0.5.0", # documentation theme
"sphinx-automodapi>=0.13", # autogenerate docs for modules
]
}

extras["all"] = extras["atari"] + extras["box2d"] + extras["pybullet"]
extras["dev"] = extras["all"] + extras["test"] + extras["docs"]

setup(
name="autonomous-learning-library",
version="0.6.2",
Expand All @@ -22,28 +49,13 @@
],
},
install_requires=[
"gym[atari,box2d]", # common environments
"numpy", # math library
"matplotlib", # plotting library
"opencv-python>=3.,<4.",# used by atari wrappers
"pybullet", # continuous environments
"tensorboardX", # tensorboard compatibility
"gym~=0.17.2", # common environment interface
"numpy>=1.18.0", # math library
"matplotlib>=3.3.0", # plotting library
"opencv-python~=3.4", # used by atari wrappers
"torch~=1.5.1", # core deep learning library
"tensorboard>=2.3.0", # logging and visualization
"tensorboardX>=2.1.0", # tensorboard/pytorch compatibility
],
extras_require={
"pytorch": [
"torch", # deep learning
"torchvision", # additional utilities
"tensorboard" # visualizations
],
"docs": [
"sphinx",
"sphinx-autobuild",
"sphinx-rtd-theme",
"sphinx-automodapi"
],
"dev": [
"pylint", # code quality tool
"torch-testing" # pytorch assertion library
]
},
extras_require=extras
)

0 comments on commit db2d1da

Please sign in to comment.