forked from apache/tvm
-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CONDA] Revamp conda recipe. (apache#6732)
* [CONDA] Revamp conda recipe. - Combines two packages into a single recipe. - Enable windows build. - Better packaging hash tag (use git string). * Address comment
- Loading branch information
Showing
26 changed files
with
296 additions
and
199 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
:: Licensed to the Apache Software Foundation (ASF) under one | ||
:: or more contributor license agreements. See the NOTICE file | ||
:: distributed with this work for additional information | ||
:: regarding copyright ownership. The ASF licenses this file | ||
:: to you under the Apache License, Version 2.0 (the | ||
:: "License"); you may not use this file except in compliance | ||
:: with the License. You may obtain a copy of the License at | ||
:: | ||
:: http://www.apache.org/licenses/LICENSE-2.0 | ||
:: | ||
:: Unless required by applicable law or agreed to in writing, | ||
:: software distributed under the License is distributed on an | ||
:: "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
:: KIND, either express or implied. See the License for the | ||
:: specific language governing permissions and limitations | ||
:: under the License. | ||
|
||
conda build --output-folder=conda/pkg conda/recipe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
:: Licensed to the Apache Software Foundation (ASF) under one | ||
:: or more contributor license agreements. See the NOTICE file | ||
:: distributed with this work for additional information | ||
:: regarding copyright ownership. The ASF licenses this file | ||
:: to you under the Apache License, Version 2.0 (the | ||
:: "License"); you may not use this file except in compliance | ||
:: with the License. You may obtain a copy of the License at | ||
:: | ||
:: http://www.apache.org/licenses/LICENSE-2.0 | ||
:: | ||
:: Unless required by applicable law or agreed to in writing, | ||
:: software distributed under the License is distributed on an | ||
:: "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
:: KIND, either express or implied. See the License for the | ||
:: specific language governing permissions and limitations | ||
:: under the License. | ||
echo on | ||
|
||
rd /s /q build | ||
mkdir build | ||
cd build | ||
|
||
cmake ^ | ||
-DCMAKE_PREFIX_PATH=%LIBRARY_PREFIX% ^ | ||
-DCMAKE_INSTALL_PREFIX:PATH=%LIBRARY_PREFIX% ^ | ||
-DUSE_LLVM=ON ^ | ||
-DUSE_RPC=ON ^ | ||
-DUSE_CPP_RPC=ON ^ | ||
-DUSE_SORT=ON ^ | ||
-DUSE_RANDOM=ON ^ | ||
-DUSE_GRAPH_RUNTIME_DEBUG=ON ^ | ||
-DINSTALL_DEV=ON ^ | ||
%SRC_DIR% | ||
|
||
cd .. | ||
:: defer build to install stage to avoid rebuild. | ||
:: sometimes windows msbuild is not very good at file | ||
:: caching and install will results in a rebuild |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,9 +16,9 @@ | |
# under the License. | ||
|
||
python: | ||
- 3.5 | ||
- 3.6 | ||
- 3.7 | ||
- 3.8 | ||
|
||
cuda: | ||
- False |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
:: Licensed to the Apache Software Foundation (ASF) under one | ||
:: or more contributor license agreements. See the NOTICE file | ||
:: distributed with this work for additional information | ||
:: regarding copyright ownership. The ASF licenses this file | ||
:: to you under the Apache License, Version 2.0 (the | ||
:: "License"); you may not use this file except in compliance | ||
:: with the License. You may obtain a copy of the License at | ||
:: | ||
:: http://www.apache.org/licenses/LICENSE-2.0 | ||
:: | ||
:: Unless required by applicable law or agreed to in writing, | ||
:: software distributed under the License is distributed on an | ||
:: "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
:: KIND, either express or implied. See the License for the | ||
:: specific language governing permissions and limitations | ||
:: under the License. | ||
|
||
cmake --build build --config Release --target install | ||
|
||
:: Copy files into library bin so that they can be found | ||
cp %LIBRARY_LIB%\tvm.dll %LIBRARY_BIN%\tvm.dll | ||
cp %LIBRARY_LIB%\tvm_runtime.dll %LIBRARY_BIN%\tvm_runtime.dll |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
:: Licensed to the Apache Software Foundation (ASF) under one | ||
:: or more contributor license agreements. See the NOTICE file | ||
:: distributed with this work for additional information | ||
:: regarding copyright ownership. The ASF licenses this file | ||
:: to you under the Apache License, Version 2.0 (the | ||
:: "License"); you may not use this file except in compliance | ||
:: with the License. You may obtain a copy of the License at | ||
:: | ||
:: http://www.apache.org/licenses/LICENSE-2.0 | ||
:: | ||
:: Unless required by applicable law or agreed to in writing, | ||
:: software distributed under the License is distributed on an | ||
:: "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
:: KIND, either express or implied. See the License for the | ||
:: specific language governing permissions and limitations | ||
:: under the License. | ||
echo on | ||
|
||
cd %SRC_DIR%\python | ||
%PYTHON% setup.py install --single-version-externally-managed --record=%SRC_DIR%\record.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you under the Apache License, Version 2.0 (the | ||
# "License"); you may not use this file except in compliance | ||
# with the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, | ||
# software distributed under the License is distributed on an | ||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
# KIND, either express or implied. See the License for the | ||
# specific language governing permissions and limitations | ||
# under the License. | ||
|
||
{% set version = '0.8.dev0' %} | ||
{% set pkg_name = 'tvm' %} | ||
{% set cuda_tag = cuda_version | replace('.', '') %} # [cuda] | ||
{% set pkg_name = pkg_name + '-cu' + cuda_tag %} # [cuda] | ||
{% set build_tag = environ.get('GIT_BUILD_STR', 'unknown') %} | ||
{% set build_tag = build_tag + '_h' + PKG_HASH + '_' + PKG_BUILDNUM %} | ||
|
||
package: | ||
name: {{ pkg_name }}-package | ||
version: {{ version }} | ||
|
||
source: | ||
path: '../..' | ||
|
||
build: | ||
number: 0 | ||
include_recipe: False | ||
missing_dso_whitelist: | ||
- "*libcuda.*" # [linux] | ||
|
||
requirements: | ||
build: | ||
# The anaconda compilers for OS X are old an annoying | ||
# so we rely on the platform ones for now | ||
- {{ compiler('cxx') }} # [not osx] | ||
- cmake | ||
- make # [not win] | ||
host: | ||
- zlib | ||
- llvmdev ==10.0.0 | ||
|
||
outputs: | ||
- name: {{ pkg_name }}-libs | ||
script: install_libtvm.bat # [win] | ||
script: install_libtvm.sh # [not win] | ||
string: {{ build_tag }} | ||
requirements: | ||
build: | ||
- {{ compiler('cxx') }} | ||
- cmake | ||
- git | ||
- make # [not win] | ||
host: | ||
- zlib | ||
- llvmdev ==10.0.0 | ||
- {{ pin_compatible('cudatoolkit', lower_bound=cuda_version, max_pin='x.x') }} # [cuda] | ||
- {{ pin_compatible('cudnn', lower_bound='7.6.0', max_pin='x') }} # [cuda] | ||
run: | ||
- llvmdev ==10.0.0 | ||
- {{ pin_compatible('cudatoolkit', lower_bound=cuda_version, max_pin='x.x') }} # [cuda] | ||
- {{ pin_compatible('cudnn', lower_bound='7.6.0', max_pin='x') }} # [cuda] | ||
|
||
- name: {{ pkg_name }} | ||
script: install_tvm_python.sh # [not win] | ||
script: install_tvm_python.bat # [win] | ||
string: {{ build_tag }}_py{{ PY_VER | replace('.', '')}} | ||
requirements: | ||
host: | ||
- python | ||
- setuptools | ||
run: | ||
- python | ||
- decorator | ||
- psutil | ||
- {{ pin_compatible('numpy') }} | ||
- {{ pin_subpackage(pkg_name + '-libs', exact=True) }} | ||
|
||
about: | ||
home: https://tvm.apache.org | ||
license: Apache2 | ||
summary: An End to End Deep Learning Compiler Stack for CPUs, GPUs and accelerators. |
Oops, something went wrong.