Skip to content

Commit 062a7aa

Browse files
authored
Build against TF 2.15 (#2857)
* Built against TF2.15
1 parent 48f1125 commit 062a7aa

13 files changed

+38
-33
lines changed

.github/workflows/release.yml

+15-11
Original file line numberDiff line numberDiff line change
@@ -43,22 +43,24 @@ jobs:
4343
matrix:
4444
# To switch on windows-2022/latest, please verify the bazel version:
4545
# https://github.com/bazelbuild/bazel/issues/14232#issuecomment-1011247429
46-
os: ['macos-12', 'windows-2019', 'ubuntu-20.04']
46+
os: ['macos-12', 'ubuntu-20.04']
47+
# Removing windows builds due to broken upstream package https://github.com/tensorflow/tensorflow/issues/61830
48+
# os: ['macos-12', 'windows-2019', 'ubuntu-20.04']
4749
py-version: ['3.9', '3.10', '3.11']
48-
tf-version: ['2.12.1', '2.13.0', '2.14.0']
50+
tf-version: ['2.13.1', '2.14.0', '2.15.0']
4951
cpu: ['x86']
5052
include:
5153
- os: 'macos-12'
5254
cpu: 'arm64'
53-
tf-version: '2.14.0'
55+
tf-version: '2.15.0'
5456
py-version: '3.9'
5557
- os: 'macos-12'
5658
cpu: 'arm64'
57-
tf-version: '2.14.0'
59+
tf-version: '2.15.0'
5860
py-version: '3.10'
5961
- os: 'macos-12'
6062
cpu: 'arm64'
61-
tf-version: '2.14.0'
63+
tf-version: '2.15.0'
6264
py-version: '3.11'
6365
fail-fast: false
6466
steps:
@@ -69,7 +71,7 @@ jobs:
6971
script: |
7072
const commit_details = await github.git.getCommit({owner: context.repo.owner, repo: context.repo.repo, commit_sha: context.sha});
7173
return commit_details.data.author.date
72-
- if: matrix.tf-version != '2.14.0'
74+
- if: matrix.tf-version != '2.15.0'
7375
shell: bash
7476
run: echo "SKIP_CUSTOM_OP_TESTS=--skip-custom-ops" >> $GITHUB_ENV
7577
- if: github.event_name == 'push'
@@ -102,22 +104,24 @@ jobs:
102104
runs-on: ubuntu-20.04
103105
strategy:
104106
matrix:
105-
os: ['macOS', 'Windows', 'Linux']
107+
os: ['macOS', 'Linux']
108+
# Removing windows builds due to broken upstream package https://github.com/tensorflow/tensorflow/issues/61830
109+
# os: ['macOS', 'Windows', 'Linux']
106110
py-version: ['3.9', '3.10', '3.11']
107-
tf-version: ['2.14.0']
111+
tf-version: ['2.15.0']
108112
cpu: ['x86']
109113
include:
110114
- os: 'macOS'
111115
cpu: 'arm64'
112-
tf-version: '2.14.0'
116+
tf-version: '2.15.0'
113117
py-version: '3.9'
114118
- os: 'macOS'
115119
cpu: 'arm64'
116-
tf-version: '2.14.0'
120+
tf-version: '2.15.0'
117121
py-version: '3.10'
118122
- os: 'macOS'
119123
cpu: 'arm64'
120-
tf-version: '2.14.0'
124+
tf-version: '2.15.0'
121125
py-version: '3.11'
122126
fail-fast: false
123127
if: (github.event_name == 'push' && github.ref == 'refs/heads/master') || github.event_name == 'release'

CONTRIBUTING.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,8 @@ conda activate my_dev_environement
173173
Just run from the root:
174174

175175
```bash
176-
pip install tensorflow==2.14.0
177-
# you can use "pip install tensorflow-cpu==2.14.0" too if you're not testing on gpu.
176+
pip install tensorflow==2.15.0
177+
# you can use "pip install tensorflow-cpu==2.15.0" too if you're not testing on gpu.
178178
pip install -e ./
179179
```
180180

@@ -262,7 +262,7 @@ If you need a custom C++/Cuda op for your test, compile your ops with
262262

263263
```bash
264264
python configure.py
265-
pip install tensorflow==2.14.0 -e ./ -r tools/install_deps/pytest.txt
265+
pip install tensorflow==2.15.0 -e ./ -r tools/install_deps/pytest.txt
266266
bash tools/install_so_files.sh # Linux/macos/WSL2
267267
sh tools/install_so_files.sh # PowerShell
268268
```
@@ -290,7 +290,7 @@ docker run --gpus all --rm -it -v ${PWD}:/addons -w /addons gcr.io/tensorflow-te
290290

291291
Configure:
292292
```bash
293-
python3 -m pip install tensorflow==2.14.0
293+
python3 -m pip install tensorflow==2.15.0
294294
python3 ./configure.py # Links project with TensorFlow dependency
295295
```
296296

@@ -329,7 +329,7 @@ quickly, as Bazel has great support for caching and distributed testing.
329329
To test with Bazel:
330330

331331
```bash
332-
python3 -m pip install tensorflow==2.14.0
332+
python3 -m pip install tensorflow==2.15.0
333333
python3 configure.py
334334
python3 -m pip install -r tools/install_deps/pytest.txt
335335
bazel test -c opt -k \

README.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ For more information see: [https://github.com/tensorflow/addons/issues/2807](htt
3131

3232
| Build | Status |
3333
| --- | --- |
34-
| **Ubuntu/macOS/Windows** | [![Status](https://github.com/tensorflow/addons/actions/workflows/release.yml/badge.svg)](https://github.com/tensorflow/addons/actions?query=workflow%3Aaddons-release) |
34+
| **Ubuntu/macOS** | [![Status](https://github.com/tensorflow/addons/actions/workflows/release.yml/badge.svg)](https://github.com/tensorflow/addons/actions?query=workflow%3Aaddons-release) |
3535
| **Ubuntu GPU custom ops** | [![Status](https://storage.googleapis.com/tensorflow-kokoro-build-badges/addons/ubuntu-gpu-py3.svg)](https://storage.googleapis.com/tensorflow-kokoro-build-badges/addons/ubuntu-gpu-py3.html) |
3636

3737
**TensorFlow Addons** is a repository of contributions that conform to
@@ -64,7 +64,8 @@ owners for all submodules.
6464

6565
## Installation
6666
#### Stable Builds
67-
TensorFlow Addons is available on PyPI for Linux, macOS, and Windows. To install the latest version,
67+
TensorFlow Addons is available on PyPI for Linux & macOS (Windows support was dropped
68+
due to [inconsistent TF2.15 whl packaging](https://github.com/tensorflow/tensorflow/issues/61830)). To install the latest version,
6869
run the following:
6970
```
7071
pip install tensorflow-addons
@@ -192,7 +193,7 @@ cd addons
192193
export TF_NEED_CUDA="1"
193194
194195
# Set these if the below defaults are different on your system
195-
export TF_CUDA_VERSION="11"
196+
export TF_CUDA_VERSION="12"
196197
export TF_CUDNN_VERSION="8"
197198
export CUDA_TOOLKIT_PATH="/usr/local/cuda"
198199
export CUDNN_INSTALL_PATH="/usr/lib/x86_64-linux-gnu"

WORKSPACE

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ http_archive(
1111
patches = [
1212
"//build_deps/tf_dependency:tf.patch",
1313
],
14-
sha256 = "ce357fd0728f0d1b0831d1653f475591662ec5bca736a94ff789e6b1944df19f",
15-
strip_prefix = "tensorflow-2.14.0",
14+
sha256 = "9cec5acb0ecf2d47b16891f8bc5bc6fbfdffe1700bdadc0d9ebe27ea34f0c220",
15+
strip_prefix = "tensorflow-2.15.0",
1616
urls = [
17-
"https://github.com/tensorflow/tensorflow/archive/refs/tags/v2.14.0.tar.gz",
17+
"https://github.com/tensorflow/tensorflow/archive/refs/tags/v2.15.0.tar.gz",
1818
],
1919
)
2020

configure.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ def configure_cuda():
185185
"CUDNN_INSTALL_PATH",
186186
os.getenv("CUDNN_INSTALL_PATH", "/usr/lib/x86_64-linux-gnu"),
187187
)
188-
write_action_env("TF_CUDA_VERSION", os.getenv("TF_CUDA_VERSION", "11.8"))
188+
write_action_env("TF_CUDA_VERSION", os.getenv("TF_CUDA_VERSION", "12.2"))
189189
write_action_env("TF_CUDNN_VERSION", os.getenv("TF_CUDNN_VERSION", "8"))
190190

191191
write("test --config=cuda")

tensorflow_addons/utils/resource_loader.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020

2121
import tensorflow as tf
2222

23-
INCLUSIVE_MIN_TF_VERSION_FOR_ABI_COMPATIBILITY = "2.14.0"
24-
EXCLUSIVE_MAX_TF_VERSION_FOR_ABI_COMPATIBILITY = "2.15.0"
23+
INCLUSIVE_MIN_TF_VERSION_FOR_ABI_COMPATIBILITY = "2.15.0"
24+
EXCLUSIVE_MAX_TF_VERSION_FOR_ABI_COMPATIBILITY = "2.16.0"
2525
abi_warning_already_raised = False
2626
SKIP_CUSTOM_OPS = False
2727

tensorflow_addons/version.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
"""Define TensorFlow Addons version information."""
1616

1717
# Required TensorFlow version [min, max)
18-
INCLUSIVE_MIN_TF_VERSION = "2.12.0"
19-
EXCLUSIVE_MAX_TF_VERSION = "2.15.0"
18+
INCLUSIVE_MIN_TF_VERSION = "2.13.0"
19+
EXCLUSIVE_MAX_TF_VERSION = "2.16.0"
2020

2121
# We follow Semantic Versioning (https://semver.org/)
2222
_MAJOR_VERSION = "0"

tools/build_dev_container.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ set -x -e
44

55
docker build \
66
-f tools/docker/dev_container.Dockerfile \
7-
--build-arg TF_VERSION=2.14.0 \
7+
--build-arg TF_VERSION=2.15.0 \
88
--build-arg TF_PACKAGE=tensorflow \
99
--build-arg PY_VERSION=$PY_VERSION \
1010
--no-cache \

tools/docker/build_wheel.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#syntax=docker/dockerfile:1.1.5-experimental
22
ARG PY_VERSION
3-
FROM tensorflow/build:2.14-python$PY_VERSION as base_install
3+
FROM tensorflow/build:2.15-python$PY_VERSION as base_install
44

55
ENV TF_NEED_CUDA="1"
66
ARG PY_VERSION

tools/docker/cpu_tests.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#syntax=docker/dockerfile:1.1.5-experimental
22
FROM python:3.9 as build_wheel
33

4-
ARG TF_VERSION=2.14.0
4+
ARG TF_VERSION=2.15.0
55
RUN pip install --default-timeout=1000 tensorflow-cpu==$TF_VERSION
66

77
RUN apt-get update && apt-get install -y sudo rsync

tools/install_deps/tensorflow-cpu.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
tensorflow-cpu~=2.14.0
1+
tensorflow-cpu~=2.15.0

tools/install_deps/tensorflow.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
tensorflow~=2.14.0
1+
tensorflow~=2.15.0

tools/run_gpu_tests.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export DOCKER_BUILDKIT=1
66
docker build \
77
-f tools/docker/build_wheel.Dockerfile \
88
--target tfa_gpu_tests \
9-
--build-arg TF_VERSION=2.14.0 \
9+
--build-arg TF_VERSION=2.15.0 \
1010
--build-arg PY_VERSION=3.9 \
1111
-t tfa_gpu_tests ./
1212
docker run --rm -t --gpus=all --shm-size=512m tfa_gpu_tests

0 commit comments

Comments
 (0)