1
1
#!/usr/bin/env python
2
- # Copyright The GeoML Team
3
- #
4
- # Licensed under the Apache License, Version 2.0 (the "License");
5
- # you may not use this file except in compliance with the License.
6
- # You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS,
12
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- # See the License for the specific language governing permissions and
14
- # limitations under the License.
15
2
import os
16
3
from io import open
17
4
18
- from setuptools import setup , find_packages , Command
5
+ from setuptools import Command , find_packages , setup
19
6
20
7
try :
21
8
import builtins
22
9
except ImportError :
23
10
import __builtin__ as builtins
24
11
25
12
PATH_ROOT = os .path .dirname (__file__ )
26
- builtins .__STOCHMAN_SETUP__ = True
13
+ builtins .__TORCHPLOT_SETUP__ = True
27
14
28
15
import torchplot
29
16
@@ -43,28 +30,27 @@ def run(self):
43
30
os .system ("rm -vrf ./build ./dist ./*.pyc ./*.tgz ./*.egg-info" )
44
31
45
32
46
- PATH_ROOT = os .path .dirname (__file__ )
33
+ with open ("README.md" , encoding = "utf-8" ) as f :
34
+ long_description = f .read ()
47
35
48
36
49
- def load_readme (path_dir = PATH_ROOT ):
50
- with open (os .path .join (path_dir , "README.md" ), encoding = "utf-8" ) as f :
51
- long_description = f .read ()
52
- return long_description
37
+ with open ("requirements.txt" , "r" ) as reqs :
38
+ requirements = reqs .read ().split ()
53
39
54
40
55
41
setup (
56
42
name = "torchplot" ,
57
43
version = torchplot .__version__ ,
58
44
description = torchplot .__docs__ ,
59
- long_description = load_readme ( PATH_ROOT ) ,
45
+ long_description = long_description ,
60
46
long_description_content_type = "text/markdown" ,
61
47
author = torchplot .__author__ ,
62
48
author_email = torchplot .__author_email__ ,
63
49
license = torchplot .__license__ ,
64
50
packages = find_packages (exclude = ["tests" , "tests/*" ]),
65
51
python_requires = ">=3" ,
66
- install_requires = [ "torch" , "matplotlib" ] ,
67
- download_url = "https://github.com/CenterBioML/torchplot/archive/0.1.4 .zip" ,
52
+ install_requires = requirements ,
53
+ download_url = "https://github.com/CenterBioML/torchplot/archive/0.1.5 .zip" ,
68
54
classifiers = [
69
55
"Environment :: Console" ,
70
56
"Natural Language :: English" ,
0 commit comments