Skip to content

Commit c512df9

Browse files
authored
BLD: fix nightlies (#824)
* Move requirements.txt into packaging directory * Remove sudo call in release script * Fix required includes for windows build
1 parent 510aa3c commit c512df9

File tree

12 files changed

+17
-8
lines changed

12 files changed

+17
-8
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ jobs:
5151
- choco install python --version 3.6.8
5252
- choco install python --version 3.7.5
5353
script:
54-
- export PATH=/c/tools/python:/c/tools/python/Scripts:$PATH
55-
- bash -x -e tools/ci_build/builds/release_windows.sh
54+
# - export PATH=/c/tools/python:/c/tools/python/Scripts:$PATH
55+
# - bash -x -e tools/ci_build/builds/release_windows.sh
5656
- export PATH=/c/Python35:/c/Python35/Scripts:$PATH
5757
- bash -x -e tools/ci_build/builds/release_windows.sh
5858
- export PATH=/c/Python36:/c/Python36/Scripts:$PATH

BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ sh_binary(
44
data = [
55
"LICENSE",
66
"MANIFEST.in",
7+
"requirements.txt",
78
"setup.py",
89
"//tensorflow_addons",
910
],

build_deps/check_deps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,4 @@ def check_dependencies(requirement_file_name):
3232

3333

3434
if __name__ == "__main__":
35-
check_dependencies('build_deps/requirements.txt')
35+
check_dependencies('requirements.txt')

build_deps/requirements.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

build_pip_pkg.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ function main() {
5555
cp ${PIP_FILE_PREFIX}setup.py "${TMPDIR}"
5656
cp ${PIP_FILE_PREFIX}MANIFEST.in "${TMPDIR}"
5757
cp ${PIP_FILE_PREFIX}LICENSE "${TMPDIR}"
58+
cp ${PIP_FILE_PREFIX}requirements.txt "${TMPDIR}"
5859
touch ${TMPDIR}/stub.cc
5960

6061
if is_windows; then

configure.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ fi
7979

8080
BRANCH=$(git rev-parse --abbrev-ref HEAD)
8181
PYTHON_PATH=$(which python)
82-
REQUIRED_PKG=$(cat build_deps/requirements.txt)
82+
REQUIRED_PKG=$(cat requirements.txt)
8383

8484
if [[ ${BRANCH} == "master" ]]; then
8585
echo "WARN: You're building from master branch, please ensure that you want to build \
@@ -95,7 +95,7 @@ if [[ $? == 1 ]]; then
9595
read -r -p "Package ${REQUIRED_PKG} will be installed. Are You Sure? [y/n] " reply
9696
case $reply in
9797
[yY]*) echo "> Installing..."
98-
python -m pip install $PIP_INSTALL_OPTS -r build_deps/requirements.txt;;
98+
python -m pip install $PIP_INSTALL_OPTS -r requirements.txt;;
9999
* ) echo "> Exiting..."; exit;;
100100
esac
101101
else

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
tf-nightly

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
if project_name == TFA_NIGHTLY:
6161
version['__version__'] += datetime.strftime(datetime.today(), "%Y%m%d")
6262

63-
with open('build_deps/requirements.txt') as f:
63+
with open('requirements.txt') as f:
6464
required_pkgs = f.read().splitlines()
6565

6666
# Manylinux2010 requires a patch for platlib

tensorflow_addons/custom_ops/activations/cc/kernels/rrelu_op.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ limitations under the License.
1717
#define TENSORFLOW_ADDONS_ACTIVATIONS_KERNELS_RRELU_OP_H_
1818

1919
#define EIGEN_USE_THREADS
20+
#define _USE_MATH_DEFINES
21+
#include <cmath>
2022

2123
#include "tensorflow/core/framework/numeric_op.h"
2224
#include "tensorflow/core/framework/op_kernel.h"

tensorflow_addons/custom_ops/image/cc/kernels/adjust_hsv_in_yiq_op.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ limitations under the License.
1818
#define EIGEN_USE_GPU
1919
#endif // GOOGLE_CUDA
2020

21+
#define _USE_MATH_DEFINES
2122
#include <cmath>
23+
2224
#include "third_party/eigen3/Eigen/Core"
2325
#include "third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
2426

0 commit comments

Comments
 (0)