-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #28 from N3PDF/migrate_tf2
Migrate TF1 to TF2
- Loading branch information
Showing
11 changed files
with
154 additions
and
110 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 |
---|---|---|
@@ -1,19 +1,44 @@ | ||
from setuptools import setup, find_packages | ||
from os import path | ||
import os | ||
import re | ||
|
||
this_directory = path.abspath(path.dirname(__file__)) | ||
with open(path.join(this_directory, "README.md"), encoding="utf-8") as f: | ||
|
||
requirements = ['numpy', 'cma'] | ||
if os.environ.get('READTHEDOCS') != 'True': | ||
requirements.append('tensorflow>2.1*') | ||
PACKAGE = 'evolutionary_keras' | ||
|
||
this_directory = os.path.abspath(os.path.dirname(__file__)) | ||
with open(os.path.join(this_directory, "README.md"), encoding="utf-8") as f: | ||
long_description = f.read() | ||
|
||
def get_version(): | ||
""" Gets the version from the package's __init__ file | ||
if there is some problem, let it happily fail """ | ||
VERSIONFILE = os.path.join('src', PACKAGE, '__init__.py') | ||
initfile_lines = open(VERSIONFILE, 'rt').readlines() | ||
VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" | ||
for line in initfile_lines: | ||
mo = re.search(VSRE, line, re.M) | ||
if mo: | ||
return mo.group(1) | ||
|
||
setup( | ||
name="evolutionary_keras", | ||
version="1.0.1", | ||
version=get_version(), | ||
author="S. Carrazza, J. Cruz-Martinez, Roy Stegeman", | ||
author_email="[email protected], [email protected]", | ||
url="https://github.com/N3PDF/evolutionary_keras", | ||
package_dir={"": "src"}, | ||
packages=find_packages("src"), | ||
install_requires=["numpy", "keras", "sphinx_rtd_theme", "recommonmark", "cma"], | ||
zip_safe=False, | ||
install_requires=requirements, | ||
extras_require={ | ||
'docs' : [ | ||
'sphinx_rtd_theme', | ||
'recommonmark', | ||
], | ||
}, | ||
python_requires=">=3.6", | ||
descriptions="An evolutionary algorithm implementation for Keras", | ||
long_description=long_description, | ||
|
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 |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = "1.0.0" | ||
__version__ = "1.9" |
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
Oops, something went wrong.