File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -80,6 +80,12 @@ def setup_cuda():
8080def setup_conda_pytorch_constraint () -> List [str ]:
8181 pytorch_constraint = f"- pytorch=={ PYTORCH_VERSION } "
8282 os .environ ["CONDA_PYTORCH_CONSTRAINT" ] = pytorch_constraint
83+ if pytorch_major_minor < (2 , 2 ):
84+ os .environ ["CONDA_PYTORCH_MKL_CONSTRAINT" ] = "- mkl!=2024.1.0"
85+ os .environ ["SETUPTOOLS_CONSTRAINT" ] = "- setuptools<70"
86+ else :
87+ os .environ ["CONDA_PYTORCH_MKL_CONSTRAINT" ] = ""
88+ os .environ ["SETUPTOOLS_CONSTRAINT" ] = "- setuptools"
8389 os .environ ["CONDA_PYTORCH_BUILD_CONSTRAINT" ] = pytorch_constraint
8490 os .environ ["PYTORCH_VERSION_NODOT" ] = PYTORCH_VERSION .replace ("." , "" )
8591
Original file line number Diff line number Diff line change @@ -12,8 +12,9 @@ requirements:
1212
1313 host :
1414 - python
15- - setuptools
15+ {{ environ.get('SETUPTOOLS_CONSTRAINT') }}
1616 {{ environ.get('CONDA_PYTORCH_BUILD_CONSTRAINT') }}
17+ {{ environ.get('CONDA_PYTORCH_MKL_CONSTRAINT') }}
1718 {{ environ.get('CONDA_CUDATOOLKIT_CONSTRAINT') }}
1819 {{ environ.get('CONDA_CPUONLY_FEATURE') }}
1920
You can’t perform that action at this time.
0 commit comments