Skip to content

Commit e49cf42

Browse files
committed
Pin Keras 2 for new TF versions
1 parent ed912c6 commit e49cf42

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import setuptools
22

3-
tensorflow = ["tensorflow>=2.6"]
3+
tensorflow = ["tensorflow>=2.6", "tf-keras~=2.16"]
44
pytorch = ["torch>=1.11", "torchdata"]
55
sklearn = ["scikit-learn>=1.0"]
66
cloud = ["tiledb-cloud"]

tiledb/ml/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
# https://pypi.org/project/setuptools-scm/#:~:text=Retrieving%20package%20version%20at%20runtime, when we stop
55
# supporting Python 3.7. We the aforementioned change, we can avoid the 100ms overhead during import of the package.
66

7+
import os
8+
os.environ["TF_USE_LEGACY_KERAS"] = 1
9+
710
try:
811
__version__ = get_distribution("tiledb-ml").version
912
except DistributionNotFound:

0 commit comments

Comments
 (0)