Skip to content

Commit

Permalink
chore: add conda recipe
Browse files Browse the repository at this point in the history
  • Loading branch information
XuehaiPan committed Jul 10, 2022
1 parent 85ecc2f commit fc1c898
Show file tree
Hide file tree
Showing 2 changed files with 72 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ cpplint-install:
$(call check_pip_install, cpplint)

clang-format-install:
command -v clang-format-11 || sudo apt-get install -y clang-format-11
command -v clang-format || sudo apt-get install -y clang-format

clang-tidy-install:
command -v clang-tidy || sudo apt-get install -y clang-tidy
Expand Down Expand Up @@ -85,7 +85,7 @@ cpplint: cpplint-install
$(PYTHON) -m cpplint $(CXX_FILES)

clang-format: clang-format-install
clang-format-11 --style=file -i $(CXX_FILES) -n --Werror
clang-format --style=file -i $(CXX_FILES) -n --Werror

# Documentation

Expand All @@ -111,7 +111,7 @@ lint: flake8 py-format mypy clang-format cpplint addlicense
format: py-format-install clang-format-install addlicense-install
$(PYTHON) -m isort --project torchopt $(PYTHON_FILES)
$(PYTHON) -m yapf --in-place --recursive $(PYTHON_FILES)
clang-format-11 -style=file -i $(CXX_FILES)
clang-format -style=file -i $(CXX_FILES)
addlicense -c $(COPYRIGHT) -l apache -y 2022 $(SOURCE_FOLDERS)

clean-py:
Expand Down
69 changes: 69 additions & 0 deletions conda-recipe.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Create virtual environment with command:
#
# conda env create --file conda-recipe.yaml
#

name: torchopt

channels:
- pytorch
- defaults
- nvidia
- conda-forge

dependencies:
- python = 3.8

# Learning
- pytorch::pytorch = 1.11
- pytorch::torchvision
- jax
- jaxlib
- tensorboard
- wandb
- pip:
- functorch

# Device select
- nvidia::cudatoolkit = 11.3.1
- cudnn

# Build toolkit
- cmake >= 3.4
- make
- cxx-compiler
- gxx >= 6.0, < 12.0
- nvidia/label/cuda-11.3.1::cuda-minimal-build
- pybind11

# Misc
- pip
- typing-extensions
- numpy
- matplotlib-base
- seaborn
- python-graphviz
- pillow

# Documentation
- sphinx
- sphinxcontrib-spelling
- sphinx-autobuild
- sphinx-copybutton
- sphinx_rtd_theme

# # Testing
# - pytest
# - pytest-cov
# - pytest-xdist
# - isort
# - yapf
# - mypy
# - flake8
# - flake8-bugbear
# - doc8
# - pydocstyle
# - pyenchant
# - clang-format
# - clang-tools # clang-tidy
# - cpplint

0 comments on commit fc1c898

Please # to comment.