Commit Graph

37 Commits

Author SHA1 Message Date
Yifei Feng
eaedb464a0 Remove the main repo reference.
PiperOrigin-RevId: 296251652
Change-Id: Ide83f2957a08b688838d8de7af92fd1cc36369e5
2020-02-20 11:26:08 -08:00
Jakob Buchgraber
09fe958fee Enable Remote Config for ROCM and CUDA RBE pre- and postsubmits
Previously TF_CUDA_CONFIG_REPO would point to a pregenerated and checked in configuration. This changes has it point to a remote repository intead that generates the configuration during the build for the specific docker image. All supported configurations can be found in third_party/toolchains/remote_config/configs.bzl. Each tensorflow_rbe_config() macro creates a few remote repositories to which to point the TF_*_CONFIG_REPO environment variables to. The remote repository names are prefixed with the macro's name. For example, tensorflow_rbe_config(name = "ubuntu") will create @ubuntu_config_python, @ubuntu_config_cuda, @ubuntu_config_nccl, etc.

This change also introduces the platform_configure. All this rule does is create a remote repository with a single platform target for the tensorflow_rbe_config(). This will make the platforms defined in //third_party/toolchains/BUILD obsolete once remote config is fully rolled out.

PiperOrigin-RevId: 296065144
Change-Id: Ia54beeb771b28846444e27a2023f70abbd9f6ad5
2020-02-19 15:05:06 -08:00
Jakob Buchgraber
478ea62407 Support remote repositories in TF_*_CONFIG_REPO environment variables
Currently TF_*_CONFIG_REPO environment variables point to checked in preconfig packages. After migrating to remote config they will point to remote repositories. The "config_repo_label" function ensures both ways continue to work.

PiperOrigin-RevId: 295990961
Change-Id: I7637ff5298893d4ee77354e9b48f87b8c328c301
2020-02-19 09:55:35 -08:00
Jakob Buchgraber
be9eb5f03f tensorrt_configure: Factor logic to create local repository into its own function
This follows the same pattern as other repository rules. In a follow up change I
will introduce remote_tensorrt_configure that will use _create_local_tensorrt_repository
as its implementation function.

PiperOrigin-RevId: 295797220
Change-Id: Idbb56df088caae114ce23a898464577573257feb
2020-02-18 13:01:31 -08:00
Jakob Buchgraber
b7796f3c85 cuda_configure: make find_cuda_config() compatible with remote execution
repository_ctx.execute() does not support uploading of files from the source tree. I initially tried constructing a command that simply embeds the file's contents. However that did not work on Windows because the file is larger than 8192 characters. So my best idea was to compress it locally and embed the compressed contents in the command and to uncompress it remotely. This works but comes with the drawback that we need to compress it first. This can't be done as part of the repository_rule either because within one repository_rule every execute() runs either locally or remotely. I thus decided to check in the compressed version in the source tree. It's very much a temporary measure as I'll add the ability to upload files to a future version of Bazel.

PiperOrigin-RevId: 295787408
Change-Id: I1545dd86cdec7e4b20cba43d6a134ad6d1a08109
2020-02-18 12:24:05 -08:00
Jakob Buchgraber
f60fc7a072 remote config: replace all uses of os.environ by get_host_environ
This change is in prepartion for rolling out remote config. It will
allow us to inject environment variables from repository rules as
well as from the shell enviroment.

PiperOrigin-RevId: 295782466
Change-Id: I1eb61fca3556473e94f2f12c45ee5eb1fe51625b
2020-02-18 12:19:55 -08:00
A. Unique TensorFlower
99ec314b06 rocm_configure: share code with cuda_configure
Move get_cpu_value() to common.bzl and use it from cuda_configure and rocm_configure

PiperOrigin-RevId: 293807189
Change-Id: I2eb0ef0ab27a64060a99985bcab9ae4706f57fc5
2020-02-07 07:09:09 -08:00
A. Unique TensorFlower
a3fddc818e tensorrt_configure: fix quadratic runtime due to label resolution
PiperOrigin-RevId: 293788006
Change-Id: Icdbcb244fdbf51736ef9a0343124196a52f3b1f3
2020-02-07 04:24:42 -08:00
A. Unique TensorFlower
9c948d12b2 cuda_configure: fix quadratic runtime due to label resolution
See for details: 62bd353452

PiperOrigin-RevId: 293548911
Change-Id: I66d77bc606458e3b40d2f9fde88770bc8f15da44
2020-02-06 02:15:48 -08:00
Pooya Davoodi
7d14cdcc25 Update TRT6 headerfiles 2019-09-09 17:59:44 -07:00
Christian Sigg
9621ac4de0 Remove # -*- Python -*- from Starlark files.
PiperOrigin-RevId: 268048675
2019-09-09 12:27:18 -07:00
Guangda Lai
f9c8169d8f Populate TF_TENSORRT_VERSION during configuration process.
PiperOrigin-RevId: 254059615
2019-06-19 13:39:53 -07:00
TensorFlower Gardener
cc03fdce67 Merge pull request from jhalakpatel:fix_trt6_version_parsing
PiperOrigin-RevId: 248706905
2019-05-17 06:14:31 -07:00
jhalakp
ef5e563bd1 Remove incorrect indentation 2019-05-15 16:23:26 -07:00
jhalakp
f6e195155a Fix how header files are updated and ran pylint 2019-05-13 01:28:29 -07:00
TensorFlower Gardener
7bd23b650b Merge pull request from jhalakpatel:build_tf_with_trt_6
PiperOrigin-RevId: 247755315
2019-05-11 07:34:58 -07:00
jhalakp
c2c551e681 run pylint and clang-format to fix formatting issues 2019-05-10 08:24:10 -07:00
jhalakp
8db2e909e5 update version information file. Also upadate tensorrt bazel configuration file 2019-05-09 15:55:58 -07:00
Guangda Lai
bb5a94d15a Fix TRT config that is used when building GPU package without TRT.
PiperOrigin-RevId: 246023930
2019-04-30 15:22:23 -07:00
A. Unique TensorFlower
b2e7f671da Switch from TF_TENSORRT_VERSION to TF_NEED_TENSORRT environment variable to determine whether to build with TF-TRT.
Store fallback env variables for CUDA configs in bazelrc as well.

PiperOrigin-RevId: 245961133
2019-04-30 09:26:48 -07:00
Taylor Jakobson
f565d992a0 Fix typo in tensorrt_include 2019-04-16 15:43:47 -05:00
A. Unique TensorFlower
8e9ca6617b Change how ./configure and bazel finds CUDA paths.
Use a single python script (third_party/gpus/find_cuda_config.py) from configure.py and the different *_configure.bzl scripts to find the different CUDA library and header paths based on a set of environment variables.

PiperOrigin-RevId: 243669844
2019-04-15 12:55:59 -07:00
Guangda Lai
e498730b17 Fix configuration script and add nvinfer_plugin library, add initialization for the plugins in Converter constructor, and fix code formatting. 2019-03-04 08:29:17 -08:00
Guangda Lai
86b99e958e
Merge branch 'master' into trt_nms 2019-02-28 18:28:15 -08:00
A. Unique TensorFlower
a0b0a50328 Formatting BUILD and bzl files.
PiperOrigin-RevId: 234543907
2019-02-18 22:24:09 -08:00
Pooya Davoodi
083eece828 TFTRT: Load TensorRT plugin library 2019-02-07 13:18:33 -08:00
A. Unique TensorFlower
72571e0824 Roll CL 229790895 forward with fix.
PiperOrigin-RevId: 229930009
2019-01-18 08:19:28 -08:00
A. Unique TensorFlower
815d49bb58 Automated rollback of commit 5c08b1f021
PiperOrigin-RevId: 229895719
2019-01-18 02:09:02 -08:00
A. Unique TensorFlower
4e8bf7f9ca Fix for CL 229790895.
PiperOrigin-RevId: 229850165
2019-01-17 18:18:06 -08:00
A. Unique TensorFlower
f8c19045a1 Improve how the library to link is determined.
PiperOrigin-RevId: 229833513
2019-01-17 16:39:50 -08:00
A. Unique TensorFlower
5c08b1f021 Remove alias redirection for RBE.
PiperOrigin-RevId: 229790895
2019-01-17 12:06:07 -08:00
A. Unique TensorFlower
5bb89f1612 Cleaning up copying system files to execroot.
Copy and use nvcc from execroot.

PiperOrigin-RevId: 229214994
2019-01-14 11:18:32 -08:00
A. Unique TensorFlower
446a5fb00e Add remote configuration for TensorRT.
PiperOrigin-RevId: 225573787
2018-12-14 11:37:51 -08:00
Mustafa Kasap
e605245fbd TensorRT support for ARM architectures ()
i.e. without this modification Tensorflow under Nvidia Jetpack 3.2 is not compiling. Else condition in if-then-else block generates a path "%s/../include" which results in "/usr/lib/include" but it must be "/usr/include/aarch64-linux-gnu"... So this fix targets ARM architectures and with this fix, Tensorflow 1.6rc compiles fine with TensorRT support.
2018-03-14 18:17:26 -07:00
gracehoney
37bcd5af97 Fix some BUILD files 2018-02-06 09:26:20 -08:00
Sami Kama
be50e66950 Fix compilation issues with new build files 2018-01-29 15:08:26 -08:00
Guangda Lai
76f6938baf Set up TensorRT configurations for external use, and add a test.
PiperOrigin-RevId: 183347199
2018-01-26 00:02:44 -08:00