url
stringlengths
63
63
repository_url
stringclasses
1 value
labels_url
stringlengths
77
77
comments_url
stringlengths
72
72
events_url
stringlengths
70
70
html_url
stringlengths
51
53
id
int64
1.57B
2.35B
node_id
stringlengths
18
19
number
int64
59.5k
69.6k
title
stringlengths
1
554
user
dict
labels
listlengths
0
8
state
stringclasses
2 values
locked
bool
2 classes
assignee
dict
assignees
listlengths
0
8
milestone
null
comments
sequencelengths
0
30
created_at
timestamp[s]
updated_at
timestamp[s]
closed_at
timestamp[s]
author_association
stringclasses
4 values
active_lock_reason
stringclasses
3 values
draft
bool
2 classes
pull_request
dict
body
stringlengths
1
65.4k
reactions
dict
timeline_url
stringlengths
72
72
performed_via_github_app
null
state_reason
stringclasses
3 values
is_pull_request
bool
2 classes
https://api.github.com/repos/tensorflow/tensorflow/issues/61978
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61978/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61978/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61978/events
https://github.com/tensorflow/tensorflow/issues/61978
1,912,318,449
I_kwDOArmXAs5x-6nx
61,978
Build from source 2.13.0 fails on Rocky Linux 8.8
{ "login": "nadyawilliams", "id": 3654337, "node_id": "MDQ6VXNlcjM2NTQzMzc=", "avatar_url": "https://avatars.githubusercontent.com/u/3654337?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nadyawilliams", "html_url": "https://github.com/nadyawilliams", "followers_url": "https://api.github.com/users/nadyawilliams/followers", "following_url": "https://api.github.com/users/nadyawilliams/following{/other_user}", "gists_url": "https://api.github.com/users/nadyawilliams/gists{/gist_id}", "starred_url": "https://api.github.com/users/nadyawilliams/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nadyawilliams/subscriptions", "organizations_url": "https://api.github.com/users/nadyawilliams/orgs", "repos_url": "https://api.github.com/users/nadyawilliams/repos", "events_url": "https://api.github.com/users/nadyawilliams/events{/privacy}", "received_events_url": "https://api.github.com/users/nadyawilliams/received_events", "type": "User", "site_admin": false }
[ { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 1205615612, "node_id": "MDU6TGFiZWwxMjA1NjE1NjEy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux", "name": "subtype: ubuntu/linux", "color": "b619ea", "default": false, "description": "Ubuntu/Linux Build/Installation Issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "@nadyawilliams Could you please run bazel clean --expunge, forcing bazel to re-download and build each dependency to avoid issues. Also sync the bazel build bazel sync.\r\nThank you!", "Thank you for a suggestion.\r\nI did bazel clean --expunge, before the build and cleaned again when i tried different options. No help.\r\nRunning bazel sync fails with multiple errors starting rom not finding cuda.h (cuda module is loaded and cuda.h is available in \r\ncuda install), followed by not finding python (also is loaded via module and available). Looks like bazel sync is not using any\r\nof the variables set by the modules. For example a python error is\r\nERROR: An error occurred during the fetch of repository 'ubuntu20.04-gcc9_manylinux2014-cuda11.8-cudnn8.6-tensorrt8.4_config_python3.11':\r\n Traceback (most recent call last):\r\n\tFile \"/export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.13.0/third_party/py/python_configure.bzl\", line 212, column 22, in _create_local_python_repository\r\n\t\t_check_python_bin(repository_ctx, python_bin)\r\n\tFile \"/export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.13.0/third_party/py/python_configure.bzl\", line 145, column 25, in _check_python_bin\r\n\t\tauto_config_fail(\"--define %s='%s' is not executable. Is it the python binary?\" % (\r\n\tFile \"/export/repositories/tensorflow-admix/yamlspecs/tensorflow-2.13.0/third_party/remote_config/common.bzl\", line 12, column 9, in auto_config_fail\r\n\t\tfail(\"%sConfiguration Error:%s %s\\n\" % (red, no_color, msg))\r\nError in fail: Configuration Error: --define PYTHON_BIN_PATH='/usr/local/bin/python3.11' is not executable. Is it the python binary?\r\n\r\nPer my modules python is\r\nwhich python\r\n/opt/apps/python/3.10.2/bin/python\r\n", "Hello, @nadyawilliams! If you are using TF v2.13 then the supported version for CUDA and cuDNN are 11.8, 8.6 respectively. Could you please verify the tested build configuration as mentioned [here](https://www.tensorflow.org/install/source#gpu) and let us know if that helps?\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "I will be able to proceed with the testing of cuda and cudNN 11.8 and 8.6 the earliest next week. both build have to be done according to our build schedule and approach. Please keep the issue open till i try this. Thank you", "Unfortunately at this time we cant upgrade our CUDA installation to 11.8. Please advise which latest version of tensorflow can be compiled with cuda 11.7 and cudNN 8.5. Thank you.", "@nadyawilliams Thanks for your response! We need to use the recommended compatible versions only otherwise the build issues would be hard to resolve. Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "Please close the issue. I can compile tensorflow 2.11 with our current cuda install and while it is not the latest it will do for now.", "@nadyawilliams Thank you for the confirmation. \r\nClosing the ticket for now. Thank you!", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61978\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61978\">No</a>\n" ]
2023-09-25T21:36:10
2023-11-06T04:10:16
2023-11-06T04:10:13
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 ### Custom code No ### OS platform and distribution Rocky Linux 8.8 ### Mobile device _No response_ ### Python version 3.10.2 ### Bazel version 5.3.0 ### GCC/compiler version clang 16.0.1 or gcc 11.2.0 ### CUDA/cuDNN version cuda 11.7.1 / cuDNN 8.5.0.96 ### GPU model and memory _No response_ ### Current behavior? 1. load modules (all built locally on the host and provide an access to the specified software) **module load bazel/5.3.0 gcc/11.2.0 llvm/16.0.1 clang/16.0.1 python/3.10.2 cuda/11.7.1 tensorRT/8.4.2.4** 2. Configure tensroflow: **./configure** Resulting .tf_configure.bazelrc is: build --action_env PYTHON_BIN_PATH="/opt/apps/python/3.10.2/bin/python3" build --action_env PYTHON_LIB_PATH="/opt/apps/python/3.10.2/lib/python3.10/site-packages" build --python_path="/opt/apps/python/3.10.2/bin/python3" build --config=tensorrt build --action_env TF_CUDA_VERSION="11" build --action_env TF_CUDNN_VERSION="8" build --action_env TF_TENSORRT_VERSION="8" build --action_env TF_NCCL_VERSION="" build --action_env TF_CUDA_PATHS="/opt/apps/cuda/11.7.1,/opt/apps/tensorRT/8.4.2.4,/usr" build --action_env CUDA_TOOLKIT_PATH="/opt/apps/cuda/11.7.1" build --action_env TF_CUDA_COMPUTE_CAPABILITIES="7.0" build --action_env LD_LIBRARY_PATH="/opt/apps/tensorRT/8.4.2.4/lib:/opt/apps/cuda/11.7.1/lib64:/opt/apps/cuda/11.7.1/nvvm/lib64:/opt/apps/cuda/11.7.1/cublas/lib64:/opt/apps/cuda/11.7.1/extras/CUPTI/lib64:/opt/apps/cuda/11.7.1 /extras/Debugger/lib64:/opt/apps/python/3.10.2/lib:/opt/apps/clang/16.0.1/lib:/opt/apps/llvm/16.0.1/lib:/opt/apps/gcc/11.2.0/lib64:/opt/apps/gcc/11.2.0/lib:/opt/apps/gcc/11.2.0/lib/gcc/x86_64-pc-linux-gnu/11.2.0" build --config=cuda_clang build --action_env CLANG_CUDA_COMPILER_PATH="/opt/apps/clang/16.0.1/bin/clang" build --config=cuda_clang build:opt --copt=-mavx2 build:opt --host_copt=-mavx2 test --flaky_test_attempts=3 test --test_size_filters=small,medium test --test_env=LD_LIBRARY_PATH test:v1 --test_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-no_gpu,-oss_serial test:v1 --build_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-no_gpu test:v2 --test_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-no_gpu,-oss_serial,-v1only test:v2 --build_tag_filters=-benchmark-test,-no_oss,-oss_excluded,-no_gpu,-v1only 3 Run bazel build **nohup bazel build --config=opt --jobs=8 --verbose_failures --verbose_explanations \ --explain=/tmp/explain.txt //tensorflow/tools/pip_package:build_pip_package > build-out.txt &** The build fails with an error. Attaching output log files build-out.txt (collect errors) and explain.txt ( collect verbose output) per above command: [build-out.txt](https://github.com/tensorflow/tensorflow/files/12719249/build-out.txt) [explain.txt](https://github.com/tensorflow/tensorflow/files/12719259/explain.txt) If i compile without cuda/tensorRT, the clang compiler is not chosen and there is no way to choose is per current configure.py as clang choose seem to be used only for gpu-enabled builds. In this case, gcc 11.2.0 is used and the error happens in a different area. I tried to use different options adding **--config=cuda** or **--cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0"** and every time i get a failure on a different file yet always the culprit seem to be these lines from the respective build output: In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/memory:77: In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr.h:53: /opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linux/12/../../../../include/c++/12/bits/shared_ptr_base.h:196:22: error: type name does not allow function specifier to be specified bazel-out/k8-opt/bin/external/local_config_cuda/cuda/cuda/include/crt/host_defines.h:83:24: note: expanded from macro '__noinline__' __attribute__((noinline)) Note, i dont have **/opt/rh...** path on this host so this must be coming during compiling some external dependencies and looking at my .tf_configure.bazelrc file i dont really have control over how external dependencies are handled. Can reproduce with nightly builds as it uses different (newer) version of tensorflow and bazel. I have previously compiled tensorflow 2.8.0 (with its corresponding bazel version) on the same host with the same cuda, python, and gcc using identical build steps and the builds went perfectly file. I am confident that all prerequisite software is installed correctly (using it for many other packages builds outside tensorflow). I would really appreciate if someone can point to what am i doing wrong or what else i can try. No conda or docker please. Neither one will work in our environment where i need home built RPMS for installation on the HPC cluster. Thanks! ### Standalone code to reproduce the issue ```shell No test case ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61978/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61978/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61977
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61977/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61977/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61977/events
https://github.com/tensorflow/tensorflow/pull/61977
1,911,950,562
PR_kwDOArmXAs5bJgWB
61,977
practice
{ "login": "paisstillearning", "id": 127503070, "node_id": "U_kgDOB5mK3g", "avatar_url": "https://avatars.githubusercontent.com/u/127503070?v=4", "gravatar_id": "", "url": "https://api.github.com/users/paisstillearning", "html_url": "https://github.com/paisstillearning", "followers_url": "https://api.github.com/users/paisstillearning/followers", "following_url": "https://api.github.com/users/paisstillearning/following{/other_user}", "gists_url": "https://api.github.com/users/paisstillearning/gists{/gist_id}", "starred_url": "https://api.github.com/users/paisstillearning/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/paisstillearning/subscriptions", "organizations_url": "https://api.github.com/users/paisstillearning/orgs", "repos_url": "https://api.github.com/users/paisstillearning/repos", "events_url": "https://api.github.com/users/paisstillearning/events{/privacy}", "received_events_url": "https://api.github.com/users/paisstillearning/received_events", "type": "User", "site_admin": false }
[ { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/61977/checks?check_run_id=17110097375) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request.", "It is spam, please don't spam. Thank you!" ]
2023-09-25T17:10:15
2023-09-26T07:42:03
2023-09-26T07:42:03
NONE
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61977", "html_url": "https://github.com/tensorflow/tensorflow/pull/61977", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61977.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61977.patch", "merged_at": null }
practicing on workflow of the github by using open source project.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61977/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61977/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61976
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61976/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61976/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61976/events
https://github.com/tensorflow/tensorflow/issues/61976
1,911,909,295
I_kwDOArmXAs5x9Wuv
61,976
NotFoundError could not find registered transfer manager for platform Host -- check target linkage [Op:__inference__jit_compiled_convolution_op_26169] TPU-VM
{ "login": "innat", "id": 17668390, "node_id": "MDQ6VXNlcjE3NjY4Mzkw", "avatar_url": "https://avatars.githubusercontent.com/u/17668390?v=4", "gravatar_id": "", "url": "https://api.github.com/users/innat", "html_url": "https://github.com/innat", "followers_url": "https://api.github.com/users/innat/followers", "following_url": "https://api.github.com/users/innat/following{/other_user}", "gists_url": "https://api.github.com/users/innat/gists{/gist_id}", "starred_url": "https://api.github.com/users/innat/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/innat/subscriptions", "organizations_url": "https://api.github.com/users/innat/orgs", "repos_url": "https://api.github.com/users/innat/repos", "events_url": "https://api.github.com/users/innat/events{/privacy}", "received_events_url": "https://api.github.com/users/innat/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 996845227, "node_id": "MDU6TGFiZWw5OTY4NDUyMjc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:dist-strat", "name": "comp:dist-strat", "color": "0052cc", "default": false, "description": "Distribution Strategy related issues" }, { "id": 5206407904, "node_id": "LA_kwDOArmXAs8AAAABNlN64A", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.12", "name": "TF 2.12", "color": "c5def5", "default": false, "description": "For issues related to Tensorflow 2.12" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @innat ,\r\n\r\nI am able to run the code on Colab by following TPU initialization code as per documentation and it executed fine as per attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/7165c07c2e944e347ec7f4360045bc57/61976_tpu.ipynb).\r\n\r\nIt seems the issue might be specific to Kaggle environment ?\r\n", "@SuryanarayanaY Thanks for checking. I also check in Colab TPU. For your concern, please check this comment https://github.com/keras-team/tf-keras/issues/655#issuecomment-1733864636 ", "@innat , You mean to say it has problem with TPU VM and on colab as it is TPU node it works fine? I would like to hear from concerned team. Thanks!", "> You mean to say it has problem with TPU VM and on colab as it is TPU node it works fine?\r\n\r\nYes.\r\n\r\n\r\ncc. @@djherbis ", "@SuryanarayanaY \r\n\r\n> I would like to hear from concerned team.\r\n\r\nCould you like to mention the appropriate person (from tf team)?\r\n", "Any update?" ]
2023-09-25T16:43:23
2023-10-02T16:32:42
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.12 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I was trying to use `groups` parameter from `keras.layers.Conv2D` API on TPU-VM device. While running on GPU works but on TPU, it doesn't if `groups > 1`. ### Standalone code to reproduce the issue Full [Code.](https://www.kaggle.com/code/ipythonx/github-issue-655-keras-tpu-vm/notebook) ```python input_shape = (4, 28, 28, 9) x = tf.random.normal(input_shape) y = tf.keras.layers.Conv2D( 27, 3, activation='relu', input_shape=input_shape[1:], groups=3 )(x) print(y.shape) ``` ### Relevant log output ```yaml --------------------------------------------------------------------------- NotFoundError Traceback (most recent call last) Cell In[133], line 3 1 input_shape = (4, 28, 28, 9) 2 x = tf.random.normal(input_shape) ----> 3 y = tf.keras.layers.Conv2D( 4 27, 3, activation='relu', input_shape=input_shape[1:], groups=3 5 )(x) 7 print(y.shape) File /usr/local/lib/python3.8/site-packages/keras/utils/traceback_utils.py:70, in filter_traceback.<locals>.error_handler(*args, **kwargs) 67 filtered_tb = _process_traceback_frames(e.__traceback__) 68 # To get the full stack trace, call: 69 # `tf.debugging.disable_traceback_filtering()` ---> 70 raise e.with_traceback(filtered_tb) from None 71 finally: 72 del filtered_tb File /usr/local/lib/python3.8/site-packages/tensorflow/python/eager/execute.py:52, in quick_execute(op_name, num_outputs, inputs, attrs, ctx, name) 50 try: 51 ctx.ensure_initialized() ---> 52 tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name, 53 inputs, attrs, num_outputs) 54 except core._NotOkStatusException as e: 55 if name is not None: NotFoundError: Exception encountered when calling layer 'conv2d_335' (type Conv2D). could not find registered transfer manager for platform Host -- check target linkage [Op:__inference__jit_compiled_convolution_op_26236] Call arguments received by layer 'conv2d_335' (type Conv2D): • inputs=tf.Tensor(shape=(4, 28, 28, 9), dtype=float32) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61976/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61976/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61975
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61975/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61975/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61975/events
https://github.com/tensorflow/tensorflow/issues/61975
1,911,886,478
I_kwDOArmXAs5x9RKO
61,975
tf.math.cumsum weird behaviour
{ "login": "sermakarevich", "id": 9593371, "node_id": "MDQ6VXNlcjk1OTMzNzE=", "avatar_url": "https://avatars.githubusercontent.com/u/9593371?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sermakarevich", "html_url": "https://github.com/sermakarevich", "followers_url": "https://api.github.com/users/sermakarevich/followers", "following_url": "https://api.github.com/users/sermakarevich/following{/other_user}", "gists_url": "https://api.github.com/users/sermakarevich/gists{/gist_id}", "starred_url": "https://api.github.com/users/sermakarevich/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sermakarevich/subscriptions", "organizations_url": "https://api.github.com/users/sermakarevich/orgs", "repos_url": "https://api.github.com/users/sermakarevich/repos", "events_url": "https://api.github.com/users/sermakarevich/events{/privacy}", "received_events_url": "https://api.github.com/users/sermakarevich/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@sermakarevich,\r\nAs mentioned the provided code was executed with the different results in tensorflow [v2.13](https://colab.research.google.com/gist/tilakrayal/8b2044bbe3672aa4c4cca41eb33ae1b9/untitled1377.ipynb). But whereas when I tried to execute the same code on tf-nightly(2.15.0-dev20230926), the **manual cumsum diff is 0.0**. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/df65231d360551bacbc068728fbcd0d1/untitled1378.ipynb). Thank you! ", "@tilakrayal thank you. confirmed that on latest nightly it works well. \r\n\r\nhowever it does not work on nightly of version 2.14.0* even early versions of 2.15.0 still have the same problems\r\nIs this some kind of a known bug and there is a commit with the fix I can check ? Unfortunately bumping tf version is not an option for me atm. ", "@sermakarevich,\r\nAs mentioned, it was the issue/bug with the 2.14 nightly versions which has been resolved with the latest nightly release(2.15.0-dev20230926). You can try to use the latest tf-nightly for immediate use-case and it will be made available from TF 2.15. Thank you!", "@tilakrayal got it. \r\n\r\nIs there a chance to backport the fix into 2.11 and 2.12 tf versions ? ", "@sermakarevich,\r\nIt's unlikely for older versions to receive any bug fixes except when we have security patches. We recommend the community to use the latest versions if the bug is resolved. Thank you!", "@tilakrayal roger. Can you please point me to the commit with the fix ? I tried to scroll down through commits over last three days but did not found anything that looked related to cumsum fix", "@sermakarevich,\r\nI will do a deep dive into the same requirement and try to provide the information if it is available. Meanwhile, you can try to install the tf-nightly from the master branch, where it resolved the issue mentioned above. \r\nhttps://www.tensorflow.org/install\r\nhttps://github.com/tensorflow/tensorflow\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61975\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61975\">No</a>\n" ]
2023-09-25T16:29:53
2023-10-20T08:06:16
2023-10-20T08:06:14
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13 ### Custom code Yes ### OS platform and distribution Ubuntu 22.04.2 LTS ### Mobile device _No response_ ### Python version ython 3.10.12 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.0 ### GPU model and memory T4 ### Current behavior? tf.math.cumsum produce weird results on float32 and float64 when device is GPU: - results are different than on CPU - results do not match manual cumsum calculation - cumsum value can change when adding 0 (last two values in log output). - float64 has similar problems as well - tested on multiple GPUs: T4, GTX1080Ti and tensorflow versions: 2.13, 2.8.4 ### Standalone code to reproduce the issue ```shell with tf.device('/GPU'): arr = tf.constant( [ 0. , 0. , 0. , 0. , 9759.35, 9759.35, 9759.35, 9759.35, 9759.35, 9759.35, 9762.03, 9700.78, 9700.78, 9700.78, 9700.78, 9700.78, 9700.78, 9660.83, 9600.46, 9600.46, 9600.46, 9600.46, 9600.46, 9600.46, 9715.65, 9742.31, 9742.31, 9742.31, 9742.31, 9742.31, 9742.31, 9774.32, 9750.2 , 9750.2 , 9750.2 , 9750.2 , 9750.2 , 9750.2 , 9796.23, 9824.72, 9824.72, 9824.72, 9824.72, 9824.72, 9824.72, 11737.25, 9759.23, 9759.23, 9759.23, 9759.23, 9759.23, 9759.23, 9551.41, 9551.47, 9551.47, 9551.47, 9551.47, 9551.47, 9551.47, 9723.25, 9693.61, 9693.61, 9693.61, 9693.61, 9693.61, 9693.61, 9629.34, 9658.78, 9658.78, 9658.78, 9658.78, 9658.78, 9658.78, 9986.66, 10005.04, 10005.04, 10005.04, 10005.04, 10005.04, 10005.04, 9977.68, 9955.32, 9955.32, 9955.32, 9955.32, 9955.32, 9955.32, 9875.19, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0.], dtype=tf.float32) manual_cumsum = [] for val in arr: if len(manual_cumsum) == 0: manual_cumsum.append(val) else: manual_cumsum.append(manual_cumsum[-1] + val) tf_cumsum = tf.math.cumsum(arr) for index in range(arr.shape[0]): print("arr_value:", arr[index].numpy(), "tensor - manual cumsum diff:", (tf_cumsum[index] - manual_cumsum[index]).numpy()) ``` ``` ### Relevant log output ```shell arr_value: 0.0 tensor - manual cumsum diff: 0.0 arr_value: 0.0 tensor - manual cumsum diff: 0.0 arr_value: 0.0 tensor - manual cumsum diff: 0.0 arr_value: 0.0 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9759.35 tensor - manual cumsum diff: 0.0 arr_value: 9762.03 tensor - manual cumsum diff: 0.0 arr_value: 9700.78 tensor - manual cumsum diff: 0.0 arr_value: 9700.78 tensor - manual cumsum diff: -0.0078125 arr_value: 9700.78 tensor - manual cumsum diff: -0.0078125 arr_value: 9700.78 tensor - manual cumsum diff: -0.0078125 arr_value: 9700.78 tensor - manual cumsum diff: -0.0078125 arr_value: 9700.78 tensor - manual cumsum diff: -0.0078125 arr_value: 9660.83 tensor - manual cumsum diff: -0.015625 arr_value: 9600.46 tensor - manual cumsum diff: -0.015625 arr_value: 9600.46 tensor - manual cumsum diff: -0.015625 arr_value: 9600.46 tensor - manual cumsum diff: 0.0 arr_value: 9600.46 tensor - manual cumsum diff: 0.0 arr_value: 9600.46 tensor - manual cumsum diff: 0.0 arr_value: 9600.46 tensor - manual cumsum diff: 0.0 arr_value: 9715.65 tensor - manual cumsum diff: 0.03125 arr_value: 9742.31 tensor - manual cumsum diff: 0.03125 arr_value: 9742.31 tensor - manual cumsum diff: 0.03125 arr_value: 9742.31 tensor - manual cumsum diff: 0.03125 arr_value: 9742.31 tensor - manual cumsum diff: 0.015625 arr_value: 9742.31 tensor - manual cumsum diff: 0.015625 arr_value: 9742.31 tensor - manual cumsum diff: 0.015625 arr_value: 9774.32 tensor - manual cumsum diff: 0.03125 arr_value: 9750.2 tensor - manual cumsum diff: 0.03125 arr_value: 9750.2 tensor - manual cumsum diff: 0.03125 arr_value: 9750.2 tensor - manual cumsum diff: 0.03125 arr_value: 9750.2 tensor - manual cumsum diff: 0.03125 arr_value: 9750.2 tensor - manual cumsum diff: 0.09375 arr_value: 9750.2 tensor - manual cumsum diff: 0.09375 arr_value: 9796.23 tensor - manual cumsum diff: 0.09375 arr_value: 9824.72 tensor - manual cumsum diff: 0.09375 arr_value: 9824.72 tensor - manual cumsum diff: 0.125 arr_value: 9824.72 tensor - manual cumsum diff: 0.125 arr_value: 9824.72 tensor - manual cumsum diff: 0.125 arr_value: 9824.72 tensor - manual cumsum diff: 0.125 arr_value: 9824.72 tensor - manual cumsum diff: 0.125 arr_value: 11737.25 tensor - manual cumsum diff: 0.125 arr_value: 9759.23 tensor - manual cumsum diff: 0.125 arr_value: 9759.23 tensor - manual cumsum diff: 0.125 arr_value: 9759.23 tensor - manual cumsum diff: 0.15625 arr_value: 9759.23 tensor - manual cumsum diff: 0.15625 arr_value: 9759.23 tensor - manual cumsum diff: 0.15625 arr_value: 9759.23 tensor - manual cumsum diff: 0.15625 arr_value: 9551.41 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9551.47 tensor - manual cumsum diff: 0.1875 arr_value: 9723.25 tensor - manual cumsum diff: 0.1875 arr_value: 9693.61 tensor - manual cumsum diff: 0.1875 arr_value: 9693.61 tensor - manual cumsum diff: 0.1875 arr_value: 9693.61 tensor - manual cumsum diff: 0.1875 arr_value: 9693.61 tensor - manual cumsum diff: 0.1875 arr_value: 9693.61 tensor - manual cumsum diff: 0.125 arr_value: 9693.61 tensor - manual cumsum diff: 0.125 arr_value: 9629.34 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.125 arr_value: 9658.78 tensor - manual cumsum diff: 0.25 arr_value: 9986.66 tensor - manual cumsum diff: 0.25 arr_value: 10005.04 tensor - manual cumsum diff: 0.25 arr_value: 10005.04 tensor - manual cumsum diff: 0.25 arr_value: 10005.04 tensor - manual cumsum diff: 0.1875 arr_value: 10005.04 tensor - manual cumsum diff: 0.1875 arr_value: 10005.04 tensor - manual cumsum diff: 0.1875 arr_value: 10005.04 tensor - manual cumsum diff: 0.1875 arr_value: 9977.68 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9955.32 tensor - manual cumsum diff: 0.1875 arr_value: 9875.19 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.1875 arr_value: 0.0 tensor - manual cumsum diff: 0.25 arr_value: 0.0 tensor - manual cumsum diff: 0.25 ``` ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61975/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61975/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61974
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61974/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61974/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61974/events
https://github.com/tensorflow/tensorflow/issues/61974
1,911,746,482
I_kwDOArmXAs5x8u-y
61,974
AttributeError: module 'tensorflow.python.distribute.input_lib' has no attribute 'DistributedDatasetInterface'
{ "login": "PreWisdom", "id": 130530743, "node_id": "U_kgDOB8e9tw", "avatar_url": "https://avatars.githubusercontent.com/u/130530743?v=4", "gravatar_id": "", "url": "https://api.github.com/users/PreWisdom", "html_url": "https://github.com/PreWisdom", "followers_url": "https://api.github.com/users/PreWisdom/followers", "following_url": "https://api.github.com/users/PreWisdom/following{/other_user}", "gists_url": "https://api.github.com/users/PreWisdom/gists{/gist_id}", "starred_url": "https://api.github.com/users/PreWisdom/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/PreWisdom/subscriptions", "organizations_url": "https://api.github.com/users/PreWisdom/orgs", "repos_url": "https://api.github.com/users/PreWisdom/repos", "events_url": "https://api.github.com/users/PreWisdom/events{/privacy}", "received_events_url": "https://api.github.com/users/PreWisdom/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1478826728, "node_id": "MDU6TGFiZWwxNDc4ODI2NzI4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core", "name": "comp:core", "color": "024391", "default": false, "description": "issues related to core part of tensorflow" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @PreWisdom ,\r\n\r\nBy looking at attribute error, I would like to suggest to check the issue with TF2.12V and let us know the outcome.It seems there are shiftings in Tf2.12v and Tf2.13v. \r\n\r\nWith Tf2.13V the path `tensorflow.python.distribute.input_lib` don't have the class `DistributedDatasetInterface` but in Tf2.12 it does.\r\n", "> Hi @PreWisdom ,\r\n> \r\n> By looking at attribute error, I would like to suggest to check the issue with TF2.12V and let us know the outcome.It seems there are shiftings in Tf2.12v and Tf2.13v.\r\n> \r\n> With Tf2.13V the path `tensorflow.python.distribute.input_lib` don't have the class `DistributedDatasetInterface` but in Tf2.12 it does.\r\n\r\nthanks for reply, I'm gonna change version to 2.12 and see what happen.", "Hi @PreWisdom ,\r\n\r\nCould you please check the issue with tf-nightly. Actually there has been some changes. Now Keras has became a Multi backend support (for TF,Pytorch and JAX). All the tf.keras module i.e Keras with TF backend has been moved to new repo i.e [tf-keras](https://github.com/keras-team/tf-keras).\r\n\r\nI can see in tf-keras the code is different than in tf.keras module. I want to cross check with you with both tf-nightly and keras-nightly and confirm outcome ?", "> Hi @PreWisdom ,\r\n> \r\n> Could you please check the issue with tf-nightly. Actually there has been some changes. Now Keras has became a Multi backend support (for TF,Pytorch and JAX). All the tf.keras module i.e Keras with TF backend has been moved to new repo i.e [tf-keras](https://github.com/keras-team/tf-keras).\r\n> \r\n> I can see in tf-keras the code is different than in tf.keras module. I want to cross check with you with both tf-nightly and keras-nightly and confirm outcome ?\r\n\r\nsure, there are still has some problems in my code, looks like it's due to a package name change. I'll keep on tracking these bugs.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61974\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61974\">No</a>\n" ]
2023-09-25T15:19:18
2023-10-20T08:06:19
2023-10-20T08:06:16
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution Linux Ubuntu 22.04.3 ### Mobile device _No response_ ### Python version 2.13.0 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? OS : Ubuntu 22.04.3 Software: Pycharm files: LogisticRegression_withTensorflow.ipynb I dont know what happen, it just work yesterday when I run this code: `model.fit(X_train, y_train, epochs=150)` ### Standalone code to reproduce the issue ```shell # import library import numpy as np import tensorflow as tf from tensorflow.python.keras import Sequential from tensorflow.python.keras.layers import Dense from tensorflow.python.keras.losses import BinaryCrossentropy print(tf.__version__) # 2.13.0 # import data X = [] y = [] with open('../../Part1/Week2/data/ex2data1.txt') as file: # with open('/home/wisdom/vs_code_repository/Python/AndrewNG_ML/Part1/Week2/data/ex2data1.txt', 'r') as file: for lines in file: colums = lines.strip().split(',') X.append([float(colums[0]), float(colums[1])]) y.append(float(colums[2])) X = np.array(X) y = np.array(y) # normalization X_mean = np.mean(X, axis=0) X_max = np.max(X, axis=0) X_min = np.min(X, axis=0) X = (X - X_mean) / (X_max - X_min) # split data into training_set and testing_set X_train = X[:80] y_train = y[:80] X_test = X[80:] y_test = y[80:] model = Sequential([Dense(units=32, activation='sigmoid'), Dense(units=16, activation='sigmoid'), Dense(units=1, activation='sigmoid')]) model.compile(loss=BinaryCrossentropy()) model.fit(X_train, y_train, epochs=150) # bug appears this line ``` ### Relevant log output ```shell AttributeError Traceback (most recent call last) Cell In[13], line 1 ----> 1 model.fit(X_train, y_train, epochs=150) File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/training.py:1138, in Model.fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, validation_batch_size, validation_freq, max_queue_size, workers, use_multiprocessing) 1132 self._cluster_coordinator = cluster_coordinator.ClusterCoordinator( 1133 self.distribute_strategy) 1135 with self.distribute_strategy.scope(), \ 1136 training_utils.RespectCompiledTrainableState(self): 1137 # Creates a `tf.data.Dataset` and handles batch and epoch iteration. -> 1138 data_handler = data_adapter.get_data_handler( 1139 x=x, 1140 y=y, 1141 sample_weight=sample_weight, 1142 batch_size=batch_size, 1143 steps_per_epoch=steps_per_epoch, 1144 initial_epoch=initial_epoch, 1145 epochs=epochs, 1146 shuffle=shuffle, 1147 class_weight=class_weight, 1148 max_queue_size=max_queue_size, 1149 workers=workers, 1150 use_multiprocessing=use_multiprocessing, 1151 model=self, 1152 steps_per_execution=self._steps_per_execution) 1154 # Container that configures and calls `tf.keras.Callback`s. 1155 if not isinstance(callbacks, callbacks_module.CallbackList): File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:1398, in get_data_handler(*args, **kwargs) 1396 if getattr(kwargs["model"], "_cluster_coordinator", None): 1397 return _ClusterCoordinatorDataHandler(*args, **kwargs) -> 1398 return DataHandler(*args, **kwargs) File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:1152, in DataHandler.__init__(self, x, y, sample_weight, batch_size, steps_per_epoch, initial_epoch, epochs, shuffle, class_weight, max_queue_size, workers, use_multiprocessing, model, steps_per_execution, distribute) 1149 self._steps_per_execution = steps_per_execution 1150 self._steps_per_execution_value = steps_per_execution.numpy().item() -> 1152 adapter_cls = select_data_adapter(x, y) 1153 self._adapter = adapter_cls( 1154 x, 1155 y, (...) 1164 distribution_strategy=distribute_lib.get_strategy(), 1165 model=model) 1167 strategy = distribute_lib.get_strategy() File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:988, in select_data_adapter(x, y) 986 def select_data_adapter(x, y): 987 """Selects a data adapter than can handle a given x and y.""" --> 988 adapter_cls = [cls for cls in ALL_ADAPTER_CLS if cls.can_handle(x, y)] 989 if not adapter_cls: 990 # TODO(scottzhu): This should be a less implementation-specific error. 991 raise ValueError( 992 "Failed to find data adapter that can handle " 993 "input: {}, {}".format( 994 _type_name(x), _type_name(y))) File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:988, in <listcomp>(.0) 986 def select_data_adapter(x, y): 987 """Selects a data adapter than can handle a given x and y.""" --> 988 adapter_cls = [cls for cls in ALL_ADAPTER_CLS if cls.can_handle(x, y)] 989 if not adapter_cls: 990 # TODO(scottzhu): This should be a less implementation-specific error. 991 raise ValueError( 992 "Failed to find data adapter that can handle " 993 "input: {}, {}".format( 994 _type_name(x), _type_name(y))) File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:707, in DatasetAdapter.can_handle(x, y) 704 @staticmethod 705 def can_handle(x, y=None): 706 return (isinstance(x, (data_types.DatasetV1, data_types.DatasetV2)) or --> 707 _is_distributed_dataset(x)) File /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py:1699, in _is_distributed_dataset(ds) 1698 def _is_distributed_dataset(ds): -> 1699 return isinstance(ds, input_lib.DistributedDatasetInterface) AttributeError: module 'tensorflow.python.distribute.input_lib' has no attribute 'DistributedDatasetInterface' ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61974/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61974/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61973
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61973/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61973/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61973/events
https://github.com/tensorflow/tensorflow/pull/61973
1,911,640,189
PR_kwDOArmXAs5bIbvS
61,973
Registering CPU kernel with half dtype for cholesky_op
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" }, { "id": 1178505529, "node_id": "MDU6TGFiZWwxMTc4NTA1NTI5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/prtype:bugfix", "name": "prtype:bugfix", "color": "159b2e", "default": false, "description": "PR to fix a bug" }, { "id": 1478826728, "node_id": "MDU6TGFiZWwxNDc4ODI2NzI4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core", "name": "comp:core", "color": "024391", "default": false, "description": "issues related to core part of tensorflow" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Also not sure for `BatchCholesky` whether half dtype should have support? At present as per code `BatchCholesky` supports only float and double and complex dtypes which are supported on Cholesky also excluded.", "I don't think it's as easy as just registering a kernel for the type. These matrix decomposition ops are sensitive to errors, and using `half` directly in the computation will likely lead to horrible accuracy. It's probably best to do the decomposition in higher precision then cast the final result back to half.", "@cantonios ,\r\n\r\nThanks for the explanation.Actually this Op registered with `half` dtype for **XLA** and hence tried adding kernel here. Also when I cross checked with `jit_compile=True` and with `half` dtype its not raising exception but generating few NaNs in output.Refer attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/b4e804b28f1d2119cc123d489c5dea7c/61973_with_jit_compile.ipynb)\r\n\r\nIs this behaviour is due to the reason you mentioned ?\r\n\r\nAs per your suggestion we can do casting to high precision dtype say `float32` then apply cholesky op and convert the output back to `half` dtype. All this pre and post casting be done at Python level only if I am not wrong. The source code link for [cholesky](https://www.tensorflow.org/api_docs/python/tf/linalg/cholesky) is not available in documentation and I couldn't figure out it exactly. Any help is appreciated.", "> @cantonios ,\r\n> \r\n> Thanks for the explanation.Actually this Op registered with `half` dtype for **XLA** and hence tried adding kernel here. Also when I cross checked with `jit_compile=True` and with `half` dtype its not raising exception but generating few NaNs in output.Refer attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/b4e804b28f1d2119cc123d489c5dea7c/61973_with_jit_compile.ipynb)\r\n> \r\n> Is this behaviour is due to the reason you mentioned ?\r\n\r\nProbably. Personally, I don't think any of these matrix decomposition ops _should_ support `half`, but if they must, then it should definitely do the cast before/after.\r\n\r\n> As per your suggestion we can do casting to high precision dtype say `float32` then apply cholesky op and convert the output back to `half` dtype. All this pre and post casting be done at Python level only if I am not wrong.\r\n\r\nYou need to do the casting in C++ if you're registering a `half` C++ kernel. To do the casting, you would need to create a higher-precision copy of the matrix [here](https://github.com/tensorflow/tensorflow/blob/dab293abf1b258358660173965bc955c3884e5c0/tensorflow/core/kernels/linalg/cholesky_op.cc#L49), then also cast the output back during assignment [here](https://github.com/tensorflow/tensorflow/blob/dab293abf1b258358660173965bc955c3884e5c0/tensorflow/core/kernels/linalg/cholesky_op.cc#L64). I don't know about XLA - that probably also needs to be updated.\r\n\r\n\r\n\r\n", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!\r\n ", "This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "Hi @SuryanarayanaY Any update on this PR? Please. Thank you!", "This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.", "Not stale.Will work on it soon.", "This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.", "This PR was closed because it has been inactive for 14 days since being marked as stale. Please reopen if you'd like to work on this further." ]
2023-09-25T14:29:30
2024-04-07T01:48:46
2024-04-07T01:48:38
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61973", "html_url": "https://github.com/tensorflow/tensorflow/pull/61973", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61973.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61973.patch", "merged_at": null }
The `tf.linalg.cholesky` should support `half` data type as per documentation. The Op registered for `half` data type also in `REGISTER_OP()`. But There is no CPU kernel for this Op to support half dtype. Hence adding the CPU kernel for same. Fixes #61907
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61973/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61973/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61972
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61972/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61972/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61972/events
https://github.com/tensorflow/tensorflow/issues/61972
1,911,167,280
I_kwDOArmXAs5x6hkw
61,972
Unable to load TensorFlow saved model (AttributeError: '_UserObject' object has no attribute 'add_slot')
{ "login": "RabJon", "id": 54168706, "node_id": "MDQ6VXNlcjU0MTY4NzA2", "avatar_url": "https://avatars.githubusercontent.com/u/54168706?v=4", "gravatar_id": "", "url": "https://api.github.com/users/RabJon", "html_url": "https://github.com/RabJon", "followers_url": "https://api.github.com/users/RabJon/followers", "following_url": "https://api.github.com/users/RabJon/following{/other_user}", "gists_url": "https://api.github.com/users/RabJon/gists{/gist_id}", "starred_url": "https://api.github.com/users/RabJon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/RabJon/subscriptions", "organizations_url": "https://api.github.com/users/RabJon/orgs", "repos_url": "https://api.github.com/users/RabJon/repos", "events_url": "https://api.github.com/users/RabJon/events{/privacy}", "received_events_url": "https://api.github.com/users/RabJon/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 3531398540, "node_id": "LA_kwDOArmXAs7SfN2M", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.7", "name": "TF 2.7", "color": "77237D", "default": false, "description": "Issues related to TF 2.7.0" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "@RabJon Could you please try to use the latest TF 2.13 as you are using an older version. \r\nIn order to expedite the trouble-shooting process, please provide a complete code snippet to reproduce the issue reported here. Thank you!", "I faced similar but slightly opposite issue once with `tf.saved_model.load` API but worked in ` tf.keras.models.load_model` API. \r\n\r\nhttps://www.kaggle.com/competitions/google-universal-image-embedding/discussion/336534#1882377", "@sushreebarsa unfortunately there is no GPU support after TF 2.10 for Windows Native. Therefore, I tried TF 2.10 instead of the newest version, but the result was the same as for the versions 2.6 and 2.7.\r\n\r\nHowever, I could reproduce the exception on Google Colab with v2.13. Here is the URL for the notebook: [Model_Load_Problem.ipynb](https://colab.research.google.com/drive/1YyyU6kyn947JCuTHOrjRiDGQb2XBOueu?usp=sharing) ", "Thank you @innat for the comment. Unfortunately, in my case both approaches to loading models do not work.", "@RabJon Generally this error is caused because the model you are trying to load was saved using a newer version of TensorFlow than the one you are currently using. To fix this, you will need to upgrade your TensorFlow installation.\r\n\r\nTo upgrade TensorFlow, run the following command:\r\n```\r\n!pip install tensorflow --upgrade\r\n```\r\nOnce you have upgraded TensorFlow, you can reload the model by running the following code:\r\n\r\n``` \r\nmodel = tf.keras.models.load_model(path)\r\n```\r\nPlease let us know if it helps?\r\nThank you!", "@sushreebarsa I tried to run the same code with TF v2.7 and TF v2.10 on Windows Native and I always got the same exception. Since v2.10, which was released in September 2022, is the latest version of TF for Windows Native it would have been impossible for me to save the models with a newer version than that. Furthermore, many of my models are older than the release date of v2.10 so they were created with a lower version for sure.\r\n\r\nI am fine for now, because I managed to load the models through a loophole in my implementation that I actually never thought to be useful: I did not only save the entire model in \"saved_model\" format, but I also saved the model weights alone as h5 files. Given that I didn't change the model architecture I could recreate and compile the models and then just load the corresponding weights from the h5 files. So, personally I don't need a solution anymore. However, I think that this is still a general issue that needs to be solved.", "@RabJon Thank you for your response here!\r\n\r\nYes, you can always use the .h5 extension in case you are using two different versions for training and loading the models. In the HDF5 format with a .h5 extension you can save weights manually. \r\nCould you please move this issue to closed status if it has been resolved from your end? \r\nStarting with TensorFlow 2.11, you will need to install [TensorFlow in WSL2](https://tensorflow.org/install/pip#windows-wsl2), or install tensorflow or tensorflow-cpu and, optionally, try the [TensorFlow-DirectML-Plugin](https://github.com/microsoft/tensorflow-directml-plugin#tensorflow-directml-plugin-)\r\nThank you!", "Yes, I will close this issue, because it is solved from my site. However, I want to point out again that this was only possible because I decided to save both the entire TensorFlow model (in \"saved_model\" format) and the weights of the trained model (as .h5 file). So, it was due to my (lucky) design decision that I could solve this issue!", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61972\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61972\">No</a>\n" ]
2023-09-25T10:23:54
2023-10-06T08:25:42
2023-10-06T08:25:39
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source binary ### TensorFlow version 2.7.0 ### Custom code Yes ### OS platform and distribution Windows 10 Enterprise LTSC ### Mobile device _No response_ ### Python version 3.9.12 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 11.2/8 ### GPU model and memory Nvidia Geforce RTX 3090 24 GB ### Current behavior? I have several trained TensorFlow models stored on my device in saved_model format. All the models have the same architecture and serve the same purpose, but they were created at different points in time. While I have no problems to load the newest models (created from 5th September 2022 onward) with the command `tensorflow.keras.models.load_model(filepath)`, older models that were created before this date raise the following exception when this method is called: > AttributeError: '_UserObject' object has no attribute 'add_slot' The same exception is also raised when trying to load these models with: `tensorflow.saved_model.load(filepath)`, which was one of the suggestions I found to solve the issue. Another possible solution that I took from the related issue #52091 was to use another TF version, I tried it with the older v2.6 and the newest Windows native version v.2.10, but the result was the same. ### Standalone code to reproduce the issue [EDIT] I could reproduce the exception on Google Colab using the newest TF version. Please find the notebook here: [Model_Load_Problem.ipynb](https://colab.research.google.com/drive/1YyyU6kyn947JCuTHOrjRiDGQb2XBOueu?usp=sharing) ### Relevant log output ```shell 2023-09-25 11:36:20.048929: I tensorflow/core/platform/cpu_feature_guard.cc:151] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX AVX2 To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags. 2023-09-25 11:36:21.096591: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1525] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 18788 MB memory: -> device: 0, name: NVIDIA GeForce RTX 3090, pci bus id: 0000:1a:00.0, compute capability: 8.6 Traceback (most recent call last): File "C:\Users\icon\Desktop\Testing_Models\iCoNet\source\model.py", line 699, in load_trained_model model = tf.keras.models.load_model(model_path) File "C:\Users\icon\.conda\envs\iConNet\lib\site-packages\keras\utils\traceback_utils.py", line 67, in error_handler raise e.with_traceback(filtered_tb) from None File "C:\Users\icon\.conda\envs\iConNet\lib\site-packages\tensorflow\python\saved_model\load.py", line 466, in _load_nodes slot_variable = optimizer_object.add_slot( AttributeError: '_UserObject' object has no attribute 'add_slot' ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61972/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61972/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61971
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61971/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61971/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61971/events
https://github.com/tensorflow/tensorflow/issues/61971
1,910,981,707
I_kwDOArmXAs5x50RL
61,971
Windows 10 Source build failure if python installed in a directory with spaces
{ "login": "ArttuLinden", "id": 47938721, "node_id": "MDQ6VXNlcjQ3OTM4NzIx", "avatar_url": "https://avatars.githubusercontent.com/u/47938721?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ArttuLinden", "html_url": "https://github.com/ArttuLinden", "followers_url": "https://api.github.com/users/ArttuLinden/followers", "following_url": "https://api.github.com/users/ArttuLinden/following{/other_user}", "gists_url": "https://api.github.com/users/ArttuLinden/gists{/gist_id}", "starred_url": "https://api.github.com/users/ArttuLinden/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ArttuLinden/subscriptions", "organizations_url": "https://api.github.com/users/ArttuLinden/orgs", "repos_url": "https://api.github.com/users/ArttuLinden/repos", "events_url": "https://api.github.com/users/ArttuLinden/events{/privacy}", "received_events_url": "https://api.github.com/users/ArttuLinden/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1188421838, "node_id": "MDU6TGFiZWwxMTg4NDIxODM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:windows", "name": "subtype:windows", "color": "b619ea", "default": false, "description": "Windows Build/Installation Issues" }, { "id": 4511033337, "node_id": "LA_kwDOArmXAs8AAAABDODn-Q", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10", "name": "TF 2.10", "color": "C15088", "default": false, "description": "" } ]
closed
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "@ArttuLinden GPU support on native-Windows is only available for 2.10 or earlier versions, starting in TF 2.11, CUDA build is not supported for Windows. For using TensorFlow GPU on Windows, you will need to build/install TensorFlow in WSL2 or use tensorflow-cpu with TensorFlow-DirectML-Plugin. Please check the configuration for TF v2.10 as mentioned [here](https://www.tensorflow.org/install/source_windows#gpu). Thank you!", "Hi, I am aware that 2.10 is the latest version for native windows to support tensorflow GPU. I have followed the guideline and my current configuration matches with `tensorflow_gpu-2.10.0 | 3.7-3.10 | MSVC 2019 | Bazel 5.1.1 | 8.1 | 11.2`. As I stated it is a bug in the `cuda_configure.bzl` that python_bin_path can't point to a python executive where the path contains spaces. Function `_check_cuda_libs (line 492)`. Especially these lines in the `cuda_configure.bzl` cause the error:\r\n\r\ncmd += \"system('%s script.py %s');\" % (python_bin, args)\r\nall_paths = [path for path, _ in libs]\r\nchecked_paths = execute(repository_ctx, [python_bin, \"-c\", cmd]).stdout.splitlines()\r\n\r\nPYTHON_BIN_PATH=C:/Python39/python.exe -- This works\r\nPYTHON_BIN_PATH=C:/Program Files/Python39/python.exe -- This fails", "@ArttuLinden, can you pls try PYTHON_BIN_PATH=C:/Program\\ Files/Python39/python.exe\r\nor try C:\\Program Files\\Python39\\python.exe\r\nPlease let us know if you face any issue further or if the error persists", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61971\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61971\">No</a>\n" ]
2023-09-25T08:41:33
2023-10-26T01:47:27
2023-10-26T01:47:24
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version tf 2.10 ### Custom code Yes ### OS platform and distribution Windows 10 ### Mobile device _No response_ ### Python version 3.9.13 ### Bazel version 5.1.1 ### GCC/compiler version _No response_ ### CUDA/cuDNN version 11.2/8.1.1 ### GPU model and memory Quadro P2000 / 5 Gb ### Current behavior? Building 2.10 tensorflow with cuda support from sources using Bazel 5.1.1 would result in an error if the python is downloaded in a directory with spaces. In my case I had python installed under `C:/Program Files/python39`. The error showed that: `'c:/program' is not recognized as an internal or external command building tensorflow'`. I traced this error into the `tensorflow\third_party\gpus\cuda_configure.bzl` file. In this file there is a function called `_check_cuda_libs` (line 492). This function checks the precense of cuda libraries by compling a cmd. However, the cmd won't work if the python_bin points to a python executive which is located in a directory with spaces. This error was simply fixed by moving python to a directory without spaces (No need to change the scripts inside `.bzl` file). ### Standalone code to reproduce the issue ```shell You should be able to reproduce the issue by following the "Build from source on Windows" instructions and downloading python for example under "Program Files" folder. Build should be configured to include CUDA support. I used the following build command: bazel build --config=opt --config=cuda --define=no_tensorflow_py_deps=true //tensorflow/tools/pip_package:build_pip_package ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61971/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61971/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61970
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61970/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61970/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61970/events
https://github.com/tensorflow/tensorflow/pull/61970
1,910,858,679
PR_kwDOArmXAs5bFxGi
61,970
Corrected several typos
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-25T07:29:38
2023-10-03T08:40:42
2023-10-03T08:40:41
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61970", "html_url": "https://github.com/tensorflow/tensorflow/pull/61970", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61970.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61970.patch", "merged_at": "2023-10-03T08:40:41" }
Documentation has been updated with correct words. Please have a look at this and do the needful. Thank you!
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61970/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61970/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61969
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61969/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61969/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61969/events
https://github.com/tensorflow/tensorflow/issues/61969
1,910,469,842
I_kwDOArmXAs5x33TS
61,969
Use github.com/apssouza22/chatflow as a conversational layer. It would enable actual API requests to be carried out from natural language inputs.
{ "login": "GiovanniSmokes", "id": 138458840, "node_id": "U_kgDOCEC22A", "avatar_url": "https://avatars.githubusercontent.com/u/138458840?v=4", "gravatar_id": "", "url": "https://api.github.com/users/GiovanniSmokes", "html_url": "https://github.com/GiovanniSmokes", "followers_url": "https://api.github.com/users/GiovanniSmokes/followers", "following_url": "https://api.github.com/users/GiovanniSmokes/following{/other_user}", "gists_url": "https://api.github.com/users/GiovanniSmokes/gists{/gist_id}", "starred_url": "https://api.github.com/users/GiovanniSmokes/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/GiovanniSmokes/subscriptions", "organizations_url": "https://api.github.com/users/GiovanniSmokes/orgs", "repos_url": "https://api.github.com/users/GiovanniSmokes/repos", "events_url": "https://api.github.com/users/GiovanniSmokes/events{/privacy}", "received_events_url": "https://api.github.com/users/GiovanniSmokes/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173272, "node_id": "MDU6TGFiZWw0NzMxNzMyNzI=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature", "name": "type:feature", "color": "159b2e", "default": false, "description": "Feature requests" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" } ]
closed
true
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@GiovanniSmokes,\r\nCould you please elaborate about your Feature. Also, please specify the Use Cases for this feature which helps us to analyse the issue. Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "Doesn't belong in the repo, looks more like promo/spam" ]
2023-09-25T00:59:47
2023-10-04T19:18:14
2023-10-04T19:18:14
NONE
spam
null
null
### Issue type Feature Request ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version all of em ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Fine as hell ### Standalone code to reproduce the issue ```shell n/a ``` ### Relevant log output ```shell i <3 tensorflow ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61969/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61969/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61968
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61968/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61968/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61968/events
https://github.com/tensorflow/tensorflow/issues/61968
1,910,435,733
I_kwDOArmXAs5x3u-V
61,968
TFLite model with `l2_normalize(tf.transpose(x))` produces wrong outputs
{ "login": "dengyinlin", "id": 30567397, "node_id": "MDQ6VXNlcjMwNTY3Mzk3", "avatar_url": "https://avatars.githubusercontent.com/u/30567397?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dengyinlin", "html_url": "https://github.com/dengyinlin", "followers_url": "https://api.github.com/users/dengyinlin/followers", "following_url": "https://api.github.com/users/dengyinlin/following{/other_user}", "gists_url": "https://api.github.com/users/dengyinlin/gists{/gist_id}", "starred_url": "https://api.github.com/users/dengyinlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dengyinlin/subscriptions", "organizations_url": "https://api.github.com/users/dengyinlin/orgs", "repos_url": "https://api.github.com/users/dengyinlin/repos", "events_url": "https://api.github.com/users/dengyinlin/events{/privacy}", "received_events_url": "https://api.github.com/users/dengyinlin/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" } ]
open
false
{ "login": "haozha111", "id": 6316921, "node_id": "MDQ6VXNlcjYzMTY5MjE=", "avatar_url": "https://avatars.githubusercontent.com/u/6316921?v=4", "gravatar_id": "", "url": "https://api.github.com/users/haozha111", "html_url": "https://github.com/haozha111", "followers_url": "https://api.github.com/users/haozha111/followers", "following_url": "https://api.github.com/users/haozha111/following{/other_user}", "gists_url": "https://api.github.com/users/haozha111/gists{/gist_id}", "starred_url": "https://api.github.com/users/haozha111/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/haozha111/subscriptions", "organizations_url": "https://api.github.com/users/haozha111/orgs", "repos_url": "https://api.github.com/users/haozha111/repos", "events_url": "https://api.github.com/users/haozha111/events{/privacy}", "received_events_url": "https://api.github.com/users/haozha111/received_events", "type": "User", "site_admin": false }
[ { "login": "haozha111", "id": 6316921, "node_id": "MDQ6VXNlcjYzMTY5MjE=", "avatar_url": "https://avatars.githubusercontent.com/u/6316921?v=4", "gravatar_id": "", "url": "https://api.github.com/users/haozha111", "html_url": "https://github.com/haozha111", "followers_url": "https://api.github.com/users/haozha111/followers", "following_url": "https://api.github.com/users/haozha111/following{/other_user}", "gists_url": "https://api.github.com/users/haozha111/gists{/gist_id}", "starred_url": "https://api.github.com/users/haozha111/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/haozha111/subscriptions", "organizations_url": "https://api.github.com/users/haozha111/orgs", "repos_url": "https://api.github.com/users/haozha111/repos", "events_url": "https://api.github.com/users/haozha111/events{/privacy}", "received_events_url": "https://api.github.com/users/haozha111/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "I was able to reproduce this in TF 2.14 and nightly as well. Please find this [gist](https://colab.research.google.com/gist/pjpratik/ebeaf229c5c8e161fa24ea6c76b75e4a/61968.ipynb).\r\n\r\n@pkgoogle Could you please look into this issue?\r\n\r\nThanks.", "I was able to reproduce with the same gist as above, @haozha111, can you please take a look? Thanks." ]
2023-09-25T00:12:15
2023-09-28T21:03:45
null
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04 - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0-dev20230924 ### 2. Code ```python import tensorflow as tf import numpy as np class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.b = tf.Variable(np.array([[1],[2]],dtype=np.float32)) def call(self, x): x = tf.add(x,1) return tf.math.l2_normalize(tf.transpose(x)) # Initializing the model m = Model() # Call model input_shape = [1, 1, 2] x1 = tf.constant(1., shape=input_shape) y1 = m(x1) print('expected model output:') print(y1) converter = tf.lite.TFLiteConverter.from_keras_model(m) tflite_model = converter.convert() def _evaluateTFLiteModel(tflite_model, input_data): interpreter = tf.lite.Interpreter(model_content=tflite_model) interpreter.allocate_tensors() input_details = interpreter.get_input_details() output_details = interpreter.get_output_details() for i in range(len(input_data)): interpreter.set_tensor(input_details[i]['index'], input_data[i]) interpreter.invoke() output_data = [interpreter.get_tensor(output_details[i]['index']) for i in range(len(output_details))] return output_data actual_value = _evaluateTFLiteModel(tflite_model,[x1]) print('tflite model output:') print(actual_value[0]) ``` ### 3. Failure after conversion Output: ``` expected model output: tf.Tensor( [[[0.70710677]] [[0.70710677]]], shape=(2, 1, 1), dtype=float32) tflite model output: [[[1.]] [[1.]]] ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61968/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61968/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61967
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61967/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61967/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61967/events
https://github.com/tensorflow/tensorflow/issues/61967
1,910,428,050
I_kwDOArmXAs5x3tGS
61,967
TFLite model produces wrong output after fusion optimization
{ "login": "dengyinlin", "id": 30567397, "node_id": "MDQ6VXNlcjMwNTY3Mzk3", "avatar_url": "https://avatars.githubusercontent.com/u/30567397?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dengyinlin", "html_url": "https://github.com/dengyinlin", "followers_url": "https://api.github.com/users/dengyinlin/followers", "following_url": "https://api.github.com/users/dengyinlin/following{/other_user}", "gists_url": "https://api.github.com/users/dengyinlin/gists{/gist_id}", "starred_url": "https://api.github.com/users/dengyinlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dengyinlin/subscriptions", "organizations_url": "https://api.github.com/users/dengyinlin/orgs", "repos_url": "https://api.github.com/users/dengyinlin/repos", "events_url": "https://api.github.com/users/dengyinlin/events{/privacy}", "received_events_url": "https://api.github.com/users/dengyinlin/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 2671351731, "node_id": "MDU6TGFiZWwyNjcxMzUxNzMx", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ModelOptimizationToolkit", "name": "ModelOptimizationToolkit", "color": "BFD629", "default": false, "description": "TF Model Optimization Toolkit" } ]
open
false
{ "login": "abattery", "id": 3203059, "node_id": "MDQ6VXNlcjMyMDMwNTk=", "avatar_url": "https://avatars.githubusercontent.com/u/3203059?v=4", "gravatar_id": "", "url": "https://api.github.com/users/abattery", "html_url": "https://github.com/abattery", "followers_url": "https://api.github.com/users/abattery/followers", "following_url": "https://api.github.com/users/abattery/following{/other_user}", "gists_url": "https://api.github.com/users/abattery/gists{/gist_id}", "starred_url": "https://api.github.com/users/abattery/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abattery/subscriptions", "organizations_url": "https://api.github.com/users/abattery/orgs", "repos_url": "https://api.github.com/users/abattery/repos", "events_url": "https://api.github.com/users/abattery/events{/privacy}", "received_events_url": "https://api.github.com/users/abattery/received_events", "type": "User", "site_admin": false }
[ { "login": "abattery", "id": 3203059, "node_id": "MDQ6VXNlcjMyMDMwNTk=", "avatar_url": "https://avatars.githubusercontent.com/u/3203059?v=4", "gravatar_id": "", "url": "https://api.github.com/users/abattery", "html_url": "https://github.com/abattery", "followers_url": "https://api.github.com/users/abattery/followers", "following_url": "https://api.github.com/users/abattery/following{/other_user}", "gists_url": "https://api.github.com/users/abattery/gists{/gist_id}", "starred_url": "https://api.github.com/users/abattery/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abattery/subscriptions", "organizations_url": "https://api.github.com/users/abattery/orgs", "repos_url": "https://api.github.com/users/abattery/repos", "events_url": "https://api.github.com/users/abattery/events{/privacy}", "received_events_url": "https://api.github.com/users/abattery/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "I was able to reproduce this in TF 2.14 and nightly as well. Please find this [gist](https://colab.research.google.com/gist/pjpratik/3fa5fdf7a56b481f61fd7698e2b6ed50/61967.ipynb).\r\n\r\n@pkgoogle Could you please look into this issue?\r\n\r\nThanks.", "I was able to reproduce with the same gist, @abattery, can you please take a look? Thanks." ]
2023-09-25T00:01:12
2023-09-28T21:11:51
null
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04 - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0-dev20230924 ### 2. Code ``` import tensorflow as tf class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__(name="model") self.w1 = tf.Variable([[0.], [0.5]]) self.b1 = tf.Variable([-4.]) self.r = tf.Variable([-7.]) self.c = tf.Variable(1.) self.m1 = tf.Variable([-4.]) self.m2 = tf.Variable([1.]) def call(self, x): x = x + self.m1 x2 = tf.math.multiply(x, self.r) x3 = tf.linalg.matmul(x2, self.w1) x4 = tf.math.add(x3, self.b1) x5 = tf.math.multiply(x4, self.r) x6 = tf.math.add(x5, self.m2) x7 = tf.math.multiply(x6, self.r) return x7 # Initializing the model m = Model() # Inputs to the model x = tf.constant([[2., -3.]], shape=[1, 2], dtype=tf.float32) # Call model y = m(x) print('expected model output:') print(y) converter = tf.lite.TFLiteConverter.from_keras_model(m) tflite_model = converter.convert() def _evaluateTFLiteModel(tflite_model, input_data): interpreter = tf.lite.Interpreter(model_content=tflite_model) interpreter.allocate_tensors() input_details = interpreter.get_input_details() output_details = interpreter.get_output_details() for i in range(len(input_data)): interpreter.set_tensor(input_details[i]['index'], input_data[i]) interpreter.invoke() output_data = [interpreter.get_tensor(output_details[i]['index']) for i in range(len(output_details))] return output_data actual_value = _evaluateTFLiteModel(tflite_model,[x]) print('tflite model output:') print(actual_value[0]) ``` ### 3. Failure after conversion Output: ``` expected model output: tf.Tensor([[997.5]], shape=(1, 1), dtype=float32) tflite model output: [[311.5]] ``` P.S. It seems multiple optimizations are triggered, including `FuseAddAndFullyConnected`, `FuseMulAndFullyConnected`, `FuseFullyConnectedAndMul`, `FuseFullyConnectedAndAdd`. It's unclear which one of them causes the bug and further inspection is needed.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61967/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61967/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61966
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61966/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61966/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61966/events
https://github.com/tensorflow/tensorflow/issues/61966
1,910,325,369
I_kwDOArmXAs5x3UB5
61,966
Color prediction result
{ "login": "A729891", "id": 144511711, "node_id": "U_kgDOCJ0S3w", "avatar_url": "https://avatars.githubusercontent.com/u/144511711?v=4", "gravatar_id": "", "url": "https://api.github.com/users/A729891", "html_url": "https://github.com/A729891", "followers_url": "https://api.github.com/users/A729891/followers", "following_url": "https://api.github.com/users/A729891/following{/other_user}", "gists_url": "https://api.github.com/users/A729891/gists{/gist_id}", "starred_url": "https://api.github.com/users/A729891/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/A729891/subscriptions", "organizations_url": "https://api.github.com/users/A729891/orgs", "repos_url": "https://api.github.com/users/A729891/repos", "events_url": "https://api.github.com/users/A729891/events{/privacy}", "received_events_url": "https://api.github.com/users/A729891/received_events", "type": "User", "site_admin": false }
[]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @A729891 ,\r\n\r\nCould you please file the issue in prescribed format attached [here](https://github.com/tensorflow/tensorflow/issues/new?assignees=&labels=&projects=&template=tensorflow_issue_template.yaml) with all the relevant details needed?", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further." ]
2023-09-24T18:03:29
2023-10-11T01:47:22
2023-10-11T01:47:20
NONE
null
null
null
Fastwin color prediction game results
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61966/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61966/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61965
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61965/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61965/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61965/events
https://github.com/tensorflow/tensorflow/issues/61965
1,909,982,082
I_kwDOArmXAs5x2AOC
61,965
XLA compiled `floordiv` allows `integer division by zero`
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1133285679, "node_id": "MDU6TGFiZWwxMTMzMjg1Njc5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla", "name": "comp:xla", "color": "0052cc", "default": false, "description": "XLA" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@YangChenyuan,\r\nI was able to reproduce the issue on TensorFlow v2.15, v2.16 and tf-nightly. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/4a765779a644a2c13cc09d78d81e55fc/untitled1906.ipynb)." ]
2023-09-23T19:51:17
2024-05-20T07:02:36
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230914 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA compiled `floordiv` allows `integer division by zero` where an exception `Integer division by zero` will be raised without XLA compilation. ### Standalone code to reproduce the issue ```shell import tensorflow as tf """ XLA Compiled """ class Model(tf.keras.Model): @tf.function(jit_compile=True) def call(self, x1): x2 = tf.math.floordiv(3, 0) x3 = tf.math.multiply(x1, x2) return x3 m = Model() x1 = tf.constant(1, shape=[]) print(m(x1)) # tf.Tensor(-1, shape=(), dtype=int32) """ Without XLA """ class Model(tf.keras.Model): def call(self, x1): x2 = tf.math.floordiv(3, 0) x3 = tf.math.multiply(x1, x2) return x3 m = Model() x1 = tf.constant(1, shape=[]) print(m(x1)) ``` ### Relevant log output ```shell InvalidArgumentError: Exception encountered when calling layer 'model_21' (type Model). {{function_node __wrapped__FloorDiv_device_/job:localhost/replica:0/task:0/device:CPU:0}} Integer division by zero [Op:FloorDiv] name: Call arguments received by layer 'model_21' (type Model): • x1=tf.Tensor(shape=(), dtype=int32) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61965/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61965/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61964
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61964/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61964/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61964/events
https://github.com/tensorflow/tensorflow/issues/61964
1,909,953,800
I_kwDOArmXAs5x15UI
61,964
also missing from the include "patch" is file "tensorflow/tsl/c/tsl_status.h" (there might be others)
{ "login": "esohns", "id": 510572, "node_id": "MDQ6VXNlcjUxMDU3Mg==", "avatar_url": "https://avatars.githubusercontent.com/u/510572?v=4", "gravatar_id": "", "url": "https://api.github.com/users/esohns", "html_url": "https://github.com/esohns", "followers_url": "https://api.github.com/users/esohns/followers", "following_url": "https://api.github.com/users/esohns/following{/other_user}", "gists_url": "https://api.github.com/users/esohns/gists{/gist_id}", "starred_url": "https://api.github.com/users/esohns/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/esohns/subscriptions", "organizations_url": "https://api.github.com/users/esohns/orgs", "repos_url": "https://api.github.com/users/esohns/repos", "events_url": "https://api.github.com/users/esohns/events{/privacy}", "received_events_url": "https://api.github.com/users/esohns/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 1188421838, "node_id": "MDU6TGFiZWwxMTg4NDIxODM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:windows", "name": "subtype:windows", "color": "b619ea", "default": false, "description": "Windows Build/Installation Issues" }, { "id": 5244472328, "node_id": "LA_kwDOArmXAs8AAAABOJhMCA", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:cpu-intel", "name": "subtype:cpu-intel", "color": "507561", "default": false, "description": "To track windows cpu issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
closed
false
{ "login": "nitins17", "id": 29348997, "node_id": "MDQ6VXNlcjI5MzQ4OTk3", "avatar_url": "https://avatars.githubusercontent.com/u/29348997?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nitins17", "html_url": "https://github.com/nitins17", "followers_url": "https://api.github.com/users/nitins17/followers", "following_url": "https://api.github.com/users/nitins17/following{/other_user}", "gists_url": "https://api.github.com/users/nitins17/gists{/gist_id}", "starred_url": "https://api.github.com/users/nitins17/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nitins17/subscriptions", "organizations_url": "https://api.github.com/users/nitins17/orgs", "repos_url": "https://api.github.com/users/nitins17/repos", "events_url": "https://api.github.com/users/nitins17/events{/privacy}", "received_events_url": "https://api.github.com/users/nitins17/received_events", "type": "User", "site_admin": false }
[ { "login": "nitins17", "id": 29348997, "node_id": "MDQ6VXNlcjI5MzQ4OTk3", "avatar_url": "https://avatars.githubusercontent.com/u/29348997?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nitins17", "html_url": "https://github.com/nitins17", "followers_url": "https://api.github.com/users/nitins17/followers", "following_url": "https://api.github.com/users/nitins17/following{/other_user}", "gists_url": "https://api.github.com/users/nitins17/gists{/gist_id}", "starred_url": "https://api.github.com/users/nitins17/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nitins17/subscriptions", "organizations_url": "https://api.github.com/users/nitins17/orgs", "repos_url": "https://api.github.com/users/nitins17/repos", "events_url": "https://api.github.com/users/nitins17/events{/privacy}", "received_events_url": "https://api.github.com/users/nitins17/received_events", "type": "User", "site_admin": false } ]
null
[ "note: this issue picks up where #59762 left off", "@esohns ,\r\n\r\nThanks for your time bringing this.I have gone through the older ticket #59762, understood the context and it seems there might be a fix for this. Would it still exists in latest versions also ? Please confirm meanwhile I will bring this to the attention of concerned team.\r\n\r\nWindows builds are maintained by the intel team, hence I am bringing the issue to their attention to fix it if not fixed already in latest/nightly version.\r\n\r\nCC- @TensorFlow-MKL for comments.\r\n\r\nThank you!", " @TensorFlow-MKL,\r\nthis came from the latest c download (version 2.14) off the project site. After inserting the tf_buffer.h and tsl_status.h header files (both taken from the linux tarball), my project compiles just fine. So at least these two files should be included in the windows release zip file.", "Hi @esohns and @SuryanarayanaY, the issue should be fixed in the upcoming releases. Thank you!", "@esohns Thanks for letting us know! It does seem like we were missing certain headers in the Windows libtensorflow archive. https://github.com/tensorflow/tensorflow/commit/66681ea34bee93fa359486458f92ceea864cc6de should fix it. ", "ok thank you for fixing this issue" ]
2023-09-23T18:04:32
2024-04-18T19:54:25
2023-10-27T16:15:41
NONE
null
null
null
also missing from the include "patch" is file "tensorflow/tsl/c/tsl_status.h" (there might be others) _Originally posted by @esohns in https://github.com/tensorflow/tensorflow/issues/59762#issuecomment-1732376736_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61964/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61964/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61963
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61963/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61963/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61963/events
https://github.com/tensorflow/tensorflow/issues/61963
1,909,886,794
I_kwDOArmXAs5x1o9K
61,963
KeyError: 'min'
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61963\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61963\">No</a>\n" ]
2023-09-23T14:14:42
2023-09-23T15:47:05
2023-09-23T15:47:02
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/operation_layers.py", line 31, in convert_clip if params['min'] == 0: KeyError: 'min' ### Standalone code to reproduce the issue ```shell from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('ssd_bmv1_torch.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'ssd_bmv1_torch.h5', overwrite=True, save_format="h5") onnx file can be downloaded at https://pan.xunlei.com/s/VNf1O2DqsdqdbTYYpyemSqveA1?pwd=by77# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/operation_layers.py", line 31, in convert_clip if params['min'] == 0: KeyError: 'min' ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61963/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61963/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61962
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61962/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61962/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61962/events
https://github.com/tensorflow/tensorflow/issues/61962
1,909,885,774
I_kwDOArmXAs5x1otO
61,962
KeyError: 'ConstantOfShape'
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" } ]
closed
false
{ "login": "Varsha-anjanappa", "id": 137163810, "node_id": "U_kgDOCCz0Ig", "avatar_url": "https://avatars.githubusercontent.com/u/137163810?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Varsha-anjanappa", "html_url": "https://github.com/Varsha-anjanappa", "followers_url": "https://api.github.com/users/Varsha-anjanappa/followers", "following_url": "https://api.github.com/users/Varsha-anjanappa/following{/other_user}", "gists_url": "https://api.github.com/users/Varsha-anjanappa/gists{/gist_id}", "starred_url": "https://api.github.com/users/Varsha-anjanappa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Varsha-anjanappa/subscriptions", "organizations_url": "https://api.github.com/users/Varsha-anjanappa/orgs", "repos_url": "https://api.github.com/users/Varsha-anjanappa/repos", "events_url": "https://api.github.com/users/Varsha-anjanappa/events{/privacy}", "received_events_url": "https://api.github.com/users/Varsha-anjanappa/received_events", "type": "User", "site_admin": false }
[ { "login": "Varsha-anjanappa", "id": 137163810, "node_id": "U_kgDOCCz0Ig", "avatar_url": "https://avatars.githubusercontent.com/u/137163810?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Varsha-anjanappa", "html_url": "https://github.com/Varsha-anjanappa", "followers_url": "https://api.github.com/users/Varsha-anjanappa/followers", "following_url": "https://api.github.com/users/Varsha-anjanappa/following{/other_user}", "gists_url": "https://api.github.com/users/Varsha-anjanappa/gists{/gist_id}", "starred_url": "https://api.github.com/users/Varsha-anjanappa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Varsha-anjanappa/subscriptions", "organizations_url": "https://api.github.com/users/Varsha-anjanappa/orgs", "repos_url": "https://api.github.com/users/Varsha-anjanappa/repos", "events_url": "https://api.github.com/users/Varsha-anjanappa/events{/privacy}", "received_events_url": "https://api.github.com/users/Varsha-anjanappa/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61962\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61962\">No</a>\n" ]
2023-09-23T14:11:33
2023-09-23T15:47:11
2023-09-23T15:47:08
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version 3.8.17 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( KeyError: 'ConstantOfShape' ### Standalone code to reproduce the issue ```shell from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('patchcore_torch.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'patchcore_torch.h5', overwrite=True, save_format="h5") onnx file can be downloaded at https://pan.xunlei.com/s/VNf1NLiBYfIh_GKpSvMjqJQAA1?pwd=3wzb# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( KeyError: 'ConstantOfShape' ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61962/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61962/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61961
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61961/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61961/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61961/events
https://github.com/tensorflow/tensorflow/issues/61961
1,909,884,471
I_kwDOArmXAs5x1oY3
61,961
AttributeError: Number of inputs is not equal 1 for unsqueeze layer
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61961\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61961\">No</a>\n" ]
2023-09-23T14:07:35
2023-09-23T15:47:17
2023-09-23T15:47:14
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version 3.8.17 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['onnx::Unsqueeze_0'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 210, in convert_unsqueeze raise AttributeError('Number of inputs is not equal 1 for unsqueeze layer') AttributeError: Number of inputs is not equal 1 for unsqueeze layer ### Standalone code to reproduce the issue ```shell please run the below codes to reproduce: from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('textcnn_torch.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['onnx::Unsqueeze_0'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'textcnn_torch.h5', overwrite=True, save_format="h5") ``` onnx file can be downloaded at https://pan.xunlei.com/s/VNf1M2KIkqx6PBbrBdTiuTkMA1?pwd=wxqf# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['onnx::Unsqueeze_0'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 210, in convert_unsqueeze raise AttributeError('Number of inputs is not equal 1 for unsqueeze layer') AttributeError: Number of inputs is not equal 1 for unsqueeze layer ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61961/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61961/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61960
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61960/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61960/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61960/events
https://github.com/tensorflow/tensorflow/issues/61960
1,909,883,000
I_kwDOArmXAs5x1oB4
61,960
AttributeError: Can't gather from tf tensor.
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 4257391797, "node_id": "LA_kwDOArmXAs79wqS1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/wsl2", "name": "wsl2", "color": "A352E6", "default": false, "description": "Windows Subsystem for Linux" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Hi @pzy2000 ,\r\n\r\nWe can't say for sure whether it is related to tensorflow or keras since there is another library i.e `onxx` involved here.\r\n\r\nCould you please submit a code without external libraries dependencies to reproduce the reported issue.We are not sure whether its bug in `onxx` or `TF/keras`.\r\n\r\nThank you!\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61960\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61960\">No</a>\n" ]
2023-09-23T14:02:34
2023-10-11T01:47:26
2023-10-11T01:47:22
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version 3.8.17 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['onnx::Cast_0', 'onnx::Cast_1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 87, in convert_gather raise AttributeError('Can\'t gather from tf tensor.') AttributeError: Can't gather from tf tensor. ### Standalone code to reproduce the issue ```shell please run the codes below to reproduce: from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('fasttext_torch.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['onnx::Cast_0', 'onnx::Cast_1'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'fasttext_torch.h5', overwrite=True, save_format="h5") ``` onnx file can be downloaded at https://pan.xunlei.com/s/VNf1LHoMqVe2TuzMTA8uhjO5A1?pwd=ibm3# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['onnx::Cast_0', 'onnx::Cast_1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 87, in convert_gather raise AttributeError('Can\'t gather from tf tensor.') AttributeError: Can't gather from tf tensor. ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61960/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61960/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61959
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61959/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61959/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61959/events
https://github.com/tensorflow/tensorflow/issues/61959
1,909,881,162
I_kwDOArmXAs5x1nlK
61,959
AttributeError: Not implemented
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61959\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61959\">No</a>\n" ]
2023-09-23T13:56:17
2023-09-23T15:47:40
2023-09-23T15:47:38
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version 3.8.17 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 294, in convert_slice raise AttributeError('Not implemented') AttributeError: Not implemented ### Standalone code to reproduce the issue ```shell reproduce by running the following code: from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('deeplabv3_torch.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'deeplabv3_torch.h5', overwrite=True, save_format="h5") ``` onnx file can be downloaded at https://pan.xunlei.com/s/VNf1JfHu9m6WG6yE2IuzWtKpA1?pwd=ux7b# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['input.1'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/reshape_layers.py", line 294, in convert_slice raise AttributeError('Not implemented') AttributeError: Not implemented ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61959/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61959/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61958
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61958/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61958/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61958/events
https://github.com/tensorflow/tensorflow/issues/61958
1,909,876,769
I_kwDOArmXAs5x1mgh
61,958
ValueError: Exception encountered when calling layer "13" (type Lambda).
{ "login": "pzy2000", "id": 77827720, "node_id": "MDQ6VXNlcjc3ODI3NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pzy2000", "html_url": "https://github.com/pzy2000", "followers_url": "https://api.github.com/users/pzy2000/followers", "following_url": "https://api.github.com/users/pzy2000/following{/other_user}", "gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}", "starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions", "organizations_url": "https://api.github.com/users/pzy2000/orgs", "repos_url": "https://api.github.com/users/pzy2000/repos", "events_url": "https://api.github.com/users/pzy2000/events{/privacy}", "received_events_url": "https://api.github.com/users/pzy2000/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" } ]
closed
false
{ "login": "Varsha-anjanappa", "id": 137163810, "node_id": "U_kgDOCCz0Ig", "avatar_url": "https://avatars.githubusercontent.com/u/137163810?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Varsha-anjanappa", "html_url": "https://github.com/Varsha-anjanappa", "followers_url": "https://api.github.com/users/Varsha-anjanappa/followers", "following_url": "https://api.github.com/users/Varsha-anjanappa/following{/other_user}", "gists_url": "https://api.github.com/users/Varsha-anjanappa/gists{/gist_id}", "starred_url": "https://api.github.com/users/Varsha-anjanappa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Varsha-anjanappa/subscriptions", "organizations_url": "https://api.github.com/users/Varsha-anjanappa/orgs", "repos_url": "https://api.github.com/users/Varsha-anjanappa/repos", "events_url": "https://api.github.com/users/Varsha-anjanappa/events{/privacy}", "received_events_url": "https://api.github.com/users/Varsha-anjanappa/received_events", "type": "User", "site_admin": false }
[ { "login": "Varsha-anjanappa", "id": 137163810, "node_id": "U_kgDOCCz0Ig", "avatar_url": "https://avatars.githubusercontent.com/u/137163810?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Varsha-anjanappa", "html_url": "https://github.com/Varsha-anjanappa", "followers_url": "https://api.github.com/users/Varsha-anjanappa/followers", "following_url": "https://api.github.com/users/Varsha-anjanappa/following{/other_user}", "gists_url": "https://api.github.com/users/Varsha-anjanappa/gists{/gist_id}", "starred_url": "https://api.github.com/users/Varsha-anjanappa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Varsha-anjanappa/subscriptions", "organizations_url": "https://api.github.com/users/Varsha-anjanappa/orgs", "repos_url": "https://api.github.com/users/Varsha-anjanappa/repos", "events_url": "https://api.github.com/users/Varsha-anjanappa/events{/privacy}", "received_events_url": "https://api.github.com/users/Varsha-anjanappa/received_events", "type": "User", "site_admin": false } ]
null
[ "This at most belongs to keras, not TF", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61958\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61958\">No</a>\n" ]
2023-09-23T13:40:43
2023-09-23T15:47:47
2023-09-23T15:47:45
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.13 ### Custom code Yes ### OS platform and distribution 5.15.90.1-microsoft-standard-WSL2 ### Mobile device _No response_ ### Python version 3.8.17 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? <html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"> <head> <meta name=ProgId content=Excel.Sheet> <meta name=Generator content="Microsoft Excel 15"> <link id=Main-File rel=Main-File href="file:///C:/Users/pengg/AppData/Local/Temp/msohtmlclip1/01/clip.htm"> <link rel=File-List href="file:///C:/Users/pengg/AppData/Local/Temp/msohtmlclip1/01/clip_filelist.xml"> <style> <!--table {mso-displayed-decimal-separator:"\."; mso-displayed-thousand-separator:"\,";} @page {margin:.75in .7in .75in .7in; mso-header-margin:.3in; mso-footer-margin:.3in;} .font5 {color:windowtext; font-size:9.0pt; font-weight:400; font-style:normal; text-decoration:none; font-family:等线; mso-generic-font-family:auto; mso-font-charset:134;} tr {mso-height-source:auto; mso-ruby-visibility:none;} col {mso-width-source:auto; mso-ruby-visibility:none;} br {mso-data-placement:same-cell;} td {padding-top:1px; padding-right:1px; padding-left:1px; mso-ignore:padding; color:black; font-size:11.0pt; font-weight:400; font-style:normal; text-decoration:none; font-family:等线; mso-generic-font-family:auto; mso-font-charset:134; mso-number-format:General; text-align:general; vertical-align:middle; border:none; mso-background-source:auto; mso-pattern:auto; mso-protection:locked visible; white-space:nowrap; mso-rotate:0;} .xl65 {text-align:center;} .xl66 {text-align:center; white-space:normal;} ruby {ruby-align:left;} rt {color:windowtext; font-size:9.0pt; font-weight:400; font-style:normal; text-decoration:none; font-family:等线; mso-generic-font-family:auto; mso-font-charset:134; mso-char-type:none; display:none;} --> </style> </head> <body link="#0563C1" vlink="#954F72"> ValueError: Exception encountered when calling layer "13" (type Lambda). Dimensions must be equal, but are 204 and 206 for '{{node 13/Add}} = AddV2[T=DT_FLOAT](Placeholder, Placeholder_1)' with input shapes: [?,64,204,204], [?,64,206,206]. Call arguments received by layer "13" (type Lambda):   • inputs=['tf.Tensor(shape=(None, 64, 204, 204), dtype=float32)', 'tf.Tensor(shape=(None, 64, 206, 206), dtype=float32)']   • mask=None   • training=None -- </body> </html> ### Standalone code to reproduce the issue ```shell just run the following code to reproduce: from onnx2keras import onnx_to_keras import keras import onnx import sys # sys.path.append("/root/MR") onnx_model = onnx.load('yolov3_darknet53.onnx') onnx_inputs = onnx_model.graph.input print("===========================") print(onnx_inputs) # onnx_model = onnx.load('vgg11.onnx') k_model = onnx_to_keras(onnx_model, ['x'], name_policy='renumerate', verbose=True) keras.models.save_model(k_model, 'ssd_resnet50fpn_torch.h5', overwrite=True, save_format="h5") ``` the onnx file can be downloaded at https://pan.xunlei.com/s/VNf1FtBh2v6mP_QXJWVailBmA1?pwd=g43e# ``` ### Relevant log output ```shell Traceback (most recent call last): File "o2k.py", line 11, in <module> k_model = onnx_to_keras(onnx_model, ['x'], name_policy='renumerate', verbose=True) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/converter.py", line 175, in onnx_to_keras AVAILABLE_CONVERTERS[node_type]( File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/elementwise_layers.py", line 83, in convert_elementwise_add layers[node_name] = lambda_layer([input_0, input_1]) File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None File "/root/miniconda3/envs/onnx/lib/python3.8/site-packages/onnx2keras/elementwise_layers.py", line 76, in target_layer layer = tf.add( ValueError: Exception encountered when calling layer "LAYER_12" (type Lambda). Dimensions must be equal, but are 204 and 206 for '{{node LAYER_12/Add}} = AddV2[T=DT_FLOAT](Placeholder, Placeholder_1)' with input shapes: [?,64,204,204], [?,64,206,206]. Call arguments received by layer "LAYER_12" (type Lambda): • inputs=['tf.Tensor(shape=(None, 64, 204, 204), dtype=float32)', 'tf.Tensor(shape=(None, 64, 206, 206), dtype=float32)'] • mask=None • training=None ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61958/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61958/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61957
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61957/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61957/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61957/events
https://github.com/tensorflow/tensorflow/issues/61957
1,909,861,723
I_kwDOArmXAs5x1i1b
61,957
ValueError: Tried to convert 'shape' to a tensor and failed. Error: None values not supported.
{ "login": "Aksh-kumar", "id": 21700957, "node_id": "MDQ6VXNlcjIxNzAwOTU3", "avatar_url": "https://avatars.githubusercontent.com/u/21700957?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Aksh-kumar", "html_url": "https://github.com/Aksh-kumar", "followers_url": "https://api.github.com/users/Aksh-kumar/followers", "following_url": "https://api.github.com/users/Aksh-kumar/following{/other_user}", "gists_url": "https://api.github.com/users/Aksh-kumar/gists{/gist_id}", "starred_url": "https://api.github.com/users/Aksh-kumar/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Aksh-kumar/subscriptions", "organizations_url": "https://api.github.com/users/Aksh-kumar/orgs", "repos_url": "https://api.github.com/users/Aksh-kumar/repos", "events_url": "https://api.github.com/users/Aksh-kumar/events{/privacy}", "received_events_url": "https://api.github.com/users/Aksh-kumar/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@Aksh-kumar,\r\nApologies for the delay. Thanks for reporting the issue.\r\nSince this request is specific to Keras, could you please close this and open a new issue in Keras repo https://github.com/keras-team/keras/issues\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "posted in keras-team github page closing it here.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61957\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61957\">No</a>\n" ]
2023-09-23T12:48:40
2023-11-09T10:06:11
2023-11-09T10:06:07
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution Window 10 ### Mobile device _No response_ ### Python version 3.9.12 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I am trying to implement [this](https://keras.io/examples/vision/image_classification_with_vision_transformer/) in tensorflow 2.13 but getting this error "**ValueError: Tried to convert 'shape' to a tensor and failed. Error: None values not supported**" after searching a lot I got to know we have to use -1 in case of None but even after trying that it was not working I am getting this error in custom Patches layer patches = tf.reshape(patches, [batch_size, -1, patch_dims]) can anybody please help? ### Standalone code to reproduce the issue ```shell class Patches(layers.Layer): def __init__(self, patch_size, **kwargs): super(Patches, self).__init__() self.patch_size = patch_size def call(self, images): batch_size = tf.shape(images)[0] # Get the Batch Size patches = tf.image.extract_patches( images=images, sizes=[1, self.patch_size, self.patch_size, 1], # only along the Height and Width Dimension strides=[1, self.patch_size, self.patch_size, 1], # The next patch should not overlap the previus patch rates=[1,1,1,1], padding='VALID' ) patch_dims = patches.shape[-1] patches = tf.reshape(patches, [batch_size, -1, patch_dims]) return patches def get_config(self): config = super().get_config() config.update({ "path-size": self.patch_size, }) return config ``` ### Relevant log output ```shell history = model.fit( 27 train_generator, 28 validation_data=valid_generator, 29 batch_size=BATCH_SIZE, 30 epochs=NUM_EPOCHS, 31 callbacks=[ 32 checkpoint_callback, 33 tf.keras.callbacks.EarlyStopping(patience=5, monitor='val_Accuracy', mode='max' ,restore_best_weights=True) 34 ], 35 ) 37 model.load_weights(checkpoint_filepath) 38 _, accuracy, top_5_accuracy = model.evaluate(x_test, y_test) File ~\AppData\Roaming\Python\Python39\site-packages\keras\src\utils\traceback_utils.py:70, in filter_traceback.<locals>.error_handler(*args, **kwargs) 67 filtered_tb = _process_traceback_frames(e.__traceback__) 68 # To get the full stack trace, call: 69 # `tf.debugging.disable_traceback_filtering()` ---> 70 raise e.with_traceback(filtered_tb) from None 71 finally: 72 del filtered_tb File ~\AppData\Local\Temp\__autograph_generated_filelwsbm473.py:15, in outer_factory.<locals>.inner_factory.<locals>.tf__train_function(iterator) 13 try: 14 do_return = True ---> 15 retval_ = ag__.converted_call(ag__.ld(step_function), (ag__.ld(self), ag__.ld(iterator)), None, fscope) 16 except: 17 do_return = False File ~\AppData\Local\Temp\__autograph_generated_filewl0d9m3r.py:13, in outer_factory.<locals>.inner_factory.<locals>.tf__call(self, images) 11 patches = ag__.converted_call(ag__.ld(tf).image.extract_patches, (), dict(images=ag__.ld(images), sizes=[1, ag__.ld(self).patch_size, ag__.ld(self).patch_size, 1], strides=[1, ag__.ld(self).patch_size, ag__.ld(self).patch_size, 1], rates=[1, 1, 1, 1], padding='VALID'), fscope) 12 patch_dims = ag__.ld(patches).shape[-1] ---> 13 patches = ag__.converted_call(ag__.ld(tf).reshape, (ag__.ld(patches), [ag__.ld(batch_size), -1, ag__.ld(patch_dims)]), None, fscope) 14 try: 15 do_return = True ValueError: in user code: File "C:\Users\aksh1\AppData\Roaming\Python\Python39\site-packages\keras\src\engine\training.py", line 1338, in train_function * return step_function(self, iterator) File "C:\Users\aksh1\AppData\Roaming\Python\Python39\site-packages\keras\src\engine\training.py", line 1322, in step_function ** outputs = model.distribute_strategy.run(run_step, args=(data,)) File "C:\Users\aksh1\AppData\Roaming\Python\Python39\site-packages\keras\src\engine\training.py", line 1303, in run_step ** outputs = model.train_step(data) File "C:\Users\aksh1\AppData\Roaming\Python\Python39\site-packages\keras\src\engine\training.py", line 1080, in train_step y_pred = self(x, training=True) File "C:\Users\aksh1\AppData\Roaming\Python\Python39\site-packages\keras\src\utils\traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None File "C:\Users\aksh1\AppData\Local\Temp\__autograph_generated_filewl0d9m3r.py", line 13, in tf__call patches = ag__.converted_call(ag__.ld(tf).reshape, (ag__.ld(patches), [ag__.ld(batch_size), -1, ag__.ld(patch_dims)]), None, fscope) ValueError: Exception encountered when calling layer 'patches_3' (type Patches). in user code: File "C:\Users\aksh1\AppData\Local\Temp\ipykernel_11744\2749589268.py", line 17, in call * patches = tf.reshape(patches, [batch_size, -1, patch_dims]) ValueError: Tried to convert 'shape' to a tensor and failed. Error: None values not supported. Call arguments received by layer 'patches_3' (type Patches): • images=tf.Tensor(shape=(None, None, None, None), dtype=float32) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61957/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61957/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61956
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61956/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61956/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61956/events
https://github.com/tensorflow/tensorflow/issues/61956
1,909,822,258
I_kwDOArmXAs5x1ZMy
61,956
Error with protobuf during installation
{ "login": "logisin", "id": 18378540, "node_id": "MDQ6VXNlcjE4Mzc4NTQw", "avatar_url": "https://avatars.githubusercontent.com/u/18378540?v=4", "gravatar_id": "", "url": "https://api.github.com/users/logisin", "html_url": "https://github.com/logisin", "followers_url": "https://api.github.com/users/logisin/followers", "following_url": "https://api.github.com/users/logisin/following{/other_user}", "gists_url": "https://api.github.com/users/logisin/gists{/gist_id}", "starred_url": "https://api.github.com/users/logisin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/logisin/subscriptions", "organizations_url": "https://api.github.com/users/logisin/orgs", "repos_url": "https://api.github.com/users/logisin/repos", "events_url": "https://api.github.com/users/logisin/events{/privacy}", "received_events_url": "https://api.github.com/users/logisin/received_events", "type": "User", "site_admin": false }
[ { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 1205615612, "node_id": "MDU6TGFiZWwxMjA1NjE1NjEy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux", "name": "subtype: ubuntu/linux", "color": "b619ea", "default": false, "description": "Ubuntu/Linux Build/Installation Issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @logisin ,\r\n\r\nCould you please confirm whether you are trying to build for TF2.13v ? Seems typo mistake in the template.\r\n\r\nPlease confirm the protobuf version you have installed ? You can find the required protobuf versions [here](https://github.com/tensorflow/tensorflow/blob/r2.13/tensorflow/tools/pip_package/setup.py#L96).\r\n\r\nIf using Tf2.13v you need to use bazel 5.3.0v. Other versions may cause inconsistent behaviour. Please refer to attached test [configurations](https://www.tensorflow.org/install/source#gpu) here.\r\n\r\nAfter testing with official configurations and still have any problems please let us know.\r\n\r\nThanks!\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61956\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61956\">No</a>\n" ]
2023-09-23T10:40:34
2023-10-11T01:47:29
2023-10-11T01:47:24
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 12.3 ### Custom code Yes ### OS platform and distribution Ubuntu 22.04 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version 6.1.0 ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? /home/user1/.cache/bazel/_bazel_user1/2ed8e7afdea3ff827d1d2c14869018ce/external/com_google_protobuf/BUILD.bazel:459:10: Compiling src/google/protobuf/compiler/main.cc [for tool] failed: (Exit 1): clang failed: error executing command (from target @com_google_protobuf//:protoc) (cd /home/user1/.cache/bazel/_bazel_user1/2ed8e7afdea3ff827d1d2c14869018ce/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda-12.2/lib64 \ PATH=/home/user1/.cache/bazelisk/downloads/sha256/6c25a6d716545d6b672ec46f770521cd9ebb63d73617b8f4e6747825d1db1839/bin:/home/user1/bin:/usr/local/cuda-12.2/bin:/home/user1/anaconda3/bin:/home/user1/anaconda3/condabin:/home/user1/.local/bin:/home/user1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin \ PWD=/proc/self/cwd \ /usr/lib/llvm-16/bin/clang -MD -MF bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.d '-frandom-seed=bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.o' '-DBAZEL_CURRENT_REPOSITORY="com_google_protobuf"' -iquote external/com_google_protobuf -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/zlib -iquote external/bazel_tools -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/bazel_tools -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/src -isystem external/zlib -isystem bazel-out/k8-opt-exec-50AE0418/bin/external/zlib -fmerge-all-constants -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -fPIE -U_FORTIFY_SOURCE '-D_FORTIFY_SOURCE=1' -fstack-protector -Wall -Wno-invalid-partial-specialization -fno-omit-frame-pointer -no-canonical-prefixes -DNDEBUG -g0 -O2 -ffunction-sections -fdata-sections '--cuda-path=/usr/local/cuda-12.2' -g0 -w -g0 '-std=c++17' -c external/com_google_protobuf/src/google/protobuf/compiler/main.cc -o bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.o) # Configuration: be1b6d30ad6b895c5d0cb4e11b08ee9fdfd7ce804f01eb0679a5e177ceb7e39b # Execution platform: @local_execution_config_platform//:platform In file included from external/com_google_protobuf/src/google/protobuf/compiler/main.cc:31: external/com_google_protobuf/src/google/protobuf/compiler/cpp/generator.h:40:10: fatal error: 'string' file not found #include <string> ^~~~~~~~ 1 error generated. Target //tensorflow/tools/pip_package:build_pip_package failed to build ERROR: /home/user1/tensorflow/tensorflow/tools/pip_package/BUILD:252:10 Middleman _middlemen/tensorflow_Stools_Spip_Upackage_Sbuild_Upip_Upackage-runfiles failed: (Exit 1): clang failed: error executing command (from target @com_google_protobuf//:protoc) (cd /home/user1/.cache/bazel/_bazel_user1/2ed8e7afdea3ff827d1d2c14869018ce/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda-12.2/lib64 \ PATH=/home/user1/.cache/bazelisk/downloads/sha256/6c25a6d716545d6b672ec46f770521cd9ebb63d73617b8f4e6747825d1db1839/bin:/home/user1/bin:/usr/local/cuda-12.2/bin:/home/user1/anaconda3/bin:/home/user1/anaconda3/condabin:/home/user1/.local/bin:/home/user1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin \ PWD=/proc/self/cwd \ /usr/lib/llvm-16/bin/clang -MD -MF bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.d '-frandom-seed=bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.o' '-DBAZEL_CURRENT_REPOSITORY="com_google_protobuf"' -iquote external/com_google_protobuf -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/zlib -iquote external/bazel_tools -iquote bazel-out/k8-opt-exec-50AE0418/bin/external/bazel_tools -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/src -isystem external/zlib -isystem bazel-out/k8-opt-exec-50AE0418/bin/external/zlib -fmerge-all-constants -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -fPIE -U_FORTIFY_SOURCE '-D_FORTIFY_SOURCE=1' -fstack-protector -Wall -Wno-invalid-partial-specialization -fno-omit-frame-pointer -no-canonical-prefixes -DNDEBUG -g0 -O2 -ffunction-sections -fdata-sections '--cuda-path=/usr/local/cuda-12.2' -g0 -w -g0 '-std=c++17' -c external/com_google_protobuf/src/google/protobuf/compiler/main.cc -o bazel-out/k8-opt-exec-50AE0418/bin/external/com_google_protobuf/_objs/protoc/main.o) # Configuration: be1b6d30ad6b895c5d0cb4e11b08ee9fdfd7ce804f01eb0679a5e177ceb7e39b # Execution platform: @local_execution_config_platform//:platform INFO: Elapsed time: 0.200s, Critical Path: 0.08s INFO: 44 processes: 42 internal, 2 local. FAILED: Build did NOT complete successfully ### Standalone code to reproduce the issue ```shell bazel build //tensorflow/tools/pip_package:build_pip_package --verbose_failures ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61956/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61956/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61955
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61955/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61955/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61955/events
https://github.com/tensorflow/tensorflow/issues/61955
1,909,787,980
I_kwDOArmXAs5x1Q1M
61,955
linalg.svd - complex64 - NaN - bug
{ "login": "yhao-z", "id": 59129069, "node_id": "MDQ6VXNlcjU5MTI5MDY5", "avatar_url": "https://avatars.githubusercontent.com/u/59129069?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yhao-z", "html_url": "https://github.com/yhao-z", "followers_url": "https://api.github.com/users/yhao-z/followers", "following_url": "https://api.github.com/users/yhao-z/following{/other_user}", "gists_url": "https://api.github.com/users/yhao-z/gists{/gist_id}", "starred_url": "https://api.github.com/users/yhao-z/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yhao-z/subscriptions", "organizations_url": "https://api.github.com/users/yhao-z/orgs", "repos_url": "https://api.github.com/users/yhao-z/repos", "events_url": "https://api.github.com/users/yhao-z/events{/privacy}", "received_events_url": "https://api.github.com/users/yhao-z/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "cantonios", "id": 2538739, "node_id": "MDQ6VXNlcjI1Mzg3Mzk=", "avatar_url": "https://avatars.githubusercontent.com/u/2538739?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cantonios", "html_url": "https://github.com/cantonios", "followers_url": "https://api.github.com/users/cantonios/followers", "following_url": "https://api.github.com/users/cantonios/following{/other_user}", "gists_url": "https://api.github.com/users/cantonios/gists{/gist_id}", "starred_url": "https://api.github.com/users/cantonios/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cantonios/subscriptions", "organizations_url": "https://api.github.com/users/cantonios/orgs", "repos_url": "https://api.github.com/users/cantonios/repos", "events_url": "https://api.github.com/users/cantonios/events{/privacy}", "received_events_url": "https://api.github.com/users/cantonios/received_events", "type": "User", "site_admin": false }
[ { "login": "cantonios", "id": 2538739, "node_id": "MDQ6VXNlcjI1Mzg3Mzk=", "avatar_url": "https://avatars.githubusercontent.com/u/2538739?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cantonios", "html_url": "https://github.com/cantonios", "followers_url": "https://api.github.com/users/cantonios/followers", "following_url": "https://api.github.com/users/cantonios/following{/other_user}", "gists_url": "https://api.github.com/users/cantonios/gists{/gist_id}", "starred_url": "https://api.github.com/users/cantonios/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cantonios/subscriptions", "organizations_url": "https://api.github.com/users/cantonios/orgs", "repos_url": "https://api.github.com/users/cantonios/repos", "events_url": "https://api.github.com/users/cantonios/events{/privacy}", "received_events_url": "https://api.github.com/users/cantonios/received_events", "type": "User", "site_admin": false }, { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "there are similar issues #8905 #26842", "@sachinprasadhs I was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/0782f8b41efbbf02e9b2a45c2b764fa5/61955.ipynb). Thank you!", "As per the comment from one of the linked issues, it looks like an issue from Eigen. \r\n@cantonios , Could you please take a look into this issue. Thanks!", "@yhao-z,\r\nI tried to execute the mentioned code on the tf-nightly and observed that the output of executed code is intended and changed from the earlier output. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/963f9337ef41e6403219cf7bf045eae3/untitled1888.ipynb).\r\n \r\n**Output:**\r\n```python\r\nFalse\r\n[0.01783315 0.00682789 0.00398225 0.00252413 0.0014872 0.00082805\r\n 0.00066117 0.00051815 0.00050564]\r\nFalse\r\nFalse\r\nFalse\r\n[0.01783314 0.00682789 0.00398224 0.00252413 0.0014872 0.00082805\r\n 0.00066117 0.00051815 0.00050564]\r\nFalse\r\nFalse\r\nFalse\r\n```\r\n\r\nThank you!", "Yes, the error will not occur in the nightly version. Perhaps my previous expression in the '**Note**' was not clear enough; I would like to restate the declaration in the '**Note**' here.\r\n- Under the Linux system, both version 2.9 and 2.13 will encounter errors, just as @sushreebarsa has reproduced.\r\n- Under the Linux system, the nightly version will not experience NaN errors.\r\n- Under the Windows system, version 2.9 will also not encounter NaN errors.\r\n- Considering the inconsistencies observed across different versions and systems, I believe it might be a bug.\r\n\r\nTherefore, it might be possible to inspect the differences between the nightly and 2.13 versions to pinpoint the bug, or alternatively, comparing the behavior of version 2.9 under Windows with that under Linux could also help in localization.", "> Yes, the error will not occur in the nightly version. Perhaps my previous expression in the '**Note**' was not clear enough; I would like to restate the declaration in the '**Note**' here.\r\n> \r\n> * Under the Linux system, both version 2.9 and 2.13 will encounter errors, just as @sushreebarsa has reproduced.\r\n> * Under the Linux system, the nightly version will not experience NaN errors.\r\n> * Under the Windows system, version 2.9 will also not encounter NaN errors.\r\n> * Considering the inconsistencies observed across different versions and systems, I believe it might be a bug.\r\n> \r\n> Therefore, it might be possible to inspect the differences between the nightly and 2.13 versions to pinpoint the bug, or alternatively, comparing the behavior of version 2.9 under Windows with that under Linux could also help in localization.\r\n\r\nWe don't backport fixes unless they are high-priority security vulnerabilities. So in this case the bug is now fixed in the latest version.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61955\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61955\">No</a>\n" ]
2023-09-23T08:44:22
2024-05-10T15:13:44
2024-05-10T15:13:41
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf nightly, 2.13, 2.9 using docker container ### Custom code Yes ### OS platform and distribution Linux Ubuntu 20.04 with Docker ### Python version 3.9 ### Current behavior? For a special matrix, as I tested, a `tf.complex64` matrix without **NaN**, the `tf.linalg.svd` gives the singular values with **NaN**, and the singular vector `u` and `v` also have **NaN**. However, numpy does not give any NaN. The tiny code and its output have provided, and u can also download it from [my github repo](https://github.com/yhao-z/tensorflow-svd-NaN). **Notes:** - i test this code in docker container, which is created from the offical images released by tensorflow. - this code is normal in nightly edition of Linux Docker and 2.9 of Windows. - the code encounter error in 2.9 and 2.13 editions of Linux Docker. - based on the conflict results for different platform and editions, i think this issue may be a bug. ### Standalone code to reproduce the issue ```shell import tensorflow as tf import numpy as np M = np.load('NaN_matrix.npy') print(tf.reduce_any(tf.math.is_nan(tf.abs(M))).numpy()) # False, no nan in M # tensorflow svd [s,u,v] = tf.linalg.svd(M) print(s.numpy()[0:9]) # [nan 0.01783315 0.00682789 0.00398225 0.00252413 0.0014872 0.00082805 0.00066117 0.00051815] print(tf.reduce_any(tf.math.is_nan(s)).numpy()) # True, nan in s print(tf.reduce_any(tf.math.is_nan(tf.abs(u))).numpy()) # True, nan in u print(tf.reduce_any(tf.math.is_nan(tf.abs(v))).numpy()) # True, nan in v # numpy svd [u,s,v] = np.linalg.svd(M) print(s[0:9]) # [0.01783314 0.00682789 0.00398224 0.00252413 0.0014872 0.00082805 0.00066117 0.00051815 0.00050564] print(np.isnan(s).any()) # False, no nan in s print(np.isnan(u).any()) # False, no nan in u print(np.isnan(v).any()) # False, no nan in v ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61955/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61955/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61954
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61954/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61954/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61954/events
https://github.com/tensorflow/tensorflow/issues/61954
1,909,386,427
I_kwDOArmXAs5xzuy7
61,954
ExtensionType to be considered a complete nested structure
{ "login": "AndreiMoraru123", "id": 81184255, "node_id": "MDQ6VXNlcjgxMTg0MjU1", "avatar_url": "https://avatars.githubusercontent.com/u/81184255?v=4", "gravatar_id": "", "url": "https://api.github.com/users/AndreiMoraru123", "html_url": "https://github.com/AndreiMoraru123", "followers_url": "https://api.github.com/users/AndreiMoraru123/followers", "following_url": "https://api.github.com/users/AndreiMoraru123/following{/other_user}", "gists_url": "https://api.github.com/users/AndreiMoraru123/gists{/gist_id}", "starred_url": "https://api.github.com/users/AndreiMoraru123/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/AndreiMoraru123/subscriptions", "organizations_url": "https://api.github.com/users/AndreiMoraru123/orgs", "repos_url": "https://api.github.com/users/AndreiMoraru123/repos", "events_url": "https://api.github.com/users/AndreiMoraru123/events{/privacy}", "received_events_url": "https://api.github.com/users/AndreiMoraru123/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473173272, "node_id": "MDU6TGFiZWw0NzMxNzMyNzI=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature", "name": "type:feature", "color": "159b2e", "default": false, "description": "Feature requests" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" } ]
open
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "I volunteer to take this issue", "The error you're encountering is because tf.nest.map_structure requires all elements within the nested structure to be TensorFlow tensors, and MyComplexData is not considered a TensorFlow tensor by default. To make your code compatible with tf.nest.map_structure, you need to ensure that the elements within MyComplexData are TensorFlow tensors.\r\n\r\nYou can do this by adding a method to the MyComplexData class that converts its internal data to TensorFlow tensors. In the updated code, I've included a method called as_tensors that does this conversion for x and y. By calling data.as_tensors(), you can convert your custom data structure into a format compatible with TensorFlow operations. This should allow you to use tf.nest.map_structure with the gather_fn function without encountering the error.", "import tensorflow as tf\r\n\r\nclass MyComplexData(tf.experimental.ExtensionType):\r\n x: tf.Tensor\r\n y: tf.Tensor\r\n\r\n def __init__(self, x, y):\r\n self.x = x\r\n self.y = y\r\n\r\n def as_tensors(self):\r\n return MyComplexData(tf.convert_to_tensor(self.x), tf.convert_to_tensor(self.y))\r\n\r\ndef gather_fn(tensor):\r\n indices = tf.constant([[0], [1]])\r\n return tf.gather_nd(tensor, indices)\r\n\r\ndata = MyComplexData([1, 2, 3], [[1.0, 2.0], [3.0, 4.0]])\r\n\r\n# Convert the data to TensorFlow tensors\r\ndata = data.as_tensors()\r\n\r\ntry:\r\n mapped_data = tf.nest.map_structure(gather_fn, data)\r\n print(mapped_data)\r\nexcept Exception as e:\r\n print(f\"Failed to apply map_structure with gather_fn on MyComplexData: {e}\")\r\n" ]
2023-09-22T18:59:01
2023-11-03T07:55:44
null
NONE
null
null
null
### Issue type Feature Request ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13 (& 2.15 nightly) ### Custom code No ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version 3.10 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Tensorflow's current experimental [ExtensionType](https://www.tensorflow.org/api_docs/python/tf/experimental/ExtensionType) is a very useful data structure to replace python data structures when the modelled tensors are in fact more complex structures of tensors of varying shapes and types. One would intuitively think that this class would click with `tf.nest`, but unfortunately they are not among the valid nested structures: ``` collections.abc.Sequence (except string and bytes). This includes list, tuple, and namedtuple. collections.abc.Mapping (with sortable keys). This includes dict and collections.OrderedDict. collections.abc.MappingView (with sortable keys). ``` as taken from [Module: tf.nest](https://www.tensorflow.org/api_docs/python/tf/nest). Moreover, `tf.nest` is not registered as an api for [@tf.experimental.dispatch_for_api(tf_api)](https://www.tensorflow.org/api_docs/python/tf/experimental/dispatch_for_api), which would be helpful for redifining the behaviour of nesting inside an `ExtensionType`. Currently, the only solutions that I have found were either to: 1. Use multiple inheritance and also inherit from one of the valid nested structures in order to allow `tf.nest` to work as an api. This also requires implementing all the abstract methods of the superclass which may not make sense all the time. 2. Rewrite all the functionalities that use nesting as methods inside the class implementing `ExtensionType`, which is not great when you are seeking code reusability. 3. Have a method to change the type to something that can be considered a structure and have that called whenever `tf.nest`ing is used, which as well requires some changes everywhere in the code base. ### Standalone code to reproduce the issue ```python # Not inheriting from Sequence import tensorflow as tf class MyComplexData(tf.experimental.ExtensionType): x: tf.Tensor y: tf.Tensor def __init__(self, x, y): self.x = x self.y = y def gather_fn(tensor): indices = tf.constant([[0], [1]]) return tf.gather_nd(tensor, indices) data = MyComplexData(tf.constant([1, 2, 3]), tf.constant([[1.0, 2.0], [3.0, 4.0]])) try: mapped_data = tf.nest.map_structure(gather_fn, data) print(mapped_data) except Exception as e: print(f"Failed to apply map_structure with gather_fn on MyComplexData: {e}") ``` ```python # Inheriting from Sequence import tensorflow as tf from collections.abc import Sequence class MyComplexDataSequence(tf.experimental.ExtensionType, Sequence): x: tf.Tensor y: tf.Tensor def __init__(self, x, y): self.x = x self.y = y def __getitem__(self, index): return [self.x, self.y][index] def __len__(self): return 2 def gather_fn(tensor): indices = tf.constant([[0], [1]]) return tf.gather_nd(tensor, indices) data_seq = MyComplexDataSequence(tf.constant([1, 2, 3]), tf.constant([[1.0, 2.0], [3.0, 4.0]])) try: mapped_data_seq = tf.nest.map_structure(gather_fn, data_seq) print(mapped_data_seq) except Exception as e: print(f"Failed to apply map_structure with gather_fn on MyComplexDataSequence: {e}") ``` ### Relevant log output ```shell # Not inheriting from Sequence Failed to apply map_structure with gather_fn on MyComplexData: Attempt to convert a value (MyComplexData(x=<tf.Tensor: shape=(3,), dtype=int32, numpy=array([1, 2, 3], dtype=int32)>, y=<tf.Tensor: shape=(2, 2), dtype=float32, numpy= array([[1., 2.], [3., 4.]], dtype=float32)>)) with an unsupported type (<class '__main__.MyComplexData'>) to a Tensor. ``` ```shell # Inheriting from Sequence MyComplexDataSequence(x=<tf.Tensor: shape=(2,), dtype=int32, numpy=array([1, 2], dtype=int32)>, y=<tf.Tensor: shape=(2, 2), dtype=float32, numpy= array([[1., 2.], [3., 4.]], dtype=float32)>) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61954/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61954/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61953
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61953/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61953/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61953/events
https://github.com/tensorflow/tensorflow/issues/61953
1,908,843,538
I_kwDOArmXAs5xxqQS
61,953
SpectralNormalization layer is not trainable. Please help (OperatorNotAllowedInGraphError: Exception encountered when calling layer 'spectral_normalization' (type SpectralNormalization).)
{ "login": "kavjayawardana", "id": 145772925, "node_id": "U_kgDOCLBRfQ", "avatar_url": "https://avatars.githubusercontent.com/u/145772925?v=4", "gravatar_id": "", "url": "https://api.github.com/users/kavjayawardana", "html_url": "https://github.com/kavjayawardana", "followers_url": "https://api.github.com/users/kavjayawardana/followers", "following_url": "https://api.github.com/users/kavjayawardana/following{/other_user}", "gists_url": "https://api.github.com/users/kavjayawardana/gists{/gist_id}", "starred_url": "https://api.github.com/users/kavjayawardana/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kavjayawardana/subscriptions", "organizations_url": "https://api.github.com/users/kavjayawardana/orgs", "repos_url": "https://api.github.com/users/kavjayawardana/repos", "events_url": "https://api.github.com/users/kavjayawardana/events{/privacy}", "received_events_url": "https://api.github.com/users/kavjayawardana/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @kavjayawardana ,\r\n\r\nBy looking into the error, it appears that the problem might be due to the reason that `SpectralNormalization` layer seems not supported with Graph execution.\r\n\r\nI have set `run_eagerly= True` in `model.compile(run_eagerly= True)` then the error is gone but shape incompatibility error araised. This was corrected by changing the `y` in your code to `y = np.random.rand(batch, height-2, width-2, filters)`.\r\n\r\nWith all these modification it executes fine and attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/df980d43493ceeddf0d9b9f4f1242a1d/61953_spectralnormalization.ipynb) for reference.\r\n\r\nPlease cross check and confirm if still have any queries.\r\n\r\nThanks!\r\n\r\n", "Thank you very much @SuryanarayanaY. Setting run_eagerly= True made it trainable. Thank you again for being prompt with your reply and incredibly helpful with your solution\r\n\r\nbest\r\n\r\nkav", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61953\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61953\">No</a>\n" ]
2023-09-22T12:46:16
2023-09-25T10:05:36
2023-09-25T10:05:33
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 ### Custom code No ### OS platform and distribution Ubuntu 22.04.3 LTS and Google Colab ### Mobile device _No response_ ### Python version 3.9 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version cudatoolkit=11.8.0, nvidia-cudnn-cu11==8.6.0.163 ### GPU model and memory _No response_ ### Current behavior? SpectralNormalization layer is not trainable. Whenever I try to use the "model.fit" method, TF outputs the error "Using a symbolic `tf.Tensor` as a Python `bool` is not allowed: AutoGraph did convert this function. This might indicate you are trying to use an unsupported feature." Please help Best Kav ### Standalone code to reproduce the issue ```shell LINK TO COLAB NOTEBOOK: https://colab.research.google.com/drive/1TYoNIrrpk-bLBqpzNJXq5VOI6Mpln5Ty?usp=sharing STANDALONE CODE: batch = 1 height = 10 width = 10 channels = 1 filters = 4 kernel_size = 3 x_input = Input(shape=(height, width, channels)) conv2d = SpectralNormalization(Conv2D(filters, kernel_size)) x_output = conv2d(x_input) model = Model(x_input, x_output) model.compile(loss='mse') x = np.random.rand(batch, height, width, channels) y = np.random.rand(batch, height, width, filters) model.fit(x, y) ``` ### Relevant log output ```shell --------------------------------------------------------------------------- OperatorNotAllowedInGraphError Traceback (most recent call last) <ipython-input-6-d3dc977168f5> in <cell line: 1>() ----> 1 model.fit(x, y) 1 frames /usr/local/lib/python3.10/dist-packages/tensorflow/python/eager/polymorphic_function/autograph_util.py in autograph_handler(*args, **kwargs) 50 except Exception as e: # pylint:disable=broad-except 51 if hasattr(e, "ag_error_metadata"): ---> 52 raise e.ag_error_metadata.to_exception(e) 53 else: 54 raise OperatorNotAllowedInGraphError: in user code: File "/usr/local/lib/python3.10/dist-packages/keras/src/engine/training.py", line 1338, in train_function * return step_function(self, iterator) File "/usr/local/lib/python3.10/dist-packages/keras/src/engine/training.py", line 1322, in step_function ** outputs = model.distribute_strategy.run(run_step, args=(data,)) File "/usr/local/lib/python3.10/dist-packages/keras/src/engine/training.py", line 1303, in run_step ** outputs = model.train_step(data) File "/usr/local/lib/python3.10/dist-packages/keras/src/engine/training.py", line 1080, in train_step y_pred = self(x, training=True) File "/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None OperatorNotAllowedInGraphError: Exception encountered when calling layer 'spectral_normalization' (type SpectralNormalization). Using a symbolic `tf.Tensor` as a Python `bool` is not allowed: AutoGraph did convert this function. This might indicate you are trying to use an unsupported feature. Call arguments received by layer 'spectral_normalization' (type SpectralNormalization): • inputs=tf.Tensor(shape=(None, 10, 10, 1), dtype=float32) • training=True ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61953/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61953/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61952
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61952/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61952/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61952/events
https://github.com/tensorflow/tensorflow/pull/61952
1,908,659,969
PR_kwDOArmXAs5a-nTz
61,952
Fixed typos in TF doc
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-22T10:40:21
2023-10-03T08:47:23
2023-10-03T08:47:22
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61952", "html_url": "https://github.com/tensorflow/tensorflow/pull/61952", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61952.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61952.patch", "merged_at": "2023-10-03T08:47:22" }
Multiple typos fixed in the TF documentation.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61952/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61952/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61951
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61951/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61951/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61951/events
https://github.com/tensorflow/tensorflow/issues/61951
1,908,537,760
I_kwDOArmXAs5xwfmg
61,951
Can not find strtod_l function on Android device
{ "login": "yen-dang-ts", "id": 119931172, "node_id": "U_kgDOByYBJA", "avatar_url": "https://avatars.githubusercontent.com/u/119931172?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yen-dang-ts", "html_url": "https://github.com/yen-dang-ts", "followers_url": "https://api.github.com/users/yen-dang-ts/followers", "following_url": "https://api.github.com/users/yen-dang-ts/following{/other_user}", "gists_url": "https://api.github.com/users/yen-dang-ts/gists{/gist_id}", "starred_url": "https://api.github.com/users/yen-dang-ts/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yen-dang-ts/subscriptions", "organizations_url": "https://api.github.com/users/yen-dang-ts/orgs", "repos_url": "https://api.github.com/users/yen-dang-ts/repos", "events_url": "https://api.github.com/users/yen-dang-ts/events{/privacy}", "received_events_url": "https://api.github.com/users/yen-dang-ts/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "miaout17", "id": 22063, "node_id": "MDQ6VXNlcjIyMDYz", "avatar_url": "https://avatars.githubusercontent.com/u/22063?v=4", "gravatar_id": "", "url": "https://api.github.com/users/miaout17", "html_url": "https://github.com/miaout17", "followers_url": "https://api.github.com/users/miaout17/followers", "following_url": "https://api.github.com/users/miaout17/following{/other_user}", "gists_url": "https://api.github.com/users/miaout17/gists{/gist_id}", "starred_url": "https://api.github.com/users/miaout17/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/miaout17/subscriptions", "organizations_url": "https://api.github.com/users/miaout17/orgs", "repos_url": "https://api.github.com/users/miaout17/repos", "events_url": "https://api.github.com/users/miaout17/events{/privacy}", "received_events_url": "https://api.github.com/users/miaout17/received_events", "type": "User", "site_admin": false }
[ { "login": "miaout17", "id": 22063, "node_id": "MDQ6VXNlcjIyMDYz", "avatar_url": "https://avatars.githubusercontent.com/u/22063?v=4", "gravatar_id": "", "url": "https://api.github.com/users/miaout17", "html_url": "https://github.com/miaout17", "followers_url": "https://api.github.com/users/miaout17/followers", "following_url": "https://api.github.com/users/miaout17/following{/other_user}", "gists_url": "https://api.github.com/users/miaout17/gists{/gist_id}", "starred_url": "https://api.github.com/users/miaout17/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/miaout17/subscriptions", "organizations_url": "https://api.github.com/users/miaout17/orgs", "repos_url": "https://api.github.com/users/miaout17/repos", "events_url": "https://api.github.com/users/miaout17/events{/privacy}", "received_events_url": "https://api.github.com/users/miaout17/received_events", "type": "User", "site_admin": false }, { "login": "turbotoribio", "id": 34755817, "node_id": "MDQ6VXNlcjM0NzU1ODE3", "avatar_url": "https://avatars.githubusercontent.com/u/34755817?v=4", "gravatar_id": "", "url": "https://api.github.com/users/turbotoribio", "html_url": "https://github.com/turbotoribio", "followers_url": "https://api.github.com/users/turbotoribio/followers", "following_url": "https://api.github.com/users/turbotoribio/following{/other_user}", "gists_url": "https://api.github.com/users/turbotoribio/gists{/gist_id}", "starred_url": "https://api.github.com/users/turbotoribio/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/turbotoribio/subscriptions", "organizations_url": "https://api.github.com/users/turbotoribio/orgs", "repos_url": "https://api.github.com/users/turbotoribio/repos", "events_url": "https://api.github.com/users/turbotoribio/events{/privacy}", "received_events_url": "https://api.github.com/users/turbotoribio/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "@yen-dang-ts \r\nIn order to expedite the trouble-shooting process, please provide a code snippet to reproduce the issue reported here. Thank you!", "Hi @sushreebarsa ,\r\n\r\n- Load model part:\r\n\r\n```\r\nval options = Interpreter.Options()\r\n val tfLite = Interpreter(\r\n TFLiteUtils.loadModelFile(context.assets, modelFileName),\r\n options\r\n )\r\n```\r\n\r\n- `loadModelFile` function\r\n```\r\nfun loadModelFile(assets: AssetManager, modelFilename: String?): MappedByteBuffer {\r\n val fileDescriptor = assets.openFd(modelFilename!!)\r\n val inputStream = FileInputStream(fileDescriptor.fileDescriptor)\r\n val fileChannel = inputStream.channel\r\n val startOffset = fileDescriptor.startOffset\r\n val declaredLength = fileDescriptor.declaredLength\r\n return fileChannel.map(FileChannel.MapMode.READ_ONLY, startOffset, declaredLength)\r\n }\r\n```\r\nPls note that this issue just happen on 2.12.0 and 2.13.0 version. Below versions still work fine.\r\nPlease have a look on that.", "Hi @yen-dang-ts \r\n\r\nWhat is the SDK and NDK version that are being used? \r\n\r\nAs per the documentation,\r\n\r\n```\r\nNDK_API_LEVEL=\"26\"\r\nANDROID_BUILD_TOOLS_VERSION=\"30.0.3\"\r\nANDROID_SDK_API_LEVEL=\"30\"\r\n```\r\nare recommended for the latest versions.\r\n\r\nThanks.", "Here is my config:\r\n\r\n```\r\n ndkVersion \"26.0.10792818\"\r\n compileSdkVersion 33\r\n buildToolsVersion \"30.0.3\"\r\n```\r\nAnd issue still happen", "Hi @yen-dang-ts \r\n\r\nThanks for the information. I believe there is a Android version compatibility issue with latest TF versions. \r\n\r\nAre you using tflite-flutter for the task?\r\n\r\nHave you tried compiling the `libtensorflowlite_jni.so` for arm64 with the the latest TF 2.13 and nightly pull and still observe the same error?\r\n\r\nThanks.", "This problem has been reported in May for `tflite-flutter`: https://github.com/tensorflow/flutter-tflite/issues/73\r\n\r\nThe problem happens with Android 7.1.1 too. Not sure if Android 8.x/9.x are impacted (Android 13 is not impacted). (EDIT 2023-10-10: Android >= 8 are not impacted)\r\n\r\nWhere are the instructions to build `libtensorflowlite_jni.so`? I could help investigate this issue. Note that Google ML Kit Image Labeling for Flutter does support Android 5.0+ and includes runtime support for TF Lite.\r\n\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "> Hi @yen-dang-ts\r\n> \r\n> Thanks for the information. I believe there is a Android version compatibility issue with latest TF versions.\r\n> \r\n> Are you using tflite-flutter for the task?\r\n> \r\n> Have you tried compiling the `libtensorflowlite_jni.so` for amr64 with the the latest TF 2.13 and nightly pull and still observe the same error?\r\n> \r\n> Thanks.\r\n\r\n@pjpratik The problem was introduced in Tensorflow Lite 2.12.0. All versions >= 2.12.0 seem to be [affected](https://github.com/tensorflow/flutter-tflite/issues/73#issuecomment-1754696187). Version 2.11.0 is not affected by this issue. I also tested version 2.10.0, not affected either.\r\n\r\n", "Hi @yen-dang-ts, @andynewman10, can you give me more context to help reproduce your issue. Do you have a toy version of your model that reproduces this issue on load? Does it run into this on any model? If you can export/share a toy project that'll be easiest, or at least tell me your imports that contextualizes your code snippets:\r\n\r\n```\r\nval options = Interpreter.Options()\r\n val tfLite = Interpreter(\r\n TFLiteUtils.loadModelFile(context.assets, modelFileName),\r\n options\r\n )\r\n```\r\n```\r\nfun loadModelFile(assets: AssetManager, modelFilename: String?): MappedByteBuffer {\r\n val fileDescriptor = assets.openFd(modelFilename!!)\r\n val inputStream = FileInputStream(fileDescriptor.fileDescriptor)\r\n val fileChannel = inputStream.channel\r\n val startOffset = fileDescriptor.startOffset\r\n val declaredLength = fileDescriptor.declaredLength\r\n return fileChannel.map(FileChannel.MapMode.READ_ONLY, startOffset, declaredLength)\r\n }\r\n```\r\nI should note that currently we only support NDK up to 25b and not 26, you might want to see if that resolves your issues.", "https://github.com/tensorflow/tensorflow/blob/1bd1b7f4b0311575ead19f14e74488a97b524555/tensorflow/lite/g3doc/android/lite_build.md?plain=1#L126\r\nApparently , the minimum supported version of the official build is Android 8.0", "> Hi @yen-dang-ts, @andynewman10, can you give me more context to help reproduce your issue. Do you have a toy version of your model that reproduces this issue on load? Does it run into this on any model? If you can export/share a toy project that'll be easiest, or at least tell me your imports that contextualizes your code snippets:\r\n\r\n@pkgoogle You can use any model, for instance, this one (that I confirm works flawlessly):\r\n\r\nhttps://tfhub.dev/tensorflow/lite-model/efficientnet/lite4/uint8/2\r\n\r\nClick on the Download link on the right (download size: 14.34MB), and load this model in your code.\r\n\r\nYour code does not have to do anything meaningful. Just import the TF Lite dependencies (>= 2.12.0) in your Gradle file, and make sure that in your program, you execute the lines of code you mentionned in your post above\r\n\r\nThen run your the code on Android 7.1.1 (real device or emulator) and this will clearly replicate the issue (libtensorflowlite_jni.so issue with 'strtod_l')\r\n\r\nNow switch to Tensorflow Lite 2.11.0 dependencies in your Gradle file : the issue will not show up.\r\n\r\n\r\n", "> https://github.com/tensorflow/tensorflow/blob/1bd1b7f4b0311575ead19f14e74488a97b524555/tensorflow/lite/g3doc/android/lite_build.md?plain=1#L126\r\n> \r\n> \r\n> Apparently , the minimum supported version of the official build is Android 8.0\r\n\r\nNice find. Apparently, this commit (dated August, 7) is the one changing API level from 21 to 26:\r\n\r\nhttps://github.com/tensorflow/tensorflow/commit/6d53a5aefdecaba99e93c0933d6cc32050c108d7\r\n\r\nAs I am writing these lines, this is the latest commit affecting this file.\r\n", "@fiberflow, my bad I thought the previous comment referred to the line above that\r\n\r\nhttps://github.com/tensorflow/tensorflow/blob/1bd1b7f4b0311575ead19f14e74488a97b524555/tensorflow/lite/g3doc/android/lite_build.md?plain=1#L125C1-L125C74\r\n```\r\nbuild --action_env ANDROID_NDK_HOME=\"/usr/local/android/android-ndk-r21e\"\r\n```\r\nwhich is the NDK version not the NDK_API_LEVEL.", "Hi @yen-dang-ts, @andynewman10 I was able to replicate here (with SDK API level = 22, i.e. Android 5.1): [Test61951_min22.zip](https://github.com/tensorflow/tensorflow/files/12875033/Test61951_min22.zip). I was able to get around the error by using a higher SDK level, I tried with SDK API 34. If you can update your Android version and thus SDK API level you can possibly get around this.\r\n\r\nHi @miaout17, can you please take a look? Thanks.\r\n", "@pkgoogle Here is what I did:\r\n\r\n- I reinstalled Android Studio Giraffe from scratch using latest version\r\n- imported your project (Test61951_min22.zip) that has `minSdkVersion 22` specified in build.gradle, as well as `org.tensorflow:tensorflow-lite:2.13.0`\r\n- ran the program on my Android 7.1.1 (API level 25) device\r\n\r\nAs expected, I am getting the exception:\r\n\r\n```\r\nProcess: com.example.test61951_min22, PID: 17748\r\njava.lang.UnsatisfiedLinkError: Failed to load native TensorFlow Lite methods. Check that the correct native libraries are present, and, if using a custom native library, have been properly loaded via System.loadLibrary():\r\n java.lang.UnsatisfiedLinkError: dlopen failed: cannot locate symbol \"strtod_l\" referenced by \"/data/app/com.example.test61951_min22-1/lib/arm64/libtensorflowlite_jni.so\"...\r\n\tat org.tensorflow.lite.TensorFlowLite.init(TensorFlowLite.java:137)\r\n\tat org.tensorflow.lite.NativeInterpreterWrapper.<init>(NativeInterpreterWrapper.java:62)\r\n\tat org.tensorflow.lite.NativeInterpreterWrapperExperimental.<init>(NativeInterpreterWrapperExperimental.java:36)\r\n\tat org.tensorflow.lite.Interpreter.<init>(Interpreter.java:232)\r\n```\r\nAfter that, I switched to `org.tensorflow:tensorflow-lite:2.11.0`: the exception disappears.\r\n\r\n**Conclusion**: Android < 8 compatibility was suddenly lost with Tensorflow Lite >= 2.12.0.\r\n\r\nIs that expected?\r\n", "Hi @pkgoogle I have tried [Test61951_min22.zip](https://github.com/tensorflow/tensorflow/files/12875033/Test61951_min22.zip) as per your instructions and updated following versions to 34. I can confirm that I am still getting the same crash on Android Emulators using Android 7 (API level 25) and below.\r\n```\r\ncompileSdk 34\r\ntargetSdk 34\r\n```", "> Conclusion: Android < 8 compatibility was suddenly lost with Tensorflow Lite >= 2.12.0.\r\n> Is that expected?\r\n\r\nThe minimum API level was increased to API 26 in order to provide guaranteed support for AHardwareBuffer,\r\nwhich is used by the GPU delegate for the asynchronous API.\r\n\r\nHowever, I don't think the consequences of this were fully anticipated, understood, and weighed off\r\nwhen that change was made. Breaking compatibility with ~6% of existing devices (based on the numbers on https://apilevels.com/) seems undesirable. I think TF Lite should strive to support ~99% of existing devices.", "@fergushenderson IMHO, it always feels really good when you know a piece of software works on a \"best endeavor\" basis, targeting the widest possible audience. (on a side note, I would point out the fact that Android OS versions may sometimes be upgraded for just a few years only for a given device, but it should be noted that many apps can target Android 5 - Android 5 has plenty to offer already).\r\n\r\nThe dealbreaker for me is that the Gpu delegate is extremely restrictive. Very few models work with it. None of my models do actually.", "Hi @pkgoogle Is there an update on this?\r\n\r\nPlease also note that the official [documentation](https://www.tensorflow.org/lite/android/development#minimum_android_sdk_versions_for_libraries) still indicates that the `minSdkVersion` is 19.", "We are going to fix this.\r\n\r\nI have been discussing this with the TF Lite team, and we have consensus that this is a problem that should be fixed.\r\nI have analyzed the cause and possible solutions, and produced a prototype solution that allows use of AHardwareBuffer on versions of Android that support it while still remaining compatible with earlier versions of Android back to Android API level 21. A TF Lite team member (@[turbotoribio](https://github.com/tensorflow/tensorflow/commits?author=turbotoribio)) has taken on the remaining tasks to get this fix landed.\r\n\r\nThe main part of the fix has landed:\r\nhttps://github.com/tensorflow/tensorflow/commit/c7c3135b2802f3b8886f2ecefc39de49799b1e9b\r\n\r\nThe remaining parts are to change ANDROID_NDK_API_LEVEL from 26 back to 21.\r\n\r\nThe fix will be included in TF Lite 2.16.", "Thanks for the reply @fergushenderson. That is a great news!\r\nAre you also considering patching the previous versions, namely 2.12.0, 2.13.0, 2.14.0?\r\n", "We are _considering_ patching 2.15, since that could be shipped a lot sooner than 2.16.\r\n\r\nThere doesn't seem to be much benefit from patching 2.12-2.14, since users who are affected by this issue could just use 2.15 instead. (But please correct me if I am wrong about that.)", "@fergushenderson Do we know when the version 2.15 can be released on Maven central?", "@fergushenderson Our project needs version 2.15 please help me to answer the release date", "@fergushenderson I have just tried tensorflow-lite version 2.15.0. Now I am getting the following compilation error:\r\n\r\n```\r\n> Failed to transform guice-5.1.0.jar (com.google.inject:guice:5.1.0) to match attributes {artifactType=android-dex, asm-transformed-variant=NONE, dexing-enable-desugaring=true, dexing-enable-jacoco-instrumentation=false, dexing-is-debuggable=true, dexing-min-sdk=21, org.gradle.category=library, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}.\r\n > Execution failed for DexingWithClasspathTransform: /Users/nijatahmadli/.gradle/caches/modules-2/files-2.1/com.google.inject/guice/5.1.0/da25056c694c54ba16e78e4fc35f17fc60f0d1b4/guice-5.1.0.jar.\r\n > Error while dexing.\r\n Increase the minSdkVersion to 26 or above.\r\n```\r\nLooks like `guice` was introduced in 2.15.0 and requires minSdkVersion 26 which I guess stems from the use of Java 8 language features. Unfortunately, upgrading to 26 is not an option for our project. ", "@fergushenderson I have the same issue with @nijat-ahmadli. Please support us", "> @fergushenderson I have just tried tensorflow-lite version 2.15.0. Now I am getting the following compilation error:\r\n> \r\n> ```\r\n> > Failed to transform guice-5.1.0.jar (com.google.inject:guice:5.1.0) to match attributes {artifactType=android-dex, asm-transformed-variant=NONE, dexing-enable-desugaring=true, dexing-enable-jacoco-instrumentation=false, dexing-is-debuggable=true, dexing-min-sdk=21, org.gradle.category=library, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}.\r\n> > Execution failed for DexingWithClasspathTransform: /Users/nijatahmadli/.gradle/caches/modules-2/files-2.1/com.google.inject/guice/5.1.0/da25056c694c54ba16e78e4fc35f17fc60f0d1b4/guice-5.1.0.jar.\r\n> > Error while dexing.\r\n> Increase the minSdkVersion to 26 or above.\r\n> ```\r\n> \r\n> Looks like `guice` was introduced in 2.15.0 and requires minSdkVersion 26 which I guess stems from the use of Java 8 language features. Unfortunately, upgrading to 26 is not an option for our project.\r\n\r\nSame problem here. ", "Thanks for raising that issue with the guice dependency. I have alerted the TensorFlow Lite team of this new issue.\r\n\r\nThe tensorflow 2.16.0 preview release is out. Is the issue still reproducible in 2.16.0?\r\n\r\nIn general it is possible to use (most) Java 8 language features while depending only on API level 21, rather than 26.\r\nSee <https://developer.android.com/studio/write/java8-support> for details.\r\nSo if guice is using Java 8 language features, that doesn't necessarily mean that it needs to be incompatible with API level 21.\r\n", "I have a problem too, I think it's the same problem\r\nERROR:C:\\Users\\hp\\.gradle\\caches\\transforms-3\\0e1dbadb4b8b682380e0f29f2a20be93\\transformed\\jetified-guice-5.1.0.jar: D8: com.android.tools.r8.internal.a2: MethodHandle.invoke and MethodHandle.invokeExact are only supported starting with Android O (--min-api 26)\r\n\r\nFAILURE: Build failed with an exception.\r\n\r\n* What went wrong:\r\nExecution failed for task ':app:mergeExtDexDebug'.\r\n> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.\r\n > Failed to transform guice-5.1.0.jar (com.google.inject:guice:5.1.0) to match attributes {artifactType=android-dex, asm-transformed-variant=NONE, dexing-enable-desugaring=true, dexing-is-debuggable=true, dexing-min-sdk=21, org.gradle.category=library, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}.\r\n > Execution failed for DexingWithClasspathTransform: C:\\Users\\hp\\.gradle\\caches\\transforms-3\\0e1dbadb4b8b682380e0f29f2a20be93\\transformed\\jetified-guice-5.1.0.jar.\r\n > Error while dexing.", "According to the error messages, guice-5.1.0.jar is not compatible with Android 21. The Java support 8 of Android by desugaring seems not working with guice-5.1.0.jar, could you please consider removing it from the dependency list of tensorflow-lite?\r\n\r\n> @fergushenderson I have just tried tensorflow-lite version 2.15.0. Now I am getting the following compilation error:\r\n> \r\n> ```\r\n> > Failed to transform guice-5.1.0.jar (com.google.inject:guice:5.1.0) to match attributes {artifactType=android-dex, asm-transformed-variant=NONE, dexing-enable-desugaring=true, dexing-enable-jacoco-instrumentation=false, dexing-is-debuggable=true, dexing-min-sdk=21, org.gradle.category=library, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}.\r\n> > Execution failed for DexingWithClasspathTransform: /Users/nijatahmadli/.gradle/caches/modules-2/files-2.1/com.google.inject/guice/5.1.0/da25056c694c54ba16e78e4fc35f17fc60f0d1b4/guice-5.1.0.jar.\r\n> > Error while dexing.\r\n> Increase the minSdkVersion to 26 or above.\r\n> ```\r\n> \r\n> Looks like `guice` was introduced in 2.15.0 and requires minSdkVersion 26 which I guess stems from the use of Java 8 language features. Unfortunately, upgrading to 26 is not an option for our project.\r\n\r\n" ]
2023-09-22T09:28:09
2024-06-06T01:49:50
null
NONE
null
null
null
### 1. System information - OS Platform and Distribution: Android 5.1, OPPO device - TensorFlow library : Tensorflow lite 2.13.0 When I try to load model and get error: `E/art: dlopen("/data/app/com.app.demo-1/lib/arm64/libtensorflowlite_jni.so", RTLD_LAZY) failed: dlopen failed: cannot locate symbol "strtod_l" referenced by "/data/app/com.app.demo-1/lib/arm64/libtensorflowlite_jni.so"...`
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61951/reactions", "total_count": 3, "+1": 3, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61951/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61950
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61950/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61950/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61950/events
https://github.com/tensorflow/tensorflow/issues/61950
1,908,510,753
I_kwDOArmXAs5xwZAh
61,950
TFLite benchmark tool with default cmake build shows weird time duration on DEPTHWISE_CONV_2D
{ "login": "captainst", "id": 23187023, "node_id": "MDQ6VXNlcjIzMTg3MDIz", "avatar_url": "https://avatars.githubusercontent.com/u/23187023?v=4", "gravatar_id": "", "url": "https://api.github.com/users/captainst", "html_url": "https://github.com/captainst", "followers_url": "https://api.github.com/users/captainst/followers", "following_url": "https://api.github.com/users/captainst/following{/other_user}", "gists_url": "https://api.github.com/users/captainst/gists{/gist_id}", "starred_url": "https://api.github.com/users/captainst/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/captainst/subscriptions", "organizations_url": "https://api.github.com/users/captainst/orgs", "repos_url": "https://api.github.com/users/captainst/repos", "events_url": "https://api.github.com/users/captainst/events{/privacy}", "received_events_url": "https://api.github.com/users/captainst/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "#61946", "Hi @captainst \r\n\r\nSorry for the delayed response.\r\n\r\nHave you observed the same in multiple runs, also can you check the same if it replicates with nightly pull as well?\r\n\r\nThanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61950\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61950\">No</a>\n" ]
2023-09-22T09:13:44
2023-10-13T01:48:29
2023-10-13T01:48:27
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version tf 2.9.3, tf 2.13.0 ### Custom code No ### OS platform and distribution Linux Ubuntu 20.04 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version 5.0 ### GCC/compiler version gcc 9.4.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Following the guide for [build_cmake](https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/g3doc/guide/build_cmake.md) `cmake ../tensorflow_src/tensorflow/lite` then build the benchmark tool & label_image: ``` cmake --build . -j -t benchmark_model cmake --build . -j -t label_image ``` I tested using the model [here](https://storage.googleapis.com/download.tensorflow.org/models/tflite/mobilenet_v1_1.0_224_quant_and_labels.zip). The results shows: ============================== Summary by node type ============================== [Node type] [count] [avg ms] [avg %] [cdf %] [mem KB] [times called] CONV_2D 15 38.265 58.415% 58.415% 0.000 15 DEPTHWISE_CONV_2D 13 27.230 41.569% 99.985% 0.000 13 AVERAGE_POOL_2D 1 0.007 0.011% 99.995% 0.000 1 SOFTMAX 1 0.003 0.005% 100.000% 0.000 1 RESHAPE 1 0.000 0.000% 100.000% 0.000 1 In theory, 13 x DEPTHWISE_CONV_2D should consume MUCH less time than 15 CONV_2, but it is not the case here. However, if I use the pre-built binary from [here](https://storage.googleapis.com/tensorflow-nightly-public/prod/tensorflow/release/lite/tools/nightly/latest/linux_x86-64_benchmark_model), the result is correct. ### Standalone code to reproduce the issue ```shell benchmark_model --graph=./mobilenet_quant_v1_224.tflite --enable_op_profiling=true ``` ### Relevant log output ```shell ============================== Summary by node type ============================== [Node type] [count] [avg ms] [avg %] [cdf %] [mem KB] [times called] CONV_2D 15 38.265 58.415% 58.415% 0.000 15 DEPTHWISE_CONV_2D 13 27.230 41.569% 99.985% 0.000 13 AVERAGE_POOL_2D 1 0.007 0.011% 99.995% 0.000 1 SOFTMAX 1 0.003 0.005% 100.000% 0.000 1 RESHAPE 1 0.000 0.000% 100.000% 0.000 1 ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61950/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61950/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61949
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61949/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61949/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61949/events
https://github.com/tensorflow/tensorflow/issues/61949
1,908,362,289
I_kwDOArmXAs5xv0wx
61,949
A call of the model which is reloaded from SavedModel format produces a TypeError
{ "login": "molokanov50", "id": 85157008, "node_id": "MDQ6VXNlcjg1MTU3MDA4", "avatar_url": "https://avatars.githubusercontent.com/u/85157008?v=4", "gravatar_id": "", "url": "https://api.github.com/users/molokanov50", "html_url": "https://github.com/molokanov50", "followers_url": "https://api.github.com/users/molokanov50/followers", "following_url": "https://api.github.com/users/molokanov50/following{/other_user}", "gists_url": "https://api.github.com/users/molokanov50/gists{/gist_id}", "starred_url": "https://api.github.com/users/molokanov50/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/molokanov50/subscriptions", "organizations_url": "https://api.github.com/users/molokanov50/orgs", "repos_url": "https://api.github.com/users/molokanov50/repos", "events_url": "https://api.github.com/users/molokanov50/events{/privacy}", "received_events_url": "https://api.github.com/users/molokanov50/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@molokanov50,\r\nApologies for the delay. When i tried to save the model with the same configuration as you mentioned, it had only one .pb file saved_model.pb. Size of the model ~3.4MB.\r\n\r\nAlso try to use keras load model to load your model.\r\n\r\n```\r\nfrom tensorflow import keras\r\n\r\nnew_model = keras.models.load_model(\"save_model_keras\")\r\nnew_model.summary()\r\n```\r\n\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61949\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61949\">No</a>\n" ]
2023-09-22T07:41:00
2023-10-29T01:48:13
2023-10-29T01:48:10
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source binary ### TensorFlow version 2.13 ### Custom code No ### OS platform and distribution Linux Ubuntu 20.04 ### Mobile device _No response_ ### Python version 3.9 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.2 ### GPU model and memory _No response_ ### Current behavior? A call of the model which is reloaded from SavedModel format produces a `TypeError: '_UserObject' object is not callable`. All necessary code is in [this tutorial](https://www.tensorflow.org/text/tutorials/transformer). Below I show code lines from there, where the error occurs. ### Standalone code to reproduce the issue ```shell reloaded = tf.saved_model.load('translator') reloaded('este é o primeiro livro que eu fiz.').numpy() ``` ### Relevant log output ```shell Traceback (most recent call last): File "/home/molokanov/tensorflow/check.py", line 13, in <module> reloaded('este é o primeiro livro que eu fiz.').numpy() TypeError: '_UserObject' object is not callable ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61949/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61949/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61948
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61948/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61948/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61948/events
https://github.com/tensorflow/tensorflow/issues/61948
1,908,233,498
I_kwDOArmXAs5xvVUa
61,948
TensorFlow.js: export failure ❌ 0.6s: [Errno 2] No such file or directory: 'tensorflowjs_converter'
{ "login": "lindow2009", "id": 1233164, "node_id": "MDQ6VXNlcjEyMzMxNjQ=", "avatar_url": "https://avatars.githubusercontent.com/u/1233164?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lindow2009", "html_url": "https://github.com/lindow2009", "followers_url": "https://api.github.com/users/lindow2009/followers", "following_url": "https://api.github.com/users/lindow2009/following{/other_user}", "gists_url": "https://api.github.com/users/lindow2009/gists{/gist_id}", "starred_url": "https://api.github.com/users/lindow2009/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lindow2009/subscriptions", "organizations_url": "https://api.github.com/users/lindow2009/orgs", "repos_url": "https://api.github.com/users/lindow2009/repos", "events_url": "https://api.github.com/users/lindow2009/events{/privacy}", "received_events_url": "https://api.github.com/users/lindow2009/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @lindow2009 \r\n\r\nThis seems to be related to tensorflow js converter issue from the information provided.\r\n\r\nPlease post this issue in tensorflow.js repo for faster resolution,\r\nhttps://github.com/tensorflow/tfjs/issues\r\n\r\nThanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further." ]
2023-09-22T05:59:06
2023-10-13T01:48:29
2023-10-13T01:48:29
NONE
null
null
null
System information OS Platform and Distribution (e.g., Linux Ubuntu 16.04): MAC OS TensorFlow installed from (source or binary): binray TensorFlow version (use command below): 2.13.0 TensorFlowJS version: 4.11.0 Python version: 3.9 When I using tensorflowjs_converter to convert pt model: TensorFlow SavedModel: export success ✅ 29.7s, saved as yolov5n-seg_saved_model (7.9 MB) TensorFlow GraphDef: starting export with tensorflow 2.13.0... TensorFlow GraphDef: export success ✅ 3.7s, saved as yolov5n-seg.pb (7.9 MB) WARNING ⚠️ invalid check_version(4.11.0, ) requested, please check values. TensorFlow.js: starting export with tensorflowjs 4.11.0... TensorFlow.js: export failure ❌ 0.6s: [Errno 2] No such file or directory: 'tensorflowjs_converter' tensorflowjs_converter not founded
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61948/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61948/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61947
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61947/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61947/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61947/events
https://github.com/tensorflow/tensorflow/issues/61947
1,908,206,399
I_kwDOArmXAs5xvOs_
61,947
TF 2.12: InternalError: cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version
{ "login": "yap231995", "id": 35169648, "node_id": "MDQ6VXNlcjM1MTY5NjQ4", "avatar_url": "https://avatars.githubusercontent.com/u/35169648?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yap231995", "html_url": "https://github.com/yap231995", "followers_url": "https://api.github.com/users/yap231995/followers", "following_url": "https://api.github.com/users/yap231995/following{/other_user}", "gists_url": "https://api.github.com/users/yap231995/gists{/gist_id}", "starred_url": "https://api.github.com/users/yap231995/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yap231995/subscriptions", "organizations_url": "https://api.github.com/users/yap231995/orgs", "repos_url": "https://api.github.com/users/yap231995/repos", "events_url": "https://api.github.com/users/yap231995/events{/privacy}", "received_events_url": "https://api.github.com/users/yap231995/received_events", "type": "User", "site_admin": false }
[ { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 1205615612, "node_id": "MDU6TGFiZWwxMjA1NjE1NjEy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux", "name": "subtype: ubuntu/linux", "color": "b619ea", "default": false, "description": "Ubuntu/Linux Build/Installation Issues" }, { "id": 5206407904, "node_id": "LA_kwDOArmXAs8AAAABNlN64A", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.12", "name": "TF 2.12", "color": "c5def5", "default": false, "description": "For issues related to Tensorflow 2.12" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "@yap231995 \r\nGenerally, this error occurs when the version of the NVIDIA driver installed on your system is not compatible with the version of CUDA you are using. Specifically, the CUDA runtime version you are using requires a higher version of the NVIDIA driver than the one currently installed on your system.\r\nI tried to replicate the issue and faced a different [error](https://colab.research.google.com/gist/sushreebarsa/33c7d1045cde839dc7d1690e2785e933/61947.ipynb), could you please provide the complete standalone code to replicate the issue reported?\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61947\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61947\">No</a>\n" ]
2023-09-22T05:29:20
2023-10-07T01:47:23
2023-10-07T01:47:20
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version TF 2.12 ### Custom code Yes ### OS platform and distribution Linux Ubuntu 16.04 ### Mobile device _No response_ ### Python version 3.9 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 11.8 ### GPU model and memory GTX970 ### Current behavior? I have install `pip install tensorflow ==2.12`. I followed the page: https://www.tensorflow.org/install/pip and install `conda install -c conda-forge cudatoolkit=11.8.0` and `nvidia-cudnn-cu11==8.6.0.163` From the build from source it says that it requires cuda 11.8 This is determined here `nvcc -version`. ``` nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2022 NVIDIA Corporation Built on Wed_Sep_21_10:33:58_PDT_2022 Cuda compilation tools, release 11.8, V11.8.89 Build cuda_11.8.r11.8/compiler.31833905_0 ``` I tried to see if it is using GPU and it does. ``` 2023-09-22 13:17:18.164612: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations. To enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags. 2023-09-22 13:17:18.813461: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT 2023-09-22 13:17:21.116323: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.117135: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.117901: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.118662: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.141750: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.142582: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.143350: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.144117: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.144878: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.145642: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.146398: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 2023-09-22 13:17:21.147155: I tensorflow/compiler/xla/stream_executor/cuda/cuda_gpu_executor.cc:996] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355 [PhysicalDevice(name='/physical_device:GPU:0', device_type='GPU'), PhysicalDevice(name='/physical_device:GPU:1', device_type='GPU'), PhysicalDevice(name='/physical_device:GPU:2', device_type='GPU'), PhysicalDevice(name='/physical_device:GPU:3', device_type='GPU')] ``` However, when I tried to create a neural network: It gives me the following error: ```shell Traceback (most recent call last): File "/home/trevor/distinguisher/main.py", line 73, in <module> net_pp = train_preprocessor_triplet_loss(n=10000, nr=num_rounds, epochs=epoch) File "/home/trevor/distinguisher/main.py", line 53, in train_preprocessor_triplet_loss net_pp = make_resnet_preprocess(depth=1) File "/home/trevor/distinguisher/main.py", line 26, in make_resnet_preprocess conv0 = Conv1D(num_filters, kernel_size=1, padding='same', kernel_regularizer=l2(reg_param))(perm) File "/home/trevor/anaconda3/envs/tf_2/lib/python3.9/site-packages/keras/utils/traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None File "/home/trevor/anaconda3/envs/tf_2/lib/python3.9/site-packages/keras/backend.py", line 2101, in random_uniform return tf.random.stateless_uniform( tensorflow.python.framework.errors_impl.InternalError: cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version ``` I have searched online and say that the CUDA version is too high but from build it seems to be 11.8. May I know what is the issue here? ### Standalone code to reproduce the issue ```shell def make_resnet_preprocess(num_blocks=2, num_filters=32, num_outputs=1, d1=64, d2=64, word_size=16, ks=3, depth=5, reg_param=0.0001, final_activation='sigmoid'): # Input and preprocessing layers inp = Input(shape=(num_blocks * word_size * 2,)) rs = Reshape((2 * num_blocks, word_size))(inp) perm = Permute((2, 1))(rs) # add a single residual layer that will expand the data to num_filters channels # this is a bit-sliced layer conv0 = Conv1D(num_filters, kernel_size=1, padding='same', kernel_regularizer=l2(reg_param))(perm) conv0 = BatchNormalization()(conv0) conv0 = Activation('relu')(conv0) # add residual blocks shortcut = conv0 for i in range(depth): conv1 = Conv1D(num_filters, kernel_size=ks, padding='same', kernel_regularizer=l2(reg_param))(shortcut) conv1 = BatchNormalization()(conv1) conv1 = Activation('relu')(conv1) conv2 = Conv1D(num_filters, kernel_size=ks, padding='same', kernel_regularizer=l2(reg_param))(conv1) conv2 = BatchNormalization()(conv2) conv2 = Activation('relu')(conv2) shortcut = Add()([shortcut, conv2]) # add prediction head flat1 = Flatten()(shortcut) dense1 = Dense(d1, kernel_regularizer=l2(reg_param))(flat1) dense1 = BatchNormalization()(dense1) dense1 = Activation('relu')(dense1) dense2 = Dense(d2, kernel_regularizer=l2(reg_param))(dense1) dense2 = BatchNormalization()(dense2) out = Activation('relu')(dense2) # out = Dense(num_outputs, activation=final_activation, kernel_regularizer=l2(reg_param))(dense2) model = Model(inputs=inp, outputs=out) return (model) net_pp = train_preprocessor_triplet_loss(n=10 ** 7, nr=num_rounds, epochs=epoch) ``` ### Relevant log output ```shell Traceback (most recent call last): File "/home/trevor/distinguisher/main.py", line 73, in <module> net_pp = train_preprocessor_triplet_loss(n=10000, nr=num_rounds, epochs=epoch) File "/home/trevor/distinguisher/main.py", line 53, in train_preprocessor_triplet_loss net_pp = make_resnet_preprocess(depth=1) File "/home/trevor/distinguisher/main.py", line 26, in make_resnet_preprocess conv0 = Conv1D(num_filters, kernel_size=1, padding='same', kernel_regularizer=l2(reg_param))(perm) File "/home/trevor/anaconda3/envs/tf_2/lib/python3.9/site-packages/keras/utils/traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None File "/home/trevor/anaconda3/envs/tf_2/lib/python3.9/site-packages/keras/backend.py", line 2101, in random_uniform return tf.random.stateless_uniform( tensorflow.python.framework.errors_impl.InternalError: cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version``` ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61947/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61947/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61946
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61946/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61946/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61946/events
https://github.com/tensorflow/tensorflow/issues/61946
1,908,077,601
I_kwDOArmXAs5xuvQh
61,946
TFLite with default cmake build, xnnpack does not work for quantized model
{ "login": "captainst", "id": 23187023, "node_id": "MDQ6VXNlcjIzMTg3MDIz", "avatar_url": "https://avatars.githubusercontent.com/u/23187023?v=4", "gravatar_id": "", "url": "https://api.github.com/users/captainst", "html_url": "https://github.com/captainst", "followers_url": "https://api.github.com/users/captainst/followers", "following_url": "https://api.github.com/users/captainst/following{/other_user}", "gists_url": "https://api.github.com/users/captainst/gists{/gist_id}", "starred_url": "https://api.github.com/users/captainst/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/captainst/subscriptions", "organizations_url": "https://api.github.com/users/captainst/orgs", "repos_url": "https://api.github.com/users/captainst/repos", "events_url": "https://api.github.com/users/captainst/events{/privacy}", "received_events_url": "https://api.github.com/users/captainst/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 2726299159, "node_id": "MDU6TGFiZWwyNzI2Mjk5MTU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite-xnnpack", "name": "comp:lite-xnnpack", "color": "97F7B2", "default": false, "description": "TensorFlow Lite XNNPack related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "terryheo", "id": 2908505, "node_id": "MDQ6VXNlcjI5MDg1MDU=", "avatar_url": "https://avatars.githubusercontent.com/u/2908505?v=4", "gravatar_id": "", "url": "https://api.github.com/users/terryheo", "html_url": "https://github.com/terryheo", "followers_url": "https://api.github.com/users/terryheo/followers", "following_url": "https://api.github.com/users/terryheo/following{/other_user}", "gists_url": "https://api.github.com/users/terryheo/gists{/gist_id}", "starred_url": "https://api.github.com/users/terryheo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/terryheo/subscriptions", "organizations_url": "https://api.github.com/users/terryheo/orgs", "repos_url": "https://api.github.com/users/terryheo/repos", "events_url": "https://api.github.com/users/terryheo/events{/privacy}", "received_events_url": "https://api.github.com/users/terryheo/received_events", "type": "User", "site_admin": false }
[ { "login": "terryheo", "id": 2908505, "node_id": "MDQ6VXNlcjI5MDg1MDU=", "avatar_url": "https://avatars.githubusercontent.com/u/2908505?v=4", "gravatar_id": "", "url": "https://api.github.com/users/terryheo", "html_url": "https://github.com/terryheo", "followers_url": "https://api.github.com/users/terryheo/followers", "following_url": "https://api.github.com/users/terryheo/following{/other_user}", "gists_url": "https://api.github.com/users/terryheo/gists{/gist_id}", "starred_url": "https://api.github.com/users/terryheo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/terryheo/subscriptions", "organizations_url": "https://api.github.com/users/terryheo/orgs", "repos_url": "https://api.github.com/users/terryheo/repos", "events_url": "https://api.github.com/users/terryheo/events{/privacy}", "received_events_url": "https://api.github.com/users/terryheo/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "I am able to replicate:\r\n\r\n```sh\r\n(base) xxxxxx@xxxxxxxxx:~/issues/61946/tflite_build/tools/benchmark$ ./benchmark_model --graph=./mobilenet_v1_1.0_224_quant.tflite\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [./mobilenet_v1_1.0_224_quant.tflite]\r\nINFO: Loaded model ./mobilenet_v1_1.0_224_quant.tflite\r\nINFO: The input model file size (MB): 4.27635\r\nINFO: Initialized session in 0.53ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=5 first=124020 curr=116061 min=115177 max=124020 avg=117225 std=3412\r\n\r\nINFO: Running benchmark for at least 50 iterations and at least 1 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=50 first=121183 curr=115199 min=111222 max=121324 avg=116066 std=1906\r\n\r\nINFO: Inference timings in us: Init: 530, First inference: 124020, Warmup (avg): 117225, Inference (avg): 116066\r\nINFO: Note: as the benchmark tool itself affects memory footprint, the following is only APPROXIMATE to the actual memory footprint of the model at runtime. Take the information at your discretion.\r\nINFO: Memory footprint delta from the start of the tool (MB): init=3.75 overall=12.1914\r\n(base) xxxxxxx@xxxxxxxxx:~/issues/61946/tflite_build/tools/benchmark$ ./benchmark_model --graph=./mobilenet_v1_1.0_224_quant.tflite --use_xnnpack=true\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [./mobilenet_v1_1.0_224_quant.tflite]\r\nINFO: Use xnnpack: [1]\r\nINFO: Loaded model ./mobilenet_v1_1.0_224_quant.tflite\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\nINFO: XNNPACK delegate created.\r\nINFO: Though XNNPACK delegate is explicitly applied, the model graph will not be executed by the delegate.\r\nINFO: The input model file size (MB): 4.27635\r\nINFO: Initialized session in 1.624ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=5 first=118606 curr=115130 min=115130 max=118606 avg=115913 std=1351\r\n\r\nINFO: Running benchmark for at least 50 iterations and at least 1 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=50 first=118240 curr=115075 min=113462 max=118240 avg=115403 std=915\r\n\r\nINFO: Inference timings in us: Init: 1624, First inference: 118606, Warmup (avg): 115913, Inference (avg): 115403\r\nINFO: Note: as the benchmark tool itself affects memory footprint, the following is only APPROXIMATE to the actual memory footprint of the model at runtime. Take the information at your discretion.\r\nINFO: Memory footprint delta from the start of the tool (MB): init=4.125 overall=12.2188\r\n(base) xxxxxx@xxxxxxxxx:~/issues/61946/tflite_build/tools/benchmark$ ./benchmark_model --graph=./mobilenet_v1_1.0_224_quant.tflite --use_xnnpack=false\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [./mobilenet_v1_1.0_224_quant.tflite]\r\nINFO: Use xnnpack: [0]\r\nINFO: Loaded model ./mobilenet_v1_1.0_224_quant.tflite\r\nINFO: The input model file size (MB): 4.27635\r\nINFO: Initialized session in 0.624ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=5 first=119736 curr=115120 min=115120 max=119736 avg=116948 std=1708\r\n\r\nINFO: Running benchmark for at least 50 iterations and at least 1 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=50 first=116137 curr=115145 min=114959 max=118105 avg=115743 std=829\r\n\r\nINFO: Inference timings in us: Init: 624, First inference: 119736, Warmup (avg): 116948, Inference (avg): 115743\r\nINFO: Note: as the benchmark tool itself affects memory footprint, the following is only APPROXIMATE to the actual memory footprint of the model at runtime. Take the information at your discretion.\r\nINFO: Memory footprint delta from the start of the tool (MB): init=3.75 overall=12.1914\r\n```\r\n\r\nSeems like maybe the cmake files might be out of date, @terryheo can you please take a look? Thanks.\r\n\r\n@captainst, can you please include the bazel build commands as well?\r\n", "@alankelly ", "This should do it: https://github.com/tensorflow/tensorflow/commit/db6395777b85e5eaa07651333bc3368b4c73a0ff" ]
2023-09-22T02:19:24
2023-11-02T21:12:19
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version tf 2.9.3, tf 2.13.0 ### Custom code No ### OS platform and distribution Linux Ubuntu 20.04 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version 5.0 ### GCC/compiler version gcc 9.4.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Following the guide for [build_cmake](https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/g3doc/guide/build_cmake.md) `cmake ../tensorflow_src/tensorflow/lite` then build the benchmark tool & label_image: ``` cmake --build . -j -t benchmark_model cmake --build . -j -t label_image ``` I tested using the model [here](https://storage.googleapis.com/download.tensorflow.org/models/tflite/mobilenet_v1_1.0_224_quant_and_labels.zip). Both the benchmark_model tool & label_image example do **NOT** show different inference time, whether using xnnpack or not. The log shows _"Though XNNPACK delegate is explicitly applied, the model graph will not be executed by the `delegate"_` **However, using the bazel build with following definitions:** ``` --define tflite_with_xnnpack_qs8=true --define tflite_with_xnnpack_qu8=true --define tflite_with_xnnpack=true ``` did show that using xnnpack, the inference time is 3x less. ### Standalone code to reproduce the issue ```shell # for benchmark, with xnnpack benchmark_model --graph=./mobilenet_quant_v1_224.tflite --use_xnnpack=true # for benchmark, no xnnpack benchmark_model --graph=./mobilenet_quant_v1_224.tflite --use_xnnpack=false # label_image, with xnnpack label_image -m ./mobilenet_quant_v1_224.tflite -i ./grace_hopper.bmp -l labels.txt -x 1 # label_image, no xnnpack label_image -m ./mobilenet_quant_v1_224.tflite -i ./grace_hopper.bmp -l labels.txt -x 0 ``` ### Relevant log output ```shell Log from benchmark_model with cmake build: STARTING! Log parameter values verbosely: [0] Graph: [./mobilenet_quant_v1_224.tflite] Use xnnpack: [1] Loaded model ./mobilenet_quant_v1_224.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. XNNPACK delegate created. Though XNNPACK delegate is explicitly applied, the model graph will not be executed by the delegate. The input model file size (MB): 4.27635 Initialized session in 0.609ms. Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds. count=6 first=88887 curr=84456 min=84307 max=88887 avg=85234.3 std=1638 ... ========================================= Log from benchmark_model with bazel build: STARTING! Log parameter values verbosely: [0] Graph: [./mobilenet_quant_v1_224.tflite] Use xnnpack: [1] Loaded model tflite_build_native_old/examples/label_image/mobilenet_quant_v1_224.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. XNNPACK delegate created. Explicitly applied XNNPACK delegate, and the model graph will be partially executed by the delegate w/ 2 delegate kernels. The input model file size (MB): 4.27635 Initialized session in 4.844ms. Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds. count=41 first=14002 curr=12270 min=12128 max=14002 avg=12400.6 std=398 ... ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61946/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61946/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61945
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61945/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61945/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61945/events
https://github.com/tensorflow/tensorflow/issues/61945
1,907,710,860
I_kwDOArmXAs5xtVuM
61,945
The metrics values in fit and in evaluate do not match (tf+keras)
{ "login": "xxraytz", "id": 41723606, "node_id": "MDQ6VXNlcjQxNzIzNjA2", "avatar_url": "https://avatars.githubusercontent.com/u/41723606?v=4", "gravatar_id": "", "url": "https://api.github.com/users/xxraytz", "html_url": "https://github.com/xxraytz", "followers_url": "https://api.github.com/users/xxraytz/followers", "following_url": "https://api.github.com/users/xxraytz/following{/other_user}", "gists_url": "https://api.github.com/users/xxraytz/gists{/gist_id}", "starred_url": "https://api.github.com/users/xxraytz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/xxraytz/subscriptions", "organizations_url": "https://api.github.com/users/xxraytz/orgs", "repos_url": "https://api.github.com/users/xxraytz/repos", "events_url": "https://api.github.com/users/xxraytz/events{/privacy}", "received_events_url": "https://api.github.com/users/xxraytz/received_events", "type": "User", "site_admin": false }
[ { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 4032183365, "node_id": "LA_kwDOArmXAs7wVjxF", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.9", "name": "TF 2.9", "color": "1CF842", "default": false, "description": "Issues found in the TF 2.9 release (or RCs)" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61945\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61945\">No</a>\n", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61945\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61945\">No</a>\n" ]
2023-09-21T20:30:46
2023-10-12T13:53:18
2023-10-12T13:53:16
NONE
null
null
null
### Issue type Support ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.9 ### Custom code Yes ### OS platform and distribution Linux Ubuntu ### Mobile device _No response_ ### Python version 3.8 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I have the issue which I described under in detail. Might be it's a my mistake but I try to fix it not a one day. I simplified it as much as possible fitting the model to show you exactly an issue. Let it be not a pre-trained model ResNet50. And let's I provide a dataset by easy way where X_train and Y_train are the ndarray with correspond shapes [N, 32, 32, 3] and [N, class_num=3]. I set batch_size=128, shuffle=False. Now I fitting my model and after the last epoch I get the metric equals 0.976, BUT If I just make model.evaluate(X_train), where X_train is the same data I use in fit I get absolutely different value - 0.456. The question is - WHY? That's logs of my fitting: 263/263 [==============================] - 7s 27ms/step - loss: 0.2063 - auc: 0.9899 - mc_f1: 0.9326 That's after evaluate: 1052/1052 [==============================] - 11s 9ms/step - loss: 0.6186 - auc: 0.9053 - mc_f1: 0.4993 To prevent questions - mc_f1 is a custom metric - averaged f1 calculated for each class separately for the multiclass case. So the code: # Change last layers last_layer = model.output output = tf.keras.layers.Dense(classes, activation="softmax")(last_layer) model = tf.keras.models.Model(inputs=model.inputs, outputs=output) return model mcf1 = MulticlassF1(num_classes=3) resnet50 = get_resnet50_model([32, 32, 3], 3) resnet50.compile( optimizer=Adam(), loss=tf.keras.losses.CategoricalCrossentropy(), metrics=[tf.metrics.AUC(name='auc'), mcf1], ) ``` Fitting: ``` deb_metric_callback = DebugMetricCallback(resnet50, (X_train, Y_train), mcf1) resnet50.fit( X_train, Y_train, epochs=100, batch_size=128, # verbose=0, shuffle=False, callbacks=[deb_metric_callback], ) ``` I have the issue which I described under in detail. Might be it's a my mistake but I try to fix it not a one day. I simplified it as much as possible fitting the model to show you exactly an issue. Let it be not a pre-trained model ResNet50. And let's I provide a dataset by easy way where X_train and Y_train are the ndarray with correspond shapes [N, 32, 32, 3] and [N, class_num=3]. I set batch_size=128, shuffle=False. Now I fitting my model and after the last epoch I get the metric equals 0.976, BUT If I just make model.evaluate(X_train), where X_train is the same data I use in fit I get absolutely different value - 0.456. The question is - WHY? That's logs of my fitting: 263/263 [==============================] - 7s 27ms/step - loss: 0.2063 - auc: 0.9899 - mc_f1: 0.9326 That's after evaluate: 1052/1052 [==============================] - 11s 9ms/step - loss: 0.6186 - auc: 0.9053 - mc_f1: 0.4993 To prevent questions - mc_f1 is a custom metric - averaged f1 calculated for each class separately for the multiclass case. So the code: The metric: ``` class MulticlassF1(tf.keras.metrics.Metric): def __init__(self, name='mc_f1', num_classes=None, **kwargs): super(MulticlassF1, self).__init__(name=name, **kwargs) self.__zero_support = tf.cast(1e-7, dtype=tf.float16) self.__cm = self.add_weight(name='fn', initializer='zeros', shape=[num_classes, num_classes]) if num_classes is not None: self.__num_classes = num_classes def update_state(self, y_true, y_pred, sample_weight=None): y_pred = K.argmax(y_pred, axis=1) y_true = K.argmax(y_true, axis=1) m = tf.math.confusion_matrix(y_true, y_pred, num_classes=self.__num_classes, dtype=tf.float32) self.__cm.assign_add(m) def reset_state(self): self.__cm.assign(tf.zeros((self.__num_classes, self.__num_classes))) def result(self): denominator = 0 m = self.__cm for i in range(m.shape[0]): tp = m[i, i] fn = K.sum(m[:, i]) - tp fp = K.sum(m[i, :]) - tp tn = K.sum(K.flatten(m)) - (tp + fn + fp) tp = K.cast(tp, dtype=tf.float16) tn = K.cast(tn, dtype=tf.float16) fp = K.cast(fp, dtype=tf.float16) fn = K.cast(fn, dtype=tf.float16) precision = tp / ((tp + fp) + self.__zero_support) + self.__zero_support recall = tp / (tf.cast(tp + fn, dtype=tf.float16) + self.__zero_support) + self.__zero_support denominator += (1 / precision + 1 / recall) f1_combined = K.cast(2 * m.shape[0] / denominator, dtype=tf.float32) return f1_combined ``` The model declaration ``` def get_resnet50_model(window_size, classes): # Model initialization model = tf.keras.applications.ResNet50V2( include_top=False, weights=None, input_tensor=None, input_shape=window_size, pooling='max', classes=classes, ) # Change last layers last_layer = model.output output = tf.keras.layers.Dense(classes, activation="softmax")(last_layer) model = tf.keras.models.Model(inputs=model.inputs, outputs=output) return model mcf1 = MulticlassF1(num_classes=3) resnet50 = get_resnet50_model([32, 32, 3], 3) resnet50.compile( optimizer=Adam(), loss=tf.keras.losses.CategoricalCrossentropy(), metrics=[tf.metrics.AUC(name='auc'), mcf1], ) ``` Fitting: ``` deb_metric_callback = DebugMetricCallback(resnet50, (X_train, Y_train), mcf1) resnet50.fit( X_train, Y_train, epochs=100, batch_size=128, # verbose=0, shuffle=False, callbacks=[deb_metric_callback], ) ``` I tried to do some debug and make a CallBack: ``` class DebugMetricCallback(Callback): def __init__(self, test, metr): super().__init__() self.test = test self.metric = metr def on_epoch_end(self, epoch, logs=None): print(self.metric.result()) x, y = self.test y_pred = self.model.predict(x) inline_measure = MulticlassF1(num_classes=3) inline_measure.update_state(y, y_pred) print(self.metric.result().numpy(), inline_measure.result().numpy()) ``` Here I get absolutely different confusion matrices. Also I thought that this is the problem with BatchNormalization, but I save and compare model before and after evaluate it wasn't changed. ### Standalone code to reproduce the issue ```shell https://github.com/xxraytz/temp.git ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61945/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61945/timeline
null
not_planned
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61944
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61944/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61944/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61944/events
https://github.com/tensorflow/tensorflow/issues/61944
1,907,519,309
I_kwDOArmXAs5xsm9N
61,944
TF Lite runtime error: "Didn't find op for builtin opcode 'PLACEHOLDER_FOR_GREATER_OP_CODES' version '1'"
{ "login": "andynewman10", "id": 113537099, "node_id": "U_kgDOBsRwSw", "avatar_url": "https://avatars.githubusercontent.com/u/113537099?v=4", "gravatar_id": "", "url": "https://api.github.com/users/andynewman10", "html_url": "https://github.com/andynewman10", "followers_url": "https://api.github.com/users/andynewman10/followers", "following_url": "https://api.github.com/users/andynewman10/following{/other_user}", "gists_url": "https://api.github.com/users/andynewman10/gists{/gist_id}", "starred_url": "https://api.github.com/users/andynewman10/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/andynewman10/subscriptions", "organizations_url": "https://api.github.com/users/andynewman10/orgs", "repos_url": "https://api.github.com/users/andynewman10/repos", "events_url": "https://api.github.com/users/andynewman10/events{/privacy}", "received_events_url": "https://api.github.com/users/andynewman10/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @andynewman10 \r\n\r\nI'm not sure if there is a build for 2.13.0 because the Flutter packages are not officially supported but rather contributed by the community.\r\n\r\nYou may try updating package dependencies https://docs.flutter.dev/packages-and-plugins/using-packages#updating-package-dependencies or use flutter tflite plugin https://github.com/tensorflow/flutter-tflite which has been recently migrated to tensorflow.\r\n\r\nPlease check this [blog](https://blog.tensorflow.org/2023/08/the-tensorflow-lite-plugin-for-flutter-officially-available.html?_gl=1*1gvogab*_ga*OTQ0MDM3NDM1LjE2Njg1Nzc1NzU.*_ga_W0YLR4190T*MTY5NTczMDE1MC45MDkuMS4xNjk1NzMyNzc1LjAuMC4w) for the same.\r\n\r\nThanks.", "I have solved this issue by using TensorFlow 2.12.0 (not 2.13.0) and by changing the way I create the model (ie. use TF Hub functions). Both were necessary.\r\n" ]
2023-09-21T18:16:53
2023-09-27T16:42:53
2023-09-27T16:42:53
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Windows 11, Python 3.10.11 - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.13.0 ### 2. Code Repro steps: 1) Download the `lite-model_efficientnet_lite4_uint8_2.tflite` model from here: https://tfhub.dev/tensorflow/lite-model/efficientnet/lite4/uint8/2 (click the 14.34Mb download [link](https://tfhub.dev/tensorflow/lite-model/efficientnet/lite4/uint8/2?lite-format=tflite) ; leave this page open in your browser) 2) Start a TF Lite application using Android or Flutter. I use Flutter and the latest ML Kit. 3) Use the model in your code : it works perfectly fine. 4) Back in your browser, now click the `TF` tab on the left side on the page your left open. The TF tab allows you to download the TF (not TF lite) version of the model. Download the 46.61Mb model file `efficientnet_lite4_classification_2.tar.gz` ([here](https://tfhub.dev/tensorflow/efficientnet/lite4/classification/2)). Uncompress this archive into a `saved_model` folder somewhere. 5) Use the following code to convert the TF model into a TF Lite model; ``` converter = tf.lite.TFLiteConverter.from_saved_model(saved_model_dir, tags='train') converter.optimizations = [tf.lite.Optimize.DEFAULT] tflite_model = converter.convert() outputPath = os.path.join(cur_dir, 'tf_converted_to_tflite.tflite') fo = open(outputPath, "wb") fo.write(tflite_model) fo.close() ``` 6) Following the instructions from https://www.tensorflow.org/lite/models/convert/metadata, add model metadata by using `metadata_writer_for_image_classifier.py`, and with the following model specification (updated lines ~60 to 70, as instructed): ``` _MODEL_INFO = { "tf_converted_to_tflite.tflite": ModelSpecificInfo( name="EfficientNetB4 image classifier", version="v1", image_width=380, # As specified in the TF tab in the web page (not the TF Lite tab, which input dimension is listed as 300x300) image_height=380, # image_min=0, image_max=255, mean=[127.5], std=[127.5], num_classes=1000, author="TensorFlow") } ``` The processing completes normally. 7) Now use that model `tf_converted_to_tflite.tflite` instead of the original, readily-available TF Lite model available on TF Hub, `lite-model_efficientnet_lite4_uint8_2.tflite` (that was working fine). In other words, we are now trying to use approximately the same model, except that this time we ran the TF -> TF Lite model conversion ourselves (quantization is a bit different, but it does not matter at all). 8) Run the same application. The following PlatformException is raised: ``` "com.google.mlkit.common.MlKitException: Failed to initialize detector. Didn't find op for builtin opcode 'PLACEHOLDER_FOR_GREATER_OP_CODES' version '1'. An older version of this builtin might be supported. Are you using an old TFLite binary with a newer model? ``` ### 3. Failure after conversion I would expect the conversion process and runtime behavior to be smooth considered the model is hosted on TF Hub: the TF Lite model proposed by TF Hub works fine, but if I manually convert the TF model myself, it doesn't. Is there anything wrong in the above conversion code? I have been debugging this for days, to no avail. I have another (custom) model with a similar bug, and so far this is the best repro I could build. ### 4. First investigations One thing I figured is that I should try to use the same version of TensorFlow on my PC and on my embedded system - as suggested in the following post from the TensorFlow Team: https://discuss.tensorflow.org/t/tensorflowlite-error-didnt-find-op-for-builtin-opcode-softmax-version-1-an-older-version-of-this-builtin-might-be-supported-are-you-using-an-old-tflite-binary-with-a-newer-model/3885/6 Currently I am using TensorFlow 2.13.0 on my PC, however, how can I determine the version used in Flutter ? I use ML Kit on the Flutter side, which uses, on Android, the following Maven artifact: https://mvnrepository.com/artifact/com.google.mlkit/image-labeling-custom/17.0.1 Which TF version is this artifact using?
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61944/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61944/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61943
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61943/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61943/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61943/events
https://github.com/tensorflow/tensorflow/pull/61943
1,907,421,398
PR_kwDOArmXAs5a6cQ_
61,943
Pin ml_dtypes
{ "login": "georgiyekkert", "id": 37539237, "node_id": "MDQ6VXNlcjM3NTM5MjM3", "avatar_url": "https://avatars.githubusercontent.com/u/37539237?v=4", "gravatar_id": "", "url": "https://api.github.com/users/georgiyekkert", "html_url": "https://github.com/georgiyekkert", "followers_url": "https://api.github.com/users/georgiyekkert/followers", "following_url": "https://api.github.com/users/georgiyekkert/following{/other_user}", "gists_url": "https://api.github.com/users/georgiyekkert/gists{/gist_id}", "starred_url": "https://api.github.com/users/georgiyekkert/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/georgiyekkert/subscriptions", "organizations_url": "https://api.github.com/users/georgiyekkert/orgs", "repos_url": "https://api.github.com/users/georgiyekkert/repos", "events_url": "https://api.github.com/users/georgiyekkert/events{/privacy}", "received_events_url": "https://api.github.com/users/georgiyekkert/received_events", "type": "User", "site_admin": false }
[]
closed
false
null
[]
null
[ "Will newer versions of `ml-dtypes` be supported by tensorflow ?", "Main branch does not have the upper bound, so yes.", "Ok ! Thanks for the explanation on the PR :)" ]
2023-09-21T17:14:41
2023-10-03T07:52:54
2023-09-21T17:17:24
NONE
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61943", "html_url": "https://github.com/tensorflow/tensorflow/pull/61943", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61943.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61943.patch", "merged_at": "2023-09-21T17:17:24" }
null
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61943/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61943/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61942
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61942/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61942/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61942/events
https://github.com/tensorflow/tensorflow/issues/61942
1,907,387,101
I_kwDOArmXAs5xsGrd
61,942
calling Model in a loop would leak memory
{ "login": "alerem18", "id": 112425148, "node_id": "U_kgDOBrN4vA", "avatar_url": "https://avatars.githubusercontent.com/u/112425148?v=4", "gravatar_id": "", "url": "https://api.github.com/users/alerem18", "html_url": "https://github.com/alerem18", "followers_url": "https://api.github.com/users/alerem18/followers", "following_url": "https://api.github.com/users/alerem18/following{/other_user}", "gists_url": "https://api.github.com/users/alerem18/gists{/gist_id}", "starred_url": "https://api.github.com/users/alerem18/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alerem18/subscriptions", "organizations_url": "https://api.github.com/users/alerem18/orgs", "repos_url": "https://api.github.com/users/alerem18/repos", "events_url": "https://api.github.com/users/alerem18/events{/privacy}", "received_events_url": "https://api.github.com/users/alerem18/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "@alerem18 Could you please provide the complete standalone code to replicate the [issue](https://colab.research.google.com/gist/sushreebarsa/1312d871663ec6136f188bc447d4b939/61942.ipynb) reported?\r\nThank you!", "https://keras.io/examples/nlp/neural_machine_translation_with_transformer/\r\n\r\nin decoder_sequence", "will there be any solution or i should wait for you to reply once a month?\r\nthis is why people prefer pytorch over tensorflow", "@alerem18 I tried to replicate the issue on colab. https://keras.io/examples/nlp/neural_machine_translation_with_transformer/ is working fine in [colab](https://colab.research.google.com/gist/sushreebarsa/e8ca05c13b4748b40911c8c00a86a7bc/neural_machine_translation_with_transformer.ipynb#scrollTo=7Wz8hlIULZul) . Please let me know if i have missed something to replicate the reported error. Have you tried to use the GPU for this issue and let me know if the memory leak would be there? Thank you!", "> @alerem18 I tried to replicate the issue on colab. https://keras.io/examples/nlp/neural_machine_translation_with_transformer/ is working fine in [colab](https://colab.research.google.com/gist/sushreebarsa/e8ca05c13b4748b40911c8c00a86a7bc/neural_machine_translation_with_transformer.ipynb#scrollTo=7Wz8hlIULZul) . Please let me know if i have missed something to replicate the reported error. Have you tried to use the GPU for this issue and let me know if the memory leak would be there? Thank you!\r\n\r\ni've not tested it on gpu, but i have memory issues when translating a lot of texts, in a loop\r\ninstead of eng_vectorization use input_vectorization, for spa_vectorization use output_vectorization\r\n\r\ncopy paste the code from the keras directly don't include my code", "@sachinprasadhs same issue on this but i didn't use @tf.function in translator, so i don't know if it's related to that\r\nhttps://www.tensorflow.org/text/tutorials/transformer", "is there any damn solution for this or not?" ]
2023-09-21T16:51:08
2023-10-10T21:15:31
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version tf2.13.0 ### Custom code Yes ### OS platform and distribution Windows Server 2019 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? there is a transformer model when i try to decode messages, translate input sentence to target sentence i get memory blow up, memory is good when i use transformer.fit(), but in a loop like below it blows up memory, tf.keras.backend.clear_session() does’t help, also accuracy decrease when i use that, gc.collect() doesn’t work also here is my code ```python def decode_sequence(input_sentence): tokenized_input_sentence = input_vectorization([input_sentence]) decoded_sentence = START_TOKEN for i in tf.range(max_decoded_sentence_length): tokenized_target_sentence = output_vectorization([decoded_sentence])#[:, :-1] predictions = transformer([tokenized_input_sentence, tokenized_target_sentence]) sampled_token_index = np.argmax(predictions[0, i, :]) sampled_token = output_index_lookup[sampled_token_index] decoded_sentence += sampled_token if sampled_token == END_TOKEN: break gc.collect() return decoded_sentence from tqdm import tqdm def overall_accuracy(pairs): corrects = 0 inputs = pairs[2739:] iter = tqdm(inputs) for i, pair in enumerate(iter): input_text = pair[0] target = pair[1] predicted = decode_sequence(input_text) #guess = '✓' if predicted == target else '✗' #print('Sample Number : ', i, 'Predicted : ', predicted, 'Real : ', target, guess) if predicted == target: corrects += 1 iter.set_postfix(corrects=corrects, accuracy=corrects / (i + 1)) return corrects / len(inputs) print("Overall Acurracy : ", overall_accuracy(test_pairs))``` ### Standalone code to reproduce the issue ```shell calling model in a loop ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61942/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61942/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61941
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61941/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61941/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61941/events
https://github.com/tensorflow/tensorflow/pull/61941
1,907,247,794
PR_kwDOArmXAs5a524A
61,941
[ROCm] Hipblas-lt integration: the Tensorflow part (2nd attempt)
{ "login": "pemeliya", "id": 141146080, "node_id": "U_kgDOCGm34A", "avatar_url": "https://avatars.githubusercontent.com/u/141146080?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pemeliya", "html_url": "https://github.com/pemeliya", "followers_url": "https://api.github.com/users/pemeliya/followers", "following_url": "https://api.github.com/users/pemeliya/following{/other_user}", "gists_url": "https://api.github.com/users/pemeliya/gists{/gist_id}", "starred_url": "https://api.github.com/users/pemeliya/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pemeliya/subscriptions", "organizations_url": "https://api.github.com/users/pemeliya/orgs", "repos_url": "https://api.github.com/users/pemeliya/repos", "events_url": "https://api.github.com/users/pemeliya/events{/privacy}", "received_events_url": "https://api.github.com/users/pemeliya/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1097547538, "node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu", "name": "comp:gpu", "color": "0052cc", "default": false, "description": "GPU related issues" }, { "id": 1169365682, "node_id": "MDU6TGFiZWwxMTY5MzY1Njgy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:L", "name": "size:L", "color": "adafea", "default": false, "description": "CL Change Size: Large" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "It seems there is one test failure for this test:\r\n\r\nhttps://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/ops/batch_ops_test.py\r\n\r\n@pemeliya Can you please check whether you can reproduce this?", "@akuegel, I have tried to run this test on my branch, but for me it seems to work fine:\r\n\r\n```\r\nINFO: Build option --run_under has changed, discarding analysis cache.\r\nINFO: Analyzed 2 targets (2 packages loaded, 47879 targets configured).\r\nINFO: Found 2 test targets...\r\nINFO: Elapsed time: 64.678s, Critical Path: 50.77s\r\nINFO: 220 processes: 23 internal, 197 local.\r\nINFO: Build completed successfully, 220 total actions\r\n//tensorflow/python/ops:batch_ops_test_cpu PASSED in 7.5s\r\n//tensorflow/python/ops:batch_ops_test_gpu PASSED in 7.5s\r\n```\r\nHere is also my CUDA config:\r\n```\r\n+-----------------------------------------------------------------------------+\r\n| NVIDIA-SMI 525.60.13 Driver Version: 525.60.13 CUDA Version: 12.2 |\r\n|-------------------------------+----------------------+----------------------+\r\n| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |\r\n| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |\r\n| | | MIG M. |\r\n|===============================+======================+======================|\r\n| 0 Tesla V100-SXM2... On | 00000000:3D:00.0 Off | 0 |\r\n| N/A 35C P0 43W / 300W | 0MiB / 32768MiB | 0% Default |\r\n| | | N/A |\r\n+-------------------------------+----------------------+----------------------+\r\n| 1 Tesla V100-SXM2... On | 00000000:3E:00.0 Off | 0 |\r\n| N/A 35C P0 43W / 300W | 937MiB / 32768MiB | 0% Default |\r\n| | | N/A |\r\n+-------------------------------+----------------------+----------------------+\r\n\r\n+-----------------------------------------------------------------------------+\r\n| Processes: |\r\n| GPU GI CI PID Type Process name GPU Memory |\r\n| ID ID Usage |\r\n|=============================================================================|\r\n| No running processes found |\r\n+-----------------------------------------------------------------------------+\r\n```", "Thanks for checking. It seems this was a flaky test, now it seems to pass." ]
2023-09-21T15:27:34
2023-10-09T04:20:50
2023-10-09T04:20:50
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61941", "html_url": "https://github.com/tensorflow/tensorflow/pull/61941", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61941.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61941.patch", "merged_at": "2023-10-09T04:20:50" }
This is a remaining part of hipblas-lt integration: diffs are taken from the original pull request: https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/pull/2000 The XLA part was already integrated in: https://github.com/openxla/xla/pull/3953/files# @akuegel: can you please review the changes ?
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61941/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61941/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61940
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61940/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61940/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61940/events
https://github.com/tensorflow/tensorflow/pull/61940
1,907,157,440
PR_kwDOArmXAs5a5i-z
61,940
Hipblas-lt integration: the Tensorflow part
{ "login": "pemeliya", "id": 141146080, "node_id": "U_kgDOCGm34A", "avatar_url": "https://avatars.githubusercontent.com/u/141146080?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pemeliya", "html_url": "https://github.com/pemeliya", "followers_url": "https://api.github.com/users/pemeliya/followers", "following_url": "https://api.github.com/users/pemeliya/following{/other_user}", "gists_url": "https://api.github.com/users/pemeliya/gists{/gist_id}", "starred_url": "https://api.github.com/users/pemeliya/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pemeliya/subscriptions", "organizations_url": "https://api.github.com/users/pemeliya/orgs", "repos_url": "https://api.github.com/users/pemeliya/repos", "events_url": "https://api.github.com/users/pemeliya/events{/privacy}", "received_events_url": "https://api.github.com/users/pemeliya/received_events", "type": "User", "site_admin": false }
[ { "id": 1169365682, "node_id": "MDU6TGFiZWwxMTY5MzY1Njgy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:L", "name": "size:L", "color": "adafea", "default": false, "description": "CL Change Size: Large" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-21T14:44:54
2023-09-21T15:02:57
2023-09-21T15:02:53
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61940", "html_url": "https://github.com/tensorflow/tensorflow/pull/61940", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61940.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61940.patch", "merged_at": null }
This is a remaining part of hipblas-lt integration: diffs are taken from the original pull request: https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/pull/2000/ The XLA part was already integrated in: https://github.com/openxla/xla/pull/3953/files# Please ignore this PR: it erroneously tracks all the commit history from ROCm, another one will be created
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61940/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61940/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61939
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61939/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61939/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61939/events
https://github.com/tensorflow/tensorflow/issues/61939
1,906,957,133
I_kwDOArmXAs5xqdtN
61,939
XLA autocluster will treat `-0.0` as `0.0`
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Any progress on this issue? I believe the autocluster should process `-0.0` as negative, otherwise, the sign of the whole computation is wrong", "Hi @YangChenyuan ,\r\n\r\nI have replicated the reported behaviour and its observed with `multiplication` operation for value 0.0 (i.e float) only and for 0( i.e int) also there is no difference . For any other values the results are same and as intended.\r\n\r\nI am bit curious personally as this is observed in only multiplication operation with `0.0` and the result here will be zero anyways and how it may affect the computation. This might be fixable but to prioritize it we may need a strong demo that demonstrate how this behaviour will affect the computations.\r\n\r\nThank you!", "Hi @SuryanarayanaY, thanks for your further exploration!\r\n\r\nHere is one possible case that would be affected:\r\n```py\r\nclass Model(tf.keras.Model):\r\n def __init__(self):\r\n super(Model, self).__init__()\r\n self.v3_weight = tf.Variable(123.45)\r\n\r\n def call(self, x1):\r\n x4 = (self.v3_weight * (- 0.0))\r\n x4 = 1 / x4\r\n return x4\r\nm = Model()\r\nx = tf.constant(702.89)\r\nprint(m(x)) # tf.Tensor(-inf, shape=(), dtype=float32)\r\n```\r\n\r\n```py\r\nimport os\r\nos.environ['TF_XLA_FLAGS'] = '--tf_xla_auto_jit=2 --tf_xla_cpu_global_jit'\r\nclass Model(tf.keras.Model):\r\n def __init__(self):\r\n super(Model, self).__init__()\r\n self.v3_weight = tf.Variable(123.45)\r\n\r\n @tf.function\r\n def call(self, x1):\r\n x4 = (self.v3_weight * (- 0.0))\r\n x4 = 1 / x4\r\n return x4\r\nm = Model()\r\nx = tf.constant(702.89)\r\nprint(m(x)) # tf.Tensor(inf, shape=(), dtype=float32)\r\n```\r\nIf we divide the results 0, one of them will return `inf` and the other is `-inf`. Then if we do some check for their signs, the results will be much different.\r\n\r\nBesides, if we use `@tf.function(jit_compile=True)`, the result is consistent with naive execution", "Hi @YangChenyuan ,\r\n\r\nThe above case can demonstrate the severity. Thanks for it. We will dig more to fix this.", "Thanks for your exploration and confirmation!", "@YangChenyuan ,\r\n\r\nThis also seems issue with tf.function only. I have replicated the reported behaviour with `jit_compile=True` and `jit_compile=False` both. Attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/9849f49df56c21960083dad41b5db025/61939_r1.ipynb) for reference . Seems its a bug in tf.function. We will work on it and update you.", "@YangChenyuan This is happening because we have a graph optimization that replaces `x * 0` with zero, regardless of what `x` is [here](https://github.com/tensorflow/tensorflow/blob/eb44a46d62a5312af79d69eaf56e26b1d4439236/tensorflow/core/grappler/optimizers/constant_folding.cc#L3073).\r\n\r\nI'm not sure I'm convinced it's important to keep the -0. What is your use-case?", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61939\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61939\">No</a>\n" ]
2023-09-21T13:14:14
2024-02-28T20:37:00
2024-02-28T20:36:57
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230921 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA autocluster will treat `-0.0` as `0.0`. That said, it will automatically transfer `-0.0` to `0.0` ### Standalone code to reproduce the issue ```shell import tensorflow as tf """ Without Autocluster """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.v3_weight = tf.Variable(123.45) def call(self, x1): x4 = (self.v3_weight * (- 0.0)) return x4 m = Model() x = tf.constant(702.89) print(m(x)) # tf.Tensor(-0.0, shape=(), dtype=float32) """ With Autocluster """ import os os.environ['TF_XLA_FLAGS'] = '--tf_xla_auto_jit=2 --tf_xla_cpu_global_jit' class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.v3_weight = tf.Variable(123.45) @tf.function def call(self, x1): x4 = (self.v3_weight * (- 0.0)) return x4 m = Model() x = tf.constant(702.89) print(m(x)) # tf.Tensor(0.0, shape=(), dtype=float32) ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61939/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61939/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61938
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61938/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61938/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61938/events
https://github.com/tensorflow/tensorflow/issues/61938
1,906,915,934
I_kwDOArmXAs5xqTpe
61,938
XLA compiled `Embedding` could work for out-of-bound input
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 1133285679, "node_id": "MDU6TGFiZWwxMTMzMjg1Njc5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla", "name": "comp:xla", "color": "0052cc", "default": false, "description": "XLA" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@YangChenyuan,\r\nApologies for the delay. I tried to execute the mentioned code on tf-nightly(2.16.0-dev20231101) and the code was executed without any issue/error and the respective outputs are also the same in both the cases. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/74a405b63752afb269015e829ad5a1b0/untitled1475.ipynb). Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61938\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61938\">No</a>\n" ]
2023-09-21T12:57:04
2023-11-16T01:49:23
2023-11-16T01:49:21
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230921 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA compiled `Embedding` could work for out-of-bound input. In the following code, the model has an embedding layer using `tf.keras.layers.Embedding(64, 128)`, which means it has 64 possible tokens (usually representing words or items, indexed from 0 to 63). The input to it is `tf.constant([64], dtype=tf.int32)`, which is out of range because 64 exceeds the highest valid token index 63. If we run the model without XLA compilation, it will raise an error as expected. However, after XLA compilation, the model could process such invalid input. ### Standalone code to reproduce the issue ```shell import tensorflow as tf """ XLA compiled """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.embedding = tf.keras.layers.Embedding(64, 128) @tf.function(jit_compile=True) def call(self, x1, x2): x3 = self.embedding(x1) return (x3 * x2) tf.random.set_seed(42) m = Model() input_1 = tf.constant([64], dtype=tf.int32) input_2 = tf.constant([[[[10.0]]]], dtype=tf.float32) print(m(input_1, input_2)) """ Without XLA """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.embedding = tf.keras.layers.Embedding(64, 128) def call(self, x1, x2): x3 = self.embedding(x1) return (x3 * x2) tf.random.set_seed(42) m = Model() input_1 = tf.constant([64], dtype=tf.int32) input_2 = tf.constant([[[[10.0]]]], dtype=tf.float32) print(m(input_1, input_2)) """ InvalidArgumentError: Exception encountered when calling layer 'embedding_4' (type Embedding). {{function_node __wrapped__ResourceGather_device_/job:localhost/replica:0/task:0/device:CPU:0}} indices[0] = 64 is not in [0, 64) [Op:ResourceGather] name: """ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61938/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61938/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61937
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61937/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61937/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61937/events
https://github.com/tensorflow/tensorflow/pull/61937
1,906,858,399
PR_kwDOArmXAs5a4h_7
61,937
Fix permission denied on cp of headers
{ "login": "elfringham", "id": 10442001, "node_id": "MDQ6VXNlcjEwNDQyMDAx", "avatar_url": "https://avatars.githubusercontent.com/u/10442001?v=4", "gravatar_id": "", "url": "https://api.github.com/users/elfringham", "html_url": "https://github.com/elfringham", "followers_url": "https://api.github.com/users/elfringham/followers", "following_url": "https://api.github.com/users/elfringham/following{/other_user}", "gists_url": "https://api.github.com/users/elfringham/gists{/gist_id}", "starred_url": "https://api.github.com/users/elfringham/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/elfringham/subscriptions", "organizations_url": "https://api.github.com/users/elfringham/orgs", "repos_url": "https://api.github.com/users/elfringham/repos", "events_url": "https://api.github.com/users/elfringham/events{/privacy}", "received_events_url": "https://api.github.com/users/elfringham/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-21T12:25:26
2023-10-02T09:28:26
2023-09-21T17:45:07
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61937", "html_url": "https://github.com/tensorflow/tensorflow/pull/61937", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61937.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61937.patch", "merged_at": "2023-09-21T17:45:07" }
Remove the duplication of copies that can result in permission denied
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61937/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61937/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61936
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61936/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61936/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61936/events
https://github.com/tensorflow/tensorflow/issues/61936
1,906,383,595
I_kwDOArmXAs5xoRrr
61,936
lite hexagon后端ResizeNearestNeighbor算子层执行报错
{ "login": "hayyaw", "id": 119873470, "node_id": "U_kgDOByUfvg", "avatar_url": "https://avatars.githubusercontent.com/u/119873470?v=4", "gravatar_id": "", "url": "https://api.github.com/users/hayyaw", "html_url": "https://github.com/hayyaw", "followers_url": "https://api.github.com/users/hayyaw/followers", "following_url": "https://api.github.com/users/hayyaw/following{/other_user}", "gists_url": "https://api.github.com/users/hayyaw/gists{/gist_id}", "starred_url": "https://api.github.com/users/hayyaw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hayyaw/subscriptions", "organizations_url": "https://api.github.com/users/hayyaw/orgs", "repos_url": "https://api.github.com/users/hayyaw/repos", "events_url": "https://api.github.com/users/hayyaw/events{/privacy}", "received_events_url": "https://api.github.com/users/hayyaw/received_events", "type": "User", "site_admin": false }
[ { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-21T08:15:43
2023-09-21T09:30:30
2023-09-21T09:30:30
NONE
null
null
null
**System information** - OS Platform and Distribution :Linux Ubuntu 18.04 - TensorFlow installed from (github): - TensorFlow version (dev分支): **Provide the text output from tflite_convert** none **Standalone code to reproduce the issue** tensorflow/lite/delegates/hexagon/builders/resize_nearest_neighbor_builder.cc **Any other info / logs** STARTING! Duplicate flags: num_threads Log parameter values verbosely: [0] Min num runs: [1] Graph: [/home/wangzhiqun/yolox_resize_nearest_neighbor.tflite] Use Hexagon: [1] Loaded model /home/wangzhiqun/yolox_resize_nearest_neighbor.tflite INFO: Initialized TensorFlow Lite runtime. Hexagon delegate created. INFO: TfLiteHexagonDelegate delegate: 1 nodes delegated out of 1 nodes with 1 partitions. INFO: Replacing 1 node(s) with delegate (TfLiteHexagonDelegate) node, yielding 1 partitions. [hexagon/nn] Add Node: tid(-1) nid(1) [hexagon_nn] hexagon_nn_append_const_node(gid=1 tid=2 nid=2 type=0x3) [hexagon/nn] Add Node from Op(331) mid(0) nid(3) [hexagon_nn] hexagon_nn_append_const_node(gid=1 nid=4 type=0x3) [hexagon_nn] hexagon_nn_append_const_node(gid=1 nid=5 type=0x3) [hexagon/nn] Add Node: tid(-1) nid(6) [hexagon_nn] hexagon_nn_append_node(gid=1 nid=1 type=0x0) [hexagon_nn] hexagon_nn_append_node(nis=0 nos=1) [hexagon_nn] hexagon_nn_append_node(outputs[0].elementsize=1) [hexagon_nn] hexagon_const_node(gid=1 nid=2 type=0x3) [hexagon_nn] hexagon_nn_append_node(gid=1 nid=3 type=0x14b) [hexagon_nn] hexagon_nn_append_node(nis=6 nos=3) Error adding node: id:3, op_type:331 [hexagon_nn] hexagon_const_node(gid=1 nid=4 type=0x3) [hexagon_nn] hexagon_const_node(gid=1 nid=5 type=0x3) [hexagon_nn] hexagon_nn_append_node(gid=1 nid=6 type=0x1) [hexagon_nn] hexagon_nn_append_node(nis=1 nos=0) ---------------- Timestamp: Thu Sep 21 08:06:06 2023 Log hexagon/src/newnode.c:413:node 3 (ResizeNearestNeighbor_8): bad input count 6 hexagon/src/newnode.c:763:node id=0x3 ctor fail hexagon/src/prepare.c:4830:input 0x6:0 refers to nonexistent node 0x3 hexagon/src/prepare.c:4644:can't find id 0x3 ---------------- ERROR: Failed: Failed to prepare graph. . ERROR: Node number 1 (TfLiteHexagonDelegate) failed to prepare. ERROR: Restored original execution plan after delegate application failure. Failed to apply Hexagon delegate. Benchmarking failed.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61936/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61936/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61935
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61935/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61935/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61935/events
https://github.com/tensorflow/tensorflow/issues/61935
1,906,321,188
I_kwDOArmXAs5xoCck
61,935
lite hexagon后端ResizeNearestNeighbor算子层执行报错
{ "login": "hayyaw", "id": 119873470, "node_id": "U_kgDOByUfvg", "avatar_url": "https://avatars.githubusercontent.com/u/119873470?v=4", "gravatar_id": "", "url": "https://api.github.com/users/hayyaw", "html_url": "https://github.com/hayyaw", "followers_url": "https://api.github.com/users/hayyaw/followers", "following_url": "https://api.github.com/users/hayyaw/following{/other_user}", "gists_url": "https://api.github.com/users/hayyaw/gists{/gist_id}", "starred_url": "https://api.github.com/users/hayyaw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hayyaw/subscriptions", "organizations_url": "https://api.github.com/users/hayyaw/orgs", "repos_url": "https://api.github.com/users/hayyaw/repos", "events_url": "https://api.github.com/users/hayyaw/events{/privacy}", "received_events_url": "https://api.github.com/users/hayyaw/received_events", "type": "User", "site_admin": false }
[ { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 2888762627, "node_id": "MDU6TGFiZWwyODg4NzYyNjI3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteHexagonDelegate", "name": "TFLiteHexagonDelegate", "color": "72ECFE", "default": false, "description": "" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "@hayyaw \r\nIn order to expedite the trouble-shooting process here, could you please fill the issue [template](https://github.com/tensorflow/tensorflow/issues/new/choose),\r\nThank you!", "System information\r\n\r\nOS Platform and Distribution :Linux Ubuntu 18.04\r\nTensorFlow installed from (github):\r\nTensorFlow version (dev分支):\r\nProvide the text output from tflite_convert\r\nnone\r\n\r\nStandalone code to reproduce the issue\r\n\r\ntensorflow/lite/delegates/hexagon/builders/resize_nearest_neighbor_builder.cc\r\n\r\nAny other info / logs\r\nSTARTING!\r\nDuplicate flags: num_threads\r\nLog parameter values verbosely: [0]\r\nMin num runs: [1]\r\nGraph: [/home/wangzhiqun/yolox_resize_nearest_neighbor.tflite]\r\nUse Hexagon: [1]\r\nLoaded model /home/wangzhiqun/yolox_resize_nearest_neighbor.tflite\r\nINFO: Initialized TensorFlow Lite runtime.\r\nHexagon delegate created.\r\nINFO: TfLiteHexagonDelegate delegate: 1 nodes delegated out of 1 nodes with 1 partitions.\r\n\r\nINFO: Replacing 1 node(s) with delegate (TfLiteHexagonDelegate) node, yielding 1 partitions.\r\n[hexagon/nn] Add Node: tid(-1) nid(1)\r\n[hexagon_nn] hexagon_nn_append_const_node(gid=1 tid=2 nid=2 type=0x3)\r\n[hexagon/nn] Add Node from Op(331) mid(0) nid(3)\r\n[hexagon_nn] hexagon_nn_append_const_node(gid=1 nid=4 type=0x3)\r\n[hexagon_nn] hexagon_nn_append_const_node(gid=1 nid=5 type=0x3)\r\n[hexagon/nn] Add Node: tid(-1) nid(6)\r\n[hexagon_nn] hexagon_nn_append_node(gid=1 nid=1 type=0x0)\r\n[hexagon_nn] hexagon_nn_append_node(nis=0 nos=1)\r\n[hexagon_nn] hexagon_nn_append_node(outputs[0].elementsize=1)\r\n[hexagon_nn] hexagon_const_node(gid=1 nid=2 type=0x3)\r\n[hexagon_nn] hexagon_nn_append_node(gid=1 nid=3 type=0x14b)\r\n[hexagon_nn] hexagon_nn_append_node(nis=6 nos=3)\r\nError adding node: id:3, op_type:331\r\n[hexagon_nn] hexagon_const_node(gid=1 nid=4 type=0x3)\r\n[hexagon_nn] hexagon_const_node(gid=1 nid=5 type=0x3)\r\n[hexagon_nn] hexagon_nn_append_node(gid=1 nid=6 type=0x1)\r\n[hexagon_nn] hexagon_nn_append_node(nis=1 nos=0)\r\nTimestamp: Thu Sep 21 08:06:06 2023\r\n\r\nLog\r\nhexagon/src/newnode.c:413:node 3 (ResizeNearestNeighbor_8): bad input count 6\r\nhexagon/src/newnode.c:763:node id=0x3 ctor fail\r\nhexagon/src/prepare.c:4830:input 0x6:0 refers to nonexistent node 0x3\r\nhexagon/src/prepare.c:4644:can't find id 0x3\r\n\r\nERROR: Failed: Failed to prepare graph.\r\n.\r\nERROR: Node number 1 (TfLiteHexagonDelegate) failed to prepare.\r\nERROR: Restored original execution plan after delegate application failure.\r\nFailed to apply Hexagon delegate.\r\nBenchmarking failed.", "Hi @hayyaw \r\n\r\nCould you please provide a reproducible code and steps you have followed? It is hard to understand the issue from error log. Please please fill this issue [template](https://github.com/tensorflow/tensorflow/issues/new?assignees=&labels=TFLiteConverter&projects=&template=tflite-converter-issue.md).\r\n\r\nThanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "I am having the exact same problem with multiple TFLITE models I have made full quantized versions to run on the hexagon." ]
2023-09-21T07:39:20
2024-01-10T17:31:40
2023-10-11T01:47:26
NONE
null
null
null
hexagon/src/newnode.c:413:node 3 (ResizeNearestNeighbor_8): bad input count 6 hexagon/src/newnode.c:763:node id=0x3 ctor fail hexagon/src/prepare.c:4830:input 0x6:0 refers to nonexistent node 0x3 hexagon/src/prepare.c:4644:can't find id 0x3 ---------------- ERROR: Failed: Failed to prepare graph. . ERROR: Node number 1 (TfLiteHexagonDelegate) failed to prepare. ERROR: Restored original execution plan after delegate application failure. Failed to apply Hexagon delegate. Benchmarking failed.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61935/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61935/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61934
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61934/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61934/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61934/events
https://github.com/tensorflow/tensorflow/issues/61934
1,906,152,173
I_kwDOArmXAs5xnZLt
61,934
The Depthwise Convolution operation result is incorrect from interpreter
{ "login": "Bajirak", "id": 108508050, "node_id": "U_kgDOBnezkg", "avatar_url": "https://avatars.githubusercontent.com/u/108508050?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Bajirak", "html_url": "https://github.com/Bajirak", "followers_url": "https://api.github.com/users/Bajirak/followers", "following_url": "https://api.github.com/users/Bajirak/following{/other_user}", "gists_url": "https://api.github.com/users/Bajirak/gists{/gist_id}", "starred_url": "https://api.github.com/users/Bajirak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Bajirak/subscriptions", "organizations_url": "https://api.github.com/users/Bajirak/orgs", "repos_url": "https://api.github.com/users/Bajirak/repos", "events_url": "https://api.github.com/users/Bajirak/events{/privacy}", "received_events_url": "https://api.github.com/users/Bajirak/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "Have you considered a Re install i or re-writing the\r\ninterpreter to make sure that it matched what is required.\r\nSincerely, Hamish Leahy", "@Bajirak Could you please try to reinstall the interpreter and check the compatibility. Please try using the command Python: Clear cache. Also do mention the expected output for this operation. Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "Sorry for being late. @Hamish-Leahy , @sushreebarsa \r\n\r\nI created a new virtual environment and installed the nightly version of tensorflow.\r\n\r\n`python3.8 -m venv issue_tracking`\r\n`source issue_tracking/bin/activate`\r\n`pip install --upgrade pip`\r\n`pip install tf-nightly-cpu`\r\n`pip freeze | grep tf-nightly`\r\n\r\nIt says\r\n`tf-nightly-cpu==2.14.0.dev20230706`\r\n\r\nAfter installation, I tried the tests described above again, but the output is still incorrect. \r\n(*The weight data of DwConv is randomly generated. Therefore, the same result as the issue cannot be derived.)\r\n\r\n0) input[0, 61:64, 65:68, 24]\r\n[[0.978893 0.03620292 0.9301994 ]\r\n [0.34403667 0.4492776 0.8247143 ]\r\n [0.8075199 0.77361435 0.1642472 ]]\r\n\r\n1) weight[..., :24]\r\n[[[ 0.04345933 -0.04809386 0.07144216]\r\n [-0.08781118 0.01062268 -0.05774678]\r\n [-0.03802773 0.07661463 0.0889118 ]]]\r\n\r\n2) bias[24]\r\n-0.029987096786499023\r\n\r\n3) Deptwise Convoultion output\r\ntflite output[0, 31, 33, 24] : 0.01883140206336975\r\ntest output[0, 31, 33, 24]: 0.04737246036529541", "Hi @Bajirak \r\n\r\nI have tested both the keras and TFLite model and they produce same output given the same input. Please find this [gist](https://colab.research.google.com/gist/pjpratik/ece6465f351b841bc40e8810a0732989/61934.ipynb).\r\n\r\nAs their result goes I don't think there is an issue. Can you elaborate more about why the partial data is being tested? \r\n\r\nThanks.\r\n\r\n", "Hi @pjpratik \r\n\r\nYou are right. This isn't an issue. I thought the interpreter's operation result was invalid.\r\n\r\nSo, I tried to prove that the interpreter's results were wrong by using partial input and partial weight.\r\n\r\nHowever, I was considering the 'SAME' Pad value incorrectly. After considering this, I checked my results and the interpreter's results.\r\n\r\nThank you for checking so carefully. Sorry for taking up your time.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61934\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61934\">No</a>\n" ]
2023-09-21T05:41:36
2023-10-16T01:08:33
2023-10-16T01:08:30
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution Linux Ubuntu 18.04 ### Mobile device _No response_ ### Python version 3.8 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I am testing network inference using Interpreter for the '.tflite' that supports dynamic input shape. However, the operational results of Depthwise Convolution are different from what was expected. I simply reproduced the issue. ### Standalone code to reproduce the issue ```shell https://colab.research.google.com/drive/1WCOZBuWTYU7kn4EcjHHrG_fZm7mZcojN?usp=drive_link ``` ### Relevant log output ```shell # input : Inputs corresponding to output [0, 31, 33, 24] 0) input[0, 61:64, 65:68, 24] [[0.978893 0.03620292 0.9301994 ] [0.34403667 0.4492776 0.8247143 ] [0.8075199 0.77361435 0.1642472 ]] # weight: corresponding to output [0, 31, 33, 24] 1) weight[..., :24] [[[ 0.09494528 -0.0925059 0.07752301] [-0.07614094 0.06238136 -0.03187032] [ 0.06566823 0.09477414 -0.05954333]]] # bias: corresponding to output [0, 31, 33, 24] 2) bias[24] 0.024211471900343895 # tflite output: Interpreter result # test output: Formula result of Depthwise Convolution 3) Deptwise Convoultion output tflite output[0, 31, 33, 24] : 0.0 test output[0, 31, 33, 24]: 0.2780301570892334 ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61934/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61934/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61933
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61933/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61933/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61933/events
https://github.com/tensorflow/tensorflow/pull/61933
1,905,836,930
PR_kwDOArmXAs5a1D7q
61,933
Strip `external/local_tsl` prefix during zip of tsl protos
{ "login": "wamuir", "id": 17497234, "node_id": "MDQ6VXNlcjE3NDk3MjM0", "avatar_url": "https://avatars.githubusercontent.com/u/17497234?v=4", "gravatar_id": "", "url": "https://api.github.com/users/wamuir", "html_url": "https://github.com/wamuir", "followers_url": "https://api.github.com/users/wamuir/followers", "following_url": "https://api.github.com/users/wamuir/following{/other_user}", "gists_url": "https://api.github.com/users/wamuir/gists{/gist_id}", "starred_url": "https://api.github.com/users/wamuir/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wamuir/subscriptions", "organizations_url": "https://api.github.com/users/wamuir/orgs", "repos_url": "https://api.github.com/users/wamuir/repos", "events_url": "https://api.github.com/users/wamuir/events{/privacy}", "received_events_url": "https://api.github.com/users/wamuir/received_events", "type": "User", "site_admin": false }
[ { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-20T23:15:13
2023-09-21T06:30:35
2023-09-21T06:30:35
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61933", "html_url": "https://github.com/tensorflow/tensorflow/pull/61933", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61933.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61933.patch", "merged_at": "2023-09-21T06:30:34" }
PR strips external/local_tsl prefix from tsl protos when packaging //tensorflow/tools/lib_package:libtensorflow_proto.zip. See also #61883. Here's a head of the tree for the current zip archive to demonstrate the issue: ```. . ├── external │   └── local_tsl │   └── tsl │   ├── profiler │   │   └── protobuf │   │   ├── profiler_options.proto │   │   └── xplane.proto │   └── protobuf │   ├── bfc_memory_map.proto │   ├── coordination_config.proto │   ├── distributed_runtime_payloads.proto │   ├── error_codes.proto │   ├── histogram.proto │   ├── rpc_options.proto │   ├── status.proto │   └── test_log.proto └── tensorflow └── core ├── example │   ├── example.proto │   ├── example_parser_configuration.proto │   └── feature.proto ├── framework │   ├── allocation_description.proto │   ├── api_def.proto │   ├── attr_value.proto │   ├── cost_graph.proto │   ├── cpp_shape_inference.proto │   ├── dataset.proto │   ├── dataset_metadata.proto │   ├── dataset_options.proto │   ├── device_attributes.proto . . . ``` cc: @jakeharmon8
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61933/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61933/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61932
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61932/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61932/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61932/events
https://github.com/tensorflow/tensorflow/issues/61932
1,905,795,112
I_kwDOArmXAs5xmCAo
61,932
Can't get optimizer to apply gradients with Keras and DTensor based model
{ "login": "pentney", "id": 11462121, "node_id": "MDQ6VXNlcjExNDYyMTIx", "avatar_url": "https://avatars.githubusercontent.com/u/11462121?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pentney", "html_url": "https://github.com/pentney", "followers_url": "https://api.github.com/users/pentney/followers", "following_url": "https://api.github.com/users/pentney/following{/other_user}", "gists_url": "https://api.github.com/users/pentney/gists{/gist_id}", "starred_url": "https://api.github.com/users/pentney/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pentney/subscriptions", "organizations_url": "https://api.github.com/users/pentney/orgs", "repos_url": "https://api.github.com/users/pentney/repos", "events_url": "https://api.github.com/users/pentney/events{/privacy}", "received_events_url": "https://api.github.com/users/pentney/received_events", "type": "User", "site_admin": false }
[ { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@pentney,\r\nIn the given code snippet you have defined the class and its methods but are not calling them anywhere. Could you please provide the complete code to debug the issue. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/d4baeba4cdc407efec93501bbb2ce525/untitled1374.ipynb). Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61932\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61932\">No</a>\n" ]
2023-09-20T22:23:04
2023-10-11T01:47:34
2023-10-11T01:47:28
NONE
null
null
null
### Issue type Support ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 (also tried with 2.9.1) ### Custom code Yes ### OS platform and distribution Linux Ubuntu 16.04 ### Mobile device _No response_ ### Python version 3.8 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Trying to do distributed training, for a rather wide model, with DTensors and Keras. I'm creating an Adam optimizer, trying to update it manually with the following code for a custom DTensor training step (this is within my own model object, with self.model being a Keras model): ``` @tf.function def train_step(self, x, y, w, optimizer, train_metrics): if not self.init: # this runs once to initialize the model variables self.model(x) self.init = True with tf.GradientTape() as tape: logits = self.model(x, training=True) logits = tf.reshape(logits, (logits.shape[1], logits.shape[0])) loss = tf.reduce_sum(tf.math.multiply( tf.keras.losses.binary_crossentropy( y, logits, from_logits=True), w)) gradients = tape.gradient(loss, self.model.trainable_variables) optimizer.apply_gradients(zip(gradients, self.model.trainable_variables)) loss_per_sample = loss / len(x) results = {'loss': loss_per_sample} for metric in train_metrics.values(): metric.update_state(y_true=y, y_pred=logits) return results def dtensor_fit( self, x_train, y_train, x_val, y_val, w_train=None): num_epochs = 5 train_metrics = { "accuracy" : metrics.Accuracy(), "tp": metrics.TruePositives(), "fp": metrics.FalsePositives(), "fn": metrics.FalseNegatives(), "tn": metrics.TrueNegatives(), "auc": metrics.AUC(curve="PR"), } optimizer = tf.keras.dtensor.experimental.optimizers.Adam(mesh=self.mesh) eval_metrics = dict(train_metrics) for epoch in range(num_epochs): print("============================") print("Epoch: ", epoch) for metric in train_metrics.values(): metric.reset_state() step = 0 results = {} pbar = tf.keras.utils.Progbar(target=None, stateful_metrics=[]) def batch(x, y, w, n): num_samples = x.shape[0] l = 0 while l < num_samples: yield x[l:l+n], y[l:l+n], w[l:l+n] l += n self.init = False for inputs, labels, weights in batch(x_train, y_train, w_train, NNModel.BATCH_SIZE): indices = np.transpose(inputs.nonzero()) inputs.eliminate_zeros() values = inputs.data inputs, labels, weights = self.pack_dtensor_inputs( tf.SparseTensor(indices=indices, values=values, dense_shape=(inputs.shape[0], self.input_size)), tf.convert_to_tensor([labels], dtype =tf.bfloat16), tf.convert_to_tensor([weights], dtype=tf.bfloat16), self.input_layout, self.label_layout, self.weight_layout) optimizer.build(self.model.trainable_variables) results.update(self.train_step(inputs, labels, weights, optimizer, train_metrics)) for metric_name, metric in train_metrics.items(): results[metric_name] = metric.result() pbar.update(step, values=results.items(), finalize=False) step += 1 ``` I get the following error when I reach the apply_gradients step in the train_step function: ValueError: in user code: ``` File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/_main/keystone/training/model.py", line 263, in train_step * optimizer.apply_gradients(zip(gradients, self.model.trainable_variables)) File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/dtensor/optimizers.py", line 141, in apply_gradients ** optimizer_lib._BaseOptimizer.apply_gradients(self, grads_and_vars) File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/optimizers/optimizer.py", line 650, in apply_gradients iteration = self._internal_apply_gradients(grads_and_vars) File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/dtensor/optimizers.py", line 153, in _internal_apply_gradients optimizer_lib._BaseOptimizer._internal_apply_gradients( File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/optimizers/optimizer.py", line 680, in _internal_apply_gradients self._update_step(grad, var) File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/optimizers/optimizer.py", line 240, in _update_step self.update_step(gradient, variable) File "/usr/local/home/bill/.cache/bazel/_bazel_bill/254c50c69c3701cca4e904bef759573b/execroot/_main/bazel-out/k8-fastbuild/bin/keystone/training/training.runfiles/rules_python~0.21.0~pip~pip_keras/site-packages/keras/optimizers/adam.py", line 194, in update_step m.assign_add((gradient - m) * (1 - self.beta_1)) ValueError: Dimensions must be equal, but are 5 and 0 for '{{node sub_2}} = Sub[T=DT_FLOAT](gradient_tape/keystone/feature/MatMul_1/Cast/Cast, sub_2/ReadVariableOp)' with input shapes: [8299614,5], [0]. ``` It looks like the optimizer momentums are not of the correct shape. I tried explicitly adding `optimizer.build(self.model.trainable_variables) `after the `self.model(x)` in `train_step` to force correct population, but the variables are still wrong. I have seen the same results with TF versions 2.9.1 and 2.13.0. Is this a bug? How do I get the optimizer to be correctly set up for training? ### Standalone code to reproduce the issue ```shell see above ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61932/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61932/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61931
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61931/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61931/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61931/events
https://github.com/tensorflow/tensorflow/pull/61931
1,905,702,723
PR_kwDOArmXAs5a0m9C
61,931
Update RELEASE.md to remove estimator deprecation notice
{ "login": "rtg0795", "id": 36429068, "node_id": "MDQ6VXNlcjM2NDI5MDY4", "avatar_url": "https://avatars.githubusercontent.com/u/36429068?v=4", "gravatar_id": "", "url": "https://api.github.com/users/rtg0795", "html_url": "https://github.com/rtg0795", "followers_url": "https://api.github.com/users/rtg0795/followers", "following_url": "https://api.github.com/users/rtg0795/following{/other_user}", "gists_url": "https://api.github.com/users/rtg0795/gists{/gist_id}", "starred_url": "https://api.github.com/users/rtg0795/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rtg0795/subscriptions", "organizations_url": "https://api.github.com/users/rtg0795/orgs", "repos_url": "https://api.github.com/users/rtg0795/repos", "events_url": "https://api.github.com/users/rtg0795/events{/privacy}", "received_events_url": "https://api.github.com/users/rtg0795/received_events", "type": "User", "site_admin": false }
[]
closed
false
null
[]
null
[]
2023-09-20T20:52:30
2023-09-20T20:56:26
2023-09-20T20:56:25
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61931", "html_url": "https://github.com/tensorflow/tensorflow/pull/61931", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61931.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61931.patch", "merged_at": "2023-09-20T20:56:25" }
null
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61931/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61931/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61930
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61930/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61930/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61930/events
https://github.com/tensorflow/tensorflow/pull/61930
1,905,662,502
PR_kwDOArmXAs5a0eH1
61,930
r2.14 cherry-pick: 0e3480236ce "include THIRD_PARTY_NOTICES.txt in the wheel."
{ "login": "tensorflow-jenkins", "id": 16359713, "node_id": "MDQ6VXNlcjE2MzU5NzEz", "avatar_url": "https://avatars.githubusercontent.com/u/16359713?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tensorflow-jenkins", "html_url": "https://github.com/tensorflow-jenkins", "followers_url": "https://api.github.com/users/tensorflow-jenkins/followers", "following_url": "https://api.github.com/users/tensorflow-jenkins/following{/other_user}", "gists_url": "https://api.github.com/users/tensorflow-jenkins/gists{/gist_id}", "starred_url": "https://api.github.com/users/tensorflow-jenkins/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tensorflow-jenkins/subscriptions", "organizations_url": "https://api.github.com/users/tensorflow-jenkins/orgs", "repos_url": "https://api.github.com/users/tensorflow-jenkins/repos", "events_url": "https://api.github.com/users/tensorflow-jenkins/events{/privacy}", "received_events_url": "https://api.github.com/users/tensorflow-jenkins/received_events", "type": "User", "site_admin": false }
[]
closed
false
null
[]
null
[]
2023-09-20T20:21:25
2023-10-25T07:01:36
2023-09-20T21:48:45
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61930", "html_url": "https://github.com/tensorflow/tensorflow/pull/61930", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61930.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61930.patch", "merged_at": "2023-09-20T21:48:45" }
Refer to the original commit: https://github.com/tensorflow/tensorflow/commit/0e3480236cec19ea558cd93dd017013e5cfee1b3
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61930/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61930/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61929
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61929/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61929/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61929/events
https://github.com/tensorflow/tensorflow/pull/61929
1,905,405,403
PR_kwDOArmXAs5azm4m
61,929
r2.14 cherry-pick: d03c477d727 "Add licenses and notices for third party libraries"
{ "login": "tensorflow-jenkins", "id": 16359713, "node_id": "MDQ6VXNlcjE2MzU5NzEz", "avatar_url": "https://avatars.githubusercontent.com/u/16359713?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tensorflow-jenkins", "html_url": "https://github.com/tensorflow-jenkins", "followers_url": "https://api.github.com/users/tensorflow-jenkins/followers", "following_url": "https://api.github.com/users/tensorflow-jenkins/following{/other_user}", "gists_url": "https://api.github.com/users/tensorflow-jenkins/gists{/gist_id}", "starred_url": "https://api.github.com/users/tensorflow-jenkins/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tensorflow-jenkins/subscriptions", "organizations_url": "https://api.github.com/users/tensorflow-jenkins/orgs", "repos_url": "https://api.github.com/users/tensorflow-jenkins/repos", "events_url": "https://api.github.com/users/tensorflow-jenkins/events{/privacy}", "received_events_url": "https://api.github.com/users/tensorflow-jenkins/received_events", "type": "User", "site_admin": false }
[]
closed
false
null
[]
null
[]
2023-09-20T17:06:16
2023-10-25T09:32:27
2023-09-20T17:49:55
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61929", "html_url": "https://github.com/tensorflow/tensorflow/pull/61929", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61929.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61929.patch", "merged_at": "2023-09-20T17:49:55" }
Refer to the original commit: https://github.com/tensorflow/tensorflow/commit/d03c477d727b93b71ac1710885c6c918d7754361
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61929/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61929/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61928
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61928/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61928/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61928/events
https://github.com/tensorflow/tensorflow/pull/61928
1,905,291,924
PR_kwDOArmXAs5azORP
61,928
[Do not merge] Test copybara import miss
{ "login": "MichaelHudgins", "id": 30155094, "node_id": "MDQ6VXNlcjMwMTU1MDk0", "avatar_url": "https://avatars.githubusercontent.com/u/30155094?v=4", "gravatar_id": "", "url": "https://api.github.com/users/MichaelHudgins", "html_url": "https://github.com/MichaelHudgins", "followers_url": "https://api.github.com/users/MichaelHudgins/followers", "following_url": "https://api.github.com/users/MichaelHudgins/following{/other_user}", "gists_url": "https://api.github.com/users/MichaelHudgins/gists{/gist_id}", "starred_url": "https://api.github.com/users/MichaelHudgins/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/MichaelHudgins/subscriptions", "organizations_url": "https://api.github.com/users/MichaelHudgins/orgs", "repos_url": "https://api.github.com/users/MichaelHudgins/repos", "events_url": "https://api.github.com/users/MichaelHudgins/events{/privacy}", "received_events_url": "https://api.github.com/users/MichaelHudgins/received_events", "type": "User", "site_admin": false }
[ { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
null
[]
null
[]
2023-09-20T15:52:49
2023-09-22T12:34:18
2023-09-22T12:34:15
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61928", "html_url": "https://github.com/tensorflow/tensorflow/pull/61928", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61928.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61928.patch", "merged_at": null }
Testing what is being missed on import. Do not merge - i will close this once i am done.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61928/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61928/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61927
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61927/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61927/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61927/events
https://github.com/tensorflow/tensorflow/pull/61927
1,905,168,891
PR_kwDOArmXAs5ayzS_
61,927
[ROCm] Updates for rocm_dnn header dependency
{ "login": "i-chaochen", "id": 913790, "node_id": "MDQ6VXNlcjkxMzc5MA==", "avatar_url": "https://avatars.githubusercontent.com/u/913790?v=4", "gravatar_id": "", "url": "https://api.github.com/users/i-chaochen", "html_url": "https://github.com/i-chaochen", "followers_url": "https://api.github.com/users/i-chaochen/followers", "following_url": "https://api.github.com/users/i-chaochen/following{/other_user}", "gists_url": "https://api.github.com/users/i-chaochen/gists{/gist_id}", "starred_url": "https://api.github.com/users/i-chaochen/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/i-chaochen/subscriptions", "organizations_url": "https://api.github.com/users/i-chaochen/orgs", "repos_url": "https://api.github.com/users/i-chaochen/repos", "events_url": "https://api.github.com/users/i-chaochen/events{/privacy}", "received_events_url": "https://api.github.com/users/i-chaochen/received_events", "type": "User", "site_admin": false }
[ { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1097547538, "node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu", "name": "comp:gpu", "color": "0052cc", "default": false, "description": "GPU related issues" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-20T14:50:29
2023-09-25T07:33:40
2023-09-21T04:06:35
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61927", "html_url": "https://github.com/tensorflow/tensorflow/pull/61927", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61927.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61927.patch", "merged_at": "2023-09-21T04:06:35" }
due to recent migration XLA/TF, we have clean up some code from our repo to upstream. Thanks in advance! @akuegel
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61927/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61927/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61926
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61926/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61926/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61926/events
https://github.com/tensorflow/tensorflow/issues/61926
1,905,024,911
I_kwDOArmXAs5xjF-P
61,926
Failure to create build_pip_package Ubuntu 22.04 LTS / Python 3.10 / Cuda 11.7
{ "login": "cnovel", "id": 5690282, "node_id": "MDQ6VXNlcjU2OTAyODI=", "avatar_url": "https://avatars.githubusercontent.com/u/5690282?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cnovel", "html_url": "https://github.com/cnovel", "followers_url": "https://api.github.com/users/cnovel/followers", "following_url": "https://api.github.com/users/cnovel/following{/other_user}", "gists_url": "https://api.github.com/users/cnovel/gists{/gist_id}", "starred_url": "https://api.github.com/users/cnovel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cnovel/subscriptions", "organizations_url": "https://api.github.com/users/cnovel/orgs", "repos_url": "https://api.github.com/users/cnovel/repos", "events_url": "https://api.github.com/users/cnovel/events{/privacy}", "received_events_url": "https://api.github.com/users/cnovel/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1205615612, "node_id": "MDU6TGFiZWwxMjA1NjE1NjEy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux", "name": "subtype: ubuntu/linux", "color": "b619ea", "default": false, "description": "Ubuntu/Linux Build/Installation Issues" }, { "id": 4032183365, "node_id": "LA_kwDOArmXAs7wVjxF", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.9", "name": "TF 2.9", "color": "1CF842", "default": false, "description": "Issues found in the TF 2.9 release (or RCs)" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @cnovel ,\r\n\r\nYou can find the required pacakges for specific version packages in [setup.py](https://github.com/tensorflow/tensorflow/blob/r2.9/tensorflow/tools/pip_package/setup.py#L75) file.\r\n\r\nFor TF 2.9v the required numpy version should be >=1.20\r\n\r\nhttps://github.com/tensorflow/tensorflow/blob/a5ed5f39b675a1c6f315e0caf3ad4b38478fa571/tensorflow/tools/pip_package/setup.py#L87\r\n\r\nApart from that you need to install CUDA and cuDNN also as per tested [configurations](https://www.tensorflow.org/install/source#gpu) mentioned here wrt TF version. For Tf2.9v the tested configurations are mentioned below.\r\n\r\n\r\n\r\nVersion | Python version | Compiler | Build tools | cuDNN | CUDA\r\n-- | -- | -- | -- | -- | --\r\n\r\n\r\n\r\n\r\n\r\ntensorflow-2.9.0 | 3.7-3.10 | GCC 9.3.1 | Bazel 5.0.0 | 8.1 | 11.2\r\n-- | -- | -- | -- | -- | --\r\n\r\n\r\nPlease try the build again and let us know if still have problem.\r\n\r\nThanks!\r\n\r\n\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61926\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61926\">No</a>\n" ]
2023-09-20T13:38:25
2023-10-06T01:47:34
2023-10-06T01:47:32
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.9.1 ### Custom code No ### OS platform and distribution Ubuntu 22.04 LTS ### Mobile device / ### Python version 3.10 ### Bazel version 5.0.0 ### GCC/compiler version 11.4.0 ### CUDA/cuDNN version 11.7/8.5.0 ### GPU model and memory RTX A6000, GTX 1070 ### Current behavior? I've installed CUDA 11.7 toolkit only and libcudnn 8.5.0 on Ubuntu 22.04 LTS. I'm using python 3.10 using the `python3.10` cmd. Here's the script I'm running ```bash export PATH=$PATH:/usr/local/cuda-11.7/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-11.7/lib64 export TF_CUDA_VERSION=11.7 export TF_CUDNN_VERSION=8.5.0 export TF_CUBLAS_VERSION=11.10.1 python3.10 -m virtualenv venv venv/bin/pip install numpy==1.23.5 wheel packaging requests opt_einsum venv/bin/pip install keras_preprocessing --no-deps mkdir tmp cd tmp git clone https://github.com/tensorflow/tensorflow.git cd tensorflow git checkout v2.9.1 cd .. . venv/bin/activate cd tmp/tensorflow ./configure # No ROCm, Yes CUDA, No TensorRT, 3.5,5.2,6.0,6.1,7.0,7.5,8.0 capabilities, No clang, default for the rest bazel build --config=opt --verbose_failures //tensorflow:libtensorflow_cc.so bazel build --config=opt --verbose_failures //tensorflow:install_headers bazel build --config=opt --verbose_failures //tensorflow/tools/pip_package:build_pip_package # Failure here ./bazel-bin/tensorflow/tools/pip_package/build_pip_package ./bazel-bin/tensorflow/tools/pip_package ``` The output of `bazel build --config=opt --verbose_failures //tensorflow/tools/pip_package:build_pip_package` is available in the relevant log output section. The interesting line seems to be: ``` cp: cannot stat '/home/cluster/CN_TF/ContextCapture/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_dtype_api.h': No such file or directory ``` Indeed this file does not exist. I'm unsure why it is needed, but I tried different `numpy` version and failed to find one that works (either I'm missing this file, or `.doxyfile` or something else). Can you advise which version of numpy should I be using for the compilation to be successful? ### Standalone code to reproduce the issue ```shell I'm using vanilla Tensorflow checkout, no modifications are applied. ``` ### Relevant log output ```shell INFO: Options provided by the client: Inherited 'common' options: --isatty=1 --terminal_columns=116 INFO: Reading rc options for 'build' from /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: Inherited 'common' options: --experimental_repo_remote_exec INFO: Reading rc options for 'build' from /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: 'build' options: --define framework_shared_object=true --define=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=short_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shared_library INFO: Reading rc options for 'build' from /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.tf_configure.bazelrc: 'build' options: --action_env PYTHON_BIN_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin/python3 --action_env PYTHON_LIB_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages --python_path=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin/python3 --action_env TF_CUDA_VERSION=11.7 --action_env TF_CUBLAS_VERSION=11.10.1 --action_env TF_CUDNN_VERSION=8.5.0 --action_env CUDA_TOOLKIT_PATH=/usr/local/cuda-11.7 --action_env TF_CUDA_COMPUTE_CAPABILITIES=3.5,5.2,6.0,6.1,7.0,7.5,8.0 --action_env LD_LIBRARY_PATH=:/usr/local/cuda-11.7/lib64 --action_env GCC_HOST_COMPILER_PATH=/usr/bin/x86_64-linux-gnu-gcc-11 --config=cuda INFO: Reading rc options for 'build' from /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: 'build' options: --deleted_packages=tensorflow/compiler/mlir/tfrt,tensorflow/compiler/mlir/tfrt/benchmarks,tensorflow/compiler/mlir/tfrt/jit/python_binding,tensorflow/compiler/mlir/tfrt/jit/transforms,tensorflow/compiler/mlir/tfrt/python_tests,tensorflow/compiler/mlir/tfrt/tests,tensorflow/compiler/mlir/tfrt/tests/ir,tensorflow/compiler/mlir/tfrt/tests/analysis,tensorflow/compiler/mlir/tfrt/tests/jit,tensorflow/compiler/mlir/tfrt/tests/lhlo_to_tfrt,tensorflow/compiler/mlir/tfrt/tests/tf_to_corert,tensorflow/compiler/mlir/tfrt/tests/tf_to_tfrt_data,tensorflow/compiler/mlir/tfrt/tests/saved_model,tensorflow/compiler/mlir/tfrt/transforms/lhlo_gpu_to_tfrt_gpu,tensorflow/core/runtime_fallback,tensorflow/core/runtime_fallback/conversion,tensorflow/core/runtime_fallback/kernel,tensorflow/core/runtime_fallback/opdefs,tensorflow/core/runtime_fallback/runtime,tensorflow/core/runtime_fallback/util,tensorflow/core/tfrt/common,tensorflow/core/tfrt/eager,tensorflow/core/tfrt/eager/backends/cpu,tensorflow/core/tfrt/eager/backends/gpu,tensorflow/core/tfrt/eager/core_runtime,tensorflow/core/tfrt/eager/cpp_tests/core_runtime,tensorflow/core/tfrt/gpu,tensorflow/core/tfrt/run_handler_thread_pool,tensorflow/core/tfrt/runtime,tensorflow/core/tfrt/saved_model,tensorflow/core/tfrt/graph_executor,tensorflow/core/tfrt/saved_model/tests,tensorflow/core/tfrt/tpu,tensorflow/core/tfrt/utils INFO: Found applicable config definition build:short_logs in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: --output_filter=DONT_MATCH_ANYTHING INFO: Found applicable config definition build:v2 in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: --define=tf_api_version=2 --action_env=TF2_BEHAVIOR=1 INFO: Found applicable config definition build:cuda in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: --repo_env TF_NEED_CUDA=1 --crosstool_top=@local_config_cuda//crosstool:toolchain --@local_config_cuda//:enable_cuda INFO: Found applicable config definition build:opt in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.tf_configure.bazelrc: --copt=-Wno-sign-compare --host_copt=-Wno-sign-compare INFO: Found applicable config definition build:linux in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: --copt=-w --host_copt=-w --define=PREFIX=/usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_PATH=$(PREFIX)/include --cxxopt=-std=c++14 --host_cxxopt=-std=c++14 --config=dynamic_kernels --distinct_host_configuration=false --experimental_guard_against_concurrent_changes INFO: Found applicable config definition build:dynamic_kernels in file /home/cluster/work/ThirdParty/Tensorflow/distrib/tmp/tensorflow/.bazelrc: --define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS INFO: Analyzed target //tensorflow/tools/pip_package:build_pip_package (236 packages loaded, 7837 targets configured). INFO: Found 1 target... ERROR: /home/cluster/.cache/bazel/_bazel_cluster/350d8f2feeb21f42226977fe6efcfb0a/external/local_config_python/BUILD:254:8: Executing genrule @local_config_python//:numpy_include failed: (Exit 1): bash failed: error executing command (cd /home/cluster/.cache/bazel/_bazel_cluster/350d8f2feeb21f42226977fe6efcfb0a/execroot/org_tensorflow && \ exec env - \ CUDA_TOOLKIT_PATH=/usr/local/cuda-11.7 \ GCC_HOST_COMPILER_PATH=/usr/bin/x86_64-linux-gnu-gcc-11 \ LD_LIBRARY_PATH=:/usr/local/cuda-11.7/lib64 \ PATH=/home/cluster/.cache/bazelisk/downloads/sha256/399eedb225cff7a13f9f027f7ea2aad02ddb668a8eb89b1d975d222e4dc12ed9/bin:/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin:/home/cluster/.vscode-server/bin/8b617bd08fd9e3fc94d14adb8d358b56e3f72314/bin/remote-cli:/home/cluster/.local/bin:/home/cluster/miniconda3/bin:/home/cluster/miniconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/local/cuda-11.7/bin \ PYTHON_BIN_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin/python3 \ PYTHON_LIB_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages \ TF2_BEHAVIOR=1 \ TF_CUBLAS_VERSION=11.10.1 \ TF_CUDA_COMPUTE_CAPABILITIES=3.5,5.2,6.0,6.1,7.0,7.5,8.0 \ TF_CUDA_VERSION=11.7 \ TF_CUDNN_VERSION=8.5.0 \ /bin/bash -c 'source external/bazel_tools/tools/genrule/genrule-setup.sh; cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/.doxyfile" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/.doxyfile" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/__multiarray_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/__multiarray_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/__ufunc_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/__ufunc_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_dtype_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_dtype_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_neighborhood_iterator_imp.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_neighborhood_iterator_imp.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_numpyconfig.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_numpyconfig.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_numpyconfig.h.in" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_numpyconfig.h.in" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/arrayobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/arrayobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/arrayscalars.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/arrayscalars.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/experimental_dtype_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/experimental_dtype_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/halffloat.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/halffloat.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/libdivide/LICENSE.txt" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/libdivide/LICENSE.txt" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/libdivide/libdivide.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/libdivide/libdivide.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ndarrayobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ndarrayobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ndarraytypes.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ndarraytypes.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/noprefix.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/noprefix.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_1_7_deprecated_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_3kcompat.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_3kcompat.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_common.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_common.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_cpu.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_cpu.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_endian.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_endian.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_interrupt.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_interrupt.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_math.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_math.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_no_deprecated_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_no_deprecated_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_os.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_os.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/numpyconfig.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/numpyconfig.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/old_defines.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/old_defines.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/oldnumeric.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/oldnumeric.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/random/bitgen.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/random/bitgen.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/random/distributions.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/random/distributions.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ufuncobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ufuncobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/utils.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/utils.h" ') # Configuration: d04d20a1a4a46df9c7580a4efee273c7e78fdcec51eaaa1a5c3a4ea89b71ce88 # Execution platform: @local_execution_config_platform//:platform cp: cannot stat '/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_dtype_api.h': No such file or directory Target //tensorflow/tools/pip_package:build_pip_package failed to build ERROR: /home/cluster/.cache/bazel/_bazel_cluster/350d8f2feeb21f42226977fe6efcfb0a/external/local_config_python/BUILD:66:11 Middleman _middlemen/@local_Uconfig_Upython_S_S_Cnumpy_Uheaders-BazelCppSemantics_build_arch_k8-opt failed: (Exit 1): bash failed: error executing command (cd /home/cluster/.cache/bazel/_bazel_cluster/350d8f2feeb21f42226977fe6efcfb0a/execroot/org_tensorflow && \ exec env - \ CUDA_TOOLKIT_PATH=/usr/local/cuda-11.7 \ GCC_HOST_COMPILER_PATH=/usr/bin/x86_64-linux-gnu-gcc-11 \ LD_LIBRARY_PATH=:/usr/local/cuda-11.7/lib64 \ PATH=/home/cluster/.cache/bazelisk/downloads/sha256/399eedb225cff7a13f9f027f7ea2aad02ddb668a8eb89b1d975d222e4dc12ed9/bin:/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin:/home/cluster/.vscode-server/bin/8b617bd08fd9e3fc94d14adb8d358b56e3f72314/bin/remote-cli:/home/cluster/.local/bin:/home/cluster/miniconda3/bin:/home/cluster/miniconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/local/cuda-11.7/bin \ PYTHON_BIN_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/bin/python3 \ PYTHON_LIB_PATH=/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages \ TF2_BEHAVIOR=1 \ TF_CUBLAS_VERSION=11.10.1 \ TF_CUDA_COMPUTE_CAPABILITIES=3.5,5.2,6.0,6.1,7.0,7.5,8.0 \ TF_CUDA_VERSION=11.7 \ TF_CUDNN_VERSION=8.5.0 \ /bin/bash -c 'source external/bazel_tools/tools/genrule/genrule-setup.sh; cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/.doxyfile" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/.doxyfile" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/__multiarray_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/__multiarray_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/__ufunc_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/__ufunc_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_dtype_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_dtype_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_neighborhood_iterator_imp.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_neighborhood_iterator_imp.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_numpyconfig.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_numpyconfig.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/_numpyconfig.h.in" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/_numpyconfig.h.in" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/arrayobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/arrayobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/arrayscalars.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/arrayscalars.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/experimental_dtype_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/experimental_dtype_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/halffloat.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/halffloat.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/libdivide/LICENSE.txt" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/libdivide/LICENSE.txt" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/libdivide/libdivide.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/libdivide/libdivide.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ndarrayobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ndarrayobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ndarraytypes.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ndarraytypes.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/noprefix.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/noprefix.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_1_7_deprecated_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_3kcompat.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_3kcompat.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_common.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_common.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_cpu.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_cpu.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_endian.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_endian.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_interrupt.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_interrupt.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_math.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_math.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_no_deprecated_api.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_no_deprecated_api.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/npy_os.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/npy_os.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/numpyconfig.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/numpyconfig.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/old_defines.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/old_defines.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/oldnumeric.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/oldnumeric.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/random/bitgen.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/random/bitgen.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/random/distributions.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/random/distributions.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/ufuncobject.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/ufuncobject.h" && cp -f "/home/cluster/work/ThirdParty/Tensorflow/distrib/venv/lib/python3.10/site-packages/numpy/core/include/numpy/utils.h" "bazel-out/k8-opt/bin/external/local_config_python/numpy_include/numpy/utils.h" ') # Configuration: d04d20a1a4a46df9c7580a4efee273c7e78fdcec51eaaa1a5c3a4ea89b71ce88 # Execution platform: @local_execution_config_platform//:platform INFO: Elapsed time: 136.025s, Critical Path: 44.21s INFO: 977 processes: 370 internal, 607 local. FAILED: Build did NOT complete successfully ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61926/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61926/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61925
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61925/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61925/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61925/events
https://github.com/tensorflow/tensorflow/issues/61925
1,904,390,623
I_kwDOArmXAs5xgrHf
61,925
Unable to concatenate Keras Tensor and Eager Tensor using tf.keras.layers.Concatenate
{ "login": "Prashant-THRSL", "id": 111750332, "node_id": "U_kgDOBqksvA", "avatar_url": "https://avatars.githubusercontent.com/u/111750332?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Prashant-THRSL", "html_url": "https://github.com/Prashant-THRSL", "followers_url": "https://api.github.com/users/Prashant-THRSL/followers", "following_url": "https://api.github.com/users/Prashant-THRSL/following{/other_user}", "gists_url": "https://api.github.com/users/Prashant-THRSL/gists{/gist_id}", "starred_url": "https://api.github.com/users/Prashant-THRSL/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Prashant-THRSL/subscriptions", "organizations_url": "https://api.github.com/users/Prashant-THRSL/orgs", "repos_url": "https://api.github.com/users/Prashant-THRSL/repos", "events_url": "https://api.github.com/users/Prashant-THRSL/events{/privacy}", "received_events_url": "https://api.github.com/users/Prashant-THRSL/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "@SuryanarayanaY I was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/5551526739f9cda1b55893287fc16a3d/61925.ipynb). Thank you!", "Hi @Prashant-THRSL ,\r\n\r\nApologies for the delayed response.The issue got fixed with keras3 and tf-keras 2.15v. Please refer attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/ceac0d7b22dba33b40b3a46be5eecf07/61925.ipynb).\r\n\r\nSince Keras3 is now multi backend supporting and for TF specific you need to install tf-keras package.\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61925\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61925\">No</a>\n" ]
2023-09-20T07:51:32
2023-12-27T01:48:13
2023-12-27T01:48:10
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13 ### Custom code Yes ### OS platform and distribution Ubuntu 20.04 ### Mobile device _No response_ ### Python version 3.8 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I want to pad the Keras Tensor **without using tf.pad or tf.concat**. My approach is to create an empty tensor with zeros and concatenate the last layer with the Keras Tensor. I have successfully saved the model. But when **I try to load the model, I am getting errors**, I have attached code to recreate the error and logs as well. The expected output is concatenated Keras tensor on the last axis. ### Standalone code to reproduce the issue ```shell import tensorflow as tf from tensorflow.keras.models import Model, save_model, load_model from tensorflow.keras.layers import Input, Concatenate, Conv2D, ReLU # Define the input shape input_shape = (128, 128, 3) # Replace with your input dimensions # Create the input layer input_layer = Input(shape=input_shape) # Create empty channels empty_channels = tf.zeros((input_shape[0], input_shape[1], 4)) # Expand the dimensions of empty_channels to match input_shape empty_channels = tf.expand_dims(empty_channels, axis=0) # Concatenate the input with the empty channels concatenated = Concatenate(axis=-1)([input_layer, empty_channels]) # Create the model model = Model(inputs=input_layer, outputs=concatenated) # Display model summary model.summary() # Save the model to a file model.save("concatenated_model.h5") print("Model has saved.") # Now, to load the saved model loaded_model = load_model("concatenated_model.h5") print("Model has loaded.") ``` ### Relevant log output ```shell python3 testPython.py  1 ✘ 2023-09-20 13:14:52.746990: I tensorflow/core/util/port.cc:110] oneDNN custom operations are on. You may see slightly different numerical results due to floating-point round-off errors from different computation orders. To turn them off, set the environment variable `TF_ENABLE_ONEDNN_OPTS=0`. 2023-09-20 13:14:52.777548: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations. To enable the following instructions: AVX2 AVX512F AVX512_VNNI FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags. Model: "model" _________________________________________________________________ Layer (type) Output Shape Param # ================================================================= input_1 (InputLayer) [(None, 128, 128, 3)] 0 concatenate (Concatenate) (1, 128, 128, 7) 0 ================================================================= Total params: 0 (0.00 Byte) Trainable params: 0 (0.00 Byte) Non-trainable params: 0 (0.00 Byte) _________________________________________________________________ /home/hitech/.local/lib/python3.8/site-packages/keras/src/engine/training.py:3000: UserWarning: You are saving your model as an HDF5 file via `model.save()`. This file format is considered legacy. We recommend using instead the native Keras format, e.g. `model.save('my_model.keras')`. saving_api.save_model( WARNING:tensorflow:Compiled the loaded model, but the compiled metrics have yet to be built. `model.compile_metrics` will be empty until you train or evaluate the model. Model has saved. Traceback (most recent call last): File "testPython.py", line 33, in <module> loaded_model = load_model("concatenated_model.h5") File "/home/hitech/.local/lib/python3.8/site-packages/keras/src/saving/saving_api.py", line 238, in load_model return legacy_sm_saving_lib.load_model( File "/home/hitech/.local/lib/python3.8/site-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler raise e.with_traceback(filtered_tb) from None File "/home/hitech/.local/lib/python3.8/site-packages/keras/src/layers/merging/concatenate.py", line 119, in build raise ValueError(err_msg) ValueError: A `Concatenate` layer requires inputs with matching shapes except for the concatenation axis. Received: input_shape=[(None, 128, 128, 3), [[[[(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], [(), (), (), ()], ..... ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61925/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61925/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61924
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61924/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61924/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61924/events
https://github.com/tensorflow/tensorflow/issues/61924
1,904,240,353
I_kwDOArmXAs5xgGbh
61,924
Build issue tenserflow 2.11.0 for tensorflow quantum
{ "login": "Gaurang-Belekar", "id": 69144860, "node_id": "MDQ6VXNlcjY5MTQ0ODYw", "avatar_url": "https://avatars.githubusercontent.com/u/69144860?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Gaurang-Belekar", "html_url": "https://github.com/Gaurang-Belekar", "followers_url": "https://api.github.com/users/Gaurang-Belekar/followers", "following_url": "https://api.github.com/users/Gaurang-Belekar/following{/other_user}", "gists_url": "https://api.github.com/users/Gaurang-Belekar/gists{/gist_id}", "starred_url": "https://api.github.com/users/Gaurang-Belekar/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Gaurang-Belekar/subscriptions", "organizations_url": "https://api.github.com/users/Gaurang-Belekar/orgs", "repos_url": "https://api.github.com/users/Gaurang-Belekar/repos", "events_url": "https://api.github.com/users/Gaurang-Belekar/events{/privacy}", "received_events_url": "https://api.github.com/users/Gaurang-Belekar/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1205765054, "node_id": "MDU6TGFiZWwxMjA1NzY1MDU0", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:macOS", "name": "subtype:macOS", "color": "b619ea", "default": false, "description": "macOS Build/Installation issues" }, { "id": 4829271983, "node_id": "LA_kwDOArmXAs8AAAABH9jXrw", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.11", "name": "TF 2.11", "color": "46B4D7", "default": false, "description": "Issues related to TF 2.11" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @Gaurang-Belekar ,\r\n\r\nThis issue observed in Tf2.12v also. Its due to issue in compilation problem in boringssl and it was fixed in nightly at that time. Please refer to similar issue #60191 which resolved subsequently in nightly version. \r\n\r\nCould you please check the build with Tf2.13v as the changes might not be cherry picked in Tf2.12 and earlier.\r\n\r\nThank you!\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61924\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61924\">No</a>\n" ]
2023-09-20T06:19:19
2023-10-06T01:47:37
2023-10-06T01:47:34
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.11.0 ### Custom code Yes ### OS platform and distribution Mac OS M1 ### Mobile device _No response_ ### Python version 3.9 ### Bazel version bazel 5.3.0 ### GCC/compiler version Apple clang version 14.0.3 (clang-1403.0.22.14.1) Target: arm64-apple-darwin22.5.0 Thread model: posix ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Trying to build package using bazel compiler, as given [here](https://www.tensorflow.org/quantum/install). Fails to build the file. Gives the following output mentioned in log output, after running the given command. Output: <img width="1680" alt="Screenshot 2023-09-20 at 11 47 36" src="https://github.com/tensorflow/tensorflow/assets/69144860/e699f11d-fc31-49af-83b7-34e3330f3358"> ### Standalone code to reproduce the issue ```shell bazel build -c opt --cxxopt="-O3" --cxxopt="-march=native" --cxxopt="-std=c++17" --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=1" //tensorflow/tools/pip_package:build_pip_package ``` ### Relevant log output ```shell ERROR: /private/var/tmp/_bazel_gb/4de1e45218bdc87c870302861e9b2675/external/boringssl/BUILD:161:11: Compiling src/crypto/x509/t_x509.c [for host] failed: (Exit 1): cc_wrapper.sh failed: error executing command external/local_config_cc/cc_wrapper.sh -U_FORTIFY_SOURCE -fstack-protector -Wall -Wthread-safety -Wself-assign -Wunused-but-set-parameter -Wno-free-nonheap-object -fcolor-diagnostics ... (remaining 44 arguments skipped) external/boringssl/src/crypto/x509/t_x509.c:321:18: error: variable 'l' set but not used [-Werror,-Wunused-but-set-variable] int ret = 0, l, i; ^ 1 error generated. Target //tensorflow/tools/pip_package:build_pip_package failed to build Use --verbose_failures to see the command lines of failed build steps. INFO: Elapsed time: 709.728s, Critical Path: 52.92s INFO: 4419 processes: 1508 internal, 2911 local. FAILED: Build did NOT complete successfully ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61924/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61924/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61923
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61923/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61923/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61923/events
https://github.com/tensorflow/tensorflow/issues/61923
1,903,931,450
I_kwDOArmXAs5xe7A6
61,923
Keeping last layer names in Stacked Model
{ "login": "TkinterinShanghai", "id": 46348678, "node_id": "MDQ6VXNlcjQ2MzQ4Njc4", "avatar_url": "https://avatars.githubusercontent.com/u/46348678?v=4", "gravatar_id": "", "url": "https://api.github.com/users/TkinterinShanghai", "html_url": "https://github.com/TkinterinShanghai", "followers_url": "https://api.github.com/users/TkinterinShanghai/followers", "following_url": "https://api.github.com/users/TkinterinShanghai/following{/other_user}", "gists_url": "https://api.github.com/users/TkinterinShanghai/gists{/gist_id}", "starred_url": "https://api.github.com/users/TkinterinShanghai/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/TkinterinShanghai/subscriptions", "organizations_url": "https://api.github.com/users/TkinterinShanghai/orgs", "repos_url": "https://api.github.com/users/TkinterinShanghai/repos", "events_url": "https://api.github.com/users/TkinterinShanghai/events{/privacy}", "received_events_url": "https://api.github.com/users/TkinterinShanghai/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173272, "node_id": "MDU6TGFiZWw0NzMxNzMyNzI=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature", "name": "type:feature", "color": "159b2e", "default": false, "description": "Feature requests" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" } ]
closed
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "@TkinterinShanghai , Thanks for reporting the issue.\r\n\r\nSince this feature request is specific to Keras, could you please close this and open a new issue in Keras repo https://github.com/keras-team/keras/issues\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further." ]
2023-09-20T01:27:50
2023-10-31T01:47:53
2023-10-31T01:47:53
NONE
null
null
null
### Issue type Feature Request ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 ### Custom code No ### OS platform and distribution macOS 13.4 ### Mobile device _No response_ ### Python version 3.9 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? When using Model Stacking, I would like to access the last layer in the last stacked model to pass individual loss functions to them ```python # ------------------ Encoder ------------------ encoder_model = Model(inputs=all_inputs, outputs=latent_space, name="encoder") # ... irrelevant code # ------------------ Decoder ------------------ # Output Layers numeric_output = Dense( self.numeric_dim, activation="linear", name="numeric_output")(decoder2) binary_output = Dense( self.binary_dim, activation="sigmoid", name="binary_output")(decoder2) decoder_output = [numeric_output] + [binary_output] decoder_model = Model(inputs=latent_input, outputs=decoder_output, name="decoder") # ------------------ Autoencoder ------------------ autoencoder_output = decoder_model(encoder_model(all_inputs)) autoencoder = Model(inputs=all_inputs, outputs=pass_through_layers, name="autoencoder") # This will not work: losses = { "numeric_output": "mse", "binary_output": "binary_crossentropy" } autoencoder.compile(optimizer=Adam(learning_rate=lr), loss=losses) ``` The last layer will be renamed to decoder1, decoder2, etc. It would be much nicer if there was some passthrough argument in a model that would allow referencing the last layer in the stacked model directly ### Standalone code to reproduce the issue ```shell This will fail import numpy as np from tensorflow.keras.layers import Input, Dense from tensorflow.keras.models import Model from tensorflow.keras.optimizers import Adam # Input dimensions input_dim = 10 latent_dim = 5 numeric_dim = 3 binary_dim = 2 # Learning rate lr = 0.001 # Number of samples n_samples = 1000 # Generate random data X = np.random.rand(n_samples, input_dim) y_numeric = np.random.rand(n_samples, numeric_dim) y_binary = np.random.randint(0, 2, size=(n_samples, binary_dim)) # ------------------ Encoder ------------------ all_inputs = Input(shape=(input_dim,), name="all_inputs") latent_space = Dense(latent_dim, activation="relu", name="latent_space")(all_inputs) encoder_model = Model(inputs=all_inputs, outputs=latent_space, name="encoder") # ------------------ Decoder ------------------ latent_input = Input(shape=(latent_dim,), name="latent_input") decoder2 = Dense(10, activation="relu", name="decoder2")(latent_input) numeric_output = Dense(numeric_dim, activation="linear", name="numeric_output")(decoder2) binary_output = Dense(binary_dim, activation="sigmoid", name="binary_output")(decoder2) decoder_output = [numeric_output, binary_output] decoder_model = Model(inputs=latent_input, outputs=decoder_output, name="decoder") # ------------------ Autoencoder ------------------ autoencoder_output = decoder_model(encoder_model(all_inputs)) # This will not work: losses = { "numeric_output": "mse", "binary_output": "binary_crossentropy" } autoencoder = Model(inputs=all_inputs, outputs=autoencoder_output, name="autoencoder") autoencoder.compile(optimizer=Adam(learning_rate=lr), loss=losses) # Fit the model autoencoder.fit( x=X, y=[y_numeric, y_binary], epochs=10, batch_size=32 ) ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61923/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61923/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61922
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61922/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61922/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61922/events
https://github.com/tensorflow/tensorflow/issues/61922
1,903,801,953
I_kwDOArmXAs5xebZh
61,922
Problem installing tensorflow 2.13.0
{ "login": "ihh", "id": 54113, "node_id": "MDQ6VXNlcjU0MTEz", "avatar_url": "https://avatars.githubusercontent.com/u/54113?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ihh", "html_url": "https://github.com/ihh", "followers_url": "https://api.github.com/users/ihh/followers", "following_url": "https://api.github.com/users/ihh/following{/other_user}", "gists_url": "https://api.github.com/users/ihh/gists{/gist_id}", "starred_url": "https://api.github.com/users/ihh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ihh/subscriptions", "organizations_url": "https://api.github.com/users/ihh/orgs", "repos_url": "https://api.github.com/users/ihh/repos", "events_url": "https://api.github.com/users/ihh/events{/privacy}", "received_events_url": "https://api.github.com/users/ihh/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1205615612, "node_id": "MDU6TGFiZWwxMjA1NjE1NjEy", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux", "name": "subtype: ubuntu/linux", "color": "b619ea", "default": false, "description": "Ubuntu/Linux Build/Installation Issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @ihh,\r\n\r\nThis seems to be environment issue. We have observed that with protobuf 4.24.3 version there seems some problem as in other ticket #61551 user confirmed segmentation fault with this protobuf version. That issue is under review now.\r\n\r\nCould you please try with any other protobuf version mentioned below.May be 4.23.4 or something and let us know the outcome.\r\n\r\n 'protobuf>=3.20.3,<5.0.0dev,!=4.21.0,!=4.21.1,!=4.21.2,!=4.21.3,!=4.21.4,!=4.21.5'\r\n\r\nThank you!", "Thanks @SuryanarayanaY. Unfortunately this does not resolve the problem:\r\n\r\n~~~\r\n$ pip uninstall tensorflow protobuf\r\n$ python3 -m pip install nvidia-cudnn-cu11==8.6.0.163 protobuf==4.23.4 tensorflow==2.13.*\r\n...\r\nUsing cached protobuf-4.23.4-cp37-abi3-manylinux2014_x86_64.whl (304 kB)\r\nUsing cached tensorflow-2.13.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (524.2 MB)\r\nInstalling collected packages: protobuf, tensorflow\r\nSuccessfully installed protobuf-4.23.4 tensorflow-2.13.0\r\n$ python3 -c \"import tensorflow as tf; print(tf.config.list_physical_devices('GPU'))\"\r\nTraceback (most recent call last):\r\n File \"<string>\", line 1, in <module>\r\n File \"/home/yam/miniconda3/envs/jax-cuda11/lib/python3.11/site-packages/tensorflow/__init__.py\", line 38, in <module>\r\n from tensorflow.python.tools import module_util as _module_util\r\n File \"/home/yam/miniconda3/envs/jax-cuda11/lib/python3.11/site-packages/tensorflow/python/__init__.py\", line 36, in <module>\r\n from tensorflow.python import pywrap_tensorflow as _pywrap_tensorflow\r\n File \"/home/yam/miniconda3/envs/jax-cuda11/lib/python3.11/site-packages/tensorflow/python/pywrap_tensorflow.py\", line 26, in <module>\r\n self_check.preload_check()\r\n File \"/home/yam/miniconda3/envs/jax-cuda11/lib/python3.11/site-packages/tensorflow/python/platform/self_check.py\", line 63, in preload_check\r\n from tensorflow.python.platform import _pywrap_cpu_feature_guard\r\nImportError: /home/yam/miniconda3/envs/jax-cuda11/lib/python3.11/site-packages/tensorflow/python/platform/../../libtensorflow_cc.so.2: undefined symbol: _ZN6google8protobuf7Message19CopyWithSourceCheckERS1_RKS1_\r\n~~~", "Hi @ihh ,\r\n\r\nWe are able to install tensorflow==2.13 successfully on Ubuntu22. Just to cross check,could you please uninstall tensorflow and try with fresh environment and also with latest version i.e. 2.14 as well and let us know the outcome.\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61922\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61922\">No</a>\n", "> Hi @ihh ,\r\n> \r\n> We are able to install tensorflow==2.13 successfully on Ubuntu22. Just to cross check,could you please uninstall tensorflow and try with fresh environment and also with latest version i.e. 2.14 as well and let us know the outcome.\r\n\r\nApologies for the slow reply. A fresh install worked, thank you. I think there was some cross-contamination between different package versions." ]
2023-09-19T22:17:17
2023-10-13T03:10:44
2023-10-13T01:48:33
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source binary ### TensorFlow version 2.13.0 ### Custom code No ### OS platform and distribution Linux Ubuntu 22.04, Lambda Labs TensorBook ### Mobile device n/a ### Python version 3.11.5 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 8.6.0.163 ### GPU model and memory _No response_ ### Current behavior? TensorFlow 2.1.13 won't run because of an undefined symbol in libtensorflow_cc, apparently a google.protobuf.Message symbol. ### Standalone code to reproduce the issue ```shell I am on a LambdaLabs TensorBook. This does come with a preloaded tensorflow installation in /usr/lib/python3/dist-packages However my reading of the error messages on install does not seem to suggest that conflict with that package is to blame here. Installing per instructions here: https://www.tensorflow.org/install/pip ~~~ conda create --name cuda11 conda activate cuda11 conda install python conda install -c conda-forge cudatoolkit=11.8.0 python3 -m pip install nvidia-cudnn-cu11==8.6.0.163 tensorflow==2.13. python3 -c "import tensorflow" ~~~ ...yields the following error message... ~~~ Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/yam/miniconda3/envs/cuda11/lib/python3.11/site-packages/tensorflow/__init__.py", line 38, in <module> from tensorflow.python.tools import module_util as _module_util File "/home/yam/miniconda3/envs/cuda11/lib/python3.11/site-packages/tensorflow/python/__init__.py", line 36, in <module> from tensorflow.python import pywrap_tensorflow as _pywrap_tensorflow File "/home/yam/miniconda3/envs/cuda11/lib/python3.11/site-packages/tensorflow/python/pywrap_tensorflow.py", line 26, in <module> self_check.preload_check() File "/home/yam/miniconda3/envs/cuda11/lib/python3.11/site-packages/tensorflow/python/platform/self_check.py", line 63, in preload_check from tensorflow.python.platform import _pywrap_cpu_feature_guard ImportError: /home/yam/miniconda3/envs/cuda11/lib/python3.11/site-packages/tensorflow/python/platform/../../libtensorflow_cc.so.2: undefined symbol: _ZN6google8protobuf7Message19CopyWithSourceCheckERS1_RKS1_ ~~~ pip package info: ~~~ (cuda11) yam@TensorYam:~$ python -m pip list Package Version ---------------------------- --------- absl-py 2.0.0 astunparse 1.6.3 cachetools 5.3.1 certifi 2023.7.22 charset-normalizer 3.2.0 flatbuffers 23.5.26 gast 0.4.0 google-auth 2.23.0 google-auth-oauthlib 1.0.0 google-pasta 0.2.0 grpcio 1.58.0 h5py 3.9.0 idna 3.4 keras 2.13.1 libclang 16.0.6 Markdown 3.4.4 MarkupSafe 2.1.3 numpy 1.24.3 nvidia-cublas-cu11 11.11.3.6 nvidia-cudnn-cu11 8.6.0.163 oauthlib 3.2.2 opt-einsum 3.3.0 packaging 23.1 pip 23.2.1 protobuf 4.24.3 pyasn1 0.5.0 pyasn1-modules 0.3.0 requests 2.31.0 requests-oauthlib 1.3.1 rsa 4.9 setuptools 68.0.0 six 1.16.0 tensorboard 2.13.0 tensorboard-data-server 0.7.1 tensorflow 2.13.0 tensorflow-estimator 2.13.0 tensorflow-io-gcs-filesystem 0.34.0 termcolor 2.3.0 typing_extensions 4.5.0 urllib3 1.26.16 Werkzeug 2.3.7 wheel 0.38.4 wrapt 1.15.0 ~~~ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61922/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61922/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61921
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61921/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61921/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61921/events
https://github.com/tensorflow/tensorflow/issues/61921
1,903,718,765
I_kwDOArmXAs5xeHFt
61,921
TensorFlow lite cmake compilation failed to allocate memory
{ "login": "lorenzodellagiustina", "id": 31545963, "node_id": "MDQ6VXNlcjMxNTQ1OTYz", "avatar_url": "https://avatars.githubusercontent.com/u/31545963?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lorenzodellagiustina", "html_url": "https://github.com/lorenzodellagiustina", "followers_url": "https://api.github.com/users/lorenzodellagiustina/followers", "following_url": "https://api.github.com/users/lorenzodellagiustina/following{/other_user}", "gists_url": "https://api.github.com/users/lorenzodellagiustina/gists{/gist_id}", "starred_url": "https://api.github.com/users/lorenzodellagiustina/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lorenzodellagiustina/subscriptions", "organizations_url": "https://api.github.com/users/lorenzodellagiustina/orgs", "repos_url": "https://api.github.com/users/lorenzodellagiustina/repos", "events_url": "https://api.github.com/users/lorenzodellagiustina/events{/privacy}", "received_events_url": "https://api.github.com/users/lorenzodellagiustina/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 4257391797, "node_id": "LA_kwDOArmXAs79wqS1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/wsl2", "name": "wsl2", "color": "A352E6", "default": false, "description": "Windows Subsystem for Linux" } ]
closed
false
{ "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false }
[ { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @lorenzodellagiustina, my current best guess is you are suffering from too much virtualization and the memory isn't being allocated across the virtual layers as well as you think it is. Is there any way to remove one of the layers, if only temporarily to figure out where the root of this problem lies? Otherwise can you check how much memory is actually allocated to WSL 2 and then how much memory is actually accessible to the docker?", "> Hi @lorenzodellagiustina, my current best guess is you are suffering from too much virtualization and the memory isn't being allocated across the virtual layers as well as you think it is. Is there any way to remove one of the layers, if only temporarily to figure out where the root of this problem lies? Otherwise can you check how much memory is actually allocated to WSL 2 and then how much memory is actually accessible to the docker?\r\n\r\n@Luca-Stefanescu\r\n\r\nThanks for your quick response. Turned out to be a problem with the `-j` flag of the command `cmake --build`. This flags is used to specify the number of parallel build jobs to run simultaneously. It should be used followed by a number (the number of cpu cores of my machine worked fine for me). I guess that if a number is not specified the build will be parallelized as much as possible trying to allocate way too memory (even github actions failed to build the \"minimal\" example).\r\nI think that this should be written in the guide for building TFLite with CMake. Just adding a note about the usage of `-j` flag would have saved me a lot of hours. Maybe I'll just open a pull request and I'll link it to this issue in the next days.\r\n\r\nThanks for your help.", "@lorenzodellagiustina np, Thanks for letting us know, can you please close this issue as completed if you have no more open items? Thanks!", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61921\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61921\">No</a>\n" ]
2023-09-19T21:01:57
2023-09-20T19:43:19
2023-09-20T19:43:17
NONE
null
null
null
Any update with this issue? I'm having the same problem described by @Luca-Stefanescu I am building Tensorflow Lite with cmake following the instruction given on the minimal example. I am building in a docker container with ubuntu using WSL 2 with docker desktop. The build seems to work until 91%. Then it will start to allocate all the memory (16gb of ram + 8gb of swap) until it fails to allocate throwing an allocation error or sometimes an input/output error. I think that this error message could be helpful: ``` In file included from /workspaces/tfl-dev-env/tie/../tensorflow_src/tensorflow/lite/kernels/internal/runtime_shape.h:22, from /workspaces/tfl-dev-env/tie/../tensorflow_src/tensorflow/lite/kernels/internal/types.h:24, from /workspaces/tfl-dev-env/tie/../tensorflow_src/tensorflow/lite/kernels/internal/tensor_ctypes.h:22, from /workspaces/tfl-dev-env/tensorflow_src/tensorflow/lite/kernels/embedding_lookup_sparse.cc:72: /usr/include/c++/13/memory:81:12: fatal error: /workspaces/tfl-dev-env/tie/../tensorflow_src/bits/shared_ptr_atomic.h: Cannot allocate memory 81 | # include <bits/shared_ptr_atomic.h> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ compilation terminated. ``` However trying to follow the same steps on a ubuntu VM using VMWare (and with less memory) seems to work. _Originally posted by @lorenzodellagiustina in https://github.com/tensorflow/tensorflow/issues/61485#issuecomment-1725196272_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61921/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61921/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61920
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61920/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61920/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61920/events
https://github.com/tensorflow/tensorflow/issues/61920
1,903,716,925
I_kwDOArmXAs5xeGo9
61,920
DenseFeatures Feature column combine order
{ "login": "ishmnnit", "id": 1782420, "node_id": "MDQ6VXNlcjE3ODI0MjA=", "avatar_url": "https://avatars.githubusercontent.com/u/1782420?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ishmnnit", "html_url": "https://github.com/ishmnnit", "followers_url": "https://api.github.com/users/ishmnnit/followers", "following_url": "https://api.github.com/users/ishmnnit/following{/other_user}", "gists_url": "https://api.github.com/users/ishmnnit/gists{/gist_id}", "starred_url": "https://api.github.com/users/ishmnnit/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ishmnnit/subscriptions", "organizations_url": "https://api.github.com/users/ishmnnit/orgs", "repos_url": "https://api.github.com/users/ishmnnit/repos", "events_url": "https://api.github.com/users/ishmnnit/events{/privacy}", "received_events_url": "https://api.github.com/users/ishmnnit/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "Hello, @ishmnnit! tf.feature_column is not recommended for the new code of TF v2.13 as this is deprecated. Instead, feature preprocessing can be done directly using either [Keras preprocessing layers](https://www.tensorflow.org/guide/migrate/migrating_feature_columns) or through the one-stop utility [tf.keras.utils.FeatureSpace](https://www.tensorflow.org/api_docs/python/tf/keras/utils/FeatureSpace) built on top of them. See the [migration guide](https://tensorflow.org/guide/migrate) for details.\r\nThank you!", "@sushreebarsa That part I understand. it's just I am working with a large codebase, and moving to featurespace is a few months of effort, in between that I like some solutions that work.", "@ishmnnit Sorry to say but this api is deprecated now which is not actively supported. For any further queries you may open this issue in tf discussion [forum](https://discuss.tensorflow.org/) as there is a larger community there.\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61920\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61920\">No</a>\n" ]
2023-09-19T21:00:19
2023-10-05T01:48:19
2023-10-05T01:48:16
NONE
null
null
null
### Issue type Support ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? I have this code to create DenseFeatures layer. ``` # Define the input for each feature column. inputs = {} for col in feature_columns: if type(col) == type(tf.feature_column.numeric_column("temp")): dtype = tf.float32 key = col.key else: dtype = tf.int64 key = col.categorical_column.key inputs[key] = tf.keras.layers.Input(name=key, shape=(), dtype=dtype) // Now use a DenseFeatures layer to combine them x = tf.keras.layers.DenseFeatures(feature_columns)(inputs) ``` ----------------- Now, I am trying to implement the output of the DenseFeatures layer for inference. I am facing a situation where I cannot use the TensorFlow model due to latency constraints. However, my issue is that the manner in which DenseFeatures combines the inputs does not follow the order specified in feature_columns, nor is it sorted based on the feature names. Is there a way I can determine the order in which these feature columns are combined within the DenseFeatures layer? As I understand, in most places it is mentioned that it should follow the same order as the feature columns, but this is not what I am observing. I am using TensorFlow 2.13. ### Standalone code to reproduce the issue ```shell # Define the input for each feature column. inputs = {} for col in feature_columns: if type(col) == type(tf.feature_column.numeric_column("temp")): dtype = tf.float32 key = col.key else: dtype = tf.int64 key = col.categorical_column.key inputs[key] = tf.keras.layers.Input(name=key, shape=(), dtype=dtype) // Now use a DenseFeatures layer to combine them x = tf.keras.layers.DenseFeatures(feature_columns)(inputs) ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61920/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61920/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61919
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61919/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61919/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61919/events
https://github.com/tensorflow/tensorflow/pull/61919
1,903,137,315
PR_kwDOArmXAs5ar7QR
61,919
Remove hostedtoolcache from docker build scripts
{ "login": "MichaelHudgins", "id": 30155094, "node_id": "MDQ6VXNlcjMwMTU1MDk0", "avatar_url": "https://avatars.githubusercontent.com/u/30155094?v=4", "gravatar_id": "", "url": "https://api.github.com/users/MichaelHudgins", "html_url": "https://github.com/MichaelHudgins", "followers_url": "https://api.github.com/users/MichaelHudgins/followers", "following_url": "https://api.github.com/users/MichaelHudgins/following{/other_user}", "gists_url": "https://api.github.com/users/MichaelHudgins/gists{/gist_id}", "starred_url": "https://api.github.com/users/MichaelHudgins/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/MichaelHudgins/subscriptions", "organizations_url": "https://api.github.com/users/MichaelHudgins/orgs", "repos_url": "https://api.github.com/users/MichaelHudgins/repos", "events_url": "https://api.github.com/users/MichaelHudgins/events{/privacy}", "received_events_url": "https://api.github.com/users/MichaelHudgins/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Context: Out of space on the clang 17 upgrade: https://github.com/tensorflow/tensorflow/actions/runs/6227924038" ]
2023-09-19T14:34:39
2023-09-19T18:59:58
2023-09-19T18:59:57
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61919", "html_url": "https://github.com/tensorflow/tensorflow/pull/61919", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61919.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61919.patch", "merged_at": "2023-09-19T18:59:57" }
Due to the large size of both CUDA and TF itself we are running into disk issues on the docker build scripts when a large change has been made. This will delete the hostedtoolcache to free up space.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61919/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61919/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61918
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61918/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61918/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61918/events
https://github.com/tensorflow/tensorflow/issues/61918
1,903,136,515
I_kwDOArmXAs5xb48D
61,918
implementation 'org.tensorflow:tensorflow-lite-support:0.1.0'
{ "login": "B-JackMao", "id": 57884144, "node_id": "MDQ6VXNlcjU3ODg0MTQ0", "avatar_url": "https://avatars.githubusercontent.com/u/57884144?v=4", "gravatar_id": "", "url": "https://api.github.com/users/B-JackMao", "html_url": "https://github.com/B-JackMao", "followers_url": "https://api.github.com/users/B-JackMao/followers", "following_url": "https://api.github.com/users/B-JackMao/following{/other_user}", "gists_url": "https://api.github.com/users/B-JackMao/gists{/gist_id}", "starred_url": "https://api.github.com/users/B-JackMao/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/B-JackMao/subscriptions", "organizations_url": "https://api.github.com/users/B-JackMao/orgs", "repos_url": "https://api.github.com/users/B-JackMao/repos", "events_url": "https://api.github.com/users/B-JackMao/events{/privacy}", "received_events_url": "https://api.github.com/users/B-JackMao/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" } ]
closed
false
{ "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false }
[ { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @B-JackMao, can you please fill out the issues template: https://github.com/tensorflow/tensorflow/issues/new?assignees=&labels=comp%3Alite-in-play-services&projects=&template=tflite-in-play-services.md This will give us more context so that we may help you faster (You can remove the google-play specific information).", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61918\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61918\">No</a>\n" ]
2023-09-19T14:34:15
2023-10-05T01:48:22
2023-10-05T01:48:18
NONE
null
null
null
implementation 'org.tensorflow:tensorflow-lite-support:0.1.0' Why do I run this instruction to generate two dependent libraries, TensorFlow Lite and TensorFlow Lite Support? How can I generate only tensorflow site support as a dependency library?
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61918/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61918/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61917
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61917/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61917/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61917/events
https://github.com/tensorflow/tensorflow/pull/61917
1,903,088,610
PR_kwDOArmXAs5arwmM
61,917
nicer link to OpenSSF scorecard
{ "login": "mo271", "id": 3491627, "node_id": "MDQ6VXNlcjM0OTE2Mjc=", "avatar_url": "https://avatars.githubusercontent.com/u/3491627?v=4", "gravatar_id": "", "url": "https://api.github.com/users/mo271", "html_url": "https://github.com/mo271", "followers_url": "https://api.github.com/users/mo271/followers", "following_url": "https://api.github.com/users/mo271/following{/other_user}", "gists_url": "https://api.github.com/users/mo271/gists{/gist_id}", "starred_url": "https://api.github.com/users/mo271/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mo271/subscriptions", "organizations_url": "https://api.github.com/users/mo271/orgs", "repos_url": "https://api.github.com/users/mo271/repos", "events_url": "https://api.github.com/users/mo271/events{/privacy}", "received_events_url": "https://api.github.com/users/mo271/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-19T14:11:34
2023-09-20T15:24:07
2023-09-20T15:24:06
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61917", "html_url": "https://github.com/tensorflow/tensorflow/pull/61917", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61917.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61917.patch", "merged_at": "2023-09-20T15:24:06" }
null
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61917/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61917/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61916
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61916/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61916/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61916/events
https://github.com/tensorflow/tensorflow/issues/61916
1,903,050,020
I_kwDOArmXAs5xbj0k
61,916
tf.linalg.cholesky output normal value on a complex64 matrix that is not positive definite.
{ "login": "drewshark", "id": 128925028, "node_id": "U_kgDOB689ZA", "avatar_url": "https://avatars.githubusercontent.com/u/128925028?v=4", "gravatar_id": "", "url": "https://api.github.com/users/drewshark", "html_url": "https://github.com/drewshark", "followers_url": "https://api.github.com/users/drewshark/followers", "following_url": "https://api.github.com/users/drewshark/following{/other_user}", "gists_url": "https://api.github.com/users/drewshark/gists{/gist_id}", "starred_url": "https://api.github.com/users/drewshark/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/drewshark/subscriptions", "organizations_url": "https://api.github.com/users/drewshark/orgs", "repos_url": "https://api.github.com/users/drewshark/repos", "events_url": "https://api.github.com/users/drewshark/events{/privacy}", "received_events_url": "https://api.github.com/users/drewshark/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "hello @drewshark I tried to implement this Google collab and came up with this.\r\n![Screenshot 2023-09-19 220747](https://github.com/tensorflow/tensorflow/assets/96938361/29ba5e1f-c8eb-4b9d-8cfa-892f314b0755)\r\n![Screenshot 2023-09-19 220723](https://github.com/tensorflow/tensorflow/assets/96938361/514d890e-ac74-4bd1-9890-854d8335a671)\r\n", "Hi @SouSingh \r\n\r\nI confirm your screenshot that TensorFlow and Numpy output normal result when input `array` is a **positive definite matrix**. However, my issue is that TensorFlow will still output normal value or nan value when receiving a **non-positive definite matrix**, in contrast, numpy raises crash. Here I share a link from colab that illustrates my case: https://colab.research.google.com/drive/1jNh9RCmWQw6ZWW1LRXvEUuusGRNjXs35?usp=sharing\r\n\r\nIn this case, instead of generating a positive definite matrix using:\r\n\r\n```\r\nA = np.random.rand(4,4).astype(\"complex64\")\r\narray = np.dot(A, A.T)\r\n```\r\n\r\nI just randomly generate a matrix which is likely to be not positive definite:\r\n```\r\narray = np.random.rand(4,4).astype(\"complex64\")\r\n```", "Hi @drewshark ,\r\n\r\nI have replicated the reported behaviour. Attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/7a9d78531ca7da276fdbc0b22e50b01a/61916_tf-linalg-cholesky.ipynb) for reference. I need to understand and dig more to confirm the reason for this behaviour." ]
2023-09-19T13:54:42
2023-11-10T08:16:50
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? On a randomly generated matrix that is not positive definite, tf.linalg.cholesky outputs nan if the matrix's dtype is float and outputs 0 if the matrix' dtype is complex. It may be not appropriate especially when tf.linalg.cholesky outputs 0 on an invalid input without giving any abnormal behaviors. For your inference, np.linalg.cholesky will directly raises with error message when receiving non-positive definite matrix in float or complex data type. ### Standalone code to reproduce the issue ```shell import tensorflow as tf import numpy as np import warnings import os os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2' warnings.filterwarnings("ignore") np.random.seed(1234) array = np.random.rand(4,4).astype("complex64") try: print("Numpy's result: ", np.linalg.cholesky(array)) except: print("Numpy crash.") print("TensorFlow's result: ", tf.linalg.cholesky(tf.constant(array))) array = np.random.rand(4,4).astype("float64") try: print("Numpy's result: ", np.linalg.cholesky(array)) except: print("Numpy crash.") print("TensorFlow's result: ", tf.linalg.cholesky(tf.constant(array))) ``` ### Relevant log output ```shell Numpy crash. TensorFlow's result: tf.Tensor( [[0.+0.j 0.+0.j 0.+0.j 0.+0.j] [0.+0.j 0.+0.j 0.+0.j 0.+0.j] [0.+0.j 0.+0.j 0.+0.j 0.+0.j] [0.+0.j 0.+0.j 0.+0.j 0.+0.j]], shape=(4, 4), dtype=complex64) Numpy crash. TensorFlow's result: tf.Tensor( [[nan 0. 0. 0.] [nan nan 0. 0.] [nan nan nan 0.] [nan nan nan nan]], shape=(4, 4), dtype=float64) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61916/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61916/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61915
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61915/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61915/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61915/events
https://github.com/tensorflow/tensorflow/issues/61915
1,902,997,996
I_kwDOArmXAs5xbXHs
61,915
'Adam' object has no attribute 'build' (saving and loading keras.optimizers.Adam)
{ "login": "palminha", "id": 12155015, "node_id": "MDQ6VXNlcjEyMTU1MDE1", "avatar_url": "https://avatars.githubusercontent.com/u/12155015?v=4", "gravatar_id": "", "url": "https://api.github.com/users/palminha", "html_url": "https://github.com/palminha", "followers_url": "https://api.github.com/users/palminha/followers", "following_url": "https://api.github.com/users/palminha/following{/other_user}", "gists_url": "https://api.github.com/users/palminha/gists{/gist_id}", "starred_url": "https://api.github.com/users/palminha/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/palminha/subscriptions", "organizations_url": "https://api.github.com/users/palminha/orgs", "repos_url": "https://api.github.com/users/palminha/repos", "events_url": "https://api.github.com/users/palminha/events{/privacy}", "received_events_url": "https://api.github.com/users/palminha/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097546578, "node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras", "name": "comp:keras", "color": "0052cc", "default": false, "description": "Keras related issues" }, { "id": 2046763290, "node_id": "MDU6TGFiZWwyMDQ2NzYzMjkw", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/Fixed%20in%20Nightly", "name": "Fixed in Nightly", "color": "5ecc37", "default": false, "description": "Issues that are resolved in nightly version" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "same problem reported with Keras here: https://github.com/keras-team/tf-keras/issues/46", "@palminha Thank you for raising this issue!\r\n@SuryanarayanaY I was able to replicate the issue on Macbook, please find the attached screenshot below;\r\n<img width=\"564\" alt=\"image (3)\" src=\"https://github.com/tensorflow/tensorflow/assets/84765720/a478b0ef-5b2c-44a7-a790-578da03286d7\">\r\n\r\nI was able to run the coed successfully on colab, please have a look at this [gist](https://colab.research.google.com/gist/sushreebarsa/695b5adea44465c59315c78154a787c1/61915.ipynb). Thank you!", "Hi, I am Debrup. I want to work on this problem can I be pleased assigned to the problem?", "@ palminha,\r\n\r\nFor MacOS we need to import optimizers from legacy space like keras.optimizers.legacy.Adam. I tried explicitly replacing the Adam with legacy .Adam and still its not working. Since there is no problem with Linux and Macos package was built and maintained by Apple itself, you need to report the issue at Apple developer forum [here](https://developer.apple.com/forums/tags/tensorflow-metal/).\r\n\r\nMeanwhile I will also take it to the attention of concerned engineer.\r\n\r\nThank you!", "CC - @nitins17 ,Do you have any pointers here?\r\n\r\nThanks!", "@SuryanarayanaY Here is my machine the dependency graph: in my case i'm not using `tensorflow-metal`... i'm using the package `tensorflow` (that installs as dependency the `tensorflow-macos`)\r\n\r\n```\r\ntensorflow==2.13.0\r\n└── tensorflow-macos [required: ==2.13.0, installed: 2.13.0]\r\n ├── absl-py [required: >=1.0.0, installed: 2.0.0]\r\n ├── astunparse [required: >=1.6.0, installed: 1.6.3]\r\n │ ├── six [required: >=1.6.1,<2.0, installed: 1.16.0]\r\n │ └── wheel [required: >=0.23.0,<1.0, installed: 0.41.2]\r\n ├── flatbuffers [required: >=23.1.21, installed: 23.5.26]\r\n ├── gast [required: >=0.2.1,<=0.4.0, installed: 0.4.0]\r\n ├── google-pasta [required: >=0.1.1, installed: 0.2.0]\r\n │ └── six [required: Any, installed: 1.16.0]\r\n ├── grpcio [required: >=1.24.3,<2.0, installed: 1.58.0]\r\n ├── h5py [required: >=2.9.0, installed: 3.9.0]\r\n │ └── numpy [required: >=1.17.3, installed: 1.23.5]\r\n ├── keras [required: >=2.13.1,<2.14, installed: 2.13.1]\r\n ├── libclang [required: >=13.0.0, installed: 16.0.6]\r\n ├── numpy [required: >=1.22,<=1.24.3, installed: 1.23.5]\r\n ├── opt-einsum [required: >=2.3.2, installed: 3.3.0]\r\n │ └── numpy [required: >=1.7, installed: 1.23.5]\r\n ├── packaging [required: Any, installed: 23.1]\r\n ├── protobuf [required: >=3.20.3,<5.0.0dev,!=4.21.5,!=4.21.4,!=4.21.3,!=4.21.2,!=4.21.1,!=4.21.0, installed: 3.20.3]\r\n ├── setuptools [required: Any, installed: 68.2.2]\r\n ├── six [required: >=1.12.0, installed: 1.16.0]\r\n ├── tensorboard [required: >=2.13,<2.14, installed: 2.13.0]\r\n │ ├── absl-py [required: >=0.4, installed: 2.0.0]\r\n │ ├── google-auth [required: >=1.6.3,<3, installed: 2.23.0]\r\n │ │ ├── cachetools [required: >=2.0.0,<6.0, installed: 5.3.1]\r\n │ │ ├── pyasn1-modules [required: >=0.2.1, installed: 0.3.0]\r\n │ │ │ └── pyasn1 [required: >=0.4.6,<0.6.0, installed: 0.5.0]\r\n │ │ ├── rsa [required: >=3.1.4,<5, installed: 4.9]\r\n │ │ │ └── pyasn1 [required: >=0.1.3, installed: 0.5.0]\r\n │ │ └── urllib3 [required: <2.0, installed: 1.26.16]\r\n │ ├── google-auth-oauthlib [required: >=0.5,<1.1, installed: 1.0.0]\r\n │ │ ├── google-auth [required: >=2.15.0, installed: 2.23.0]\r\n │ │ │ ├── cachetools [required: >=2.0.0,<6.0, installed: 5.3.1]\r\n │ │ │ ├── pyasn1-modules [required: >=0.2.1, installed: 0.3.0]\r\n │ │ │ │ └── pyasn1 [required: >=0.4.6,<0.6.0, installed: 0.5.0]\r\n │ │ │ ├── rsa [required: >=3.1.4,<5, installed: 4.9]\r\n │ │ │ │ └── pyasn1 [required: >=0.1.3, installed: 0.5.0]\r\n │ │ │ └── urllib3 [required: <2.0, installed: 1.26.16]\r\n │ │ └── requests-oauthlib [required: >=0.7.0, installed: 1.3.1]\r\n │ │ ├── oauthlib [required: >=3.0.0, installed: 3.2.2]\r\n │ │ └── requests [required: >=2.0.0, installed: 2.31.0]\r\n │ │ ├── certifi [required: >=2017.4.17, installed: 2023.7.22]\r\n │ │ ├── charset-normalizer [required: >=2,<4, installed: 3.2.0]\r\n │ │ ├── idna [required: >=2.5,<4, installed: 3.4]\r\n │ │ └── urllib3 [required: >=1.21.1,<3, installed: 1.26.16]\r\n │ ├── grpcio [required: >=1.48.2, installed: 1.58.0]\r\n │ ├── markdown [required: >=2.6.8, installed: 3.4.4]\r\n │ ├── numpy [required: >=1.12.0, installed: 1.23.5]\r\n │ ├── protobuf [required: >=3.19.6, installed: 3.20.3]\r\n │ ├── requests [required: >=2.21.0,<3, installed: 2.31.0]\r\n │ │ ├── certifi [required: >=2017.4.17, installed: 2023.7.22]\r\n │ │ ├── charset-normalizer [required: >=2,<4, installed: 3.2.0]\r\n │ │ ├── idna [required: >=2.5,<4, installed: 3.4]\r\n │ │ └── urllib3 [required: >=1.21.1,<3, installed: 1.26.16]\r\n │ ├── setuptools [required: >=41.0.0, installed: 68.2.2]\r\n │ ├── tensorboard-data-server [required: >=0.7.0,<0.8.0, installed: 0.7.1]\r\n │ ├── werkzeug [required: >=1.0.1, installed: 2.3.7]\r\n │ │ └── MarkupSafe [required: >=2.1.1, installed: 2.1.3]\r\n │ └── wheel [required: >=0.26, installed: 0.41.2]\r\n ├── tensorflow-estimator [required: >=2.13.0,<2.14, installed: 2.13.0]\r\n ├── termcolor [required: >=1.1.0, installed: 2.3.0]\r\n ├── typing-extensions [required: >=3.6.6,<4.6.0, installed: 4.5.0]\r\n └── wrapt [required: >=1.11.0, installed: 1.15.0]\r\n```", "@nitins17 @debrupf2946 @sushreebarsa ... \r\n\r\n@SuryanarayanaY i don't think this is a problem with `tensorflow-metal` since I'm not using that package. The problem happens when using `tensorflow` -> `tensorflow-macos` packages", "Hi @palminha ,\r\n\r\nOn Arm M1, even if you use command pip install tensorflow the package installed is still Apple's package.Please find the source here.\r\n\r\nhttps://github.com/tensorflow/tensorflow/blob/f841394b1b714c5cc5366536411cf146c8c570df/tensorflow/tools/pip_package/setup.py#L153-L156\r\n\r\nIf you haven't installed tensorflow-metal then you must install it since Mac package needs it to work with GPU as the above code in setup.py installs Apples package automatically if the` platform_system==\"Darwin\" and platform_machine==\"arm64\"` . Please refer to the instructions of Apple metal plugin [here](https://developer.apple.com/metal/tensorflow-plugin/).\r\n\r\nThanks!", "> tensorflow==2.13.0\r\n> └── tensorflow-macos [required: ==2.13.0, installed: 2.13.0]\r\n\r\nHI @SuryanarayanaY, if you check my `pipenv` dependency graph, you can see that I have `tensorflow-macos` and not `tensorflow-metal`. And I don't need to install` tensorflow-metal` to make it work... I know I won't take advantage of GPU, but nevertheless, it can run just with `tensorflow-macos`\r\n\r\n", "Hi @palminha ,\r\n\r\nTensorflow officially supports CPU only wheels which can be installable on Macos with explicit command `pip install tensorflow-macos`.This wheel is mainly intended for Intel Chip machines of Apple.\r\n\r\nAs confirmed in my above comment if you try `pip install tensorflow` and the machine is Darwin and arm64 it will install the Apple GPU package automatically as per my knowledge.With that package you might need tensorflow-metal for sure. This development happened since TF2.12v. However you can cross check the same with Apple team itself regarding whether the package installed is GPU or CPU since these packages or built and installed by Apple itself.\r\n\r\n```\r\n# Install the TensorFlow package built by Apple if the user is running \r\n# macOS on an Apple Silicon machine. \r\n standard_or_nightly('tensorflow-macos', 'tf-nightly-macos') + '==' + \r\n _VERSION + ';platform_system==\"Darwin\" and platform_machine==\"arm64\"', \r\n```\r\n\r\nI request you to take confirmation from Apple dev [forum](https://developer.apple.com/forums/tags/tensorflow-metal/).\r\n\r\nThank you!", "@palminha ,\r\n\r\n**Update**: The issue got fixed in tf-nightly version. Please refer to attached logs below. Kindly note that I have metal-plugin installed so that works fine with GPU support.I am curious to know whether it works for you with CPU only.\r\n\r\n```\r\n(base) suryanarayanay-macbookpro:Downloads suryanarayanay$ python 61915_macos_new_optimzer.py\r\n2.15.0.dev2023092207\r\nWARNING:absl:At this time, the v2.11+ optimizer `tf.keras.optimizers.Adam` runs slowly on M1/M2 Macs, please use the legacy Keras optimizer instead, located at `tf.keras.optimizers.legacy.Adam`.\r\nMetal device set to: Apple M1 Pro\r\n\r\nsystemMemory: 16.00 GB\r\nmaxCacheSize: 5.33 GB\r\n\r\n2023-09-28 14:53:58.925275: I tensorflow/core/common_runtime/pluggable_device/pluggable_device_factory.cc:306] Could not identify NUMA node of platform GPU ID 0, defaulting to 0. Your kernel may not have been built with NUMA support.\r\n2023-09-28 14:53:58.925303: I tensorflow/core/common_runtime/pluggable_device/pluggable_device_factory.cc:272] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 0 MB memory) -> physical PluggableDevice (device: 0, name: METAL, pci bus id: <undefined>)\r\nWARNING:absl:At this time, the v2.11+ optimizer `tf.keras.optimizers.Adam` runs slowly on M1/M2 Macs, please use the legacy Keras optimizer instead, located at `tf.keras.optimizers.legacy.Adam`.\r\nWARNING:absl:Skipping variable loading for optimizer 'Adam', because it has 9 variables whereas the saved optimizer has 1 variables. \r\nEnd of program\r\n(base) suryanarayanay-macbookpro:Downloads suryanarayanay$ \r\n```", "@SuryanarayanaY i just tested with tf-nightly with CPU only version\r\n```\r\n% pipenv graph\r\n...\r\ntf-nightly==2.15.0.dev20230928\r\n└── tf-nightly-macos [required: ==2.15.0-dev20230928, installed: 2.15.0.dev20230928]\r\n```\r\n\r\n\r\nit seems it solves the error\r\n```\r\n% pipenv run adam\r\nWARNING:absl:At this time, the v2.11+ optimizer `tf.keras.optimizers.Adam` runs slowly on M1/M2 Macs, please use the legacy Keras optimizer instead, located at `tf.keras.optimizers.legacy.Adam`.\r\nWARNING:absl:At this time, the v2.11+ optimizer `tf.keras.optimizers.Adam` runs slowly on M1/M2 Macs, please use the legacy Keras optimizer instead, located at `tf.keras.optimizers.legacy.Adam`.\r\nWARNING:absl:Skipping variable loading for optimizer 'Adam', because it has 9 variables whereas the saved optimizer has 1 variables. \r\n```", "@palminha ,\r\n\r\nThanks for confirmation. That means same package works for both. But to enable GPU support on Mac we need to install metal-plugin additionally and that works with GPU support as well.\r\n\r\nCan we mark it as resolved now. Please feel free to close the issue if you don't have further queries on this.\r\n\r\nThank you!\r\n ", "@SuryanarayanaY ... keras team closed the related issue: https://github.com/keras-team/tf-keras/issues/46", "> @ palminha,\r\n> \r\n> For MacOS we need to import optimizers from legacy space like keras.optimizers.legacy.Adam. I tried explicitly replacing the Adam with legacy .Adam and still its not working. Since there is no problem with Linux and Macos package was built and maintained by Apple itself, you need to report the issue at Apple developer forum [here](https://developer.apple.com/forums/tags/tensorflow-metal/).\r\n> \r\n> Meanwhile I will also take it to the attention of concerned engineer.\r\n> \r\n> Thank you!\r\n\r\nInstead of the legacy.Adam, the tf.keras.optimizers.Adam() works well and there is no Error of \r\n\"'Adam' object has no attribute 'build' \". Even though it may impact the running performance. I have not found any obvious performance impact from my personal test project with CNN. I have not had any comparing tests yet. \r\nI ignored the warning while training: \"WARNING:absl:At this time, the v2.11+ optimizer `tf.keras.optimizers.Adam` runs slowly on M1/M2 Macs, please use the legacy Keras optimizer instead, located at `tf.keras.optimizers.legacy.Adam`.\"\r\n\r\nEnvironment: OS: Macos, CPU: M2, Python3: 3.11.5, tensorflow: 2.14.0\r\n", "I have tensorflow 2.14, I use _tf.keras.optimizers.Adam_ but I still have the issue, when I try to load the model with pickle. :-/\r\n\r\nEnvironment: OS: Macos, CPU: M2 Pro, Python 3.9.6, tensorflow: 2.14.0 ", "@gszecsenyi it will be solved in version 2.15", "The issue still exists with 2.15rc1. ", "> @gszecsenyi it will be solved in version 2.15\r\n\r\nThat's true.\r\n`pip install tensorflow-macos==2.15.0`\r\nsolves this error.\r\n\r\nI'm using M2 Max mac.", "@palminha ,\r\n\r\nThe issue fixed with this [PR](https://github.com/keras-team/keras/pull/18492) and it may reflect in TF2.15v onwards. Please feel free to close the issue. If still having any issue please let us know. Thanks!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61915\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61915\">No</a>\n" ]
2023-09-19T13:30:50
2023-11-30T01:49:39
2023-11-30T01:49:24
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source binary ### TensorFlow version v2.13.0-rc2-7-g1cb1a030a62 2.13.0 ### Custom code Yes ### OS platform and distribution MacOS ARM M1 ### Mobile device _No response_ ### Python version 3.10.13 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? When running the code below we get the following error: **_AttributeError: 'Adam' object has no attribute 'build'_** ### Standalone code to reproduce the issue ```shell from tensorflow import keras if __name__ == '__main__': optimizer = keras.optimizers.Adam() vh = keras.Input(shape=(2,3), name = 'vh') v1 = keras.layers.Dense(512)(vh) output = keras.layers.Dense(1, activation='softmax', name='prediction')(v1) model = keras.Model(inputs=vh, outputs=[output], name="antibody_model") model.compile(optimizer=optimizer ) model.save('nn_model.keras') test = keras.models.load_model('nn_model.keras') ``` ### Relevant log output ```shell Traceback (most recent call last): File "/opt/homebrew/Cellar/[email protected]/3.10.13/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/opt/homebrew/Cellar/[email protected]/3.10.13/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/Users/palmito/Development/federated-demo/backend/app/test.py", line 15, in <module> test = keras.models.load_model('nn_model.keras') File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/saving/saving_api.py", line 230, in load_model return saving_lib.load_model( File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/saving/saving_lib.py", line 275, in load_model raise e File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/saving/saving_lib.py", line 240, in load_model model = deserialize_keras_object( File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/saving/serialization_lib.py", line 710, in deserialize_keras_object instance.compile_from_config(compile_config) File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/engine/training.py", line 3582, in compile_from_config self.optimizer.build(self.trainable_variables) File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/optimizers/legacy/optimizer_v2.py", line 997, in __getattribute__ raise e File "/Users/palmito/.local/share/virtualenvs/backend-tPS_SUas/lib/python3.10/site-packages/keras/src/optimizers/legacy/optimizer_v2.py", line 987, in __getattribute__ return super().__getattribute__(name) AttributeError: 'Adam' object has no attribute 'build' ``` ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61915/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61915/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61914
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61914/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61914/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61914/events
https://github.com/tensorflow/tensorflow/pull/61914
1,902,971,710
PR_kwDOArmXAs5arWqu
61,914
[Go] Add RunOptions as an argument for Tensorflow Session Run
{ "login": "yutkin", "id": 2982775, "node_id": "MDQ6VXNlcjI5ODI3NzU=", "avatar_url": "https://avatars.githubusercontent.com/u/2982775?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yutkin", "html_url": "https://github.com/yutkin", "followers_url": "https://api.github.com/users/yutkin/followers", "following_url": "https://api.github.com/users/yutkin/following{/other_user}", "gists_url": "https://api.github.com/users/yutkin/gists{/gist_id}", "starred_url": "https://api.github.com/users/yutkin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yutkin/subscriptions", "organizations_url": "https://api.github.com/users/yutkin/orgs", "repos_url": "https://api.github.com/users/yutkin/repos", "events_url": "https://api.github.com/users/yutkin/events{/privacy}", "received_events_url": "https://api.github.com/users/yutkin/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 1169364458, "node_id": "MDU6TGFiZWwxMTY5MzY0NDU4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S", "name": "size:S", "color": "adafea", "default": false, "description": "CL Change Size: Small" } ]
open
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @rohan100jain, Can you please review this PR ? Thank you!", "Hi @rohan100jain, Can you please review this PR ? Thank you!", "Hi @rohan100jain, Can you please review this PR ? Thank you!", "Hi @rohan100jain, Can you please review this PR ? Thank you!", "Hi @rohan100jain, Can you please review this PR ? Thank you!", "The PR probably needs to be updated because it has been quite a while since its proposal. But anyway, having `RunOptions` for session runs is crucial because it allows specifying a timeout for calls. We used it actively in our project.", "Hi @mihaimaruseac , Can you please review this PR ? Thank you!", "I'll review once it gets updated, if it will", "Hi @yutkin Any update on this PR? Please. Thank you!\r\n" ]
2023-09-19T13:20:10
2024-06-07T16:24:03
null
NONE
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61914", "html_url": "https://github.com/tensorflow/tensorflow/pull/61914", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61914.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61914.patch", "merged_at": null }
Add RunOptions as an argument for Tensorflow Session Run. Another option is adding a method for `Session` struct like `SetRunOptions()`. It will keep the current API the same, however, such method will be not thread-safe.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61914/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61914/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61913
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61913/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61913/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61913/events
https://github.com/tensorflow/tensorflow/pull/61913
1,902,820,761
PR_kwDOArmXAs5aq1bd
61,913
Fix null pointer deref in gif_io.
{ "login": "kobrineli", "id": 75036757, "node_id": "MDQ6VXNlcjc1MDM2NzU3", "avatar_url": "https://avatars.githubusercontent.com/u/75036757?v=4", "gravatar_id": "", "url": "https://api.github.com/users/kobrineli", "html_url": "https://github.com/kobrineli", "followers_url": "https://api.github.com/users/kobrineli/followers", "following_url": "https://api.github.com/users/kobrineli/following{/other_user}", "gists_url": "https://api.github.com/users/kobrineli/gists{/gist_id}", "starred_url": "https://api.github.com/users/kobrineli/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kobrineli/subscriptions", "organizations_url": "https://api.github.com/users/kobrineli/orgs", "repos_url": "https://api.github.com/users/kobrineli/repos", "events_url": "https://api.github.com/users/kobrineli/events{/privacy}", "received_events_url": "https://api.github.com/users/kobrineli/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 703812914, "node_id": "MDU6TGFiZWw3MDM4MTI5MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/kokoro:force-run", "name": "kokoro:force-run", "color": "1d76db", "default": false, "description": "Tests on submitted change" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" }, { "id": 1478826728, "node_id": "MDU6TGFiZWwxNDc4ODI2NzI4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core", "name": "comp:core", "color": "024391", "default": false, "description": "issues related to core part of tensorflow" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "@akuegel \r\nHi! Could you review this PR please?", "> @akuegel Hi! Could you review this PR please?\r\n\r\nI am not familiar with this code. From a quick look, I am not 100% sure whether this is the right fix. Maybe @cantonios can help?", "> I am not 100% sure whether this is the right fix.\r\n\r\nThe other way is to fix `gif` library code, because they increase image counter before buffers allocation, which may lead to such cases. But without fixing `gif` library I think that's the only way.\r\nAnyway, if `gif` returned error while parsing, why shouldn't we return an error as well?", "Hmm, so the reason we try to continue if we have at least one image is that the gif library was failing to parse some non-standard GIF extensions found in some publicly available training datasets, after the image itself was loaded. This was causing training to crash on some common image models.\r\n\r\nBut if the image counter is not reliable (increases without actually successfully parsing an image), then I guess we can't do that anymore.", "@cantonios \r\nI can send the PR to the `gif` library as well to try to fix the logic of increasing image counter before successfully parsing the image.\r\n\r\nBut in the current case yes, we cannot rely on image counter.", "@cantonios \r\nI've added the check for the raster bits buffer of the last image. We need to check only the last one, because if there are more images, then all of the previous images were loaded successfully.\r\nNow I'm working on the PR for gif library.", "@cantonios \r\nI've sent the patch to the gif library: https://sourceforge.net/p/giflib/patches/32/\r\nBut it seems like it wasn't updated since 2019, so I've also attached the patch here to apply it during TF build.\r\nIt fixes the crash", "Reviewing the internal version of this, I see a tidy error:\r\n\r\n```\r\n //tensorflow/core/lib/gif/gif_io.cc:84 ClangTidy: use nullptr\r\n```\r\n\r\nLet's hold on this change until we know if that is blocking submit" ]
2023-09-19T12:01:21
2023-10-05T18:28:27
2023-10-05T18:28:26
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61913", "html_url": "https://github.com/tensorflow/tensorflow/pull/61913", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61913.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61913.patch", "merged_at": "2023-10-05T18:28:26" }
Hi! We've been fuzzing tensorflow and found the error of null pointer dereference at `gif_io.cc:178`. ### Environment OS: ubuntu20.04 TF version: 4601e74cdcd86e6d229ec1d98ff08ba8e147c092 ### Detailed description The error of null pointer occurs, because `RasterBits` buffer at 178 line in `gif_io.cc` occurs to be nullptr. In gif library in `DGifSlurp` function, which is called from `Decode` function of tensorflow core at `gif_io.cc:78`, at `gif/dgif_lib.c:1144` `DGifGetRecordType` function is called, where new element for `SavedImages` buffer is allocated, `RasterBits` field of the corresponding element in buffer is set to `NULL`, and `ImageCount` is increased. After that, before the memory for `RasterBits` is allocated, there is a check in `DGifSlurp` function at `dgif_lib.c:1149` for image sizes to prevent potential overflow. If they are incorrect, `GIF_ERROR` is returned before the allocation of `RasterBits`. In TensorFlow at `gif_io.cc:78` there is a check for the result, which leads to returning `nullptr` only in case `ImageCount <= 0`. But `ImageCount` is incremented in gif library before the allocation of inner buffers, so returning `nullptr` only in case of `ImageCount <= 0` can lead to the following errors of null pointer dereference. To prevent this error, we suggest just to remove this check `ImageCount <= 0` and return `nullptr` in any case when `DGifSlurp` returns `GIF_ERROR`. ### How to reproduce Build Docker container from [here](https://github.com/ispras/oss-sydr-fuzz/tree/master/projects/tensorflow): ```bash $ sudo docker build -t oss-sydr-fuzz-tensorflow . ``` Run container: ```bash sudo docker run --rm -v `pwd`:/fuzz -it oss-sydr-fuzz-tensorflow /bin/bash ``` Run target on the crash input [crash](https://github.com/tensorflow/tensorflow/assets/75036757/34f2f803-b4cc-47d1-a989-1d143838e220): ```bash /fuzzer/decode_png -rss_limit_mb=0 /fuzz/crash ``` You will see the following output: ``` ==1749952==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x0000259030dd bp 0x7fff67a64090 sp 0x7fff67a63640 T254) ==1749952==The signal is caused by a READ memory access. ==1749952==Hint: address points to the zero page. #0 0x259030dd in tensorflow::gif::Decode(void const*, int, std::function<unsigned char* (int, int, int, int)> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool) /proc/self/cwd/tensorflow/core/lib/gif/gif_io.cc:178:13 #1 0x247743ca in tensorflow::(anonymous namespace)::DecodeImageV2Op::DecodeGifV2(tensorflow::OpKernelContext*, std::basic_string_view<char, std::char_traits<char> >) /proc/self/cwd/tensorflow/core/kernels/image/decode_image_op.cc:462:21 #2 0x247743ca in tensorflow::(anonymous namespace)::DecodeImageV2Op::Compute(tensorflow::OpKernelContext*) /proc/self/cwd/tensorflow/core/kernels/image/decode_image_op.cc:216:9 #3 0x48e86ff7 in tensorflow::ThreadPoolDevice::Compute(tensorflow::OpKernel*, tensorflow::OpKernelContext*) /proc/self/cwd/tensorflow/core/common_runtime/threadpool_device.cc:184:14 #4 0x492f72ea in tensorflow::(anonymous namespace)::ExecutorState<tensorflow::SimplePropagatorState>::ProcessSync(tensorflow::NodeItem const&, tensorflow::OpKernelContext::Params*, absl::lts_20230125::InlinedVector<tensorflow::Entry, 4ul, std::allocator<tensorflow::Entry> >*, tensorflow::NodeExecStatsInterface*) /proc/self/cwd/tensorflow/core/common_runtime/executor.cc:604:13 #5 0x492f72ea in tensorflow::(anonymous namespace)::ExecutorState<tensorflow::SimplePropagatorState>::ProcessInline(tensorflow::SimplePropagatorState::TaggedNodeReadyQueue*, long) /proc/self/cwd/tensorflow/core/common_runtime/executor.cc:896:13 #6 0x492eaeaa in tensorflow::(anonymous namespace)::ExecutorState<tensorflow::SimplePropagatorState>::Process(tensorflow::SimplePropagatorState::TaggedNode const&, long) /proc/self/cwd/tensorflow/core/common_runtime/executor.cc:704:10 #7 0x4b57a771 in tsl::thread::EigenEnvironment::ExecuteTask(tsl::thread::EigenEnvironment::Task const&) /proc/self/cwd/tensorflow/tsl/platform/threadpool.cc:94:5 #8 0x4b578c61 in Eigen::ThreadPoolTempl<tsl::thread::EigenEnvironment>::WorkerLoop(int) /proc/self/cwd/external/eigen_archive/Eigen/src/ThreadPool/NonBlockingThreadPool.h:330:16 #9 0x4b576cf6 in tsl::thread::EigenEnvironment::CreateThread(std::function<void ()>)::'lambda'()::operator()() const /proc/self/cwd/tensorflow/tsl/platform/threadpool.cc:71:7 #10 0x4b529b9e in tsl::(anonymous namespace)::PThread::ThreadFn(void*) /proc/self/cwd/tensorflow/tsl/platform/default/env.cc:93:5 #11 0x7ffff7e47608 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x8608) (BuildId: 7b4536f41cdaa5888408e82d0836e33dcf436466) #12 0x7ffff7b63132 in __clone (/lib/x86_64-linux-gnu/libc.so.6+0x11f132) (BuildId: 1878e6b475720c7c51969e69ab2d276fae6d1dee) AddressSanitizer can not provide additional info. SUMMARY: AddressSanitizer: SEGV /proc/self/cwd/tensorflow/core/lib/gif/gif_io.cc:178:13 in tensorflow::gif::Decode(void const*, int, std::function<unsigned char* (int, int, int, int)> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool) Thread T254 created by T0 here: #0 0x18e4d5ac in pthread_create /llvm-project-llvmorg-14.0.6/compiler-rt/lib/asan/asan_interceptors.cpp:208:3 #1 0x4b527904 in tsl::(anonymous namespace)::PThread::PThread(tsl::ThreadOptions const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, absl::lts_20230125::AnyInvocable<void ()>) /proc/self/cwd/tensorflow/tsl/platform/default/env.cc:72:15 #2 0x4b527904 in tsl::(anonymous namespace)::PosixEnv::StartThread(tsl::ThreadOptions const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, absl::lts_20230125::AnyInvocable<void ()>) /proc/self/cwd/tensorflow/tsl/platform/default/env.cc:137:16 #3 0x4b57299f in tsl::thread::EigenEnvironment::CreateThread(std::function<void ()>) /proc/self/cwd/tensorflow/tsl/platform/threadpool.cc:63:18 #4 0x4b56d255 in Eigen::ThreadPoolTempl<tsl::thread::EigenEnvironment>::ThreadPoolTempl(int, bool, tsl::thread::EigenEnvironment) /proc/self/cwd/external/eigen_archive/Eigen/src/ThreadPool/NonBlockingThreadPool.h:60:16 #5 0x4b56be71 in tsl::thread::ThreadPool::ThreadPool(tsl::Env*, tsl::ThreadOptions const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int, bool, Eigen::Allocator*) /proc/self/cwd/tensorflow/tsl/platform/threadpool.cc:116:31 #6 0x491fb8d8 in tensorflow::NewThreadPoolFromSessionOptions(tensorflow::SessionOptions const&, int) /proc/self/cwd/tensorflow/core/common_runtime/process_util.cc:162:14 #7 0x45643d53 in tensorflow::(anonymous namespace)::GlobalThreadPool(tensorflow::SessionOptions const&, int) /proc/self/cwd/tensorflow/core/common_runtime/direct_session.cc:147:7 #8 0x45643d53 in tensorflow::DirectSession::DirectSession(tensorflow::SessionOptions const&, tensorflow::DeviceMgr const*, tensorflow::DirectSessionFactory*) /proc/self/cwd/tensorflow/core/common_runtime/direct_session.cc:358:9 #9 0x45681552 in tensorflow::DirectSessionFactory::NewSession(tensorflow::SessionOptions const&, tensorflow::Session**) /proc/self/cwd/tensorflow/core/common_runtime/direct_session.cc:202:34 #10 0x48e7518c in tensorflow::NewSession(tensorflow::SessionOptions const&, tensorflow::Session**) /proc/self/cwd/tensorflow/core/common_runtime/session.cc:90:16 #11 0x48e74b46 in tensorflow::NewSession(tensorflow::SessionOptions const&) /proc/self/cwd/tensorflow/core/common_runtime/session.cc:70:14 #12 0x18e9c7bc in tensorflow::fuzzing::FuzzSession::InitIfNeeded() /proc/self/cwd/./tensorflow/core/kernels/fuzzing/fuzz_session.h:92:41 #13 0x18e953d4 in tensorflow::fuzzing::FuzzSession::Fuzz(unsigned char const*, unsigned long) /proc/self/cwd/./tensorflow/core/kernels/fuzzing/fuzz_session.h:127:21 #14 0x4c0df4ed in ExecuteFilesOnyByOne /AFLplusplus/utils/aflpp_driver/aflpp_driver.c:255:7 ==1749952==ABORTING ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61913/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61913/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61912
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61912/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61912/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61912/events
https://github.com/tensorflow/tensorflow/issues/61912
1,902,705,826
I_kwDOArmXAs5xaPyi
61,912
Randomization generating repeated sequences with `tf.function`, `tf.random.set_seed` and `tf.cond`
{ "login": "khurram-ghani", "id": 113982802, "node_id": "U_kgDOBss9Ug", "avatar_url": "https://avatars.githubusercontent.com/u/113982802?v=4", "gravatar_id": "", "url": "https://api.github.com/users/khurram-ghani", "html_url": "https://github.com/khurram-ghani", "followers_url": "https://api.github.com/users/khurram-ghani/followers", "following_url": "https://api.github.com/users/khurram-ghani/following{/other_user}", "gists_url": "https://api.github.com/users/khurram-ghani/gists{/gist_id}", "starred_url": "https://api.github.com/users/khurram-ghani/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/khurram-ghani/subscriptions", "organizations_url": "https://api.github.com/users/khurram-ghani/orgs", "repos_url": "https://api.github.com/users/khurram-ghani/repos", "events_url": "https://api.github.com/users/khurram-ghani/events{/privacy}", "received_events_url": "https://api.github.com/users/khurram-ghani/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" } ]
open
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "@sachinprasadhs I was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/a211ca25804786c1c5ac4797b4bdbdc9/61912.ipynb#scrollTo=q5yPK8X8I3N2). Thank you!" ]
2023-09-19T10:48:34
2023-10-19T19:00:41
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version 2.15.0-dev20230919 ### Custom code No ### OS platform and distribution Linux Ubuntu 22.04.2 LTS ### Mobile device _No response_ ### Python version 3.10.12 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? We have encountered an unexpected issue with `tf.function` compilation combined with the global/graph-level seed setting (`tf.random.set_seed`); under some circumstances the random variables are generating identical sequences within the same function. The issue seems to be connected with TensorFlow conditionals (`tf.cond`) within the function, particularly when the branches contain the randomization calls. Removing `tf.cond` results in the generation of unique random values, as expected. We understand the following expected behavior under `tf.function` compilation when a global/graph-level seed is set, as per the [TensorFlow documentation](https://www.tensorflow.org/api_docs/python/tf/random/set_seed): > Note that `tf.function` acts like a re-run of a program in this case. When the global seed is set but operation seeds are not set, the sequence of random numbers are the same for each `tf.function`. However, the problem we are observing arises within a single instance of the function, not across multiple instances. The behavior is as if the internal counters in `tf.random.uniform` get reset when there is a TensorFlow conditional in the graph. Is this expected behavior? To illustrate this issue, the example below presents two scenarios. The first one ("SAD" mode) shows the function producing repeated random sequences when `tf.cond` is present. The second scenario ("HAPPY" mode) shows the function generating unique random values once `tf.cond` is removed. ### Standalone code to reproduce the issue ```shell import tensorflow as tf from pprint import pprint tf.random.set_seed(42) var = tf.Variable(0, dtype=tf.int32) def get_value(happy): if happy: return tf.stack([tf.random.uniform(()) for _ in range(2)]) else: return tf.cond( var == 0, lambda: tf.stack([tf.random.uniform(()) for _ in range(2)]), lambda: tf.stack([tf.random.uniform(()) for _ in range(2)]), ) def randomize(happy): return [get_value(happy) for _ in range(3)] print("SAD") pprint(tf.function(randomize)(False)) print("HAPPY") pprint(tf.function(randomize)(True)) ``` ### Relevant log output ```shell SAD [<tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.8354591 , 0.15012848], dtype=float32)>, <tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.8354591 , 0.15012848], dtype=float32)>, <tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.8354591 , 0.15012848], dtype=float32)>] HAPPY [<tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.8354591 , 0.15012848], dtype=float32)>, <tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.98781276, 0.63789964], dtype=float32)>, <tf.Tensor: shape=(2,), dtype=float32, numpy=array([0.00857747, 0.02621067], dtype=float32)>] ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61912/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61912/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61911
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61911/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61911/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61911/events
https://github.com/tensorflow/tensorflow/issues/61911
1,902,665,668
I_kwDOArmXAs5xaF_E
61,911
`tf.device` context manager does not restore `cudaCurrentDevice` under some conditions
{ "login": "isVoid", "id": 13521008, "node_id": "MDQ6VXNlcjEzNTIxMDA4", "avatar_url": "https://avatars.githubusercontent.com/u/13521008?v=4", "gravatar_id": "", "url": "https://api.github.com/users/isVoid", "html_url": "https://github.com/isVoid", "followers_url": "https://api.github.com/users/isVoid/followers", "following_url": "https://api.github.com/users/isVoid/following{/other_user}", "gists_url": "https://api.github.com/users/isVoid/gists{/gist_id}", "starred_url": "https://api.github.com/users/isVoid/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/isVoid/subscriptions", "organizations_url": "https://api.github.com/users/isVoid/orgs", "repos_url": "https://api.github.com/users/isVoid/repos", "events_url": "https://api.github.com/users/isVoid/events{/privacy}", "received_events_url": "https://api.github.com/users/isVoid/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 1097547538, "node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu", "name": "comp:gpu", "color": "0052cc", "default": false, "description": "GPU related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "cantonios", "id": 2538739, "node_id": "MDQ6VXNlcjI1Mzg3Mzk=", "avatar_url": "https://avatars.githubusercontent.com/u/2538739?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cantonios", "html_url": "https://github.com/cantonios", "followers_url": "https://api.github.com/users/cantonios/followers", "following_url": "https://api.github.com/users/cantonios/following{/other_user}", "gists_url": "https://api.github.com/users/cantonios/gists{/gist_id}", "starred_url": "https://api.github.com/users/cantonios/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cantonios/subscriptions", "organizations_url": "https://api.github.com/users/cantonios/orgs", "repos_url": "https://api.github.com/users/cantonios/repos", "events_url": "https://api.github.com/users/cantonios/events{/privacy}", "received_events_url": "https://api.github.com/users/cantonios/received_events", "type": "User", "site_admin": false }
[ { "login": "cantonios", "id": 2538739, "node_id": "MDQ6VXNlcjI1Mzg3Mzk=", "avatar_url": "https://avatars.githubusercontent.com/u/2538739?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cantonios", "html_url": "https://github.com/cantonios", "followers_url": "https://api.github.com/users/cantonios/followers", "following_url": "https://api.github.com/users/cantonios/following{/other_user}", "gists_url": "https://api.github.com/users/cantonios/gists{/gist_id}", "starred_url": "https://api.github.com/users/cantonios/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cantonios/subscriptions", "organizations_url": "https://api.github.com/users/cantonios/orgs", "repos_url": "https://api.github.com/users/cantonios/repos", "events_url": "https://api.github.com/users/cantonios/events{/privacy}", "received_events_url": "https://api.github.com/users/cantonios/received_events", "type": "User", "site_admin": false }, { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-19T10:21:44
2023-10-17T23:54:00
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source binary ### TensorFlow version 2.13 ### Custom code No ### OS platform and distribution Linux Ubuntu 20.04.5 LTS ### Mobile device _No response_ ### Python version 3.10 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version 12.0 ### GPU model and memory _No response_ ### Current behavior? When using `tf.device` context manager, the current device of cuda runtime remains "dirty" even after exiting the context manager. This happens when: 1. tensorflow is initializing GPU context on this line (tf.device), 2. there is no materialization of tensors on GPU. For context, keeping a clean state of current device context is important to keep tensorflow in sync with other GPU based libraries such as [cuDF](github.com/rapidsai/cuDF). [RMM](github.com/rapidsai/rmm) memory allocators also depends on the assumption that the context stays the same throughout the lifetime of allocations. ### Standalone code to reproduce the issue ```shell https://gist.github.com/isVoid/9eded87fca35e86a2c2dc85f603383c2 ``` ### Relevant log output ```shell # Log output of the first cell. The second and third current device context should be 0. (<cudaError_t.cudaSuccess: 0>, 0) (<cudaError_t.cudaSuccess: 0>, 7) (<cudaError_t.cudaSuccess: 0>, 7) (<cudaError_t.cudaSuccess: 0>, 0) ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61911/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61911/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61910
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61910/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61910/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61910/events
https://github.com/tensorflow/tensorflow/pull/61910
1,902,601,474
PR_kwDOArmXAs5aqGv7
61,910
Update oneDNN to v3.2.1 for aarch64
{ "login": "fadara01", "id": 115173828, "node_id": "U_kgDOBt1pxA", "avatar_url": "https://avatars.githubusercontent.com/u/115173828?v=4", "gravatar_id": "", "url": "https://api.github.com/users/fadara01", "html_url": "https://github.com/fadara01", "followers_url": "https://api.github.com/users/fadara01/followers", "following_url": "https://api.github.com/users/fadara01/following{/other_user}", "gists_url": "https://api.github.com/users/fadara01/gists{/gist_id}", "starred_url": "https://api.github.com/users/fadara01/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fadara01/subscriptions", "organizations_url": "https://api.github.com/users/fadara01/orgs", "repos_url": "https://api.github.com/users/fadara01/repos", "events_url": "https://api.github.com/users/fadara01/events{/privacy}", "received_events_url": "https://api.github.com/users/fadara01/received_events", "type": "User", "site_admin": false }
[ { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1104829434, "node_id": "MDU6TGFiZWwxMTA0ODI5NDM0", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl", "name": "comp:mkl", "color": "0052cc", "default": false, "description": "MKL related issues" }, { "id": 1173072136, "node_id": "MDU6TGFiZWwxMTczMDcyMTM2", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XL", "name": "size:XL", "color": "adafea", "default": false, "description": "CL Change Size:Extra Large" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "@penpornk, @agramesh1 - this PR brings oneDNN up to v3.2.1 on Arm (as well as addressing an issue with bf16 reorders). ", "ARM CI has [some errors](https://github.com/tensorflow/tensorflow/actions/runs/6238555960/job/16942390897#step:5:325). Could you please help fix them? Thank you!\r\n\r\n```\r\nRROR: An error occurred during the fetch of repository 'mkl_dnn_acl_compatible':\r\n Traceback (most recent call last):\r\n\tFile \"/workspace/third_party/repo.bzl\", line 83, column 30, in _tf_http_archive_impl\r\n\t\tctx.patch(patch_file, strip = 1)\r\nError in patch: Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nERROR: /workspace/WORKSPACE:80:14: fetching _tf_http_archive rule //external:mkl_dnn_acl_compatible: Traceback (most recent call last):\r\n\tFile \"/workspace/third_party/repo.bzl\", line 83, column 30, in _tf_http_archive_impl\r\n\t\tctx.patch(patch_file, strip = 1)\r\nError in patch: Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nAnalyzing: 2137 targets (1024 packages loaded, 37578 targets configured)\r\nERROR: /tmpfs/bazel_output/_bazel_ubuntu/eab0d61a99b6696edb3d2aff87b585e8/external/local_xla/xla/service/cpu/BUILD:1006:11: @local_xla//xla/service/cpu:runtime_conv2d_mkl depends on @mkl_dnn_acl_compatible//:mkl_dnn_acl in repository @mkl_dnn_acl_compatible which failed to fetch. no such package '@mkl_dnn_acl_compatible//': Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nERROR: /tmpfs/bazel_output/_bazel_ubuntu/eab0d61a99b6696edb3d2aff87b585e8/external/local_xla/xla/service/cpu/BUILD:1649:11: @local_xla//xla/service/cpu:onednn_memory_util depends on @mkl_dnn_acl_compatible//:mkl_dnn_acl in repository @mkl_dnn_acl_compatible which failed to fetch. no such package '@mkl_dnn_acl_compatible//': Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nERROR: /tmpfs/bazel_output/_bazel_ubuntu/eab0d61a99b6696edb3d2aff87b585e8/external/local_xla/xla/service/cpu/BUILD:1701:11: @local_xla//xla/service/cpu:onednn_rewriter depends on @mkl_dnn_acl_compatible//:mkl_dnn_acl in repository @mkl_dnn_acl_compatible which failed to fetch. no such package '@mkl_dnn_acl_compatible//': Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nERROR: /tmpfs/bazel_output/_bazel_ubuntu/eab0d61a99b6696edb3d2aff87b585e8/external/local_xla/xla/service/cpu/BUILD:1678:11: @local_xla//xla/service/cpu:onednn_matmul depends on @mkl_dnn_acl_compatible//:mkl_dnn_acl in repository @mkl_dnn_acl_compatible which failed to fetch. no such package '@mkl_dnn_acl_compatible//': Error applying patch /workspace/third_party/mkl_dnn/onednn_acl_bf16_capability_detection_for_ubuntu20.04.patch: Expecting more chunk line at line 50\r\nAnalyzing: 2137 targets (1054 packages loaded, 43809 targets configured)\r\n...\r\n```\r\n", "Thanks for raising that to us! The error is because a patch file couldn't be applied as it was missing a newline at the end.\r\nI fixed that, and hopefully build will be fine now", "Sorry for the internal problems, @penpornk - this PR should be importing correctly now." ]
2023-09-19T09:45:15
2023-09-22T10:50:32
2023-09-22T10:50:32
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61910", "html_url": "https://github.com/tensorflow/tensorflow/pull/61910", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61910.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61910.patch", "merged_at": "2023-09-22T10:50:32" }
29abb6ac7121bed646f3cd832511372626e7916c updates oneDNN to v3.2.1 for aarch64 and adds a patch to oneDNN to support FP32-BF16 Jit reorders. 35b2669fbe540c812764d1ed7185c0c428ceca03 adds a patch to oneDNN for BF16 capability detection for Ubuntu 20.04 on aarch64. The contents in the patch are fully authored by @kawakami-k. The source used for this patch is available here: oneapi-src/oneDNN#1670
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61910/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61910/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61909
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61909/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61909/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61909/events
https://github.com/tensorflow/tensorflow/issues/61909
1,902,545,545
I_kwDOArmXAs5xZoqJ
61,909
Training Vanilla Transformer on TPU gives InternalError
{ "login": "h4ck4l1", "id": 105937725, "node_id": "U_kgDOBlB7PQ", "avatar_url": "https://avatars.githubusercontent.com/u/105937725?v=4", "gravatar_id": "", "url": "https://api.github.com/users/h4ck4l1", "html_url": "https://github.com/h4ck4l1", "followers_url": "https://api.github.com/users/h4ck4l1/followers", "following_url": "https://api.github.com/users/h4ck4l1/following{/other_user}", "gists_url": "https://api.github.com/users/h4ck4l1/gists{/gist_id}", "starred_url": "https://api.github.com/users/h4ck4l1/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/h4ck4l1/subscriptions", "organizations_url": "https://api.github.com/users/h4ck4l1/orgs", "repos_url": "https://api.github.com/users/h4ck4l1/repos", "events_url": "https://api.github.com/users/h4ck4l1/events{/privacy}", "received_events_url": "https://api.github.com/users/h4ck4l1/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097541661, "node_id": "MDU6TGFiZWwxMDk3NTQxNjYx", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tpus", "name": "comp:tpus", "color": "0052cc", "default": false, "description": "tpu, tpuestimator" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @h4ck4l1 ,\r\n\r\nFor TPU strategy there is one sharp edge mentioned below.\r\n\r\n> To run TF2 programs on TPUs, you can either use .compile and .fit APIs in [tf.keras](https://www.tensorflow.org/api_docs/python/tf/keras) with TPUStrategy, or write your own customized training loop by calling strategy.run directly. Note that TPUStrategy doesn't support pure eager execution, so please make sure the function passed into strategy.run is a [tf.function](https://www.tensorflow.org/api_docs/python/tf/function) or strategy.run is called inside a [tf.function](https://www.tensorflow.org/api_docs/python/tf/function) if eager behavior is enabled.\r\n\r\nFrom the error log in your attached gist the error is generated from [capture_container.capture_by_value()](https://github.com/tensorflow/tensorflow/blob/ab6bbb417f5e336f5f0f4164ade5ac0c7555874c/tensorflow/core/function/capture/capture_container.py#L88).This function will be called to capture `tensor` if it's external to the graph.\r\n\r\nWith the above note can you try using `tf.function` decorator for the functions that are defined outside strategy.run and let us know the outcome.\r\n\r\nAlso I am interested to know why GPU logical device has been created in the failing code.\r\n\r\nThanks!", "Thanks for responding @SuryanarayanaY !.\r\nI will try your suggestion and will get back to you. Can you show me where GPU logical device was created? I can't find it in the error message, I wish to rectify any redundancies in my code if any present. \r\nQ)There are some functions that I am using right now before the strategy.scope() declaration, like to get datasets, to get model...should i decorate everything with @tf.function? or only some specific funcitons?.\r\nAlso my extra naive question\r\nQ)Do I require the use the authentication for me to use TPU's? like we do the auth.authenticate_user() right?\r\n \r\nI tried your suggestion but i got a new error \r\n```\r\n---------------------------------------------------------------------------\r\nInvalidArgumentError Traceback (most recent call last)\r\n[<ipython-input-16-5bd16261e9ac>](https://localhost:8080/#) in <cell line: 1>()\r\n----> 1 model.fit(train_ds,validation_data=valid_ds,epochs=10)\r\n\r\n1 frames\r\n[/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py](https://localhost:8080/#) in error_handler(*args, **kwargs)\r\n 68 # To get the full stack trace, call:\r\n 69 # `tf.debugging.disable_traceback_filtering()`\r\n---> 70 raise e.with_traceback(filtered_tb) from None\r\n 71 finally:\r\n 72 del filtered_tb\r\n\r\n[/usr/local/lib/python3.10/dist-packages/tensorflow/python/framework/ops.py](https://localhost:8080/#) in _numpy(self)\r\n 1107 return self._numpy_internal()\r\n 1108 except core._NotOkStatusException as e: # pylint: disable=protected-access\r\n-> 1109 raise core._status_to_exception(e) from None # pylint: disable=protected-access\r\n 1110 \r\n 1111 @property\r\n\r\nInvalidArgumentError: Unable to parse tensor proto\r\n```\r\n\r\nPlease do take a look at the [notebook](https://colab.research.google.com/drive/1lUYapbE1XfLVy7Sc7Xy5oBi-CeBaTRn4#scrollTo=HuUDtZTpOo1Q) maybe it might give an idea?.\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n", "I would like to add additional data. I am not using gcs for anything here, like in past I had done \r\n[Notebook with just tensors as input](https://colab.research.google.com/drive/1ii0D2GokcdgxZVjB7oHKy0Lt-I8Ykuin)\r\n[Notebook with tfds datasets as input](https://colab.research.google.com/drive/1DJU058LhhyCfNsuHZ74kZ0E2ziHw-VYo)\r\nboth use tpu to train and i got no problem in training them, but this time its slight different its neither tensors nor tfds datasets its custom data pipeline, maybe that is problem(?) but does that mean we can't train custom pipelines on tpu(?)", "Nevermind after i converted it into tensors it started working again", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61909\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61909\">No</a>\n" ]
2023-09-19T09:12:56
2023-09-20T15:56:59
2023-09-20T15:56:56
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution Linux Ubuntu 22.04.2 (Google Colab) ### Mobile device Colab ### Python version 3.10.12 ### Bazel version Colab ### GCC/compiler version Colab ### CUDA/cuDNN version Colab ### GPU model and memory Colab ### Current behavior? Training Transformer model on TPU gives Internal Error I have some idea on the error that there's a incompatible tensor ops thats causing the problem but i can't pinpoint it. I had already done a bigger model which is using pretrained embeddings and it went off without a hitch i tried to replicate the same but with different tfds dataset If this is already solved please direct me to the relevant links ### Standalone code to reproduce the issue ``` [This is the notebook](https://colab.research.google.com/drive/1y3VEuaYXnsoB42TaVd8UBB-18U8UHFBt#scrollTo=Y0hKZ9yRC3FU) [This notebook worked fine](https://colab.research.google.com/drive/1DJU058LhhyCfNsuHZ74kZ0E2ziHw-VYo) Thankyou in advance. I will respond asap ``` ### Relevant log output ```shell --------------------------------------------------------------------------- InternalError Traceback (most recent call last) [<ipython-input-12-013fa12d9e3a>](https://localhost:8080/#) in <cell line: 1>() ----> 1 model.fit( 2 train_ds, 3 validation_data=valid_ds, 4 epochs=EPOCHS, 5 steps_per_epoch=train_steps, 1 frames [/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py](https://localhost:8080/#) in error_handler(*args, **kwargs) 68 # To get the full stack trace, call: 69 # `tf.debugging.disable_traceback_filtering()` ---> 70 raise e.with_traceback(filtered_tb) from None 71 finally: 72 del filtered_tb [/usr/local/lib/python3.10/dist-packages/tensorflow/core/function/capture/capture_container.py](https://localhost:8080/#) in capture_by_value(self, graph, tensor, name) 120 graph_const = self.by_val_internal.get(id(tensor)) 121 if graph_const is None: --> 122 graph_const = tensor._capture_as_const(name) # pylint: disable=protected-access 123 if graph_const is None: 124 # Some eager tensors, e.g. parallel tensors, are not convertible to InternalError: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:35437: Failed to connect to remote host: Connection refused Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0: :UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:35437: Failed to connect to remote host: Connection refused {created_time:"2023-09-19T08:56:09.694479753+00:00", grpc_status:14} Executing non-communication op <MultiDeviceIteratorInit> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic. ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61909/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61909/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61908
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61908/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61908/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61908/events
https://github.com/tensorflow/tensorflow/issues/61908
1,902,363,247
I_kwDOArmXAs5xY8Jv
61,908
bad_alloc
{ "login": "SiriusHsh", "id": 20510239, "node_id": "MDQ6VXNlcjIwNTEwMjM5", "avatar_url": "https://avatars.githubusercontent.com/u/20510239?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SiriusHsh", "html_url": "https://github.com/SiriusHsh", "followers_url": "https://api.github.com/users/SiriusHsh/followers", "following_url": "https://api.github.com/users/SiriusHsh/following{/other_user}", "gists_url": "https://api.github.com/users/SiriusHsh/gists{/gist_id}", "starred_url": "https://api.github.com/users/SiriusHsh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SiriusHsh/subscriptions", "organizations_url": "https://api.github.com/users/SiriusHsh/orgs", "repos_url": "https://api.github.com/users/SiriusHsh/repos", "events_url": "https://api.github.com/users/SiriusHsh/events{/privacy}", "received_events_url": "https://api.github.com/users/SiriusHsh/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" } ]
closed
false
{ "login": "alankelly", "id": 5112267, "node_id": "MDQ6VXNlcjUxMTIyNjc=", "avatar_url": "https://avatars.githubusercontent.com/u/5112267?v=4", "gravatar_id": "", "url": "https://api.github.com/users/alankelly", "html_url": "https://github.com/alankelly", "followers_url": "https://api.github.com/users/alankelly/followers", "following_url": "https://api.github.com/users/alankelly/following{/other_user}", "gists_url": "https://api.github.com/users/alankelly/gists{/gist_id}", "starred_url": "https://api.github.com/users/alankelly/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alankelly/subscriptions", "organizations_url": "https://api.github.com/users/alankelly/orgs", "repos_url": "https://api.github.com/users/alankelly/repos", "events_url": "https://api.github.com/users/alankelly/events{/privacy}", "received_events_url": "https://api.github.com/users/alankelly/received_events", "type": "User", "site_admin": false }
[ { "login": "alankelly", "id": 5112267, "node_id": "MDQ6VXNlcjUxMTIyNjc=", "avatar_url": "https://avatars.githubusercontent.com/u/5112267?v=4", "gravatar_id": "", "url": "https://api.github.com/users/alankelly", "html_url": "https://github.com/alankelly", "followers_url": "https://api.github.com/users/alankelly/followers", "following_url": "https://api.github.com/users/alankelly/following{/other_user}", "gists_url": "https://api.github.com/users/alankelly/gists{/gist_id}", "starred_url": "https://api.github.com/users/alankelly/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alankelly/subscriptions", "organizations_url": "https://api.github.com/users/alankelly/orgs", "repos_url": "https://api.github.com/users/alankelly/repos", "events_url": "https://api.github.com/users/alankelly/events{/privacy}", "received_events_url": "https://api.github.com/users/alankelly/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @SiriusHsh, I am unable to replicate your issue in master or 2.14, or with gcc or clang (to build benchmark_model), I keep getting this error with your uploaded model, which seems reasonable given the invalid nature of your model:\r\n\r\n```sh\r\n./benchmark_model --graph=malloc_large_1.tflite\r\n2023-09-19 22:11:56.591754: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [malloc_large_1.tflite]\r\n2023-09-19 22:11:56.591838: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n2023-09-19 22:11:56.591849: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n2023-09-19 22:11:56.591858: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n2023-09-19 22:11:56.591865: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n2023-09-19 22:11:56.591874: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n2023-09-19 22:11:56.591892: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n2023-09-19 22:11:56.591905: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n2023-09-19 22:11:56.591928: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n2023-09-19 22:11:56.591948: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n2023-09-19 22:11:56.591964: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n2023-09-19 22:11:56.591973: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n2023-09-19 22:11:56.591980: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n2023-09-19 22:11:56.591987: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n2023-09-19 22:11:56.591994: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n2023-09-19 22:11:56.592010: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n2023-09-19 22:11:56.592036: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n2023-09-19 22:11:56.592131: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Interpreting non ascii codepoint 148.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n2023-09-19 22:11:56.602256: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse malloc_large_1.tflite as text proto\r\n2023-09-19 22:11:56.602315: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.010285s\r\n\r\n```\r\n\r\nCan you ensure your bazel is updated, additionally can you make sure you rebuild benchmark_model with the latest code?\r\n\r\nThanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61908\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61908\">No</a>\n", "> Hi @SiriusHsh, I am unable to replicate your issue in master or 2.14, or with gcc or clang (to build benchmark_model), I keep getting this error with your uploaded model, which seems reasonable given the invalid nature of your model:\r\n> \r\n> ```shell\r\n> ./benchmark_model --graph=malloc_large_1.tflite\r\n> 2023-09-19 22:11:56.591754: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [malloc_large_1.tflite]\r\n> 2023-09-19 22:11:56.591838: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n> 2023-09-19 22:11:56.591849: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n> 2023-09-19 22:11:56.591858: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n> 2023-09-19 22:11:56.591865: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n> 2023-09-19 22:11:56.591874: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n> 2023-09-19 22:11:56.591892: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n> 2023-09-19 22:11:56.591905: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n> 2023-09-19 22:11:56.591928: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n> 2023-09-19 22:11:56.591948: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n> 2023-09-19 22:11:56.591964: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n> 2023-09-19 22:11:56.591973: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n> 2023-09-19 22:11:56.591980: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n> 2023-09-19 22:11:56.591987: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n> 2023-09-19 22:11:56.591994: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n> 2023-09-19 22:11:56.592010: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n> 2023-09-19 22:11:56.592036: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n> 2023-09-19 22:11:56.592131: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\n> To enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Interpreting non ascii codepoint 148.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n> 2023-09-19 22:11:56.602256: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse malloc_large_1.tflite as text proto\r\n> 2023-09-19 22:11:56.602315: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.010285s\r\n> ```\r\n> \r\n> Can you ensure your bazel is updated, additionally can you make sure you rebuild benchmark_model with the latest code?\r\n> \r\n> Thanks.\r\n\r\nI'm sorry for the delayed response. I don't think it's a Bazel version issue. It's possible that the way I'm building differs from yours.\r\n\r\nI'm using the build method recommended in [this official guide](https://www.tensorflow.org/lite/guide/build_cmake#step_1_install_cmake_tool), as follows:\r\n1. git clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\n2. mkdir tflite_build\r\ncd tflite_build\r\n3. cmake ../tensorflow_src/tensorflow/lite\r\n4. cmake --build . -j\r\n5. cmake --build . -j -t benchmark_model\r\n\r\nThe benchmark is in the tools directory\r\nI still encounter the same issue in the latest code, commit id: abbbcb50208cf6d5a965b7bf60efec5bb078e142.", "I was able to replicate with those steps:\r\n\r\n```bash\r\ngit clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\nmkdir tflite_build\r\ncd tflite_build\r\ncmake ../tensorflow_src/tensorflow/lite\r\ncmake --build . -j\r\ncmake --build . -j -t benchmark_model\r\ncd tools/benchmark\r\ncp path/to/malloc_large_1.tflite .\r\n./benchmark_model --graph=malloc_large_1.tflite\r\n```\r\n\r\n```\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [malloc_large_1.tflite]\r\nINFO: Loaded model malloc_large_1.tflite\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\nterminate called after throwing an instance of 'std::bad_alloc'\r\n what(): std::bad_alloc\r\nAborted\r\n```\r\n\r\nHi @alankelly, can you please take a look? Thanks.", "Not having a security background, I will ask the naive question. You try to allocate more memory than the system has. The allocation fails and the program terminates. What's the issue? Why should I be concerned? What should the behaviour be? ", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61908\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61908\">No</a>\n" ]
2023-09-19T07:20:18
2023-12-12T01:50:00
2023-12-12T01:49:57
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.14.0 ### Custom code Yes ### OS platform and distribution Ubuntu 18.04.6 ### Mobile device _No response_ ### Python version Python 3.8.3 ### Bazel version bazel 5.3.0 ### GCC/compiler version gcc 7.5.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? When allocating memory, since the value of `required_size` is determined by the model parameters, a maliciously constructed model may cause memory allocation to fail, leading to a DOS. ``` // simple_memory_arena.cc TfLiteStatus SimpleMemoryArena::Commit(TfLiteContext* context, bool* arena_reallocated) { size_t required_size = RequiredBufferSize(); if (required_size > underlying_buffer_size_) { *arena_reallocated = true; #ifdef TF_LITE_TENSORFLOW_PROFILER PauseHeapMonitoring(/*pause=*/true); OnTfLiteArenaAlloc(subgraph_index_, reinterpret_cast<std::uintptr_t>(this), required_size); #endif char* new_alloc = new char[required_size]; // here char* new_underlying_buffer_aligned_ptr = reinterpret_cast<char*>( AlignTo(arena_alignment_, reinterpret_cast<intptr_t>(new_alloc))); ``` Construct a malicious model with a shape size of `0x640000000 * 0x13 * 0x13 * 0x60`, ultimately resulting in size being an extremely large value. ``` //simple_memory_arena.cc TfLiteStatus SimpleMemoryArena::Allocate( TfLiteContext* context, size_t alignment, size_t size, int32_t tensor, int32_t first_node, int32_t last_node, ArenaAllocWithUsageInterval* new_alloc) { ... // Update the required buffer size. high_water_mark_ = std::max(high_water_mark_, best_offset + size); // size can be externally controlled. ``` [malloc_large_1.zip](https://github.com/tensorflow/tensorflow/files/12656923/malloc_large_1.zip) ### Standalone code to reproduce the issue ```shell When I use the benchmark tool for PoC validation, it causes the TensorFlow Lite inference process to be subjected to a DOS(coredump). ❯ ./benchmark_model --graph=../poc/malloc_large_1.tflite INFO: STARTING! INFO: Log parameter values verbosely: [0] INFO: Graph: [../poc/malloc_large_1.tflite] INFO: Loaded model ../poc/malloc_large_1.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc [1] 13318 abort (core dumped) ./benchmark_model --graph=../poc/malloc_large_1.tflite ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61908/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61908/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61907
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61907/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61907/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61907/events
https://github.com/tensorflow/tensorflow/issues/61907
1,902,237,369
I_kwDOArmXAs5xYda5
61,907
tf.linalg.cholesky fails on half precision
{ "login": "drewshark", "id": 128925028, "node_id": "U_kgDOB689ZA", "avatar_url": "https://avatars.githubusercontent.com/u/128925028?v=4", "gravatar_id": "", "url": "https://api.github.com/users/drewshark", "html_url": "https://github.com/drewshark", "followers_url": "https://api.github.com/users/drewshark/followers", "following_url": "https://api.github.com/users/drewshark/following{/other_user}", "gists_url": "https://api.github.com/users/drewshark/gists{/gist_id}", "starred_url": "https://api.github.com/users/drewshark/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/drewshark/subscriptions", "organizations_url": "https://api.github.com/users/drewshark/orgs", "repos_url": "https://api.github.com/users/drewshark/repos", "events_url": "https://api.github.com/users/drewshark/events{/privacy}", "received_events_url": "https://api.github.com/users/drewshark/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Same issue applies for tf.linalg.det and tf.linalg.slogdet. If it is a documentation bug, can you kindly fix them?", "Hi @drewshark ,\r\n\r\nThanks for reporting. I have replicated the reported error and its due to lack of kernel implementation with `half` dtype for the Op `Cholesky`. We will work on it and let you know updates.\r\n\r\nThanks!" ]
2023-09-19T05:37:10
2023-09-25T14:48:24
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Following the documentation: https://www.tensorflow.org/api_docs/python/tf/linalg/cholesky, tf.linalg.cholesky is expected to accept tensor in half precision but it fails. ### Standalone code to reproduce the issue ```shell import tensorflow as tf import numpy as np np.random.seed(2023) # {'input_ndims': 2} input = tf.constant(np.random.rand(3,3), dtype='half') out = tf.linalg.cholesky(input) ``` ``` ### Relevant log output ```shell /usr/local/lib/python3.10/dist-packages/tensorflow/python/framework/ops.py in raise_from_not_ok_status(e, name) 6654 def raise_from_not_ok_status(e, name): 6655 e.message += (" name: " + str(name if name is not None else "")) -> 6656 raise core._status_to_exception(e) from None # pylint: disable=protected-access 6657 6658 NotFoundError: Could not find device for node: {{node Cholesky}} = Cholesky[T=DT_HALF] All kernels registered for op Cholesky: device='XLA_CPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_COMPLEX64, DT_COMPLEX128, DT_HALF] device='XLA_GPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_COMPLEX64, DT_COMPLEX128, DT_HALF] device='GPU'; T in [DT_COMPLEX128] device='GPU'; T in [DT_COMPLEX64] device='GPU'; T in [DT_DOUBLE] device='GPU'; T in [DT_FLOAT] device='CPU'; T in [DT_COMPLEX128] device='CPU'; T in [DT_COMPLEX64] device='CPU'; T in [DT_DOUBLE] device='CPU'; T in [DT_FLOAT] [Op:Cholesky] name: ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61907/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61907/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61906
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61906/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61906/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61906/events
https://github.com/tensorflow/tensorflow/issues/61906
1,902,159,616
I_kwDOArmXAs5xYKcA
61,906
How to compile tflite-runtime to include gpu part?
{ "login": "kuangzy2011", "id": 38204055, "node_id": "MDQ6VXNlcjM4MjA0MDU1", "avatar_url": "https://avatars.githubusercontent.com/u/38204055?v=4", "gravatar_id": "", "url": "https://api.github.com/users/kuangzy2011", "html_url": "https://github.com/kuangzy2011", "followers_url": "https://api.github.com/users/kuangzy2011/followers", "following_url": "https://api.github.com/users/kuangzy2011/following{/other_user}", "gists_url": "https://api.github.com/users/kuangzy2011/gists{/gist_id}", "starred_url": "https://api.github.com/users/kuangzy2011/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kuangzy2011/subscriptions", "organizations_url": "https://api.github.com/users/kuangzy2011/orgs", "repos_url": "https://api.github.com/users/kuangzy2011/repos", "events_url": "https://api.github.com/users/kuangzy2011/events{/privacy}", "received_events_url": "https://api.github.com/users/kuangzy2011/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @kuangzy2011 \r\n\r\nThe tflite-runtime is primarly developed for the embedded devices based on Linux which come with minimal storage and computations constraint. I don't think we can compile the tflite-runtime uisng gpu as far as I know.\r\n\r\nTo use the GPU backend using the TFLite delegate APIs on Android and iOS we might need use full TF package similar to Select TF Ops.\r\n\r\nCheck these [instructions](https://developers.google.com/mediapipe/framework/getting_started/gpu_support#opengl_es_setup_on_linux_desktop) that may help setting up the gpu support on Linux desktop machines.\r\n\r\nThanks.\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61906\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61906\">No</a>\n" ]
2023-09-19T03:53:36
2023-10-07T01:47:26
2023-10-07T01:47:23
NONE
null
null
null
**System information** - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 22.04.2 LTS - TensorFlow installed from (source or binary): source - TensorFlow version (or github SHA if from source): 2.13 **Provide the text output from tflite_convert** ``` SUBCOMMAND: # @XNNPACK//:operators [action 'Compiling src/operators/convolution-nchw.c', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections -MD -MF bazel-out/k8-opt/bin/external/XNNPACK/_objs/operators/convolution-nchw.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/XNNPACK/_objs/operators/convolution-nchw.pic.o' -fPIC '-DXNN_IGNORED_PLATFORM_JIT=0' '-DXNN_LOG_LEVEL=0' -DPTHREADPOOL_NO_DEPRECATED_API '-DXNN_ENABLE_GEMM_M_SPECIALIZATION=1' '-DXNN_ENABLE_JIT=0' '-DXNN_ENABLE_ARM_FP16_SCALAR=0' '-DXNN_ENABLE_ARM_FP16_VECTOR=0' '-DXNN_ENABLE_ARM_BF16=0' '-DXNN_ENABLE_ARM_DOTPROD=0' '-DXNN_ENABLE_ASSEMBLY=1' '-DXNN_ENABLE_DWCONV_MULTIPASS=0' -iquote external/XNNPACK -iquote bazel-out/k8-opt/bin/external/XNNPACK -iquote external/pthreadpool -iquote bazel-out/k8-opt/bin/external/pthreadpool -iquote external/FXdiv -iquote bazel-out/k8-opt/bin/external/FXdiv -iquote external/FP16 -iquote bazel-out/k8-opt/bin/external/FP16 -iquote external/cpuinfo -iquote bazel-out/k8-opt/bin/external/cpuinfo -Ibazel-out/k8-opt/bin/external/pthreadpool/_virtual_includes/pthreadpool -Ibazel-out/k8-opt/bin/external/FXdiv/_virtual_includes/FXdiv -Ibazel-out/k8-opt/bin/external/FP16/_virtual_includes/FP16 -Ibazel-out/k8-opt/bin/external/cpuinfo/_virtual_includes/cpuinfo -isystem external/XNNPACK/include -isystem bazel-out/k8-opt/bin/external/XNNPACK/include -isystem external/XNNPACK/src -isystem bazel-out/k8-opt/bin/external/XNNPACK/src -isystem external/pthreadpool/include -isystem bazel-out/k8-opt/bin/external/pthreadpool/include -isystem external/FXdiv/include -isystem bazel-out/k8-opt/bin/external/FXdiv/include -isystem external/FP16/include -isystem bazel-out/k8-opt/bin/external/FP16/include -isystem external/cpuinfo/include -isystem bazel-out/k8-opt/bin/external/cpuinfo/include -isystem external/cpuinfo/src -isystem bazel-out/k8-opt/bin/external/cpuinfo/src -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' -Iinclude -Isrc -Os '-std=c99' -O2 -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/XNNPACK/src/operators/convolution-nchw.c -o bazel-out/k8-opt/bin/external/XNNPACK/_objs/operators/convolution-nchw.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,222 / 1,232] 2 actions, 1 running Compiling absl/strings/internal/charconv_bigint.cc; 0s local [Prepa] Compiling src/operators/convolution-nchw.c [1,222 / 1,232] 2 actions running Compiling absl/strings/internal/charconv_bigint.cc; 0s local Compiling src/operators/convolution-nchw.c; 0s local SUBCOMMAND: # @com_google_absl//absl/time:time [action 'Compiling absl/time/format.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/external/com_google_absl/absl/time/_objs/time/format.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_absl/absl/time/_objs/time/format.pic.o' -fPIC -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -Wall -Wextra -Wcast-qual -Wconversion-null -Wformat-security -Wmissing-declarations -Woverlength-strings -Wpointer-arith -Wundef -Wunused-local-typedefs -Wunused-result -Wvarargs -Wvla -Wwrite-strings -DNOMINMAX -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/com_google_absl/absl/time/format.cc -o bazel-out/k8-opt/bin/external/com_google_absl/absl/time/_objs/time/format.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,223 / 1,232] 2 actions, 1 running Compiling absl/strings/internal/charconv_bigint.cc; 0s local [Prepa] Compiling absl/time/format.cc [1,223 / 1,232] 2 actions running Compiling absl/strings/internal/charconv_bigint.cc; 1s local Compiling absl/time/format.cc; 0s local [1,224 / 1,232] 2 actions, 1 running Compiling absl/strings/internal/charconv_bigint.cc; 2s local [Scann] Compiling src/unpool-config.c SUBCOMMAND: # @XNNPACK//:microkernel_configs [action 'Compiling src/unpool-config.c', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections -MD -MF bazel-out/k8-opt/bin/external/XNNPACK/_objs/microkernel_configs/unpool-config.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/XNNPACK/_objs/microkernel_configs/unpool-config.pic.o' -fPIC '-DXNN_IGNORED_PLATFORM_JIT=0' '-DXNN_ENABLE_ARM_FP16_SCALAR=0' '-DXNN_ENABLE_ARM_FP16_VECTOR=0' '-DXNN_ENABLE_ARM_BF16=0' '-DXNN_ENABLE_ARM_DOTPROD=0' '-DXNN_ENABLE_ASSEMBLY=1' '-DXNN_ENABLE_DWCONV_MULTIPASS=0' '-DXNN_ENABLE_GEMM_M_SPECIALIZATION=1' '-DXNN_ENABLE_JIT=0' '-DXNN_LOG_LEVEL=0' -DPTHREADPOOL_NO_DEPRECATED_API -iquote external/XNNPACK -iquote bazel-out/k8-opt/bin/external/XNNPACK -iquote external/FXdiv -iquote bazel-out/k8-opt/bin/external/FXdiv -iquote external/pthreadpool -iquote bazel-out/k8-opt/bin/external/pthreadpool -iquote external/cpuinfo -iquote bazel-out/k8-opt/bin/external/cpuinfo -iquote external/FP16 -iquote bazel-out/k8-opt/bin/external/FP16 -Ibazel-out/k8-opt/bin/external/FXdiv/_virtual_includes/FXdiv -Ibazel-out/k8-opt/bin/external/pthreadpool/_virtual_includes/pthreadpool -Ibazel-out/k8-opt/bin/external/cpuinfo/_virtual_includes/cpuinfo -Ibazel-out/k8-opt/bin/external/FP16/_virtual_includes/FP16 -isystem external/XNNPACK/include -isystem bazel-out/k8-opt/bin/external/XNNPACK/include -isystem external/XNNPACK/src -isystem bazel-out/k8-opt/bin/external/XNNPACK/src -isystem external/FXdiv/include -isystem bazel-out/k8-opt/bin/external/FXdiv/include -isystem external/pthreadpool/include -isystem bazel-out/k8-opt/bin/external/pthreadpool/include -isystem external/cpuinfo/include -isystem bazel-out/k8-opt/bin/external/cpuinfo/include -isystem external/cpuinfo/src -isystem bazel-out/k8-opt/bin/external/cpuinfo/src -isystem external/FP16/include -isystem bazel-out/k8-opt/bin/external/FP16/include -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' -Iinclude -Isrc '-std=c99' -O2 -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/XNNPACK/src/unpool-config.c -o bazel-out/k8-opt/bin/external/XNNPACK/_objs/microkernel_configs/unpool-config.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,224 / 1,232] 2 actions, 1 running Compiling absl/strings/internal/charconv_bigint.cc; 2s local [Prepa] Compiling src/unpool-config.c SUBCOMMAND: # //tensorflow/lite/kernels:builtin_op_kernels [action 'Compiling tensorflow/lite/kernels/add.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/tensorflow/lite/kernels/_objs/builtin_op_kernels/add.pic.d '-frandom-seed=bazel-out/k8-opt/bin/tensorflow/lite/kernels/_objs/builtin_op_kernels/add.pic.o' -fPIC -DTFLITE_KERNEL_USE_XNNPACK -DPTHREADPOOL_NO_DEPRECATED_API '-DEIGEN_NEON_GEBP_NR=4' -DEIGEN_MPL2_ONLY '-DEIGEN_MAX_ALIGN_BYTES=64' '-DXNNPACK_DELEGATE_ENABLE_QS8=1' '-DXNNPACK_DELEGATE_ENABLE_QU8=1' '-DEIGEN_ALTIVEC_USE_CUSTOM_PACK=0' '-DEIGEN_USE_AVX512_GEMM_KERNELS=0' '-DXNN_IGNORED_PLATFORM_JIT=0' '-DXNN_LOG_LEVEL=0' '-DXNN_ENABLE_ARM_FP16_SCALAR=0' '-DXNN_ENABLE_ARM_FP16_VECTOR=0' '-DXNN_ENABLE_ARM_BF16=0' '-DXNN_ENABLE_ARM_DOTPROD=0' '-DXNN_ENABLE_GEMM_M_SPECIALIZATION=1' '-DXNN_ENABLE_JIT=0' '-DXNN_ENABLE_ASSEMBLY=1' '-DXNN_ENABLE_DWCONV_MULTIPASS=0' '-DXNN_ENABLE_SPARSE=1' '-DXNN_ENABLE_MEMOPT=1' -iquote . -iquote bazel-out/k8-opt/bin -iquote external/ruy -iquote bazel-out/k8-opt/bin/external/ruy -iquote external/cpuinfo -iquote bazel-out/k8-opt/bin/external/cpuinfo -iquote external/gemmlowp -iquote bazel-out/k8-opt/bin/external/gemmlowp -iquote external/pthreadpool -iquote bazel-out/k8-opt/bin/external/pthreadpool -iquote external/FXdiv -iquote bazel-out/k8-opt/bin/external/FXdiv -iquote external/arm_neon_2_x86_sse -iquote bazel-out/k8-opt/bin/external/arm_neon_2_x86_sse -iquote external/eigen_archive -iquote bazel-out/k8-opt/bin/external/eigen_archive -iquote external/flatbuffers -iquote bazel-out/k8-opt/bin/external/flatbuffers -iquote external/fft2d -iquote bazel-out/k8-opt/bin/external/fft2d -iquote external/XNNPACK -iquote bazel-out/k8-opt/bin/external/XNNPACK -iquote external/FP16 -iquote bazel-out/k8-opt/bin/external/FP16 -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -iquote external/nsync -iquote bazel-out/k8-opt/bin/external/nsync -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt/bin/external/zlib -iquote external/farmhash_archive -iquote bazel-out/k8-opt/bin/external/farmhash_archive -Ibazel-out/k8-opt/bin/external/cpuinfo/_virtual_includes/cpuinfo -Ibazel-out/k8-opt/bin/external/pthreadpool/_virtual_includes/pthreadpool -Ibazel-out/k8-opt/bin/external/FXdiv/_virtual_includes/FXdiv -Ibazel-out/k8-opt/bin/external/flatbuffers/_virtual_includes/flatbuffers -Ibazel-out/k8-opt/bin/external/flatbuffers/src/_virtual_includes/flatbuffers -Ibazel-out/k8-opt/bin/external/flatbuffers/_virtual_includes/runtime_cc -Ibazel-out/k8-opt/bin/external/FP16/_virtual_includes/FP16 -isystem external/cpuinfo/include -isystem bazel-out/k8-opt/bin/external/cpuinfo/include -isystem external/cpuinfo/src -isystem bazel-out/k8-opt/bin/external/cpuinfo/src -isystem external/pthreadpool/include -isystem bazel-out/k8-opt/bin/external/pthreadpool/include -isystem external/FXdiv/include -isystem bazel-out/k8-opt/bin/external/FXdiv/include -isystem third_party/eigen3/mkl_include -isystem bazel-out/k8-opt/bin/third_party/eigen3/mkl_include -isystem external/eigen_archive -isystem bazel-out/k8-opt/bin/external/eigen_archive -isystem tensorflow/lite/schema -isystem bazel-out/k8-opt/bin/tensorflow/lite/schema -isystem tensorflow/lite/experimental/acceleration/configuration -isystem bazel-out/k8-opt/bin/tensorflow/lite/experimental/acceleration/configuration -isystem external/XNNPACK/include -isystem bazel-out/k8-opt/bin/external/XNNPACK/include -isystem external/XNNPACK/src -isystem bazel-out/k8-opt/bin/external/XNNPACK/src -isystem external/FP16/include -isystem bazel-out/k8-opt/bin/external/FP16/include -isystem external/nsync/public -isystem bazel-out/k8-opt/bin/external/nsync/public -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/external/com_google_protobuf/src -isystem external/zlib -isystem bazel-out/k8-opt/bin/external/zlib -isystem external/farmhash_archive/src -isystem bazel-out/k8-opt/bin/external/farmhash_archive/src -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -DFARMHASH_NO_CXX_STRING -msse4.2 -O3 -fno-exceptions '-Wno-error=reorder' -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c tensorflow/lite/kernels/add.cc -o bazel-out/k8-opt/bin/tensorflow/lite/kernels/_objs/builtin_op_kernels/add.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,225 / 1,232] 2 actions, 1 running Compiling absl/strings/internal/charconv_bigint.cc; 2s local [Prepa] Compiling tensorflow/lite/kernels/add.cc SUBCOMMAND: # //tensorflow/lite:stderr_reporter [action 'Compiling tensorflow/lite/stderr_reporter.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/tensorflow/lite/_objs/stderr_reporter/stderr_reporter.pic.d '-frandom-seed=bazel-out/k8-opt/bin/tensorflow/lite/_objs/stderr_reporter/stderr_reporter.pic.o' -fPIC -DTFLITE_KERNEL_USE_XNNPACK -iquote . -iquote bazel-out/k8-opt/bin -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -DFARMHASH_NO_CXX_STRING -msse4.2 -O3 -fno-exceptions -Wall -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c tensorflow/lite/stderr_reporter.cc -o bazel-out/k8-opt/bin/tensorflow/lite/_objs/stderr_reporter/stderr_reporter.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,226 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 0s local [Prepa] Compiling tensorflow/lite/stderr_reporter.cc SUBCOMMAND: # @com_google_absl//absl/strings:cord [action 'Compiling absl/strings/cord.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/external/com_google_absl/absl/strings/_objs/cord/cord.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_absl/absl/strings/_objs/cord/cord.pic.o' -fPIC -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -Wall -Wextra -Wcast-qual -Wconversion-null -Wformat-security -Wmissing-declarations -Woverlength-strings -Wpointer-arith -Wundef -Wunused-local-typedefs -Wunused-result -Wvarargs -Wvla -Wwrite-strings -DNOMINMAX -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/com_google_absl/absl/strings/cord.cc -o bazel-out/k8-opt/bin/external/com_google_absl/absl/strings/_objs/cord/cord.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,227 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 0s local [Prepa] Compiling absl/strings/cord.cc [1,227 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 0s local Compiling absl/strings/cord.cc; 0s local [1,227 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 1s local Compiling absl/strings/cord.cc; 1s local [1,227 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 2s local Compiling absl/strings/cord.cc; 2s local [1,227 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 3s local Compiling absl/strings/cord.cc; 3s local [1,227 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 4s local Compiling absl/strings/cord.cc; 4s local [1,228 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 5s local [Scann] Compiling src/google/protobuf/stubs/statusor.cc SUBCOMMAND: # @com_google_protobuf//:protobuf_lite [action 'Compiling src/google/protobuf/stubs/statusor.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/external/com_google_protobuf/_objs/protobuf_lite/statusor.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_protobuf/_objs/protobuf_lite/statusor.pic.o' -fPIC -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/external/com_google_protobuf/src -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -DHAVE_ZLIB -Woverloaded-virtual -Wno-sign-compare -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/com_google_protobuf/src/google/protobuf/stubs/statusor.cc -o bazel-out/k8-opt/bin/external/com_google_protobuf/_objs/protobuf_lite/statusor.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,228 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 5s local [Prepa] Compiling src/google/protobuf/stubs/statusor.cc [1,228 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 6s local Compiling src/google/protobuf/stubs/statusor.cc; 0s local [1,229 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 6s local [Scann] Compiling absl/synchronization/internal/create_thread_identity.cc SUBCOMMAND: # @com_google_absl//absl/synchronization:synchronization [action 'Compiling absl/synchronization/internal/create_thread_identity.cc', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/external/com_google_absl/absl/synchronization/_objs/synchronization/create_thread_identity.pic.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_absl/absl/synchronization/_objs/synchronization/create_thread_identity.pic.o' -fPIC -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -Wno-all -Wno-extra -Wno-deprecated -Wno-deprecated-declarations -Wno-ignored-attributes -Wno-array-bounds -Wunused-result '-Werror=unused-result' -Wswitch '-Werror=switch' '-Wno-error=unused-but-set-variable' -DAUTOLOAD_DYNAMIC_KERNELS -O3 '-march=native' '-std=c++17' -Wall -Wextra -Wcast-qual -Wconversion-null -Wformat-security -Wmissing-declarations -Woverlength-strings -Wpointer-arith -Wundef -Wunused-local-typedefs -Wunused-result -Wvarargs -Wvla -Wwrite-strings -DNOMINMAX -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c external/com_google_absl/absl/synchronization/internal/create_thread_identity.cc -o bazel-out/k8-opt/bin/external/com_google_absl/absl/synchronization/_objs/synchronization/create_thread_identity.pic.o) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,229 / 1,232] 2 actions, 1 running Compiling tensorflow/lite/kernels/add.cc; 6s local [Prepa] Compiling absl/synchronization/internal/create_thread_identity.cc [1,229 / 1,232] 2 actions running Compiling tensorflow/lite/kernels/add.cc; 6s local Compiling .../synchronization/internal/create_thread_identity.cc; 0s local [1,230 / 1,232] Compiling tensorflow/lite/kernels/add.cc; 7s local [1,230 / 1,232] Compiling tensorflow/lite/kernels/add.cc; 9s local [1,230 / 1,232] Compiling tensorflow/lite/kernels/add.cc; 10s local [1,230 / 1,232] Compiling tensorflow/lite/kernels/add.cc; 11s local [1,231 / 1,232] [Prepa] ...r_wrapper:_pywrap_tensorflow_interpreter_wrapper.so SUBCOMMAND: # //tensorflow/lite/python/interpreter_wrapper:_pywrap_tensorflow_interpreter_wrapper.so [action 'Linking tensorflow/lite/python/interpreter_wrapper/_pywrap_tensorflow_interpreter_wrapper.so', configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2, execution platform: @local_execution_config_platform//:platform] (cd /root/.cache/bazel/_bazel_root/44af44c54090ffd8c730879fc5d7b491/execroot/org_tensorflow && \ exec env - \ LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/opt/conda/lib \ PATH=/opt/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ PWD=/proc/self/cwd \ TF2_BEHAVIOR=1 \ /usr/bin/gcc @bazel-out/k8-opt/bin/tensorflow/lite/python/interpreter_wrapper/_pywrap_tensorflow_interpreter_wrapper.so-2.params) # Configuration: 6bf13bb09c259727d5061837858294f1092bec30d275f05710212182ee5e1ce2 # Execution platform: @local_execution_config_platform//:platform [1,231 / 1,232] [Prepa] ...r_wrapper:_pywrap_tensorflow_interpreter_wrapper.so [1,231 / 1,232] ...wrapper:_pywrap_tensorflow_interpreter_wrapper.so; 0s local Target //tensorflow/lite/python/interpreter_wrapper:_pywrap_tensorflow_interpreter_wrapper up-to-date (nothing to build) [1,232 / 1,232] checking cached actions INFO: Elapsed time: 1504.620s, Critical Path: 75.80s [1,232 / 1,232] checking cached actions INFO: 1232 processes: 204 internal, 1028 local. [1,232 / 1,232] checking cached actions INFO: Build completed successfully, 1232 total actions INFO: Build completed successfully, 1232 total actions + cp /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/../../../../bazel-bin/tensorflow/lite/python/interpreter_wrapper/_pywrap_tensorflow_interpreter_wrapper.so /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime + chmod u+w /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/_pywrap_tensorflow_interpreter_wrapper.so + cd /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3 + case "${TENSORFLOW_TARGET}" in + [[ -n '' ]] + python3 setup.py bdist bdist_wheel /opt/conda/lib/python3.10/site-packages/setuptools/_distutils/cmd.py:66: SetuptoolsDeprecationWarning: setup.py install is deprecated. !! ******************************************************************************** Please avoid running ``setup.py`` directly. Instead, use pypa/build, pypa/installer or other standards-based tools. See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details. ******************************************************************************** !! self.initialize_options() /opt/conda/lib/python3.10/site-packages/setuptools/_distutils/dist.py:947: SetuptoolsDeprecationWarning: setup.py install is deprecated. !! ******************************************************************************** Please avoid running ``setup.py`` directly. Instead, use pypa/build, pypa/installer or other standards-based tools. See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details. ******************************************************************************** !! command.initialize_options() + echo 'Output can be found here:' Output can be found here: + find /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3 /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3 /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/MANIFEST.in /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/dist /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/dist/tflite-runtime-2.13.0.linux-x86_64.tar.gz /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/dist/tflite_runtime-2.13.0-cp310-cp310-linux_x86_64.whl /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/bdist.linux-x86_64 /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310 /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime/_pywrap_tensorflow_interpreter_wrapper.so /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime/metrics_interface.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime/__init__.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime/interpreter.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/build/lib.linux-x86_64-cpython-310/tflite_runtime/metrics_portable.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian/changelog /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian/copyright /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian/rules /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian/control /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/debian/compat /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/numpy.cc /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/interpreter_wrapper.h /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/python_utils.h /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/numpy.h /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/interpreter_wrapper_pybind11.cc /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/python_error_reporter.cc /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/python_error_reporter.h /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/python_utils.cc /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/interpreter_wrapper.cc /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/interpreter_wrapper/BUILD /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info/PKG-INFO /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info/dependency_links.txt /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info/requires.txt /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info/top_level.txt /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime.egg-info/SOURCES.txt /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/_pywrap_tensorflow_interpreter_wrapper.so /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/metrics_interface.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/__init__.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/interpreter.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/tflite_runtime/metrics_portable.py /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/setup.py + [[ '' != \y ]] + exit 0 total 7748 -rw-r--r-- 1 root root 3960944 Sep 19 03:23 tflite-runtime-2.13.0.linux-x86_64.tar.gz -rw-r--r-- 1 root root 3966013 Sep 19 03:23 tflite_runtime-2.13.0-cp310-cp310-linux_x86_64.whl /kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/dist Processing ./tflite_runtime-2.13.0-cp310-cp310-linux_x86_64.whl Requirement already satisfied: numpy>=1.21.2 in /opt/conda/lib/python3.10/site-packages (from tflite-runtime==2.13.0) (1.23.5) **Installing collected packages: tflite-runtime Successfully installed tflite-runtime-2.13.0** --------------------------------------------------------------------------- ImportError Traceback (most recent call last) Cell In[5], line 17 15 get_ipython().run_line_magic('cd', '/kaggle/working/tensorflow/tensorflow/lite/tools/pip_package/gen/tflite_pip/python3/dist/') 16 get_ipython().system('pip install tflite_runtime-2.13.0-cp310-cp310-linux_x86_64.whl') **---> 17 import tflite_runtime.interpreter as tflite** File /opt/conda/lib/python3.10/site-packages/tflite_runtime/interpreter.py:33 30 from tensorflow.python.util.tf_export import tf_export as _tf_export 31 else: 32 # This file is part of tflite_runtime package. ---> 33 from tflite_runtime import _pywrap_tensorflow_interpreter_wrapper as _interpreter_wrapper 34 from tflite_runtime import metrics_portable as metrics 36 def _tf_export(*x, **kwargs): **ImportError: /opt/conda/lib/python3.10/site-packages/tflite_runtime/_pywrap_tensorflow_interpreter_wrapper.so: undefined symbol: _ZN6tflite29farthestpointsamplingLauncherEiiiPKfPfPi** ``` **Standalone code to reproduce the issue** I tried to add custom OP and built tflite-runtime with shim, see issue https://github.com/tensorflow/tensorflow/issues/61521. And the custom OP includes some GPU code. I built tflite-runtime successfully and the installation seems successfully as well. But when tried to import tflite-runtime in python there raised errors about GPU API farthestpointsamplingLauncher. Missing the share library of GPU part? [code and change] https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/shim/test_op/sampling_op.h https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/shim/test_op/sampling_tflite_op.cc https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/shim/test_op/sampling_tflite_op.h https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/shim/test_op/tf_sampling_gpu.cu.cc https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/shim/test_op/BUILD#L159 https://github.com/kuangzy2011/tensorflow/blob/main/tensorflow/lite/kernels/BUILD#L744 **Any other info / logs** Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61906/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61906/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61905
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61905/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61905/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61905/events
https://github.com/tensorflow/tensorflow/issues/61905
1,902,158,652
I_kwDOArmXAs5xYKM8
61,905
FPE in DepthwiseConv2D
{ "login": "SiriusHsh", "id": 20510239, "node_id": "MDQ6VXNlcjIwNTEwMjM5", "avatar_url": "https://avatars.githubusercontent.com/u/20510239?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SiriusHsh", "html_url": "https://github.com/SiriusHsh", "followers_url": "https://api.github.com/users/SiriusHsh/followers", "following_url": "https://api.github.com/users/SiriusHsh/following{/other_user}", "gists_url": "https://api.github.com/users/SiriusHsh/gists{/gist_id}", "starred_url": "https://api.github.com/users/SiriusHsh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SiriusHsh/subscriptions", "organizations_url": "https://api.github.com/users/SiriusHsh/orgs", "repos_url": "https://api.github.com/users/SiriusHsh/repos", "events_url": "https://api.github.com/users/SiriusHsh/events{/privacy}", "received_events_url": "https://api.github.com/users/SiriusHsh/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "majiddadashi", "id": 5490974, "node_id": "MDQ6VXNlcjU0OTA5NzQ=", "avatar_url": "https://avatars.githubusercontent.com/u/5490974?v=4", "gravatar_id": "", "url": "https://api.github.com/users/majiddadashi", "html_url": "https://github.com/majiddadashi", "followers_url": "https://api.github.com/users/majiddadashi/followers", "following_url": "https://api.github.com/users/majiddadashi/following{/other_user}", "gists_url": "https://api.github.com/users/majiddadashi/gists{/gist_id}", "starred_url": "https://api.github.com/users/majiddadashi/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/majiddadashi/subscriptions", "organizations_url": "https://api.github.com/users/majiddadashi/orgs", "repos_url": "https://api.github.com/users/majiddadashi/repos", "events_url": "https://api.github.com/users/majiddadashi/events{/privacy}", "received_events_url": "https://api.github.com/users/majiddadashi/received_events", "type": "User", "site_admin": false }
[ { "login": "majiddadashi", "id": 5490974, "node_id": "MDQ6VXNlcjU0OTA5NzQ=", "avatar_url": "https://avatars.githubusercontent.com/u/5490974?v=4", "gravatar_id": "", "url": "https://api.github.com/users/majiddadashi", "html_url": "https://github.com/majiddadashi", "followers_url": "https://api.github.com/users/majiddadashi/followers", "following_url": "https://api.github.com/users/majiddadashi/following{/other_user}", "gists_url": "https://api.github.com/users/majiddadashi/gists{/gist_id}", "starred_url": "https://api.github.com/users/majiddadashi/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/majiddadashi/subscriptions", "organizations_url": "https://api.github.com/users/majiddadashi/orgs", "repos_url": "https://api.github.com/users/majiddadashi/repos", "events_url": "https://api.github.com/users/majiddadashi/events{/privacy}", "received_events_url": "https://api.github.com/users/majiddadashi/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi, I'm getting a different error for this:\r\n\r\n```\r\n./benchmark_model --graph=DepthwiseConv2D_FPE.tflite\r\n2023-09-22 20:14:46.893112: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [DepthwiseConv2D_FPE.tflite]\r\n2023-09-22 20:14:46.893195: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n2023-09-22 20:14:46.893203: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n2023-09-22 20:14:46.893208: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n2023-09-22 20:14:46.893237: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n2023-09-22 20:14:46.893241: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n2023-09-22 20:14:46.893245: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n2023-09-22 20:14:46.893261: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n2023-09-22 20:14:46.893271: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n2023-09-22 20:14:46.893282: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n2023-09-22 20:14:46.893293: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n2023-09-22 20:14:46.893297: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n2023-09-22 20:14:46.893307: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n2023-09-22 20:14:46.893323: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n2023-09-22 20:14:46.893337: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n2023-09-22 20:14:46.893368: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n2023-09-22 20:14:46.893386: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n2023-09-22 20:14:46.893446: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Interpreting non ascii codepoint 136.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n2023-09-22 20:14:46.903702: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse DepthwiseConv2D_FPE.tflite as text proto\r\n2023-09-22 20:14:46.903741: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.010362s\r\n```\r\n\r\nPlease note it's failing on this: [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Interpreting non ascii codepoint 136.\r\n\r\nI'm compiling from r2.14 and using gcc and bazel is up to date.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61905\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61905\">No</a>\n", "I was able to replicate with updated steps:\r\n\r\n```sh\r\ngit clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\nmkdir tflite_build\r\ncd tflite_build\r\ncmake ../tensorflow_src/tensorflow/lite\r\ncmake --build . -j\r\ncmake --build . -j -t benchmark_model\r\ncd tools/benchmark\r\ncp path/to/DepthwiseConv2D_FPE.tflite .\r\n./benchmark_model --graph=DepthwiseConv2D_FPE.tflite\r\n```\r\n```\r\n./benchmark_model --graph=DepthwiseConv2D_FPE.tflite\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [DepthwiseConv2D_FPE.tflite]\r\nINFO: Loaded model DepthwiseConv2D_FPE.tflite\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\nINFO: The input model file size (MB): 0.000772\r\nINFO: Initialized session in 1.153ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nFloating point exception\r\n```\r\n\r\nHi @majiddadashi, can you please take a look? Thanks." ]
2023-09-19T03:52:07
2023-10-10T22:42:24
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.14.0 ### Custom code Yes ### OS platform and distribution Ubuntu 18.04.6 ### Mobile device _No response_ ### Python version Python 3.8.3 ### Bazel version bazel 5.3.0 ### GCC/compiler version gcc 7.5.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Construct a malicious model for the DepthwiseConv2D operator, setting the `stride_width` to greater than `0xffff`. When initializing the DepthwiseParams structure in depthwise_conv.cc, due to precision loss, `op_params.stride_width` becomes 0. `TfLiteDepthwiseConvParams::stride_width` is a 4-byte int type, while `DepthwiseParams::stride_width` is a 2-byte int type. ``` // depthwise_conv.cc template <KernelType kernel_type> TfLiteStatus EvalFloat(TfLiteContext* context, TfLiteNode* node, TfLiteDepthwiseConvParams* params, OpData* data, const TfLiteTensor* input, const TfLiteTensor* filter, const TfLiteTensor* bias, TfLiteTensor* output) { float output_activation_min, output_activation_max; CalculateActivationRange(params->activation, &output_activation_min, &output_activation_max); DepthwiseParams op_params; op_params.padding_type = PaddingType::kSame; op_params.padding_values.width = data->padding.width; op_params.padding_values.height = data->padding.height; op_params.stride_width = params->stride_width; <== here op_params.stride_height = params->stride_height; op_params.dilation_width_factor = params->dilation_width_factor; op_params.dilation_height_factor = params->dilation_height_factor; op_params.float_activation_min = output_activation_min; op_params.float_activation_max = output_activation_max; TF_LITE_ENSURE_STATUS(ComputeDepthMultiplier(context, input, filter, &op_params.depth_multiplier)); ``` The `stride` variable may be equal to 0, leading to a division by zero error. ```cpp // depthwiseconv_float.h inline void FloatDepthwiseConvAccumRowGeneric( int stride, int dilation_factor, int input_depth, int input_width, const float* input_data, int pad_width, int depth_multiplier, int filter_width, const float* filter_data, int out_x_buffer_start, int out_x_buffer_end, int output_depth, float* acc_buffer) { ruy::profiler::ScopeLabel label("DepthwiseConvAccumRowGeneric (slow)"); const float* filter_base_ptr = filter_data; for (int filter_x = 0; filter_x < filter_width; ++filter_x) { const int out_x_loop_start = std::max( out_x_buffer_start, (pad_width - dilation_factor * filter_x + stride - 1) / stride); // FPE ``` [DepthwiseConv2D_FPE.zip](https://github.com/tensorflow/tensorflow/files/12655660/DepthwiseConv2D_FPE.zip) ### Standalone code to reproduce the issue ```shell When I use the benchmark tool for PoC validation, it causes the TensorFlow Lite inference process to be subjected to a DOS(coredump). ❯ ./benchmark_model --graph=../poc/DepthwiseConv2D_FPE.tflite INFO: STARTING! INFO: Log parameter values verbosely: [0] INFO: Graph: [../poc/DepthwiseConv2D_FPE.tflite] INFO: Loaded model ../poc/DepthwiseConv2D_FPE.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. INFO: The input model file size (MB): 0.000772 INFO: Initialized session in 14.64ms. INFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds. [1] 9351 floating point exception (core dumped) ./benchmark_model --graph=../poc/DepthwiseConv2D_FPE.tflite ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61905/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61905/timeline
null
reopened
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61904
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61904/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61904/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61904/events
https://github.com/tensorflow/tensorflow/issues/61904
1,902,156,448
I_kwDOArmXAs5xYJqg
61,904
How to measure data fetching, forward and backward pass time during training
{ "login": "PurvangL", "id": 104454645, "node_id": "U_kgDOBjnZ9Q", "avatar_url": "https://avatars.githubusercontent.com/u/104454645?v=4", "gravatar_id": "", "url": "https://api.github.com/users/PurvangL", "html_url": "https://github.com/PurvangL", "followers_url": "https://api.github.com/users/PurvangL/followers", "following_url": "https://api.github.com/users/PurvangL/following{/other_user}", "gists_url": "https://api.github.com/users/PurvangL/gists{/gist_id}", "starred_url": "https://api.github.com/users/PurvangL/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/PurvangL/subscriptions", "organizations_url": "https://api.github.com/users/PurvangL/orgs", "repos_url": "https://api.github.com/users/PurvangL/repos", "events_url": "https://api.github.com/users/PurvangL/events{/privacy}", "received_events_url": "https://api.github.com/users/PurvangL/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 4829271983, "node_id": "LA_kwDOArmXAs8AAAABH9jXrw", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.11", "name": "TF 2.11", "color": "46B4D7", "default": false, "description": "Issues related to TF 2.11" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "@PurvangL Generally you can get the time in the model.fit logs which will be taken/step. Could you please check this [guide](https://www.tensorflow.org/guide/autodiff) for more details on the gradients differentiation and how that is calculated during the training. It would have been easier to understand your query if any sample code was provided. I could also see there is one ongoing thread on TF [Forum](https://discuss.tensorflow.org/t/how-to-measure-data-fetching-forward-and-backward-pass-time-during-training/19698). As this issue is more related to support so please close this ticket and we will follow up in the other thread. Thank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "Thanks @sushreebarsa. Closing issue here.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61904\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61904\">No</a>\n" ]
2023-09-19T03:48:46
2023-10-11T17:08:24
2023-10-11T17:08:21
NONE
null
null
null
Please go to Stack Overflow for help and support: https://stackoverflow.com/questions/tagged/tensorflow If you open a GitHub issue, here is our policy: 1. It must be a bug, a feature request, or a significant problem with the documentation (for small docs fixes please send a PR instead). 2. The form below must be filled out. 3. It shouldn't be a TensorBoard issue. Those go [here](https://github.com/tensorflow/tensorboard/issues). **Here's why we have that policy**: TensorFlow developers respond to issues. We want to focus on work that benefits the whole community, e.g., fixing bugs and adding features. Support only helps individuals. GitHub also notifies thousands of people when issues are filed. We want them to see you communicating an interesting problem, rather than being redirected to Stack Overflow. ------------------------ ### System information - **Have I written custom code (as opposed to using a stock example script provided in TensorFlow)**: No - **OS Platform and Distribution (e.g., Linux Ubuntu 16.04)**: - **Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on a mobile device**: - **TensorFlow installed from (source or binary)**: Binary - **TensorFlow version (use command below)**: 2.11.0 - **Python version**: 3.8 - **Bazel version (if compiling from source)**: - **GCC/Compiler version (if compiling from source)**: - **CUDA/cuDNN version**: 12 - **GPU model and memory**: A100 - **Exact command to reproduce**: You can collect some of this information using our environment capture script: https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh You can obtain the TensorFlow version with: ```bash python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)" ``` ### Describe the problem How to measure Data fetching, Data preparation, forward and backward pass time for training [script](https://www.tensorflow.org/tutorials/images/segmentation)? ### Source code / logs Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached. Try to provide a reproducible test case that is the bare minimum necessary to generate the problem.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61904/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61904/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61903
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61903/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61903/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61903/events
https://github.com/tensorflow/tensorflow/issues/61903
1,902,155,702
I_kwDOArmXAs5xYJe2
61,903
Results with error set when running tf.raw_ops.StatelessParameterizedTruncatedNormal
{ "login": "dmc1778", "id": 17060581, "node_id": "MDQ6VXNlcjE3MDYwNTgx", "avatar_url": "https://avatars.githubusercontent.com/u/17060581?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dmc1778", "html_url": "https://github.com/dmc1778", "followers_url": "https://api.github.com/users/dmc1778/followers", "following_url": "https://api.github.com/users/dmc1778/following{/other_user}", "gists_url": "https://api.github.com/users/dmc1778/gists{/gist_id}", "starred_url": "https://api.github.com/users/dmc1778/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dmc1778/subscriptions", "organizations_url": "https://api.github.com/users/dmc1778/orgs", "repos_url": "https://api.github.com/users/dmc1778/repos", "events_url": "https://api.github.com/users/dmc1778/events{/privacy}", "received_events_url": "https://api.github.com/users/dmc1778/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "@sachinprasadhs I was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/c95ef7dfc143c2ae9a6d25072819c483/61903.ipynb). Thank you!", "@mihaimaruseac Is this a bug or security vulnerability?", "In the absence of demonstrated impact it is not security vuln.\r\n\r\nHere, it is also just errors reported back to user, no abnormal program termination.\r\n\r\nThis is all WAI", "If you don't try to catch the error, you will see: \r\n```\r\nOverflowError: Python int too large to convert to C long\r\n```\r\nThis actually has nothing to do with TF.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61903\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61903\">No</a>\n" ]
2023-09-19T03:47:35
2023-10-18T17:11:23
2023-10-18T17:11:20
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution 22.04 ### Mobile device _No response_ ### Python version 3.10 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Maybe a better error message should be raised here? ``` Error:<class 'tensorflow.python.framework.ops.EagerTensor'> returned a result with an error set Error:<class 'tensorflow.python.framework.ops.EagerTensor'> returned a result with an error set ``` ### Standalone code to reproduce the issue ```shell results = dict() import tensorflow as tf import numpy as np try: try: with tf.device('/CPU'): shape = [] seed_0 = -0.28041645497635637 seed_1 = -434 seed = [seed_0,seed_1,] means = -382 stddevs_tensor = tf.saturate_cast(tf.random.uniform([], minval=0, maxval=2, dtype=tf.int64), dtype=tf.uint64) stddevs = tf.identity(stddevs_tensor) minvals = [] maxvals = [] name_tensor = tf.random.uniform([], dtype=tf.bfloat16) name = tf.identity(name_tensor) out = tf.raw_ops.StatelessParameterizedTruncatedNormal(shape=shape,seed=seed,means=means,stddevs=stddevs,minvals=minvals,maxvals=maxvals,name=name,) except Exception as e: print("Error:"+str(e)) try: with tf.device('/GPU:0'): shape = [] seed = [seed_0,seed_1,] stddevs = tf.identity(stddevs_tensor) stddevs = tf.cast(stddevs, tf.uint64) minvals = [] maxvals = [] name = tf.identity(name_tensor) name = tf.cast(name, tf.bfloat16) tf.raw_ops.StatelessParameterizedTruncatedNormal(shape=shape,seed=seed,means=means,stddevs=stddevs,minvals=minvals,maxvals=maxvals,name=name,) except Exception as e: print("Error:"+str(e)) except Exception as e: print("Error:"+str(e)) print(results) ``` ``` ### Relevant log output ```shell 2023-09-18 23:45:51.224040: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags. 2023-09-18 23:45:51.345060: E tensorflow/stream_executor/cuda/cuda_blas.cc:2981] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered 2023-09-18 23:45:51.934234: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libnvinfer.so.7'; dlerror: libnvinfer.so.7: cannot open shared object file: No such file or directory 2023-09-18 23:45:51.934291: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libnvinfer_plugin.so.7'; dlerror: libnvinfer_plugin.so.7: cannot open shared object file: No such file or directory 2023-09-18 23:45:51.934301: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Cannot dlopen some TensorRT libraries. If you would like to use Nvidia GPU with TensorRT, please make sure the missing libraries mentioned above are installed properly. 2023-09-18 23:45:52.423299: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:980] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero 2023-09-18 23:45:52.450695: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libcudnn.so.8'; dlerror: libcudnn.so.8: cannot open shared object file: No such file or directory 2023-09-18 23:45:52.450716: W tensorflow/core/common_runtime/gpu/gpu_device.cc:1934] Cannot dlopen some GPU libraries. Please make sure the missing libraries mentioned above are installed properly if you would like to use GPU. Follow the guide at https://www.tensorflow.org/install/gpu for how to download and setup the required libraries for your platform. Skipping registering GPU devices... 2023-09-18 23:45:52.451038: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags. Error:<class 'tensorflow.python.framework.ops.EagerTensor'> returned a result with an error set Error:<class 'tensorflow.python.framework.ops.EagerTensor'> returned a result with an error set {} ``` ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61903/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61903/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61902
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61902/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61902/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61902/events
https://github.com/tensorflow/tensorflow/issues/61902
1,902,147,947
I_kwDOArmXAs5xYHlr
61,902
FPE in Conv2d
{ "login": "SiriusHsh", "id": 20510239, "node_id": "MDQ6VXNlcjIwNTEwMjM5", "avatar_url": "https://avatars.githubusercontent.com/u/20510239?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SiriusHsh", "html_url": "https://github.com/SiriusHsh", "followers_url": "https://api.github.com/users/SiriusHsh/followers", "following_url": "https://api.github.com/users/SiriusHsh/following{/other_user}", "gists_url": "https://api.github.com/users/SiriusHsh/gists{/gist_id}", "starred_url": "https://api.github.com/users/SiriusHsh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SiriusHsh/subscriptions", "organizations_url": "https://api.github.com/users/SiriusHsh/orgs", "repos_url": "https://api.github.com/users/SiriusHsh/repos", "events_url": "https://api.github.com/users/SiriusHsh/events{/privacy}", "received_events_url": "https://api.github.com/users/SiriusHsh/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "nutsiepully", "id": 1307460, "node_id": "MDQ6VXNlcjEzMDc0NjA=", "avatar_url": "https://avatars.githubusercontent.com/u/1307460?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nutsiepully", "html_url": "https://github.com/nutsiepully", "followers_url": "https://api.github.com/users/nutsiepully/followers", "following_url": "https://api.github.com/users/nutsiepully/following{/other_user}", "gists_url": "https://api.github.com/users/nutsiepully/gists{/gist_id}", "starred_url": "https://api.github.com/users/nutsiepully/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nutsiepully/subscriptions", "organizations_url": "https://api.github.com/users/nutsiepully/orgs", "repos_url": "https://api.github.com/users/nutsiepully/repos", "events_url": "https://api.github.com/users/nutsiepully/events{/privacy}", "received_events_url": "https://api.github.com/users/nutsiepully/received_events", "type": "User", "site_admin": false }
[ { "login": "nutsiepully", "id": 1307460, "node_id": "MDQ6VXNlcjEzMDc0NjA=", "avatar_url": "https://avatars.githubusercontent.com/u/1307460?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nutsiepully", "html_url": "https://github.com/nutsiepully", "followers_url": "https://api.github.com/users/nutsiepully/followers", "following_url": "https://api.github.com/users/nutsiepully/following{/other_user}", "gists_url": "https://api.github.com/users/nutsiepully/gists{/gist_id}", "starred_url": "https://api.github.com/users/nutsiepully/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nutsiepully/subscriptions", "organizations_url": "https://api.github.com/users/nutsiepully/orgs", "repos_url": "https://api.github.com/users/nutsiepully/repos", "events_url": "https://api.github.com/users/nutsiepully/events{/privacy}", "received_events_url": "https://api.github.com/users/nutsiepully/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi I'm getting a different error, can you ensure you have built your benchmark_model executable with more recent code? and your file is uploaded correctly?\r\n\r\n```\r\n./benchmark_model --graph=Conv2d_FPE.tflite\r\n2023-09-22 20:16:04.234199: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [Conv2d_FPE.tflite]\r\n2023-09-22 20:16:04.234281: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n2023-09-22 20:16:04.234289: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n2023-09-22 20:16:04.234294: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n2023-09-22 20:16:04.234298: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n2023-09-22 20:16:04.234302: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n2023-09-22 20:16:04.234315: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n2023-09-22 20:16:04.234352: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n2023-09-22 20:16:04.234371: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n2023-09-22 20:16:04.234381: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n2023-09-22 20:16:04.234411: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n2023-09-22 20:16:04.234570: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n2023-09-22 20:16:04.234592: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n2023-09-22 20:16:04.234606: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n2023-09-22 20:16:04.234620: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n2023-09-22 20:16:04.234634: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n2023-09-22 20:16:04.234664: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n2023-09-22 20:16:04.234793: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Interpreting non ascii codepoint 140.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n2023-09-22 20:16:04.244530: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse Conv2d_FPE.tflite as text proto\r\n2023-09-22 20:16:04.244570: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.009926s\r\n```", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61902\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61902\">No</a>\n", "> ```shell\r\n> ./benchmark_model --graph=../poc/Conv2d_FPE.tflite\r\n> ```\r\n\r\nI'm sorry for the delayed response. I don't think it's a Bazel version issue. It's possible that the way I'm building differs from yours.\r\n\r\nI'm using the build method recommended in [this official guide](https://www.tensorflow.org/lite/guide/build_cmake#step_1_install_cmake_tool), as follows:\r\n1. git clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\n2. mkdir tflite_build\r\ncd tflite_build\r\n3. cmake ../tensorflow_src/tensorflow/lite\r\n4. cmake --build . -j\r\n5. cmake --build . -j -t benchmark_model\r\n\r\nThe benchmark is in the tools directory\r\nI still encounter the same issue in the latest code, commit id: abbbcb50208cf6d5a965b7bf60efec5bb078e142.\r\n\r\n", "> Hi I'm getting a different error, can you ensure you have built your benchmark_model executable with more recent code? and your file is uploaded correctly?\r\n> \r\n> ```\r\n> ./benchmark_model --graph=Conv2d_FPE.tflite\r\n> 2023-09-22 20:16:04.234199: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [Conv2d_FPE.tflite]\r\n> 2023-09-22 20:16:04.234281: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n> 2023-09-22 20:16:04.234289: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n> 2023-09-22 20:16:04.234294: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n> 2023-09-22 20:16:04.234298: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n> 2023-09-22 20:16:04.234302: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n> 2023-09-22 20:16:04.234315: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n> 2023-09-22 20:16:04.234352: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n> 2023-09-22 20:16:04.234371: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n> 2023-09-22 20:16:04.234381: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n> 2023-09-22 20:16:04.234411: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n> 2023-09-22 20:16:04.234570: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n> 2023-09-22 20:16:04.234592: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n> 2023-09-22 20:16:04.234606: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n> 2023-09-22 20:16:04.234620: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n> 2023-09-22 20:16:04.234634: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n> 2023-09-22 20:16:04.234664: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n> 2023-09-22 20:16:04.234793: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\n> To enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Interpreting non ascii codepoint 140.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:33: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n> 2023-09-22 20:16:04.244530: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse Conv2d_FPE.tflite as text proto\r\n> 2023-09-22 20:16:04.244570: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.009926s\r\n> ```\r\n\r\nI'm sorry for the delayed response. I don't think it's a Bazel version issue. It's possible that the way I'm building differs from yours.\r\n\r\nI'm using the build method recommended in [this official guide](https://www.tensorflow.org/lite/guide/build_cmake#step_1_install_cmake_tool), as follows:\r\n1. git clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\n2. mkdir tflite_build\r\ncd tflite_build\r\n3. cmake ../tensorflow_src/tensorflow/lite\r\n4. cmake --build . -j\r\n5. cmake --build . -j -t benchmark_model\r\n\r\nThe benchmark is in the tools directory\r\nI still encounter the same issue in the latest code, commit id: abbbcb50208cf6d5a965b7bf60efec5bb078e142.", "I was able to replicate with updated steps:\r\n\r\n```sh\r\ngit clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\nmkdir tflite_build\r\ncd tflite_build\r\ncmake ../tensorflow_src/tensorflow/lite\r\ncmake --build . -j\r\ncmake --build . -j -t benchmark_model\r\ncd tools/benchmark\r\ncp path/to/Conv2d_FPE.tflite .\r\n./benchmark_model --graph=Conv2d_FPE.tflite\r\n```\r\n```\r\n./benchmark_model --graph=Conv2d_FPE.tflite\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [Conv2d_FPE.tflite]\r\nINFO: Loaded model Conv2d_FPE.tflite\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\nINFO: The input model file size (MB): 0.000708\r\nINFO: Initialized session in 1.411ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nFloating point exception\r\n```\r\n\r\nHi @nutsiepully, can you please take a look? Thanks." ]
2023-09-19T03:35:38
2023-10-10T22:45:52
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.14.0 ### Custom code Yes ### OS platform and distribution Ubuntu 18.04.6 ### Mobile device Ubuntu 18.04.6 ### Python version Python 3.8.3 ### Bazel version bazel 5.3.0 ### GCC/compiler version gcc 7.5.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Construct a malicious Conv2d operator model, so that `stride_width` and `stride_height` are set to 0. In the `eigen_spatial_convolutions-inl.h` file, having the `row_stride` and `col_stride` variables set to 0 leads to a division by zero exception. ```cpp // eigen_spatial_convolutions-inl.h SpatialConvolution(const Input& input, const Kernel& kernel, const Index row_stride = 1, const Index col_stride = 1, const PaddingType padding_type = PADDING_SAME, const Index row_in_stride = 1, const Index col_in_stride = 1, const OutputKernel& output_kernel = OutputKernel(), Index padding_top = 0, Index padding_bottom = 0, Index padding_left = 0, Index padding_right = 0) { ... case PADDING_SAME: { eigen_assert(!padding_explicit); out_height = divup(InputRows, row_stride); // FPE out_width = divup(InputCols, col_stride); ``` [Conv2d_FPE.zip](https://github.com/tensorflow/tensorflow/files/12655589/Conv2d_FPE.zip) ### Standalone code to reproduce the issue ```shell When I use the benchmark tool for PoC validation, it causes the TensorFlow Lite inference process to be subjected to a DOS(coredump). ❯ ./benchmark_model --graph=../poc/Conv2d_FPE.tflite INFO: STARTING! INFO: Log parameter values verbosely: [0] INFO: Graph: [../poc/Conv2d_FPE.tflite] INFO: Loaded model ../poc/Conv2d_FPE.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. INFO: The input model file size (MB): 0.000708 INFO: Initialized session in 31.286ms. INFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds. [1] 24937 floating point exception (core dumped) ./benchmark_model --graph=../poc/Conv2d_FPE.tflite ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61902/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61902/timeline
null
reopened
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61901
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61901/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61901/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61901/events
https://github.com/tensorflow/tensorflow/issues/61901
1,902,138,193
I_kwDOArmXAs5xYFNR
61,901
FPE in BatchMatMul
{ "login": "SiriusHsh", "id": 20510239, "node_id": "MDQ6VXNlcjIwNTEwMjM5", "avatar_url": "https://avatars.githubusercontent.com/u/20510239?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SiriusHsh", "html_url": "https://github.com/SiriusHsh", "followers_url": "https://api.github.com/users/SiriusHsh/followers", "following_url": "https://api.github.com/users/SiriusHsh/following{/other_user}", "gists_url": "https://api.github.com/users/SiriusHsh/gists{/gist_id}", "starred_url": "https://api.github.com/users/SiriusHsh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SiriusHsh/subscriptions", "organizations_url": "https://api.github.com/users/SiriusHsh/orgs", "repos_url": "https://api.github.com/users/SiriusHsh/repos", "events_url": "https://api.github.com/users/SiriusHsh/events{/privacy}", "received_events_url": "https://api.github.com/users/SiriusHsh/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
closed
false
{ "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false }
[ { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @SiriusHsh, I'm getting a different error, this is with branch r2.14 and gcc, my bazel is more up to date (6.1.0):\r\n\r\n```\r\n./benchmark_model --graph=BatchMatMul_FPE.tflite\r\n2023-09-22 20:08:07.554231: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [BatchMatMul_FPE.tflite]\r\n2023-09-22 20:08:07.554309: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n2023-09-22 20:08:07.554321: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n2023-09-22 20:08:07.554329: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n2023-09-22 20:08:07.554337: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n2023-09-22 20:08:07.554344: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n2023-09-22 20:08:07.554352: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n2023-09-22 20:08:07.554376: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n2023-09-22 20:08:07.554398: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n2023-09-22 20:08:07.554417: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n2023-09-22 20:08:07.554433: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n2023-09-22 20:08:07.554448: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n2023-09-22 20:08:07.554457: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n2023-09-22 20:08:07.554471: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n2023-09-22 20:08:07.554488: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n2023-09-22 20:08:07.554502: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n2023-09-22 20:08:07.554521: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n2023-09-22 20:08:07.554619: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Interpreting non ascii codepoint 132.\r\n[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n2023-09-22 20:08:07.564334: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse BatchMatMul_FPE.tflite as text proto\r\n2023-09-22 20:08:07.564384: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.009869s\r\n```\r\n\r\nDid you upload the right file? Can you try with an updated Bazel?", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61901\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61901\">No</a>\n", "> Hi @SiriusHsh, I'm getting a different error, this is with branch r2.14 and gcc, my bazel is more up to date (6.1.0):\r\n> \r\n> ```\r\n> ./benchmark_model --graph=BatchMatMul_FPE.tflite\r\n> 2023-09-22 20:08:07.554231: I tensorflow/tools/benchmark/benchmark_model.cc:475] Graph: [BatchMatMul_FPE.tflite]\r\n> 2023-09-22 20:08:07.554309: I tensorflow/tools/benchmark/benchmark_model.cc:476] Init ops:\r\n> 2023-09-22 20:08:07.554321: I tensorflow/tools/benchmark/benchmark_model.cc:477] Input layers: [input:0]\r\n> 2023-09-22 20:08:07.554329: I tensorflow/tools/benchmark/benchmark_model.cc:478] Input shapes: [1,224,224,3]\r\n> 2023-09-22 20:08:07.554337: I tensorflow/tools/benchmark/benchmark_model.cc:479] Input types: [float]\r\n> 2023-09-22 20:08:07.554344: I tensorflow/tools/benchmark/benchmark_model.cc:480] Output layers: [output:0]\r\n> 2023-09-22 20:08:07.554352: I tensorflow/tools/benchmark/benchmark_model.cc:481] Target layers: []\r\n> 2023-09-22 20:08:07.554376: I tensorflow/tools/benchmark/benchmark_model.cc:482] Num runs: [1000]\r\n> 2023-09-22 20:08:07.554398: I tensorflow/tools/benchmark/benchmark_model.cc:483] Inter-inference delay (seconds): [-1.0]\r\n> 2023-09-22 20:08:07.554417: I tensorflow/tools/benchmark/benchmark_model.cc:484] Inter-benchmark delay (seconds): [-1.0]\r\n> 2023-09-22 20:08:07.554433: I tensorflow/tools/benchmark/benchmark_model.cc:486] Num threads: [-1]\r\n> 2023-09-22 20:08:07.554448: I tensorflow/tools/benchmark/benchmark_model.cc:487] Benchmark name: []\r\n> 2023-09-22 20:08:07.554457: I tensorflow/tools/benchmark/benchmark_model.cc:488] Output prefix: []\r\n> 2023-09-22 20:08:07.554471: I tensorflow/tools/benchmark/benchmark_model.cc:489] Show sizes: [0]\r\n> 2023-09-22 20:08:07.554488: I tensorflow/tools/benchmark/benchmark_model.cc:490] Warmup runs: [1]\r\n> 2023-09-22 20:08:07.554502: I tensorflow/tools/benchmark/benchmark_model.cc:256] Loading TensorFlow.\r\n> 2023-09-22 20:08:07.554521: I tensorflow/tools/benchmark/benchmark_model.cc:264] Got config, 0 devices\r\n> 2023-09-22 20:08:07.554619: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\n> To enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:1: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:9: Invalid control characters encountered in text.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Interpreting non ascii codepoint 132.\r\n> [libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/text_format.cc:337] Error parsing text-format tensorflow.GraphDef: 1:45: Message type \"tensorflow.GraphDef\" has no field named \"TFL3\".\r\n> 2023-09-22 20:08:07.564334: E tensorflow/tools/benchmark/benchmark_model.cc:275] Could not create TensorFlow Graph: DATA_LOSS: Can't parse BatchMatMul_FPE.tflite as text proto\r\n> 2023-09-22 20:08:07.564384: I tensorflow/tools/benchmark/benchmark_model.cc:502] Initialized session in 0.009869s\r\n> ```\r\n> \r\n> Did you upload the right file? Can you try with an updated Bazel?\r\n\r\nI'm sorry for the delayed response. I don't think it's a Bazel version issue. It's possible that the way I'm building differs from yours.\r\n\r\nI'm using the build method recommended in [this official guide](https://www.tensorflow.org/lite/guide/build_cmake#step_1_install_cmake_tool), as follows:\r\n1. git clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\n2. mkdir tflite_build\r\ncd tflite_build\r\n3. cmake ../tensorflow_src/tensorflow/lite\r\n4. cmake --build . -j\r\n5. cmake --build . -j -t benchmark_model\r\n\r\nThe benchmark is in the tools directory\r\nI still encounter the same issue in the latest code, commit id: abbbcb50208cf6d5a965b7bf60efec5bb078e142.", "Hi @SiriusHsh, I wasn't able to reproduce this one:\r\n\r\n```sh\r\ngit clone https://github.com/tensorflow/tensorflow.git tensorflow_src\r\nmkdir tflite_build\r\ncd tflite_build\r\ncmake ../tensorflow_src/tensorflow/lite\r\ncmake --build . -j\r\ncmake --build . -j -t benchmark_model\r\ncd tools/benchmark\r\ncp path/to/BatchMatMul_FPE.tflite .\r\n./benchmark_model --graph=BatchMatMul_FPE.tflite\r\n```\r\n```\r\n./benchmark_model --graph=BatchMatMul_FPE.tflite\r\nINFO: STARTING!\r\nINFO: Log parameter values verbosely: [0]\r\nINFO: Graph: [BatchMatMul_FPE.tflite]\r\nINFO: Loaded model BatchMatMul_FPE.tflite\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\nINFO: The input model file size (MB): 0.0006\r\nINFO: Initialized session in 1.486ms.\r\nINFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=1785957 first=3 curr=1 min=0 max=78 avg=0.193891 std=0\r\n\r\nINFO: Running benchmark for at least 50 iterations and at least 1 seconds but terminate if exceeding 150 seconds.\r\nINFO: count=3571192 first=1 curr=1 min=0 max=101 avg=0.193897 std=0\r\n\r\nINFO: Inference timings in us: Init: 1486, First inference: 3, Warmup (avg): 0.193891, Inference (avg): 0.193897\r\nINFO: Note: as the benchmark tool itself affects memory footprint, the following is only APPROXIMATE to the actual memory footprint of the model at runtime. Take the information at your discretion.\r\nINFO: Memory footprint delta from the start of the tool (MB): init=3 overall=3\r\n```\r\n\r\nCan you verify if you uploaded the same model file or if somehow the latest code resolve this issue? Thanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61901\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61901\">No</a>\n" ]
2023-09-19T03:22:58
2023-10-26T01:47:30
2023-10-26T01:47:27
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version tf 2.14.0 ### Custom code Yes ### OS platform and distribution Ubuntu 18.04.6 ### Mobile device _No response_ ### Python version Python 3.8.3 ### Bazel version bazel 5.3.0 ### GCC/compiler version gcc 7.5.0 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Construct a malicious BatchMatMul operator model with a shape of 4x0x0x0. The `input_shape.Dims(i)` variable may be equal to 0, leading to a division by zero error. ```cpp // transpose_utils.cc size_t Flatten(const RuntimeShape& input_shape, const RuntimeShape& output_shape, const TransposeParams& params, RuntimeShape* non_flatten_input_shape, RuntimeShape* non_flatten_output_shape, TransposeParams* non_flatten_params) { // Calculate the total size of non-flatten dimensions. int skip_dims_cnt = 0; size_t flat_size = input_shape.FlatSize(); for (int i = 0; i < params.perm_count; ++i) { if (params.perm[i] == i) { flat_size /= input_shape.Dims(i); // FPE ``` [BatchMatMul_FPE.zip](https://github.com/tensorflow/tensorflow/files/12655488/BatchMatMul_FPE.zip) ### Standalone code to reproduce the issue ```shell When I use the benchmark tool for PoC validation, it causes the TensorFlow Lite inference process to be subjected to a DOS(coredump). ❯ ./benchmark_model --graph=../poc/BatchMatMul_FPE.tflite INFO: STARTING! INFO: Log parameter values verbosely: [0] INFO: Graph: [../poc/BatchMatMul_FPE.tflite] INFO: Loaded model ../poc/BatchMatMul_FPE.tflite INFO: Created TensorFlow Lite XNNPACK delegate for CPU. INFO: The input model file size (MB): 0.0006 INFO: Initialized session in 155.728ms. INFO: Running benchmark for at least 1 iterations and at least 0.5 seconds but terminate if exceeding 150 seconds. [1] 26298 floating point exception (core dumped) ./benchmark_model --graph=../poc/BatchMatMul_FPE.tflite ``` ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61901/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61901/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61900
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61900/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61900/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61900/events
https://github.com/tensorflow/tensorflow/issues/61900
1,901,716,793
I_kwDOArmXAs5xWeU5
61,900
module 'tensorflow.python.distribute.input_lib' has no attribute 'DistributedDatasetInterface'
{ "login": "ls433", "id": 128412012, "node_id": "U_kgDOB6dpbA", "avatar_url": "https://avatars.githubusercontent.com/u/128412012?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ls433", "html_url": "https://github.com/ls433", "followers_url": "https://api.github.com/users/ls433/followers", "following_url": "https://api.github.com/users/ls433/following{/other_user}", "gists_url": "https://api.github.com/users/ls433/gists{/gist_id}", "starred_url": "https://api.github.com/users/ls433/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ls433/subscriptions", "organizations_url": "https://api.github.com/users/ls433/orgs", "repos_url": "https://api.github.com/users/ls433/repos", "events_url": "https://api.github.com/users/ls433/events{/privacy}", "received_events_url": "https://api.github.com/users/ls433/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "same question", "@ls433 \r\n**tensorflow/python/keras** code is a legacy copy of Keras since the TensorFlow v2.7 release. Please remove any import of **tensorflow.python.keras** and use the public API **from tensorflow import keras** or **import tensorflow as tf**; **tf.keras**.\r\n\r\nThank you!", "> @ls433 **tensorflow/python/keras** code is a legacy copy of Keras since the TensorFlow v2.7 release. Please remove any import of **tensorflow.python.keras** and use the public API **from tensorflow import keras** or **import tensorflow as tf**; **tf.keras**.\r\n> \r\n> Thank you!\r\n\r\nThanks for the comment but unfortunately that doesn't work. \r\n\r\nI feel that I am missing something. How would you rewrite my importing of the libraries? The reason I ask is that the moment I remove the keyword 'python' it throws an immediate syntax error.\r\n\r\nWhat I have found is that I can fix the issue by uninstalling the current version of tensor flow and instead installing a previous version (tensor flow version 2.12.0).\r\n\r\nBut I would prefer to understand what you are stating. So could you show me how to rewrite my code for importing the libraries correctly?\r\n\r\nThanks ", "@ls433 Thank you for your response here. As per your previous comment, is the issue not replicating in TF v2.12? \r\nCould you please confirm if the issue still replicates in TF v2,14?\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61900\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61900\">No</a>\n", "https://stackoverflow.com/a/77733620/13086128", "> @ls433 **tensorflow/python/keras** code is a legacy copy of Keras since the TensorFlow v2.7 release. Please remove any import of **tensorflow.python.keras** and use the public API **from tensorflow import keras** or **import tensorflow as tf**; **tf.keras**.\r\n> \r\n> Thank you!\r\n\r\nif i remove [ from tensorflow.python.keras import * ] this as you suggest, other part of the code doesn't work. tensorflow.python.keras is very important for other part of the code sir. " ]
2023-09-18T20:47:45
2024-04-30T10:18:50
2023-10-19T01:48:00
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13.0 ### Custom code Yes ### OS platform and distribution Google Colab ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Very new to coding so am unfamiliar with what to say. I used tensor flow to run a model to find the best fitted line. Last week the model run perfectly. This week the script incurs an error upon running the model. Ran a script that was even older and incurred that same problem. Had read that the issue is to do with conflict between _tensorflow_ and _keras_ but I don't understand what that means with relation to my code. I also read not to use the term 'python' when importing a library. from tensorflow.**python**.keras.models import Sequential I have to use 'python' as part of the syntax as google colab reports this message if I don't _Import "tensorflow.keras.models" could not be resolved(reportMissingImports)_ Is this something to so with my google colab environment? I updated tensorflow to the latest version but the problem still exists. I have no idea what to do and am quite stuck. ### Standalone code to reproduce the issue ```shell import tensorflow as tf from tensorflow.python.keras.models import Sequential from tensorflow.python.keras.layers import Dense from tensorflow.python.keras.activations import linear from tensorflow.python.keras.optimizers import adam_v2 from tensorflow.python.keras.losses import MeanSquaredError x = [ [23], [45], [78], [12]] y = [ [12], [22], [36], [6]] model = Sequential([ tf.keras.layers.Dense(units=25, activation='relu', name='layer1'), tf.keras.layers.Dense(input_shape=(25,), units=15, activation='relu', name='layer2'), tf.keras.layers.Dense(input_shape=(15,), units=1, activation='linear', name='layer3') ] ,name="Model1" ) loss=MeanSquaredError() opt=adam_v2.Adam(learning_rate=0.001) model.compile( loss=loss, optimizer=opt ) model.fit(x, y, epochs=100) ``` ### Relevant log output ```shell AttributeError Traceback (most recent call last) <ipython-input-27-a1b963ff7586> in <cell line: 26>() 24 optimizer=opt 25 ) ---> 26 model.fit(x, y, epochs=100) 6 frames /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/training.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, validation_batch_size, validation_freq, max_queue_size, workers, use_multiprocessing) 1136 training_utils.RespectCompiledTrainableState(self): 1137 # Creates a `tf.data.Dataset` and handles batch and epoch iteration. -> 1138 data_handler = data_adapter.get_data_handler( 1139 x=x, 1140 y=y, /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in get_data_handler(*args, **kwargs) 1396 if getattr(kwargs["model"], "_cluster_coordinator", None): 1397 return _ClusterCoordinatorDataHandler(*args, **kwargs) -> 1398 return DataHandler(*args, **kwargs) 1399 1400 /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in __init__(self, x, y, sample_weight, batch_size, steps_per_epoch, initial_epoch, epochs, shuffle, class_weight, max_queue_size, workers, use_multiprocessing, model, steps_per_execution, distribute) 1150 self._steps_per_execution_value = steps_per_execution.numpy().item() 1151 -> 1152 adapter_cls = select_data_adapter(x, y) 1153 self._adapter = adapter_cls( 1154 x, /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in select_data_adapter(x, y) 986 def select_data_adapter(x, y): 987 """Selects a data adapter than can handle a given x and y.""" --> 988 adapter_cls = [cls for cls in ALL_ADAPTER_CLS if cls.can_handle(x, y)] 989 if not adapter_cls: 990 # TODO(scottzhu): This should be a less implementation-specific error. /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in <listcomp>(.0) 986 def select_data_adapter(x, y): 987 """Selects a data adapter than can handle a given x and y.""" --> 988 adapter_cls = [cls for cls in ALL_ADAPTER_CLS if cls.can_handle(x, y)] 989 if not adapter_cls: 990 # TODO(scottzhu): This should be a less implementation-specific error. /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in can_handle(x, y) 705 def can_handle(x, y=None): 706 return (isinstance(x, (data_types.DatasetV1, data_types.DatasetV2)) or --> 707 _is_distributed_dataset(x)) 708 709 def __init__(self, /usr/local/lib/python3.10/dist-packages/tensorflow/python/keras/engine/data_adapter.py in _is_distributed_dataset(ds) 1697 1698 def _is_distributed_dataset(ds): -> 1699 return isinstance(ds, input_lib.DistributedDatasetInterface) AttributeError: module 'tensorflow.python.distribute.input_lib' has no attribute 'DistributedDatasetInterface' ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61900/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61900/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61899
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61899/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61899/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61899/events
https://github.com/tensorflow/tensorflow/issues/61899
1,901,625,764
I_kwDOArmXAs5xWIGk
61,899
TFLite model cannot slice a zero-dim tensor
{ "login": "dengyinlin", "id": 30567397, "node_id": "MDQ6VXNlcjMwNTY3Mzk3", "avatar_url": "https://avatars.githubusercontent.com/u/30567397?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dengyinlin", "html_url": "https://github.com/dengyinlin", "followers_url": "https://api.github.com/users/dengyinlin/followers", "following_url": "https://api.github.com/users/dengyinlin/following{/other_user}", "gists_url": "https://api.github.com/users/dengyinlin/gists{/gist_id}", "starred_url": "https://api.github.com/users/dengyinlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dengyinlin/subscriptions", "organizations_url": "https://api.github.com/users/dengyinlin/orgs", "repos_url": "https://api.github.com/users/dengyinlin/repos", "events_url": "https://api.github.com/users/dengyinlin/events{/privacy}", "received_events_url": "https://api.github.com/users/dengyinlin/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" } ]
open
false
{ "login": "haozha111", "id": 6316921, "node_id": "MDQ6VXNlcjYzMTY5MjE=", "avatar_url": "https://avatars.githubusercontent.com/u/6316921?v=4", "gravatar_id": "", "url": "https://api.github.com/users/haozha111", "html_url": "https://github.com/haozha111", "followers_url": "https://api.github.com/users/haozha111/followers", "following_url": "https://api.github.com/users/haozha111/following{/other_user}", "gists_url": "https://api.github.com/users/haozha111/gists{/gist_id}", "starred_url": "https://api.github.com/users/haozha111/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/haozha111/subscriptions", "organizations_url": "https://api.github.com/users/haozha111/orgs", "repos_url": "https://api.github.com/users/haozha111/repos", "events_url": "https://api.github.com/users/haozha111/events{/privacy}", "received_events_url": "https://api.github.com/users/haozha111/received_events", "type": "User", "site_admin": false }
[ { "login": "haozha111", "id": 6316921, "node_id": "MDQ6VXNlcjYzMTY5MjE=", "avatar_url": "https://avatars.githubusercontent.com/u/6316921?v=4", "gravatar_id": "", "url": "https://api.github.com/users/haozha111", "html_url": "https://github.com/haozha111", "followers_url": "https://api.github.com/users/haozha111/followers", "following_url": "https://api.github.com/users/haozha111/following{/other_user}", "gists_url": "https://api.github.com/users/haozha111/gists{/gist_id}", "starred_url": "https://api.github.com/users/haozha111/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/haozha111/subscriptions", "organizations_url": "https://api.github.com/users/haozha111/orgs", "repos_url": "https://api.github.com/users/haozha111/repos", "events_url": "https://api.github.com/users/haozha111/events{/privacy}", "received_events_url": "https://api.github.com/users/haozha111/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "I was able to reproduce this issue. Please find this [gist](https://colab.research.google.com/gist/pjpratik/d4ec293ef89703c4a3eb2c119ae4ec9b/61899.ipynb) and also a similiar issue #57084.\r\n\r\n@pkgoogle Could you please look into this issue?\r\n\r\nThanks.", "I was able to reproduce with the same gists, while we don't necessarily guarantee consistent behavior between Keras API and TFLite, this might be worth a look. @haozha111 can you please take a look? Do we expect TFLite to behave this way, should we standardize to Keras API behavior?" ]
2023-09-18T19:42:59
2023-09-22T19:14:10
null
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04 - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0-dev20230918 ### 2. Code ``` import tensorflow as tf class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() def call(self, x): values, indices = tf.math.top_k(x, k=2, sorted=False) y = tf.slice(values, tf.constant([0, 0]), tf.constant([0, 1])) return y # Initializing the model m = Model() # Inputs to the model x = tf.constant([1., 2.], shape=[1, 2]) expected_value = m(x) print(expected_value.numpy()) converter = tf.lite.TFLiteConverter.from_keras_model(m) tflite_model = converter.convert() def _evaluateTFLiteModel(tflite_model, input_data): interpreter = tf.lite.Interpreter(model_content=tflite_model) interpreter.allocate_tensors() input_details = interpreter.get_input_details() output_details = interpreter.get_output_details() for i in range(len(input_data)): interpreter.set_tensor(input_details[i]['index'], input_data[i]) interpreter.invoke() output_data = [interpreter.get_tensor(output_details[i]['index']) for i in range(len(output_details))] return output_data actual_value = _evaluateTFLiteModel(tflite_model,[x]) print('tflite model output:') print(actual_value[0]) ``` ### 3. Failure after conversion Output: ``` keras model output: [] ... ValueError: Invalid tensor size. ``` The conversion is successful, but it throws an error during inference. This is because the `size` to `tf.slice` contains zero. If we change `size` to `[1,1]`, there's no error. I think tflite model should support slice size = 0, similar to the original model.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61899/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61899/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61898
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61898/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61898/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61898/events
https://github.com/tensorflow/tensorflow/issues/61898
1,901,585,168
I_kwDOArmXAs5xV-MQ
61,898
Extra semicolon in tensorflow/lite/micro/micro_profiler.h:90
{ "login": "matthewbstokes-zz", "id": 1340077, "node_id": "MDQ6VXNlcjEzNDAwNzc=", "avatar_url": "https://avatars.githubusercontent.com/u/1340077?v=4", "gravatar_id": "", "url": "https://api.github.com/users/matthewbstokes-zz", "html_url": "https://github.com/matthewbstokes-zz", "followers_url": "https://api.github.com/users/matthewbstokes-zz/followers", "following_url": "https://api.github.com/users/matthewbstokes-zz/following{/other_user}", "gists_url": "https://api.github.com/users/matthewbstokes-zz/gists{/gist_id}", "starred_url": "https://api.github.com/users/matthewbstokes-zz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/matthewbstokes-zz/subscriptions", "organizations_url": "https://api.github.com/users/matthewbstokes-zz/orgs", "repos_url": "https://api.github.com/users/matthewbstokes-zz/repos", "events_url": "https://api.github.com/users/matthewbstokes-zz/events{/privacy}", "received_events_url": "https://api.github.com/users/matthewbstokes-zz/received_events", "type": "User", "site_admin": false }
[ { "id": 284443156, "node_id": "MDU6TGFiZWwyODQ0NDMxNTY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:docs-bug", "name": "type:docs-bug", "color": "159b2e", "default": false, "description": "Document issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1589976566, "node_id": "MDU6TGFiZWwxNTg5OTc2NTY2", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:micro", "name": "comp:micro", "color": "3e2eea", "default": false, "description": "Related to TensorFlow Lite Microcontrollers" } ]
closed
false
{ "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false }
[ { "login": "tilakrayal", "id": 81610181, "node_id": "MDQ6VXNlcjgxNjEwMTgx", "avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tilakrayal", "html_url": "https://github.com/tilakrayal", "followers_url": "https://api.github.com/users/tilakrayal/followers", "following_url": "https://api.github.com/users/tilakrayal/following{/other_user}", "gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}", "starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions", "organizations_url": "https://api.github.com/users/tilakrayal/orgs", "repos_url": "https://api.github.com/users/tilakrayal/repos", "events_url": "https://api.github.com/users/tilakrayal/events{/privacy}", "received_events_url": "https://api.github.com/users/tilakrayal/received_events", "type": "User", "site_admin": false } ]
null
[ "@matthewbstokes-zz,\r\nThank you for pointing out the error. As this issue is related to **tf-lite/micro**, I raised the PR for the above mentioned error. Kindly find the PR details [here](https://github.com/tensorflow/tflite-micro/pull/2235) and will update once the related PR gets merged. Thank you!", "@matthewbstokes-zz,\r\nThe related PR got merged and the changes have been done in the mentioned file. Kindly find the reference below\r\nhttps://github.com/tensorflow/tflite-micro/pull/2235\r\n\r\nhttps://github.com/tensorflow/tflite-micro/blob/main/tensorflow/lite/micro/micro_profiler.h#L90\r\n\r\n```\r\n TicksPerTag total_ticks_per_tag[kMaxEvents] = {};\r\n\r\n int FindExistingOrNextPosition(const char* tag_name);\r\n\r\n TF_LITE_REMOVE_VIRTUAL_DELETE\r\n};\r\n\r\n#if defined(TF_LITE_STRIP_ERROR_STRINGS)\r\n```\r\n\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61898\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61898\">No</a>\n" ]
2023-09-18T19:14:32
2023-10-07T01:47:32
2023-10-07T01:47:29
NONE
null
null
null
Remove extra semicolon in tensorflow/lite/micro/micro_profiler.h on line 90 Before: ``` TF_LITE_REMOVE_VIRTUAL_DELETE; ``` After: ``` TF_LITE_REMOVE_VIRTUAL_DELETE ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61898/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61898/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61897
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61897/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61897/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61897/events
https://github.com/tensorflow/tensorflow/pull/61897
1,901,333,833
PR_kwDOArmXAs5alzn6
61,897
lite: Add config option to enable benchmark_model
{ "login": "jameshilliard", "id": 3298484, "node_id": "MDQ6VXNlcjMyOTg0ODQ=", "avatar_url": "https://avatars.githubusercontent.com/u/3298484?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jameshilliard", "html_url": "https://github.com/jameshilliard", "followers_url": "https://api.github.com/users/jameshilliard/followers", "following_url": "https://api.github.com/users/jameshilliard/following{/other_user}", "gists_url": "https://api.github.com/users/jameshilliard/gists{/gist_id}", "starred_url": "https://api.github.com/users/jameshilliard/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jameshilliard/subscriptions", "organizations_url": "https://api.github.com/users/jameshilliard/orgs", "repos_url": "https://api.github.com/users/jameshilliard/repos", "events_url": "https://api.github.com/users/jameshilliard/events{/privacy}", "received_events_url": "https://api.github.com/users/jameshilliard/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1169364458, "node_id": "MDU6TGFiZWwxMTY5MzY0NDU4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S", "name": "size:S", "color": "adafea", "default": false, "description": "CL Change Size: Small" } ]
open
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @jameshilliard Can you please resolve conflicts? Thank you!", "rebased", "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @arfaian Can you please review this PR ? Thank you!", "Hi @arfaian Can you please review this PR ? Thank you!" ]
2023-09-18T16:37:33
2024-06-07T16:14:14
null
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61897", "html_url": "https://github.com/tensorflow/tensorflow/pull/61897", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61897.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61897.patch", "merged_at": null }
It's handy to have an option to enable the benchmark_model tool so that it can be built and installed using the all target which is preferable in some cases when packaging tensorflow-lite. This is the `benchmark_model` equivalent of #60021.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61897/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61897/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61896
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61896/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61896/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61896/events
https://github.com/tensorflow/tensorflow/issues/61896
1,901,294,381
I_kwDOArmXAs5xU3Mt
61,896
Why are not all of my conv2d layer weights Int8 when converting with dynamic range quantization?
{ "login": "christian-steinmeyer", "id": 7511021, "node_id": "MDQ6VXNlcjc1MTEwMjE=", "avatar_url": "https://avatars.githubusercontent.com/u/7511021?v=4", "gravatar_id": "", "url": "https://api.github.com/users/christian-steinmeyer", "html_url": "https://github.com/christian-steinmeyer", "followers_url": "https://api.github.com/users/christian-steinmeyer/followers", "following_url": "https://api.github.com/users/christian-steinmeyer/following{/other_user}", "gists_url": "https://api.github.com/users/christian-steinmeyer/gists{/gist_id}", "starred_url": "https://api.github.com/users/christian-steinmeyer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/christian-steinmeyer/subscriptions", "organizations_url": "https://api.github.com/users/christian-steinmeyer/orgs", "repos_url": "https://api.github.com/users/christian-steinmeyer/repos", "events_url": "https://api.github.com/users/christian-steinmeyer/events{/privacy}", "received_events_url": "https://api.github.com/users/christian-steinmeyer/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 2671351731, "node_id": "MDU6TGFiZWwyNjcxMzUxNzMx", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ModelOptimizationToolkit", "name": "ModelOptimizationToolkit", "color": "BFD629", "default": false, "description": "TF Model Optimization Toolkit" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "abattery", "id": 3203059, "node_id": "MDQ6VXNlcjMyMDMwNTk=", "avatar_url": "https://avatars.githubusercontent.com/u/3203059?v=4", "gravatar_id": "", "url": "https://api.github.com/users/abattery", "html_url": "https://github.com/abattery", "followers_url": "https://api.github.com/users/abattery/followers", "following_url": "https://api.github.com/users/abattery/following{/other_user}", "gists_url": "https://api.github.com/users/abattery/gists{/gist_id}", "starred_url": "https://api.github.com/users/abattery/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abattery/subscriptions", "organizations_url": "https://api.github.com/users/abattery/orgs", "repos_url": "https://api.github.com/users/abattery/repos", "events_url": "https://api.github.com/users/abattery/events{/privacy}", "received_events_url": "https://api.github.com/users/abattery/received_events", "type": "User", "site_admin": false }
[ { "login": "abattery", "id": 3203059, "node_id": "MDQ6VXNlcjMyMDMwNTk=", "avatar_url": "https://avatars.githubusercontent.com/u/3203059?v=4", "gravatar_id": "", "url": "https://api.github.com/users/abattery", "html_url": "https://github.com/abattery", "followers_url": "https://api.github.com/users/abattery/followers", "following_url": "https://api.github.com/users/abattery/following{/other_user}", "gists_url": "https://api.github.com/users/abattery/gists{/gist_id}", "starred_url": "https://api.github.com/users/abattery/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abattery/subscriptions", "organizations_url": "https://api.github.com/users/abattery/orgs", "repos_url": "https://api.github.com/users/abattery/repos", "events_url": "https://api.github.com/users/abattery/events{/privacy}", "received_events_url": "https://api.github.com/users/abattery/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Since two people already took a look at this issue: Could you perhaps comment on whether what I experience is to be expected or if it is, indeed, a bug?", "Hi @christian-steinmeyer \r\n\r\nSorry for the delayed response. \r\n\r\nI was able to reproduce the issue for dynamic range quantization, but with representative dataset, the full integer quantization, the conversion works fine. Please find this [gist](https://colab.research.google.com/gist/pjpratik/c44593dbedf19f58327a3e3eb4b44aa2/61896.ipynb).\r\n\r\n@pkgoogle Could you please check this issue?\r\n\r\nThanks.", "Hi @pjpratik and thank you for getting back to me! Just now, using a representative dataset is not an option for me (although it is likely to be a step down the line - so thanks for already checking that it works!). And mostly I am looking for an answer to the question: Did I misunderstand anything or should all conv2d layers have int8 weights?", "Hi @christian-steinmeyer, the default behavior of the quantization system is to fallback to float32 ops if the converter finds it impossible (for various reasons) to convert the entire model to int8 ... that being said if it is possible to convert it to int8 and it doesn't, then that's a bug. So unless explicitly stated otherwise, you can expect the default behavior.", "Thanks for the response @pkgoogle! Are those various reasons documented somewhere?", "Hi @christian-steinmeyer, unfortunately, not that I currently know of .. there are some code changes coming up which will make it more obvious/known to end users (at least when it fails), but it will likely be experimental when first releasing.", "Alright, looking forward to those changes - I suppose they are coming with 2.15?", "@christian-steinmeyer, Unfortunately not, I am not comfortable making a prediction yet on it's release date yet.", "Alright - thanks for the feedback! For the case I posted above, how exactly can I find out if it is expected behavior? Do you know that by chance?\r\n\r\nI created the model using code like this\r\n```py\r\n model = tf.keras.Sequential([\r\n tf.keras.layers.InputLayer(input_shape=(5, None, 1)),\r\n tf.keras.layers.Conv2D(16, (3, 3), padding='same', activation='relu'),\r\n tf.keras.layers.DepthwiseConv2D((3, 3), padding='same'),\r\n tf.keras.layers.Conv2D(16, (3, 3), padding='same', activation='relu'),\r\n tf.keras.layers.AveragePooling2D((3, 3), padding='same'),\r\n ])\r\n```", "Hi @christian-steinmeyer,\r\n\r\nI don't see a reason why that shouldn't be fully convertable, @abattery, can you please take a look? Thanks.", "Hello @christian-steinmeyer, I'm encountering the same problem, some Conv2d layers are DQing into int8 and some are not. Have you found a workaround or the source of the problem? ", "Hi @Doomski99, I have not. Without diving deep into the code, I pretty much just accepted TF's behavior at that point. " ]
2023-09-18T16:17:04
2024-02-15T16:55:18
null
CONTRIBUTOR
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): MacOS Ventura 13.5.2 (22G91) - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.13.0 ### 2. Code I have a [Keras model](https://github.com/tensorflow/tensorflow/files/12650691/model.zip) (here, I uploaded just an untrained sub-model which is equivalent to the beginning of my actual model) and follow the [Post-training dynamic range quantization guide](https://www.tensorflow.org/lite/performance/post_training_quant) to convert it to a tflite model. ```py # model defined above converter = tf.lite.TFLiteConverter.from_keras_model(model) converter.optimizations = [tf.lite.Optimize.DEFAULT] tflite_model = converter.convert() ``` ### 3. Failure after conversion - Model produces correct results, but it is slower than the dynamic range Float16 quantized version. - Tflite model has some Conv2D layers with Int8 weights (expected) and some Conv2D layers with Float32 weights (not expected) ### 5. (optional) Any other info / logs I am confused because I didn't come across any documentation whatsoever stating that only parts of the model might be quantized.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61896/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61896/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61895
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61895/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61895/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61895/events
https://github.com/tensorflow/tensorflow/issues/61895
1,901,256,998
I_kwDOArmXAs5xUuEm
61,895
Building benchmark_model using Buildroot failed
{ "login": "Sourabh-ALTEN", "id": 104615913, "node_id": "U_kgDOBjxP6Q", "avatar_url": "https://avatars.githubusercontent.com/u/104615913?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Sourabh-ALTEN", "html_url": "https://github.com/Sourabh-ALTEN", "followers_url": "https://api.github.com/users/Sourabh-ALTEN/followers", "following_url": "https://api.github.com/users/Sourabh-ALTEN/following{/other_user}", "gists_url": "https://api.github.com/users/Sourabh-ALTEN/gists{/gist_id}", "starred_url": "https://api.github.com/users/Sourabh-ALTEN/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Sourabh-ALTEN/subscriptions", "organizations_url": "https://api.github.com/users/Sourabh-ALTEN/orgs", "repos_url": "https://api.github.com/users/Sourabh-ALTEN/repos", "events_url": "https://api.github.com/users/Sourabh-ALTEN/events{/privacy}", "received_events_url": "https://api.github.com/users/Sourabh-ALTEN/received_events", "type": "User", "site_admin": false }
[ { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 4257391797, "node_id": "LA_kwDOArmXAs79wqS1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/wsl2", "name": "wsl2", "color": "A352E6", "default": false, "description": "Windows Subsystem for Linux" }, { "id": 4829271983, "node_id": "LA_kwDOArmXAs8AAAABH9jXrw", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.11", "name": "TF 2.11", "color": "46B4D7", "default": false, "description": "Issues related to TF 2.11" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "@Sourabh-ALTEN Could you please check if you're using the same compile flags for both libtensorflow-lite.a and minimal. Please try with the latest TF v2.13 and let us know the outcome?\r\nThank you!\r\n\r\n", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61895\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61895\">No</a>\n" ]
2023-09-18T15:56:36
2023-10-10T01:47:26
2023-10-10T01:47:23
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.11.0 ### Custom code Yes ### OS platform and distribution WSL2/Ubuntu 20.04 ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version gcc compiler for aarch64 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? Hello, I am trying to build the benchmark_model from tensorflow-lite using Buildroot for my i.MX 8 platform. The tensorflow-lite and label_image examples are built successfully. But now when I am building the benchmark_model I am getting below error from `benchmark_tflite_model.cc` ``undefined reference to `absl::lts_20220623`` Buildroot is using `cmake` and build command is `/usr/bin/cmake --build /.../build/tensorflow-lite-2.11.0/tensorflow/lite/buildroot-build -t benchmark_model` Same build command was used for label_image and there were no errors related to linking. ### Standalone code to reproduce the issue ```shell `/usr/bin/cmake --build /.../build/tensorflow-lite-2.11.0/tensorflow/lite/buildroot-build -t benchmark_model` ``` ### Relevant log output ```shell [ 98%] Building CXX object tools/benchmark/CMakeFiles/benchmark_model.dir/__/delegates/external_delegate_provider.cc.o [100%] Linking CXX executable benchmark_model ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: CMakeFiles/benchmark_model.dir/benchmark_tflite_model.cc.o: in function `absl::lts_20220623::strings_internal::Splitter<absl::lts_20220623::ByChar, absl::lts_20220623::AllowEmpty, std::basic_string_view<char, std::char_traits<char> > >::ConvertToContainer<std::vector<std::basic_string_view<char, std::char_traits<char> >, std::allocator<std::basic_string_view<char, std::char_traits<char> > > >, std::basic_string_view<char, std::char_traits<char> >, false>::operator()(absl::lts_20220623::strings_internal::Splitter<absl::lts_20220623::ByChar, absl::lts_20220623::AllowEmpty, std::basic_string_view<char, std::char_traits<char> > > const&) const [clone .isra.0]': benchmark_tflite_model.cc:(.text+0x204): undefined reference to `absl::lts_20220623::ByChar::Find(std::basic_string_view<char, std::char_traits<char> >, unsigned long) const' ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: benchmark_tflite_model.cc:(.text+0x284): undefined reference to `absl::lts_20220623::ByChar::Find(std::basic_string_view<char, std::char_traits<char> >, unsigned long) const' ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: CMakeFiles/benchmark_model.dir/benchmark_tflite_model.cc.o: in function `tflite::benchmark::SplitInputLayerNameAndValueFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)': benchmark_tflite_model.cc:(.text+0xcf0): undefined reference to `absl::lts_20220623::StrReplaceAll[abi:cxx11](std::basic_string_view<char, std::char_traits<char> >, std::initializer_list<std::pair<std::basic_string_view<char, std::char_traits<char> >, std::basic_string_view<char, std::char_traits<char> > > >)' ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: benchmark_tflite_model.cc:(.text+0xdd4): undefined reference to `absl::lts_20220623::StrReplaceAll[abi:cxx11](std::basic_string_view<char, std::char_traits<char> >, std::initializer_list<std::pair<std::basic_string_view<char, std::char_traits<char> >, std::basic_string_view<char, std::char_traits<char> > > >)' ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: CMakeFiles/benchmark_model.dir/benchmark_tflite_model.cc.o: in function `tflite::benchmark::BenchmarkTfLiteModel::ValidateParams()': benchmark_tflite_model.cc:(.text+0x8388): undefined reference to `absl::lts_20220623::numbers_internal::safe_strto32_base(std::basic_string_view<char, std::char_traits<char> >, int*, int)' ...per-package/tensorflow-lite/host/opt/ext-toolchain/bin/../lib/gcc/aarch64-buildroot-linux-gnu/10.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: benchmark_tflite_model.cc:(.text+0x83a4): undefined reference to `absl::lts_20220623::numbers_internal::safe_strto32_base(std::basic_string_view<char, std::char_traits<char> >, int*, int)' collect2: error: ld returned 1 exit status ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61895/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61895/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61894
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61894/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61894/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61894/events
https://github.com/tensorflow/tensorflow/pull/61894
1,901,130,459
PR_kwDOArmXAs5alG0g
61,894
Integrate in the linaro fork of the TF docker
{ "login": "MichaelHudgins", "id": 30155094, "node_id": "MDQ6VXNlcjMwMTU1MDk0", "avatar_url": "https://avatars.githubusercontent.com/u/30155094?v=4", "gravatar_id": "", "url": "https://api.github.com/users/MichaelHudgins", "html_url": "https://github.com/MichaelHudgins", "followers_url": "https://api.github.com/users/MichaelHudgins/followers", "following_url": "https://api.github.com/users/MichaelHudgins/following{/other_user}", "gists_url": "https://api.github.com/users/MichaelHudgins/gists{/gist_id}", "starred_url": "https://api.github.com/users/MichaelHudgins/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/MichaelHudgins/subscriptions", "organizations_url": "https://api.github.com/users/MichaelHudgins/orgs", "repos_url": "https://api.github.com/users/MichaelHudgins/repos", "events_url": "https://api.github.com/users/MichaelHudgins/events{/privacy}", "received_events_url": "https://api.github.com/users/MichaelHudgins/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1173072136, "node_id": "MDU6TGFiZWwxMTczMDcyMTM2", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XL", "name": "size:XL", "color": "adafea", "default": false, "description": "CL Change Size:Extra Large" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "CC @elfringham", "@elfringham - there are a few .sh files in here missing the TF copyright header, ci/official/containers/linux_arm64/builder.patchelf/build_patchelf.sh for instance. As i believe you were the original author of these few files can you either confirm my ability to add the TF copyright header or change the upstream to have it? ", "You are ok to add the tf copyright header.\r\n\r\nAndrew\r\n\r\nOn Mon, 18 Sept 2023, 17:15 Michael Hudgins, ***@***.***>\r\nwrote:\r\n\r\n> @elfringham <https://github.com/elfringham> - there are a few .sh files\r\n> in here missing the TF copyright header,\r\n> ci/official/containers/linux_arm64/builder.patchelf/build_patchelf.sh for\r\n> instance. As i believe you were the original author of these few files can\r\n> you either confirm my ability to add the TF copyright header or change the\r\n> upstream to have it?\r\n>\r\n> —\r\n> Reply to this email directly, view it on GitHub\r\n> <https://github.com/tensorflow/tensorflow/pull/61894#issuecomment-1723677467>,\r\n> or unsubscribe\r\n> <https://github.com/notifications/unsubscribe-auth/ACPVKEJDKBC35SFY4C7K563X3BQQRANCNFSM6AAAAAA443SGPI>\r\n> .\r\n> You are receiving this because you were mentioned.Message ID:\r\n> ***@***.***>\r\n>\r\n" ]
2023-09-18T14:56:55
2023-09-18T19:00:52
2023-09-18T19:00:52
COLLABORATOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61894", "html_url": "https://github.com/tensorflow/tensorflow/pull/61894", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61894.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61894.patch", "merged_at": "2023-09-18T19:00:52" }
Pull in the ARM64 docker files to being the process of creating a TF published set of ARM64 docker images. These files will likely be modified somewhat and may not yet ready for use.
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61894/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61894/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61893
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61893/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61893/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61893/events
https://github.com/tensorflow/tensorflow/issues/61893
1,900,910,396
I_kwDOArmXAs5xTZc8
61,893
BMP decode channels = 1 support
{ "login": "yalwan-sage", "id": 82372549, "node_id": "MDQ6VXNlcjgyMzcyNTQ5", "avatar_url": "https://avatars.githubusercontent.com/u/82372549?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yalwan-sage", "html_url": "https://github.com/yalwan-sage", "followers_url": "https://api.github.com/users/yalwan-sage/followers", "following_url": "https://api.github.com/users/yalwan-sage/following{/other_user}", "gists_url": "https://api.github.com/users/yalwan-sage/gists{/gist_id}", "starred_url": "https://api.github.com/users/yalwan-sage/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yalwan-sage/subscriptions", "organizations_url": "https://api.github.com/users/yalwan-sage/orgs", "repos_url": "https://api.github.com/users/yalwan-sage/repos", "events_url": "https://api.github.com/users/yalwan-sage/events{/privacy}", "received_events_url": "https://api.github.com/users/yalwan-sage/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473173272, "node_id": "MDU6TGFiZWw0NzMxNzMyNzI=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature", "name": "type:feature", "color": "159b2e", "default": false, "description": "Feature requests" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false }
[ { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-18T13:11:07
2023-10-19T19:08:02
null
NONE
null
null
null
### Issue type Feature Request ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source binary ### TensorFlow version 2.13.0 ### Custom code No ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? `decode_bmp` to support `channels=1` This seems like an arbitrary limitation to not support this for BMP formats. ### Standalone code to reproduce the issue ```shell import tensorflow image = tensorflow.image.decode_image(bmp_bytes, channels=1) ``` ### Relevant log output ```shell `tensorflow.python.framework.errors_impl.InvalidArgumentError: {{function_node __wrapped__DecodeImage_device_/job:localhost/replica:0/task:0/device:CPU:0}} `channels` must be 0, 3 or 4 for BMP, but got 1 [Op:DecodeImage] name:` ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61893/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61893/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61892
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61892/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61892/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61892/events
https://github.com/tensorflow/tensorflow/pull/61892
1,900,825,564
PR_kwDOArmXAs5akEKn
61,892
Negate the pad values when legalizing transpose_conv2d
{ "login": "jamwar01", "id": 70524219, "node_id": "MDQ6VXNlcjcwNTI0MjE5", "avatar_url": "https://avatars.githubusercontent.com/u/70524219?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jamwar01", "html_url": "https://github.com/jamwar01", "followers_url": "https://api.github.com/users/jamwar01/followers", "following_url": "https://api.github.com/users/jamwar01/following{/other_user}", "gists_url": "https://api.github.com/users/jamwar01/gists{/gist_id}", "starred_url": "https://api.github.com/users/jamwar01/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jamwar01/subscriptions", "organizations_url": "https://api.github.com/users/jamwar01/orgs", "repos_url": "https://api.github.com/users/jamwar01/repos", "events_url": "https://api.github.com/users/jamwar01/events{/privacy}", "received_events_url": "https://api.github.com/users/jamwar01/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
open
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @rsuderman Can you please review this PR ? Thank you!", "Hi @rsuderman Can you please review this PR ? Thank you!", "Hi @jpienaar Can you please review this PR ? Thank you!", "Hi @rdzhabarov Can you please review this PR ? Thank you!", "Hi @jpienaar Can you please review this PR ? Thank you!", "Hi @jpienaar Can you please review this PR ? Thank you!" ]
2023-09-18T12:25:52
2024-06-07T16:14:03
null
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61892", "html_url": "https://github.com/tensorflow/tensorflow/pull/61892", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61892.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61892.patch", "merged_at": null }
Matches the new definition in the specification Change-Id: I4f8dfa3d380039a88b96fd74f09e8f8ebabee3f5
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61892/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61892/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61891
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61891/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61891/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61891/events
https://github.com/tensorflow/tensorflow/issues/61891
1,900,750,056
I_kwDOArmXAs5xSyTo
61,891
TFLite inference order is not the same as TensorFlow model
{ "login": "keltonlee", "id": 68526411, "node_id": "MDQ6VXNlcjY4NTI2NDEx", "avatar_url": "https://avatars.githubusercontent.com/u/68526411?v=4", "gravatar_id": "", "url": "https://api.github.com/users/keltonlee", "html_url": "https://github.com/keltonlee", "followers_url": "https://api.github.com/users/keltonlee/followers", "following_url": "https://api.github.com/users/keltonlee/following{/other_user}", "gists_url": "https://api.github.com/users/keltonlee/gists{/gist_id}", "starred_url": "https://api.github.com/users/keltonlee/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/keltonlee/subscriptions", "organizations_url": "https://api.github.com/users/keltonlee/orgs", "repos_url": "https://api.github.com/users/keltonlee/repos", "events_url": "https://api.github.com/users/keltonlee/events{/privacy}", "received_events_url": "https://api.github.com/users/keltonlee/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false }
[ { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi, i am new around here, and I was hoping for some guidance on how I can contribute to tensorflow specifically and open source in general. \r\n\r\nIs there something i should go through first before giving a shot at this issue?", "Hi, I am also new to TensorFlow lite. You can try this out with a (1, 7, 7, 3) tensor input and will have a (1, 3, 3, 1) output feature map as a result. \r\n\r\n```\r\ncustom_layer = PatchBasedConv2D()\r\ninput_tensor = tf.keras.layers.Input(shape = input_tensor.shape)\r\noutput_tensor = custom_layer(input)\r\nmodel = tf.keras.Model(inputs=input_tensor, outputs=output_tensor)\r\n```\r\nThis would work fine, but my problem is that when I look at the converted tflite model using html, it seems that the inference order has changed. In my custom layer, the inference should be done patch by patch, however, the tflite model expands all the patch first and inference by layer-by-layer.", "Hi @keltonlee, there are a lot of things that happen on conversion such that the architecture does not necessarily stay exactly the same. If you are familiar with how high languages get translated to machine code, you can think of it as how the same program can be translated to a different set of machine instructions. So, this is not necessarily an issue ... unless do you see performance degradation? (either in speed, accuracy, some other ML measure?), is the output extremely different or possibly degenerate for the same input? To give you an idea of you can see the passes that get applied on conversion: https://github.com/tensorflow/tensorflow/blob/master/tensorflow/compiler/mlir/lite/tf_tfl_passes.h and trace through the logic.\r\n\r\nHi @Saurabh-Mokashi, I appreciate your enthusiasm. First review: https://github.com/tensorflow/tensorflow/blob/master/CONTRIBUTING.md\r\n\r\nUnfortunately, I do not know your background so it's hard to say what you should do next, for Tensorflow specifically, I recommend a MOOC or course that teaches TF and related concepts in ML and AI. Create your own custom TF model if you haven't and try to train and evaluate it, perhaps create your own service if you have the skills. For actually adjusting and contributing to the framework, you should start with understanding Python and C++ generally. For most frameworks, Templated Meta Programming in C++ is usually a requirement, we moved to C++17 so be sure to be up to date w/ this version of C++. If you are confident in all that then pick an issue and start digging (you will likely need a debugging tool, logging, or print statements), you will probably get stuck, that means you have something to learn, awesome, go learn it and keep going until you are able to resolve an issue.\r\n\r\nFor TFLite, understand that TF represents everything as a computation graph, and that every computer program can be reduced to a computational graph as well (every computer program can be reduced to a series of machine instructions, which is a very simple graph with nodes in a series -- one input, one output). Thus you can use the same abstractions as compilers to convert/change this computational graph. If you haven't taken a compilers class, this is recommended. Not all issues require all this understanding but if you understand all of the above, contributing will be easier.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61891\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61891\">No</a>\n" ]
2023-09-18T11:41:36
2023-10-04T01:48:19
2023-10-04T01:48:16
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): MacOS - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.13.0 ### 2. Code This is a custom depth-first inference layer, I try it using a (1, 7, 7, 4) tensor, the output is the same as the two layer cnn model and the output size is (1, 3, 3, 1). ``` create_conv_layer1 = Conv2D(filters=4, kernel_size=(3, 3), activation='relu', trainable=False, kernel_initializer=tf.initializers.Constant(0.5)) create_conv_layer2 = Conv2D(filters=1, kernel_size=(3, 3), activation='relu', trainable=False, kernel_initializer=tf.initializers.Constant(0.5)) ``` ``` class PatchBasedConv2D(Layer): def __init__(self, **kwargs): super(PatchBasedConv2D, self).__init__(**kwargs) self.layer_number = 2 self.output_size = (3, 3, 1) self.expand_size = (1, 1) self.patch_stride = None @staticmethod def compute_last_patch_size(output_size, kernel_size, stride): input_height = (output_size[0] - 1) * stride[0] + kernel_size[0] input_width = (output_size[1] - 1) * stride[1] + kernel_size[1] return (input_height, input_width) def calculate_patch_count(self, input_size, patch_size, stride): return ((input_size[0] - patch_size[0]) // stride[0] + 1) * ((input_size[1] - patch_size[1]) // stride[1] + 1) def get_current_patch_possition(self, input_size, patch_size, stride, current_round): return ((current_round // ((input_size[1] - patch_size[1]) // stride[1] + 1)) * stride[0], (current_round % ((input_size[1] - patch_size[1]) // stride[1] + 1)) * stride[1]) def build(self, input_shape): with tf.device('/CPU:0'): self.conv1 = create_conv_layer1 self.conv2 = create_conv_layer2 self.patch_size_tmp = self.compute_last_patch_size(self.expand_size, self.conv2.kernel_size, self.conv2.strides) self.patch_size = self.compute_last_patch_size(self.patch_size_tmp, self.conv1.kernel_size, self.conv1.strides) self.patch_stride = self.conv1.strides def call(self, inputs): if self.conv1.padding == 'same': inputs = tf.pad(inputs, [[0, 0], [1, 1], [1, 1], [0, 0]], mode='CONSTANT') num_patch = self.calculate_patch_count((inputs.shape[1], inputs.shape[2]), self.patch_size, self.patch_stride) number_patch_in_row = int(self.output_size[1] // self.expand_size[1]) output_feature_map_tmp = None output_feature_map = None for current_round in range(num_patch): position = get_current_patch_possition((inputs.shape[1], inputs.shape[2]), self.patch_size, self.patch_stride, current_round) patch_output = self.conv1(inputs[:, position[0]: position[0] + self.patch_size[0], position[1]: position[1] + self.patch_size[1], :]) patch_output = self.conv2(patch_output) if output_feature_map_tmp is None: output_feature_map_tmp = patch_output else: output_feature_map_tmp = tf.concat([output_feature_map_tmp, patch_output], axis=2) if (current_round + 1) % number_patch_in_row == 0 and current_round != 0: if output_feature_map is None: output_feature_map = output_feature_map_tmp else: output_feature_map = tf.concat([output_feature_map, output_feature_map_tmp], axis=1) output_feature_map_tmp = None return output_feature_map ``` ### 3. Failure after conversion I am working on implementing depth-first inference on Tflite micro, above is my custom layer. You can see that in the call function, I picked out a patch of the input image and did 2 layers of Conv first, then went on to the next patch. It works just fine in my jupyter-notebook. However, when I convert it to tflite using TFLiteConverter, I found that it first expand all the patches, then do 2 Conv on all the patches. This turns out to be an inference layer-by-layer and uses up even more memory, why is that? ![截圖 2023-09-18 下午7 33 19](https://github.com/tensorflow/tensorflow/assets/68526411/e3768de1-b03f-44a8-8a61-51318c8b8f92)
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61891/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61891/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61890
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61890/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61890/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61890/events
https://github.com/tensorflow/tensorflow/issues/61890
1,900,525,811
I_kwDOArmXAs5xR7jz
61,890
Build problems when using TensorFlow Lite from another project in Windows
{ "login": "martaiborra", "id": 73105403, "node_id": "MDQ6VXNlcjczMTA1NDAz", "avatar_url": "https://avatars.githubusercontent.com/u/73105403?v=4", "gravatar_id": "", "url": "https://api.github.com/users/martaiborra", "html_url": "https://github.com/martaiborra", "followers_url": "https://api.github.com/users/martaiborra/followers", "following_url": "https://api.github.com/users/martaiborra/following{/other_user}", "gists_url": "https://api.github.com/users/martaiborra/gists{/gist_id}", "starred_url": "https://api.github.com/users/martaiborra/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/martaiborra/subscriptions", "organizations_url": "https://api.github.com/users/martaiborra/orgs", "repos_url": "https://api.github.com/users/martaiborra/repos", "events_url": "https://api.github.com/users/martaiborra/events{/privacy}", "received_events_url": "https://api.github.com/users/martaiborra/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1188421838, "node_id": "MDU6TGFiZWwxMTg4NDIxODM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:windows", "name": "subtype:windows", "color": "b619ea", "default": false, "description": "Windows Build/Installation Issues" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
closed
false
{ "login": "terryheo", "id": 2908505, "node_id": "MDQ6VXNlcjI5MDg1MDU=", "avatar_url": "https://avatars.githubusercontent.com/u/2908505?v=4", "gravatar_id": "", "url": "https://api.github.com/users/terryheo", "html_url": "https://github.com/terryheo", "followers_url": "https://api.github.com/users/terryheo/followers", "following_url": "https://api.github.com/users/terryheo/following{/other_user}", "gists_url": "https://api.github.com/users/terryheo/gists{/gist_id}", "starred_url": "https://api.github.com/users/terryheo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/terryheo/subscriptions", "organizations_url": "https://api.github.com/users/terryheo/orgs", "repos_url": "https://api.github.com/users/terryheo/repos", "events_url": "https://api.github.com/users/terryheo/events{/privacy}", "received_events_url": "https://api.github.com/users/terryheo/received_events", "type": "User", "site_admin": false }
[ { "login": "terryheo", "id": 2908505, "node_id": "MDQ6VXNlcjI5MDg1MDU=", "avatar_url": "https://avatars.githubusercontent.com/u/2908505?v=4", "gravatar_id": "", "url": "https://api.github.com/users/terryheo", "html_url": "https://github.com/terryheo", "followers_url": "https://api.github.com/users/terryheo/followers", "following_url": "https://api.github.com/users/terryheo/following{/other_user}", "gists_url": "https://api.github.com/users/terryheo/gists{/gist_id}", "starred_url": "https://api.github.com/users/terryheo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/terryheo/subscriptions", "organizations_url": "https://api.github.com/users/terryheo/orgs", "repos_url": "https://api.github.com/users/terryheo/repos", "events_url": "https://api.github.com/users/terryheo/events{/privacy}", "received_events_url": "https://api.github.com/users/terryheo/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @martaiborra, this seems like a MVC++ compiler issue, it doesn't like the implicit cast from bool to const std::atomic_flag. Is there a way you can switch to clang? That will be better supported now and in the future. I was able to run your scripts successfully on a Linux (Debian) distribution with clang. (Unless your scripts somehow manually changed compilers)\r\n\r\n```sh\r\ngit clone https://github.com/Blosc/blosc2_btune.git\r\ncd blosc2_btune\r\npython -m pip install -r requirements-build.txt\r\nchmod 755 prebuild.sh\r\n./prebuild.sh\r\npython setup.py bdist_wheel\r\n```\r\n\r\nAlternatively you can try with WSL as well.", "Hi, thank you for your answer.\r\nOne reason because we wanted to use MSVC it's because the project is a python extension and the usually used compiler for that is MSVC but I will try to use clang and see.\r\n\r\nAlso, it is really interesting because if I try to compile TensorFlow Lite alone with MSVC, it works totally fine:\r\n```\r\nmkdir tflite_build\r\ncd tflite_build\r\ncmake ../tensorflow/lite\r\ncmake --build . -j\r\n```\r\n\r\n", "Tried using Clang from the Visual Studio Build tools. I got an error when building TensorFlow Lite alone (not inside the blosc2_btune project).\r\n\r\n```\r\ncmake ..\\tensorflow\\lite -G \"Visual Studio 17 2022\" -T ClangCL -A x64\r\ncmake --build . -j\r\n```\r\n\r\nThe following error occurs:\r\n\r\n```\r\nBuilding Custom Rule C:/Users/marta/blosc2_btune/tensorflow_src/tflite_build/xnnpack/CMakeLists.txt\r\n operator-utils.vcxproj -> C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\_deps\\xnnpack-build\\operator-utils.\r\n dir\\Debug\\operator-utils.lib\r\n indirection.vcxproj -> C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\_deps\\xnnpack-build\\indirection.dir\\De\r\n bug\\indirection.lib\r\n In file included from C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\cpuinfo\\src\\x86\\topology.c:5:\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\cpuinfo\\src\\cpuinfo/utils.h(13,4): error : call to undeclared l\r\nibrary function '_BitScanReverse' with type 'unsigned char (unsigned long *, unsigned long)'; ISO C99 and later do not\r\nsupport implicit function declarations [-Wimplicit-function-declaration] [C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tf\r\nlite_build\\_deps\\cpuinfo-build\\cpuinfo.vcxproj]\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\cpuinfo\\src\\cpuinfo/utils.h(13,4): message : include the header\r\n <intrin.h> or explicitly provide a declaration for '_BitScanReverse' [C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflit\r\ne_build\\_deps\\cpuinfo-build\\cpuinfo.vcxproj]\r\n operator-run.vcxproj -> C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\_deps\\xnnpack-build\\operator-run.dir\\\r\n Debug\\operator-run.lib\r\n memory.vcxproj -> C:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tflite_build\\_deps\\xnnpack-build\\memory.dir\\Debug\\memory\r\n .lib\r\n```", "Hi @martaiborra, Have you ensured you followed these instructions? https://clang.llvm.org/get_started.html specifically the \"Using Visual Studio\" section? Alternatively, can you use WSL to continue/compile your project?", "Hi, I'll check that. With WSL works perfectly fine, but we wanted to be able to use it without the need of WSL.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "Tried using Clang following the instructions and it works for tensorflow alone. I'm still trying to figure out how to use clang when creating the wheels. ", "Tried using clang and it shows the same error. Instead of creating the wheel, I tried to only use cmake with:\r\n\r\n```\r\ncd blosc2_btune\r\nmkdir build\r\ncd build\r\ncmake -DLLVM_ENABLE_PROJECTS=clang -G \"Visual Studio 17 2022\" -A x64 -Thost=x64 ..\r\ncmake --build . -j\r\n```\r\n\r\nBut it stills shows the same error.\r\n```\r\n btune_model.cpp\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tensorflow/lite/core/interpreter.h(1002,40): error C2665: 'std::atomic_flag::atomic_fl\r\nag': no overloaded function could convert all the argument types [C:\\Users\\marta\\blosc2_btune\\build\\src\\blosc2_btune.vcxproj]\r\nC:\\Program Files (x86)\\Microsoft Visual Studio\\2022\\BuildTools\\VC\\Tools\\MSVC\\14.37.32822\\include\\atomic(2886,1): message : could\r\nbe 'std::atomic_flag::atomic_flag(const std::atomic_flag &)' [C:\\Users\\marta\\blosc2_btune\\build\\src\\blosc2_btune.vcxproj]\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tensorflow/lite/core/interpreter.h(1002,40): message : 'std::atomic_flag::atomic_flag(\r\nconst std::atomic_flag &)': cannot convert argument 1 from 'bool' to 'const std::atomic_flag &' [C:\\Users\\marta\\blosc2_btune\\buil\r\nd\\src\\blosc2_btune.vcxproj]\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tensorflow/lite/core/interpreter.h(1002,41): message : Reason: cannot convert from 'bo\r\nol' to 'const std::atomic_flag' [C:\\Users\\marta\\blosc2_btune\\build\\src\\blosc2_btune.vcxproj]\r\nC:\\Users\\marta\\blosc2_btune\\tensorflow_src\\tensorflow/lite/core/interpreter.h(1002,40): message : while trying to match the argum\r\nent list '(bool)' [C:\\Users\\marta\\blosc2_btune\\build\\src\\blosc2_btune.vcxproj]\r\n```\r\n", "Hi @martaiborra, I think your root issue might have to do with the MVC++ compiler, I am unsure if not being able to do that cast is uncompliant w/ the C++ standard or not, so you might want to check with the MVC++ team to see if this is their root issue. It seems you are able to continue with WSL so I recommend you continue working with that stack until this issue is resolved.\r\n\r\nHi @terryheo, can you please take a look at this issue? Thanks.", "Hi, we found out the problem. In our CMakeLists.txt we had:\r\n`set (CMAKE_CXX_STANDARD 20)`\r\n\r\nBy downgrading it to:\r\n`set (CMAKE_CXX_STANDARD 17)`\r\nit does not complain anymore.\r\n\r\nThank you very much for your help!", "Hi @martaiborra, thank you for the update, please feel free to close the issue as completed if you have no more open issues. Thanks.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61890\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61890\">No</a>\n", "The documentation at\r\nhttps://en.cppreference.com/w/cpp/atomic/atomic_flag/atomic_flag\r\nmakes it pretty clear that this is not standard-conforming code,\r\nfor all versions of the C++ standard.\r\n\r\nI have made a patch to use ATOMIC_FLAG_INIT instead\r\n<https://en.cppreference.com/w/cpp/atomic/ATOMIC_FLAG_INIT>\r\nand have sent that for review.\r\n" ]
2023-09-18T09:26:45
2023-10-19T18:10:07
2023-10-19T07:28:14
NONE
null
null
null
### Issue type Build/Install ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version 2.13 ### Custom code Yes ### OS platform and distribution Windows 10 ### Mobile device _No response_ ### Python version 3.11 ### Bazel version compiled using CMake ### GCC/compiler version MSVC 17 2022 ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? When trying to create a project wheel which uses TensorFlow Lite, it is expected to work fine with: `python setup.py bdist_wheel` This command works fine for MacOS and Linux but does not work for Windows raising an error from the `tensorflow_src\tensorflow/lite/core/interpreter.h` file (you can see the error in the Relevant log output section). For using TensorFlow Lite from the project, we followed the instructions in https://www.tensorflow.org/lite/guide/build_cmake#create_a_cmake_project_which_uses_tensorflow_lite as can be seen in its CMake files (https://github.com/Blosc/blosc2_btune/blob/main/src/CMakeLists.txt). Also, there is no issue even on Windows for building TensorFlow Lite alone with ``` cmake ../tensorflow_src/tensorflow/lite cmake --build . -j ``` ### Standalone code to reproduce the issue ```shell The issue project is blosc2_btune (https://github.com/Blosc/blosc2_btune). You can clone it `git clone https://github.com/Blosc/blosc2_btune.git` install the requirements `python -m pip install -r requirements-build.txt` and reproduce the error with prebuild.sh python setup.py bdist_wheel ``` ``` ### Relevant log output ```shell Generating Code... btune_model.cpp C:\Users\marta\blosc2_btune\tensorflow_src\tensorflow/lite/core/interpreter.h(1000,40): error C2665: 'std::atomic_flag: :atomic_flag': no overloaded function could convert all the argument types [C:\Users\marta\blosc2_btune\_skbuild\win-am d64-3.11\cmake-build\src\blosc2_btune.vcxproj] C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.37.32822\include\atomic(2886,1): messag e : could be 'std::atomic_flag::atomic_flag(const std::atomic_flag &)' [C:\Users\marta\blosc2_btune\_skbuild\win-amd64- 3.11\cmake-build\src\blosc2_btune.vcxproj] C:\Users\marta\blosc2_btune\tensorflow_src\tensorflow/lite/core/interpreter.h(1000,40): message : 'std::atomic_flag::at omic_flag(const std::atomic_flag &)': cannot convert argument 1 from 'bool' to 'const std::atomic_flag &' [C:\Users\mar ta\blosc2_btune\_skbuild\win-amd64-3.11\cmake-build\src\blosc2_btune.vcxproj] C:\Users\marta\blosc2_btune\tensorflow_src\tensorflow/lite/core/interpreter.h(1000,41): message : Reason: cannot conver t from 'bool' to 'const std::atomic_flag' [C:\Users\marta\blosc2_btune\_skbuild\win-amd64-3.11\cmake-build\src\blosc2_b tune.vcxproj] C:\Users\marta\blosc2_btune\tensorflow_src\tensorflow/lite/core/interpreter.h(1000,40): message : while trying to match the argument list '(bool)' [C:\Users\marta\blosc2_btune\_skbuild\win-amd64-3.11\cmake-build\src\blosc2_btune.vcxproj] Traceback (most recent call last): File "C:\Users\marta\miniconda3\envs\blosc2_btune2\Lib\site-packages\skbuild\setuptools_wrap.py", line 674, in setup cmkr.make(make_args, install_target=cmake_install_target, env=env) File "C:\Users\marta\miniconda3\envs\blosc2_btune2\Lib\site-packages\skbuild\cmaker.py", line 697, in make self.make_impl(clargs=clargs, config=config, source_dir=source_dir, install_target=install_target, env=env) File "C:\Users\marta\miniconda3\envs\blosc2_btune2\Lib\site-packages\skbuild\cmaker.py", line 742, in make_impl raise SKBuildError(msg) An error occurred while building with CMake. Command: 'C:\Users\marta\miniconda3\envs\blosc2_btune2\Lib\site-packages\cmake\data\bin/cmake.exe' --build . --target install --config Release -- Install target: install Source directory: C:\Users\marta\blosc2_btune Working directory: C:\Users\marta\blosc2_btune\_skbuild\win-amd64-3.11\cmake-build Please check the install target is valid and see CMake's output for more information. ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61890/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61890/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61889
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61889/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61889/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61889/events
https://github.com/tensorflow/tensorflow/issues/61889
1,900,381,625
I_kwDOArmXAs5xRYW5
61,889
tensorflow.tf concurrency issue
{ "login": "bugzyz", "id": 31982774, "node_id": "MDQ6VXNlcjMxOTgyNzc0", "avatar_url": "https://avatars.githubusercontent.com/u/31982774?v=4", "gravatar_id": "", "url": "https://api.github.com/users/bugzyz", "html_url": "https://github.com/bugzyz", "followers_url": "https://api.github.com/users/bugzyz/followers", "following_url": "https://api.github.com/users/bugzyz/following{/other_user}", "gists_url": "https://api.github.com/users/bugzyz/gists{/gist_id}", "starred_url": "https://api.github.com/users/bugzyz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bugzyz/subscriptions", "organizations_url": "https://api.github.com/users/bugzyz/orgs", "repos_url": "https://api.github.com/users/bugzyz/repos", "events_url": "https://api.github.com/users/bugzyz/events{/privacy}", "received_events_url": "https://api.github.com/users/bugzyz/received_events", "type": "User", "site_admin": false }
[ { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097547147, "node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops", "name": "comp:ops", "color": "0052cc", "default": false, "description": "OPs related issues" }, { "id": 4829271983, "node_id": "LA_kwDOArmXAs8AAAABH9jXrw", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.11", "name": "TF 2.11", "color": "46B4D7", "default": false, "description": "Issues related to TF 2.11" } ]
closed
false
{ "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false }
[ { "login": "sushreebarsa", "id": 84765720, "node_id": "MDQ6VXNlcjg0NzY1NzIw", "avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sushreebarsa", "html_url": "https://github.com/sushreebarsa", "followers_url": "https://api.github.com/users/sushreebarsa/followers", "following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}", "gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}", "starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions", "organizations_url": "https://api.github.com/users/sushreebarsa/orgs", "repos_url": "https://api.github.com/users/sushreebarsa/repos", "events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}", "received_events_url": "https://api.github.com/users/sushreebarsa/received_events", "type": "User", "site_admin": false } ]
null
[ "The error you're encountering is an InvalidArgumentError that originates from TensorFlow. This error typically occurs when TensorFlow operations are performed on tensors with incompatible shapes. In your case, you are attempting to concatenate tensors using tf.concat, and TensorFlow has detected that the shapes of the input tensors are not compatible for concatenation.", "> The error you're encountering is an InvalidArgumentError that originates from TensorFlow. This error typically occurs when TensorFlow operations are performed on tensors with incompatible shapes. In your case, you are attempting to concatenate tensors using tf.concat, and TensorFlow has detected that the shapes of the input tensors are not compatible for concatenation.\r\n\r\nYes, I understand. \r\n**The question is why the incompatible shapes error only happens in multi-thread environment?** It looks like one thread just set first array's shape and another thread set second array's shape in tf.concat that causes the incompatible shape error. Any idea?", "@bugzyz This issue seems to be fixed in the latest TF version 2.13, please find the gist [here](https://colab.research.google.com/gist/sushreebarsa/bf6f7a9bc929f0e4933d5e64ab14a282/61889.ipynb) and confirm the same?\r\nThank you!", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61889\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61889\">No</a>\n" ]
2023-09-18T08:00:41
2023-10-10T01:47:29
2023-10-10T01:47:25
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version unknown 2.11.0 (from nvcr.io/nvidia/tensorflow:23.03-tf2-py3)) ### Custom code Yes ### OS platform and distribution Ubuntu 20.04.6 LTS ### Mobile device _No response_ ### Python version 3.8.10 ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version cuda_12.1.r12.1/compiler.32415258_0 ### GPU model and memory _No response_ ### Current behavior? We found that running tensorflow.concat operation will have concurrency issue only in the Nvidia tensorflow image. We also tried with other image but the issue cannot reproduce. We expect that tensorflow.concat work fine for multi-thread environment. But it's not. Is it expected? FYI, adding a lock for concat can avoid such issue. What's the best practice? Our environment: GPU: A100 image: nvcr.io/nvidia/tensorflow:23.03-tf2-py3 driver: NVIDIA-SMI 525.125.06 Driver Version: 525.125.06 CUDA Version: 12.0 ### Standalone code to reproduce the issue ```shell import tensorflow as tf from concurrent.futures import ThreadPoolExecutor, as_completed client_num = 10 repeat = 10000 executor = ThreadPoolExecutor(max_workers=client_num) future_2_input_shapes = {} # import threading # lock = threading.Lock() test_cases = [ [[1, 2] * 31, [2, 3]], [[1, 2, 8, 90] * 31, [2, 3, 3, 1]], [[[7, 4, 3], [8, 4, 3]], [[2, 10, 3], [15, 11, 3]] * 63], ] def do_concat(t1, t2): # with lock: # return tf.concat([t1, t2], 0) return tf.concat([t1, t2], 0) print("creating task") for _ in range(repeat): for test_case in test_cases: a = tf.constant(test_case[0]) b = tf.constant(test_case[1]) future = executor.submit(do_concat, a, b) future_2_input_shapes[future] = a.shape, b.shape print("waiting task") count = 0 for future in as_completed(future_2_input_shapes.keys()): print(f"{count}: {future_2_input_shapes[future]}") data = future.result() count = count + 1 ``` ``` ### Relevant log output ```shell ... 17086: (TensorShape([62]), TensorShape([2])) 17087: (TensorShape([2, 3]), TensorShape([126, 3])) 17088: (TensorShape([124]), TensorShape([4])) 17089: (TensorShape([124]), TensorShape([4])) 17090: (TensorShape([2, 3]), TensorShape([126, 3])) 17091: (TensorShape([124]), TensorShape([4])) 17092: (TensorShape([2, 3]), TensorShape([126, 3])) Traceback (most recent call last): File "x.py", line 37, in <module> data = future.result() File "/usr/lib/python3.8/concurrent/futures/_base.py", line 437, in result return self.__get_result() File "/usr/lib/python3.8/concurrent/futures/_base.py", line 389, in __get_result raise self._exception File "/usr/lib/python3.8/concurrent/futures/thread.py", line 57, in run result = self.fn(*self.args, **self.kwargs) File "x.py", line 22, in do_concat return tf.concat([t1, t2], 0) File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/traceback_utils.py", line 153, in error_handler raise e.with_traceback(filtered_tb) from None File "/usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/ops.py", line 7215, in raise_from_not_ok_status raise core._status_to_exception(e) from None # pylint: disable=protected-access tensorflow.python.framework.errors_impl.InvalidArgumentError: {{function_node __wrapped__ConcatV2_N_2_device_/job:localhost/replica:0/task:0/device:GPU:0}} ConcatOp : Ranks of all input tensors should match: shape[0] = [124] vs. shape[1] = [126,3] [Op:ConcatV2] name: concat ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61889/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61889/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61888
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61888/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61888/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61888/events
https://github.com/tensorflow/tensorflow/pull/61888
1,900,340,804
PR_kwDOArmXAs5aiaIe
61,888
[XLA][StreamExecutor] add empty implementation for host stream, avoid…
{ "login": "qingyunqu", "id": 29956693, "node_id": "MDQ6VXNlcjI5OTU2Njkz", "avatar_url": "https://avatars.githubusercontent.com/u/29956693?v=4", "gravatar_id": "", "url": "https://api.github.com/users/qingyunqu", "html_url": "https://github.com/qingyunqu", "followers_url": "https://api.github.com/users/qingyunqu/followers", "following_url": "https://api.github.com/users/qingyunqu/following{/other_user}", "gists_url": "https://api.github.com/users/qingyunqu/gists{/gist_id}", "starred_url": "https://api.github.com/users/qingyunqu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/qingyunqu/subscriptions", "organizations_url": "https://api.github.com/users/qingyunqu/orgs", "repos_url": "https://api.github.com/users/qingyunqu/repos", "events_url": "https://api.github.com/users/qingyunqu/events{/privacy}", "received_events_url": "https://api.github.com/users/qingyunqu/received_events", "type": "User", "site_admin": false }
[ { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1133285679, "node_id": "MDU6TGFiZWwxMTMzMjg1Njc5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla", "name": "comp:xla", "color": "0052cc", "default": false, "description": "XLA" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
open
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[]
2023-09-18T07:34:20
2024-06-05T08:22:05
null
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61888", "html_url": "https://github.com/tensorflow/tensorflow/pull/61888", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61888.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61888.patch", "merged_at": null }
… to log ERROR message when call SetPriority on host stream
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61888/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61888/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61887
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61887/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61887/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61887/events
https://github.com/tensorflow/tensorflow/issues/61887
1,900,079,949
I_kwDOArmXAs5xQOtN
61,887
Tensorflow failed build due to ImportError: DLL load failed while importing _pywrap_tensorflow_internal: A dynamic link library (DLL) initialization routine failed.
{ "login": "Eva-An", "id": 122774610, "node_id": "U_kgDOB1FkUg", "avatar_url": "https://avatars.githubusercontent.com/u/122774610?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Eva-An", "html_url": "https://github.com/Eva-An", "followers_url": "https://api.github.com/users/Eva-An/followers", "following_url": "https://api.github.com/users/Eva-An/following{/other_user}", "gists_url": "https://api.github.com/users/Eva-An/gists{/gist_id}", "starred_url": "https://api.github.com/users/Eva-An/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Eva-An/subscriptions", "organizations_url": "https://api.github.com/users/Eva-An/orgs", "repos_url": "https://api.github.com/users/Eva-An/repos", "events_url": "https://api.github.com/users/Eva-An/events{/privacy}", "received_events_url": "https://api.github.com/users/Eva-An/received_events", "type": "User", "site_admin": false }
[ { "id": 386191887, "node_id": "MDU6TGFiZWwzODYxOTE4ODc=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response", "name": "stat:awaiting response", "color": "f4b400", "default": false, "description": "Status - Awaiting response from author" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 473173351, "node_id": "MDU6TGFiZWw0NzMxNzMzNTE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install", "name": "type:build/install", "color": "159b2e", "default": false, "description": "Build and install issues" }, { "id": 474725938, "node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale", "name": "stale", "color": "d4c5f9", "default": false, "description": "This label marks the issue/pr stale - to be closed automatically if no activity" }, { "id": 1188421838, "node_id": "MDU6TGFiZWwxMTg4NDIxODM4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:windows", "name": "subtype:windows", "color": "b619ea", "default": false, "description": "Windows Build/Installation Issues" } ]
closed
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @Eva-An ,\r\n\r\nNormally this type of error occurs if your CPU not supports AVX instruction sets.starting from TF1.6v and higher TF binaries are prebuilt with AVX instruction sets. This means on any CPU that do not have these instruction sets either CPU or GPU version of TF will fail to load with reported error.\r\n\r\nCould you please cross check similar issues #19584 , #21977 and let us know if it helps.\r\n\r\nThanks!", "Hi @SuryanarayanaY , my machine is a virtual machine and the CPU is Intel(R) Xeon(R) Platinum 8168 CPU. I check on its official [website](https://www.intel.com/content/www/us/en/products/sku/120504/intel-xeon-platinum-8168-processor-33m-cache-2-70-ghz/specifications.html) that it seems to be supportive.", "Hi @Eva-An ,\r\n\r\nI acknowledge that your CPU do support AVX instruction set. Thanks for confirmation.\r\n\r\nCurrently nightly versions are building using bazel 6.1.0 whereas you are using higher version which may some times cause incompatibility issues. Could you please try with bazel 6.1.0 and let us know outcome.\r\n\r\nThank you!\r\n\r\n", "Could you please confirm the compiler you are using. Also could you please check whether this flag `/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR` is compatible with clang ?", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61887\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61887\">No</a>\n" ]
2023-09-18T03:02:31
2023-10-06T01:47:42
2023-10-06T01:47:40
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? No ### Source source ### TensorFlow version master branch, commit: a442440 ### Custom code No ### OS platform and distribution Windows Server 2022 ### Mobile device _No response_ ### Python version 3.9 ### Bazel version 6.3.2 ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? ImportError: DLL load failed while importing _pywrap_tensorflow_internal: A dynamic link library (DLL) initialization routine failed. During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\tools\api\generator\create_python_api.py", line 22, in <module> from tensorflow.python.tools.api.generator import doc_srcs File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\__init__.py", line 37, in <module> from tensorflow.python.tpu import api File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\tpu\api.py", line 22, in <module> from tensorflow.python.tpu import bfloat16 File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\tpu\bfloat16.py", line 20, in <module> from tensorflow.python.framework import dtypes File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\framework\dtypes.py", line 28, in <module> from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\pywrap_tensorflow.py", line 77, in <module> raise ImportError( ImportError: Traceback (most recent call last): File "C:\Users\CPPTES~1\AppData\Local\Temp\2\Bazel.runfiles_pr3ptqbl\runfiles\org_tensorflow\tensorflow\python\pywrap_tensorflow.py", line 62, in <module> from tensorflow.python._pywrap_tensorflow_internal import * ImportError: DLL load failed while importing _pywrap_tensorflow_internal: A dynamic link library (DLL) initialization routine failed. Failed to load the native TensorFlow runtime. See https://www.tensorflow.org/install/errors for some common causes and solutions. If you need help, create an issue at https://github.com/tensorflow/tensorflow/issues and include the entire stack trace above this error message. Target //tensorflow/tools/pip_package:build_pip_package failed to build ERROR: F:/tensorflow/tensorflow/tensorflow/tools/pip_package/BUILD:252:10 Middleman _middlemen/tensorflow_Stools_Spip_Upackage_Sbuild_Upip_Upackage.exe-runfiles failed: (Exit 1): bash.exe failed: error executing command (from target //tensorflow:tf_python_api_gen_v2) ### Standalone code to reproduce the issue ```shell git clone https://github.com/tensorflow/tensorflow.git F:\Tensorflow\tensorflow cd /d F:\Tensorflow\tensorflow pip3 uninstall -r tensorflow/tools/ci_build/release/requirements_common.txt --yes pip3 install -r tensorflow/tools/ci_build/release/requirements_common.txt --upgrade set PATH=F:\Tensorflow\tensorflow\..\tools;%path% set PATH=F:\Tensorflow\tensorflow\..\tools\msys64\usr\bin;%path% yes "" 2>nul | python ./configure.py C:\Python39\python.exe -m pip install --upgrade pip set TF_PYTHON_VERSION=3.9 set BAZEL_VC=C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC set BAZEL_VC_FULL_VERSION=14.37.32822 set PATH=F:\Tensorflow\tensorflow\..\tools;%path% set PATH=F:\Tensorflow\tensorflow\..\tools\msys64\usr\bin;%path% bazel --output_user_root F:\bazelTemp build --jobs 8 --config=opt --local_ram_resources=4096 --host_cxxopt="/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR" --subcommands //tensorflow/tools/pip_package:build_pip_package ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61887/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61887/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61886
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61886/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61886/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61886/events
https://github.com/tensorflow/tensorflow/issues/61886
1,900,019,264
I_kwDOArmXAs5xP_5A
61,886
TF Lite produces wrong graph with a sequence of tensor reshape operators
{ "login": "dengyinlin", "id": 30567397, "node_id": "MDQ6VXNlcjMwNTY3Mzk3", "avatar_url": "https://avatars.githubusercontent.com/u/30567397?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dengyinlin", "html_url": "https://github.com/dengyinlin", "followers_url": "https://api.github.com/users/dengyinlin/followers", "following_url": "https://api.github.com/users/dengyinlin/following{/other_user}", "gists_url": "https://api.github.com/users/dengyinlin/gists{/gist_id}", "starred_url": "https://api.github.com/users/dengyinlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dengyinlin/subscriptions", "organizations_url": "https://api.github.com/users/dengyinlin/orgs", "repos_url": "https://api.github.com/users/dengyinlin/repos", "events_url": "https://api.github.com/users/dengyinlin/events{/privacy}", "received_events_url": "https://api.github.com/users/dengyinlin/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" }, { "id": 1661751498, "node_id": "MDU6TGFiZWwxNjYxNzUxNDk4", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter", "name": "TFLiteConverter", "color": "bfdadc", "default": false, "description": "For issues related to TFLite converter" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "zichuan-wei", "id": 10928342, "node_id": "MDQ6VXNlcjEwOTI4MzQy", "avatar_url": "https://avatars.githubusercontent.com/u/10928342?v=4", "gravatar_id": "", "url": "https://api.github.com/users/zichuan-wei", "html_url": "https://github.com/zichuan-wei", "followers_url": "https://api.github.com/users/zichuan-wei/followers", "following_url": "https://api.github.com/users/zichuan-wei/following{/other_user}", "gists_url": "https://api.github.com/users/zichuan-wei/gists{/gist_id}", "starred_url": "https://api.github.com/users/zichuan-wei/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zichuan-wei/subscriptions", "organizations_url": "https://api.github.com/users/zichuan-wei/orgs", "repos_url": "https://api.github.com/users/zichuan-wei/repos", "events_url": "https://api.github.com/users/zichuan-wei/events{/privacy}", "received_events_url": "https://api.github.com/users/zichuan-wei/received_events", "type": "User", "site_admin": false }
[ { "login": "zichuan-wei", "id": 10928342, "node_id": "MDQ6VXNlcjEwOTI4MzQy", "avatar_url": "https://avatars.githubusercontent.com/u/10928342?v=4", "gravatar_id": "", "url": "https://api.github.com/users/zichuan-wei", "html_url": "https://github.com/zichuan-wei", "followers_url": "https://api.github.com/users/zichuan-wei/followers", "following_url": "https://api.github.com/users/zichuan-wei/following{/other_user}", "gists_url": "https://api.github.com/users/zichuan-wei/gists{/gist_id}", "starred_url": "https://api.github.com/users/zichuan-wei/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zichuan-wei/subscriptions", "organizations_url": "https://api.github.com/users/zichuan-wei/orgs", "repos_url": "https://api.github.com/users/zichuan-wei/repos", "events_url": "https://api.github.com/users/zichuan-wei/events{/privacy}", "received_events_url": "https://api.github.com/users/zichuan-wei/received_events", "type": "User", "site_admin": false }, { "login": "pkgoogle", "id": 132095473, "node_id": "U_kgDOB9-d8Q", "avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pkgoogle", "html_url": "https://github.com/pkgoogle", "followers_url": "https://api.github.com/users/pkgoogle/followers", "following_url": "https://api.github.com/users/pkgoogle/following{/other_user}", "gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}", "starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions", "organizations_url": "https://api.github.com/users/pkgoogle/orgs", "repos_url": "https://api.github.com/users/pkgoogle/repos", "events_url": "https://api.github.com/users/pkgoogle/events{/privacy}", "received_events_url": "https://api.github.com/users/pkgoogle/received_events", "type": "User", "site_admin": false } ]
null
[ "@pkgoogle,\r\nI was able to reproduce the issue on tensorflow v2.13, v2.12 and tf-nightly. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/616cd0d8c23665915a8fe123d1b348fa/untitled1364.ipynb).", "I was able to replicate with the same gist, @zichuan-wei, can you please take a look? Thanks." ]
2023-09-18T01:27:44
2023-09-19T18:19:48
null
NONE
null
null
null
### 1. System information - OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04 - TensorFlow installation (pip package or built from source): pip - TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0-dev20230917 ### 2. Code Provide code to help us reproduce your issues using one of the following options: ``` x1 = tf.constant([[1., 2.], [3., 4.], [5., 6.]], shape=[3, 2]) class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() @tf.function(input_signature=[tf.TensorSpec(x1.shape, x1.dtype)]) def call(self, x): a = tf.reshape(x, [3, 2, 1]) b = tf.unstack(a, axis=1) c = tf.concat(b, 0) d = tf.reshape(c, [3, 2]) return d m = Model() expected_value = m(x1) print('keras model output:') print(expected_value.numpy()) converter = tf.lite.TFLiteConverter.from_keras_model(m) tflite_model = converter.convert() def _evaluateTFLiteModel(tflite_model, input_data): interpreter = tf.lite.Interpreter(model_content=tflite_model) interpreter.allocate_tensors() input_details = interpreter.get_input_details() output_details = interpreter.get_output_details() for i in range(len(input_data)): interpreter.set_tensor(input_details[i]['index'], input_data[i]) interpreter.invoke() output_data = [interpreter.get_tensor(output_details[i]['index']) for i in range(len(output_details))] return output_data actual_value = _evaluateTFLiteModel(tflite_model,[x1]) print('tflite model output:') print(actual_value[0]) tf.lite.experimental.Analyzer.analyze(model_content=tflite_model) ``` ### 3. Failure after conversion The model conversion is successful, but it produces wrong results. Output: ``` keras model output: [[1. 3.] [5. 2.] [4. 6.]] tflite model output: [[1. 2.] [3. 4.] [5. 6.]] ``` TFLite ModelAnalyzer: ``` Your TFLite model has '1' subgraph(s). In the subgraph description below, T# represents the Tensor numbers. Subgraph#0 main(T#0) -> [T#0] Tensors of Subgraph#0 T#0(serving_default_args_0:0) shape:[3, 2], type:FLOAT32 --------------------------------------------------------------- Your TFLite model has '1' signature_def(s). Signature#0 key: 'serving_default' - Subgraph: Subgraph#0 - Inputs: 'args_0' : T#0 - Outputs: 'output_1' : T#0 ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61886/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61886/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61885
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61885/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61885/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61885/events
https://github.com/tensorflow/tensorflow/issues/61885
1,900,005,284
I_kwDOArmXAs5xP8ek
61,885
Adding `@tf.function` changes model output
{ "login": "dengyinlin", "id": 30567397, "node_id": "MDQ6VXNlcjMwNTY3Mzk3", "avatar_url": "https://avatars.githubusercontent.com/u/30567397?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dengyinlin", "html_url": "https://github.com/dengyinlin", "followers_url": "https://api.github.com/users/dengyinlin/followers", "following_url": "https://api.github.com/users/dengyinlin/following{/other_user}", "gists_url": "https://api.github.com/users/dengyinlin/gists{/gist_id}", "starred_url": "https://api.github.com/users/dengyinlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dengyinlin/subscriptions", "organizations_url": "https://api.github.com/users/dengyinlin/orgs", "repos_url": "https://api.github.com/users/dengyinlin/repos", "events_url": "https://api.github.com/users/dengyinlin/events{/privacy}", "received_events_url": "https://api.github.com/users/dengyinlin/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Instead of using tf.constant([6.]) use just 6. and 7. it solves the issue", "I cant find the where the decorator is but this above solution solves the issue...Can someone please tell me where the decorator is located in the repo.", "Hi @YashIngle21 ,\r\n\r\nIn the code example above, in the first model, `def call(self, x)` is decorated with `@tf.function`.\r\nModifying the model code will indeed solve the issue. However, the bug here is the inconsistency with or without `@tf.function` conversion. Thanks!", "oh! ok i will try solving the issue...Thanks!!!", "@dengyinlin ,\r\n\r\nI have replicated the reported issue and acknowledging the difference in results. Attaching [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/f34ca877dc5b01949931369975d2b912/61885.ipynb) for reference.\r\n\r\nAs per my observation the first instance of `tf.constant` not adding to the computations though autograph is able to build a node for it. If we add 3 instances of tf.constant then also first instance getting ignored but remaining two instances are getting added. But as per autograph generated there are nodes generated for each of 3 instances.\r\n\r\nIMO, this seems a bug and we need to dig more to find out root cause of this.\r\n\r\nThank you!" ]
2023-09-18T01:07:56
2023-10-12T09:18:07
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230917 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? After adding `@tf.function` to the following model, the output `y` is wrong (`[[42, 36]]`). This issue only happens on CPU. On CUDA it is able to output the expected output (`[[42, 42]]`). ### Standalone code to reproduce the issue ```shell import tensorflow as tf x1 = tf.constant([[6., 7.]], shape=[1, 2]) ##### With @tf.function ##### class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.fc1 = tf.keras.layers.Dense(2, name='fc', kernel_initializer='ones', bias_initializer='ones') self.fc2 = tf.keras.layers.Dense(2, name='fc', kernel_initializer='ones', bias_initializer='ones') @tf.function def call(self, x): x = self.fc1(x) x = self.fc2(x) x = tf.constant([6.]) + x return tf.constant([7.]) + x m = Model() y = m(x1) print(y.numpy()) ##### Without @tf.function ##### class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.fc1 = tf.keras.layers.Dense(2, name='fc', kernel_initializer='ones', bias_initializer='ones') self.fc2 = tf.keras.layers.Dense(2, name='fc', kernel_initializer='ones', bias_initializer='ones') def call(self, x): x = self.fc1(x) x = self.fc2(x) x = tf.constant([6.]) + x return tf.constant([7.]) + x m = Model() expected_value = m(x1) print(expected_value.numpy()) ``` ### Relevant log output ```shell [[42. 36.]] [[42. 42.]] ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61885/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61885/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61884
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61884/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61884/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61884/events
https://github.com/tensorflow/tensorflow/issues/61884
1,899,880,337
I_kwDOArmXAs5xPd-R
61,884
XLA doesn't do the DCE as autocluster
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1133285679, "node_id": "MDU6TGFiZWwxMTMzMjg1Njc5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla", "name": "comp:xla", "color": "0052cc", "default": false, "description": "XLA" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "@SuryanarayanaY I was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/bc8d4335093bf160f96c76455d156322/61884.ipynb). Thank you!", "@YangChenyuan ,\r\n\r\nI can able to replicate the behaviour with `jit_compile=True` passed to tf.function. With `jit_compile=False` its working fine. It seems issue with XLA and will triage accordingly.\r\n\r\nAttaching [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/fdda23e3e415b84b0057ae167f40be91/61884_r1.ipynb) for same. \r\n\r\nThank you!\r\n" ]
2023-09-17T18:49:54
2023-09-26T06:16:19
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230914 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA doesn't do the DCE as autocluster. In the example below, the second line `sliced2 = tf.slice(x1, [0, 1, 0, 0], [-1, -1, 4, -1])` is dead code, which is deleted when enabling `autocluster`. However, the XLA compiled model will still execute this line. It is expected to delete this line since it is dead code. ### Standalone code to reproduce the issue ```shell import tensorflow as tf import os """ Autocluster """ os.environ['TF_XLA_FLAGS'] = '--tf_xla_auto_jit=2 --tf_xla_cpu_global_jit' class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() @tf.function def call(self, x1): sliced1 = tf.slice(x1, [0, 0, 1, 0], [-1, -1, 1, -1]) sliced2 = tf.slice(x1, [0, 1, 0, 0], [-1, -1, 4, -1]) return sliced1 # Initializing the model x1_shape = (1, 3, 3, 2) m = Model() # Inputs to the model x1 = tf.range(18) x1 = tf.reshape(x1, x1_shape) # Call model output_tensor = m(x1) """ XLA """ os.environ['TF_XLA_FLAGS'] = '' class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() @tf.function(jit_compile=True) def call(self, x1): sliced1 = tf.slice(x1, [0, 0, 1, 0], [-1, -1, 1, -1]) sliced2 = tf.slice(x1, [0, 1, 0, 0], [-1, -1, 4, -1]) return sliced1 # Initializing the model x1_shape = (1, 3, 3, 2) m = Model() # Inputs to the model x1 = tf.range(18) x1 = tf.reshape(x1, x1_shape) # Call model output_tensor = m(x1) """ InvalidArgumentError: Exception encountered when calling layer 'model_5' (type Model). Expected size[2] in [0, 3], but got 4 """ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61884/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61884/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61883
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61883/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61883/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61883/events
https://github.com/tensorflow/tensorflow/pull/61883
1,899,646,083
PR_kwDOArmXAs5agLkt
61,883
Strip `external/local_tsl` prefix during tar of tsl c headers
{ "login": "wamuir", "id": 17497234, "node_id": "MDQ6VXNlcjE3NDk3MjM0", "avatar_url": "https://avatars.githubusercontent.com/u/17497234?v=4", "gravatar_id": "", "url": "https://api.github.com/users/wamuir", "html_url": "https://github.com/wamuir", "followers_url": "https://api.github.com/users/wamuir/followers", "following_url": "https://api.github.com/users/wamuir/following{/other_user}", "gists_url": "https://api.github.com/users/wamuir/gists{/gist_id}", "starred_url": "https://api.github.com/users/wamuir/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wamuir/subscriptions", "organizations_url": "https://api.github.com/users/wamuir/orgs", "repos_url": "https://api.github.com/users/wamuir/repos", "events_url": "https://api.github.com/users/wamuir/events{/privacy}", "received_events_url": "https://api.github.com/users/wamuir/received_events", "type": "User", "site_admin": false }
[ { "id": 390482148, "node_id": "MDU6TGFiZWwzOTA0ODIxNDg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review", "name": "awaiting review", "color": "bc3869", "default": false, "description": "Pull request awaiting review" }, { "id": 987666414, "node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull", "name": "ready to pull", "color": "2cd643", "default": false, "description": "PR ready for merge process" }, { "id": 1169364259, "node_id": "MDU6TGFiZWwxMTY5MzY0MjU5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS", "name": "size:XS", "color": "adafea", "default": false, "description": "CL Change Size: Extra Small" } ]
closed
false
{ "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false }
[ { "login": "gbaned", "id": 48215717, "node_id": "MDQ6VXNlcjQ4MjE1NzE3", "avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4", "gravatar_id": "", "url": "https://api.github.com/users/gbaned", "html_url": "https://github.com/gbaned", "followers_url": "https://api.github.com/users/gbaned/followers", "following_url": "https://api.github.com/users/gbaned/following{/other_user}", "gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}", "starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/gbaned/subscriptions", "organizations_url": "https://api.github.com/users/gbaned/orgs", "repos_url": "https://api.github.com/users/gbaned/repos", "events_url": "https://api.github.com/users/gbaned/events{/privacy}", "received_events_url": "https://api.github.com/users/gbaned/received_events", "type": "User", "site_admin": false } ]
null
[ "Thanks for the fix! I assume `external/local_xla` has the same problem. I'll try to get this merged in before looking for a way to fix both.", "@jakeharmon8 \r\n\r\nThanks for reviewing! Re:xla, if so it isn't an issue that is hitting the nightly libtensorflow builds.\r\n\r\nThere is a related/similar problem with the proto package (`//tensorflow/tools/lib_package:libtensorflow_proto`). I'll create a separate PR" ]
2023-09-17T03:55:47
2023-09-25T09:54:39
2023-09-25T09:54:38
CONTRIBUTOR
null
false
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/61883", "html_url": "https://github.com/tensorflow/tensorflow/pull/61883", "diff_url": "https://github.com/tensorflow/tensorflow/pull/61883.diff", "patch_url": "https://github.com/tensorflow/tensorflow/pull/61883.patch", "merged_at": "2023-09-25T09:54:38" }
PR strips `external/local_tsl` prefix from tsl c headers when packaging //tensorflow/tools/lib_package:cheaders (and, thus libtensorflow.tar.gz). This prefix is not consistent with #include directives used in tensorflow and tsl c headers. The current tree of libtensorflow.tar.gz is shown below to demonstrate the issue. ``` . ├── LICENSE ├── THIRD_PARTY_TF_C_LICENSES ├── include │   ├── external │   │   └── local_tsl │   │   └── tsl │   │   ├── c │   │   │   └── tsl_status.h │   │   └── platform │   │   ├── ctstring.h │   │   └── ctstring_internal.h │   └── tensorflow │   ├── c │   │   ├── c_api.h │   │   ├── c_api_experimental.h │   │   ├── c_api_macros.h │   │   ├── eager │   │   │   ├── c_api.h │   │   │   ├── c_api_experimental.h │   │   │   └── dlpack.h │   │   ├── tensor_interface.h │   │   ├── tf_attrtype.h │   │   ├── tf_buffer.h │   │   ├── tf_datatype.h │   │   ├── tf_file_statistics.h │   │   ├── tf_status.h │   │   ├── tf_tensor.h │   │   ├── tf_tensor_helper.h │   │   └── tf_tstring.h │   └── core │   └── platform │   ├── ctstring.h │   └── ctstring_internal.h └── lib ├── libtensorflow.so -> libtensorflow.so.2 ├── libtensorflow.so.2 -> libtensorflow.so.2.15.0 ├── libtensorflow.so.2.15.0 ├── libtensorflow_framework.so -> libtensorflow_framework.so.2 ├── libtensorflow_framework.so.2 -> libtensorflow_framework.so.2.15.0 └── libtensorflow_framework.so.2.15.0 ```
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61883/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61883/timeline
null
null
true
https://api.github.com/repos/tensorflow/tensorflow/issues/61882
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61882/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61882/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61882/events
https://github.com/tensorflow/tensorflow/issues/61882
1,899,627,778
I_kwDOArmXAs5xOgUC
61,882
XLA compiled model skip `build` method
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" }, { "id": 5922361893, "node_id": "LA_kwDOArmXAs8AAAABYQASJQ", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14", "name": "TF2.14", "color": "b60205", "default": false, "description": "For issues related to Tensorflow 2.14.x" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @YangChenyuan ,\r\n\r\nThanks for reaching out. The reported behaviour was replicated with or without `jit_complie` (XLA).Attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/fff293e94440eaf75b677ace3f157a7d/61882.ipynb) for reference.\r\n\r\n It seems there is some issue with tf.function. We need to dig more to find the root cause.\r\n\r\nThank you!\r\n\r\n", "Thanks for your further exploration!" ]
2023-09-17T02:11:14
2023-10-18T07:02:20
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230914 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA compiled model skip `build` method, which is not expected since the `build` method is expected to be invoked automatically before the first execution of `call()`invoked automatically before the first execution of call(). The example below shows that the XLA compiled model doesn't invoke `build` since `self.w` is still `[[1, 0], [0, 1]]` instead of the result by `add_weight`. ### Standalone code to reproduce the issue ```shell """ Without XLA """ import tensorflow as tf class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.w = tf.Variable([[1., 0.], [0., 1.]]) def build(self, input_shape): super(Model, self).build(input_shape) self.w = self.add_weight("weight", shape=input_shape[1:], trainable=True) def call(self, x): return tf.matmul(x, self.w), self.w # Initializing the model m = Model() # Input to the model x1 = tf.constant([[6., 7.], [2., 7.]], shape=[1,2,2]) print(m(x1)) """ (<tf.Tensor: shape=(1, 2, 2), dtype=float32, numpy= array([[[4.0300035, 3.5133138], [3.804155 , 5.0799932]]], dtype=float32)>, <tf.Variable 'model_4/weight:0' shape=(2, 2) dtype=float32, numpy= array([[ 0.05646205, -0.3916698 ], [ 0.5273187 , 0.83761895]], dtype=float32)>) """ """ With XLA """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.w = tf.Variable([[1., 0.], [0., 1.]]) def build(self, input_shape): super(Model, self).build(input_shape) self.w = self.add_weight("weight", shape=input_shape[1:], trainable=True) @tf.function(jit_compile=True) def call(self, x): return tf.matmul(x, self.w), self.w # Initializing the model m = Model() # Input to the model x1 = tf.constant([[6., 7.], [2., 7.]], shape=[1,2,2]) print(m(x1)) """ (<tf.Tensor: shape=(1, 2, 2), dtype=float32, numpy= array([[[6., 7.], [2., 7.]]], dtype=float32)>, <tf.Tensor: shape=(2, 2), dtype=float32, numpy= array([[1., 0.], [0., 1.]], dtype=float32)>) """ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61882/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61882/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61881
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61881/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61881/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61881/events
https://github.com/tensorflow/tensorflow/issues/61881
1,899,566,804
I_kwDOArmXAs5xORbU
61,881
XLA compiled `tf.matmul` can work for two size-incompatible matrices
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1133285679, "node_id": "MDU6TGFiZWwxMTMzMjg1Njc5", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla", "name": "comp:xla", "color": "0052cc", "default": false, "description": "XLA" }, { "id": 5508003926, "node_id": "LA_kwDOArmXAs8AAAABSE14Vg", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13", "name": "TF 2.13", "color": "B13ACB", "default": false, "description": "For issues related to Tensorflow 2.13" } ]
open
false
{ "login": "kenfranko", "id": 56562020, "node_id": "MDQ6VXNlcjU2NTYyMDIw", "avatar_url": "https://avatars.githubusercontent.com/u/56562020?v=4", "gravatar_id": "", "url": "https://api.github.com/users/kenfranko", "html_url": "https://github.com/kenfranko", "followers_url": "https://api.github.com/users/kenfranko/followers", "following_url": "https://api.github.com/users/kenfranko/following{/other_user}", "gists_url": "https://api.github.com/users/kenfranko/gists{/gist_id}", "starred_url": "https://api.github.com/users/kenfranko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kenfranko/subscriptions", "organizations_url": "https://api.github.com/users/kenfranko/orgs", "repos_url": "https://api.github.com/users/kenfranko/repos", "events_url": "https://api.github.com/users/kenfranko/events{/privacy}", "received_events_url": "https://api.github.com/users/kenfranko/received_events", "type": "User", "site_admin": false }
[ { "login": "kenfranko", "id": 56562020, "node_id": "MDQ6VXNlcjU2NTYyMDIw", "avatar_url": "https://avatars.githubusercontent.com/u/56562020?v=4", "gravatar_id": "", "url": "https://api.github.com/users/kenfranko", "html_url": "https://github.com/kenfranko", "followers_url": "https://api.github.com/users/kenfranko/followers", "following_url": "https://api.github.com/users/kenfranko/following{/other_user}", "gists_url": "https://api.github.com/users/kenfranko/gists{/gist_id}", "starred_url": "https://api.github.com/users/kenfranko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kenfranko/subscriptions", "organizations_url": "https://api.github.com/users/kenfranko/orgs", "repos_url": "https://api.github.com/users/kenfranko/repos", "events_url": "https://api.github.com/users/kenfranko/events{/privacy}", "received_events_url": "https://api.github.com/users/kenfranko/received_events", "type": "User", "site_admin": false }, { "login": "sachinprasadhs", "id": 73069040, "node_id": "MDQ6VXNlcjczMDY5MDQw", "avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4", "gravatar_id": "", "url": "https://api.github.com/users/sachinprasadhs", "html_url": "https://github.com/sachinprasadhs", "followers_url": "https://api.github.com/users/sachinprasadhs/followers", "following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}", "gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}", "starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions", "organizations_url": "https://api.github.com/users/sachinprasadhs/orgs", "repos_url": "https://api.github.com/users/sachinprasadhs/repos", "events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}", "received_events_url": "https://api.github.com/users/sachinprasadhs/received_events", "type": "User", "site_admin": false } ]
null
[ "Any progress on this issue?", "@sachinprasadhs,\r\nI was able to reproduce the issue on tensorflow v2.12, v2.13 and tf-nightly. Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/8b36e72bb2c1522665716df44450d82e/untitled1375.ipynb)." ]
2023-09-16T21:02:17
2023-10-05T08:10:08
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230914 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? XLA compiled `tf.matmul` can work for two size-incompatible matrices, like `[1, 5]` and `[10, 1]`. By contrast, if we run `tf.matmul` directly without XLA compilation, it will raise the error as expected: `Matrix size-incompatible: In[0]: [1,5], In[1]: [10,1] [Op:BatchMatMulV2] name: ` ### Standalone code to reproduce the issue ```shell import tensorflow as tf """ With XLA """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.w = tf.Variable(tf.random.normal([10,1]), shape=tf.TensorShape(None), dtype='float32') @tf.function(jit_compile=True) def call(self, x): return tf.matmul(x, self.w) m = Model() # Inputs to the model x1 = tf.constant([1., 2., 3., -3., 2.5], shape=[1, 5]) print(m(x1)) # tf.Tensor([[-11.37509]], shape=(1, 1), dtype=float32) """ Without XLA """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.w = tf.Variable(tf.random.normal([10,1]), shape=tf.TensorShape(None), dtype='float32') def call(self, x): return tf.matmul(x, self.w) m = Model() # Inputs to the model x1 = tf.constant([1., 2., 3., -3., 2.5], shape=[1, 5]) print(m(x1)) """ InvalidArgumentError: Exception encountered when calling layer 'model' (type Model). {{function_node __wrapped__BatchMatMulV2_device_/job:localhost/replica:0/task:0/device:GPU:0}} Matrix size-incompatible: In[0]: [1,5], In[1]: [10,1] [Op:BatchMatMulV2] name: Call arguments received by layer 'model' (type Model): • x=tf.Tensor(shape=(1, 5), dtype=float32) """ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61881/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61881/timeline
null
null
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61880
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61880/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61880/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61880/events
https://github.com/tensorflow/tensorflow/issues/61880
1,899,363,024
I_kwDOArmXAs5xNfrQ
61,880
org.tensorflow:tensorflow-lite-task-vision:
{ "login": "B-JackMao", "id": 57884144, "node_id": "MDQ6VXNlcjU3ODg0MTQ0", "avatar_url": "https://avatars.githubusercontent.com/u/57884144?v=4", "gravatar_id": "", "url": "https://api.github.com/users/B-JackMao", "html_url": "https://github.com/B-JackMao", "followers_url": "https://api.github.com/users/B-JackMao/followers", "following_url": "https://api.github.com/users/B-JackMao/following{/other_user}", "gists_url": "https://api.github.com/users/B-JackMao/gists{/gist_id}", "starred_url": "https://api.github.com/users/B-JackMao/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/B-JackMao/subscriptions", "organizations_url": "https://api.github.com/users/B-JackMao/orgs", "repos_url": "https://api.github.com/users/B-JackMao/repos", "events_url": "https://api.github.com/users/B-JackMao/events{/privacy}", "received_events_url": "https://api.github.com/users/B-JackMao/received_events", "type": "User", "site_admin": false }
[ { "id": 473184161, "node_id": "MDU6TGFiZWw0NzMxODQxNjE=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support", "name": "type:support", "color": "159b2e", "default": false, "description": "Support issues" }, { "id": 750616506, "node_id": "MDU6TGFiZWw3NTA2MTY1MDY=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite", "name": "comp:lite", "color": "0052cc", "default": false, "description": "TF Lite related issues" } ]
closed
false
{ "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false }
[ { "login": "pjpratik", "id": 118897289, "node_id": "U_kgDOBxY6iQ", "avatar_url": "https://avatars.githubusercontent.com/u/118897289?v=4", "gravatar_id": "", "url": "https://api.github.com/users/pjpratik", "html_url": "https://github.com/pjpratik", "followers_url": "https://api.github.com/users/pjpratik/followers", "following_url": "https://api.github.com/users/pjpratik/following{/other_user}", "gists_url": "https://api.github.com/users/pjpratik/gists{/gist_id}", "starred_url": "https://api.github.com/users/pjpratik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pjpratik/subscriptions", "organizations_url": "https://api.github.com/users/pjpratik/orgs", "repos_url": "https://api.github.com/users/pjpratik/repos", "events_url": "https://api.github.com/users/pjpratik/events{/privacy}", "received_events_url": "https://api.github.com/users/pjpratik/received_events", "type": "User", "site_admin": false } ]
null
[ "Hi @B-JackMao \r\n\r\nCould you please fill the [template](https://github.com/tensorflow/tensorflow/issues/new?assignees=&labels=comp%3Alite-in-play-services&projects=&template=tflite-in-play-services.md) and update to be relevant to the issue?\r\n\r\nPlease check [Build TensorFlow Lite](https://www.tensorflow.org/lite/android/lite_build) for Android that describes how to build TensorFlow Lite Android library on your own.\r\n\r\nThanks.", "This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.", "This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.", "Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61880\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61880\">No</a>\n" ]
2023-09-16T08:57:56
2023-10-07T01:47:35
2023-10-07T01:47:31
NONE
null
null
null
implementation 'org.tensorflow:tensorflow-lite-task-vision:0.1.0' Can I generate this dependency locally? What instructions should I use to generate in TFlite?
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61880/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61880/timeline
null
completed
false
https://api.github.com/repos/tensorflow/tensorflow/issues/61879
https://api.github.com/repos/tensorflow/tensorflow
https://api.github.com/repos/tensorflow/tensorflow/issues/61879/labels{/name}
https://api.github.com/repos/tensorflow/tensorflow/issues/61879/comments
https://api.github.com/repos/tensorflow/tensorflow/issues/61879/events
https://github.com/tensorflow/tensorflow/issues/61879
1,899,214,796
I_kwDOArmXAs5xM7fM
61,879
Invalid `Conv2d` can be executed without compilation
{ "login": "YangChenyuan", "id": 55501188, "node_id": "MDQ6VXNlcjU1NTAxMTg4", "avatar_url": "https://avatars.githubusercontent.com/u/55501188?v=4", "gravatar_id": "", "url": "https://api.github.com/users/YangChenyuan", "html_url": "https://github.com/YangChenyuan", "followers_url": "https://api.github.com/users/YangChenyuan/followers", "following_url": "https://api.github.com/users/YangChenyuan/following{/other_user}", "gists_url": "https://api.github.com/users/YangChenyuan/gists{/gist_id}", "starred_url": "https://api.github.com/users/YangChenyuan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YangChenyuan/subscriptions", "organizations_url": "https://api.github.com/users/YangChenyuan/orgs", "repos_url": "https://api.github.com/users/YangChenyuan/repos", "events_url": "https://api.github.com/users/YangChenyuan/events{/privacy}", "received_events_url": "https://api.github.com/users/YangChenyuan/received_events", "type": "User", "site_admin": false }
[ { "id": 404586594, "node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower", "name": "stat:awaiting tensorflower", "color": "f4b400", "default": false, "description": "Status - Awaiting response from tensorflower" }, { "id": 473172988, "node_id": "MDU6TGFiZWw0NzMxNzI5ODg=", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug", "name": "type:bug", "color": "159b2e", "default": false, "description": "Bug" }, { "id": 1097545817, "node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis", "name": "comp:apis", "color": "0052cc", "default": false, "description": "Highlevel API related issues" }, { "id": 2691123225, "node_id": "MDU6TGFiZWwyNjkxMTIzMjI1", "url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function", "name": "comp:tf.function", "color": "0052cc", "default": false, "description": "tf.function related issues" } ]
open
false
{ "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false }
[ { "login": "SuryanarayanaY", "id": 116063290, "node_id": "U_kgDOBur8Og", "avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4", "gravatar_id": "", "url": "https://api.github.com/users/SuryanarayanaY", "html_url": "https://github.com/SuryanarayanaY", "followers_url": "https://api.github.com/users/SuryanarayanaY/followers", "following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}", "gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}", "starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions", "organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs", "repos_url": "https://api.github.com/users/SuryanarayanaY/repos", "events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}", "received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events", "type": "User", "site_admin": false } ]
null
[ "Any update for this issue?", "@YangChenyuan Sorry for the late response!\r\nI was able to replicate the issue reported [here](https://colab.research.google.com/gist/sushreebarsa/5f2c13f3189b6dc82794d58c01d9b62e/61879.ipynb).\r\n@SuryanarayanaY Could you please have a look at this issue?\r\nThank you!", "@sushreebarsa Thanks for your further exploration and confirmation!", "Hi @YangChenyuan ,\r\n\r\nThis also seems issue with `tf.function` rather than XLA as per exercise in attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/f92d1a1d9a20c08139c5c716771e453e/61879_r1.ipynb). Without `tf.function` it works fine. Needs to dig more to find out the root cause.\r\n\r\nThank you!" ]
2023-09-15T23:55:07
2023-12-12T06:34:24
null
NONE
null
null
null
### Issue type Bug ### Have you reproduced the bug with TensorFlow Nightly? Yes ### Source source ### TensorFlow version 2.15.0-dev20230914 ### Custom code Yes ### OS platform and distribution _No response_ ### Mobile device _No response_ ### Python version _No response_ ### Bazel version _No response_ ### GCC/compiler version _No response_ ### CUDA/cuDNN version _No response_ ### GPU model and memory _No response_ ### Current behavior? An invalid `Conv2d` can be executed without compilation. By contrast, after using `@tf.function(jit_compile=True)`, it will raise error `Negative dimension size caused by subtracting 2 from 1 for '{{node conv2d_6/Conv2D}} ...` ### Standalone code to reproduce the issue ```shell import tensorflow as tf """ Don't use @tf.function(jit_compile=True) """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.conv2d = tf.keras.layers.Conv2D(5, 2, activation=tf.nn.relu) def call(self, x): conv2d = self.conv2d(x) return conv2d # Initializing the model m = Model() # Inputs to the model # This input results in a Conv2D kernel that has the shape (1, 2, 3, 5). x1 = tf.constant([[[[1., 2., 3.], [4., 5., 6.]]]], shape=[1, 1, 2, 3]) y = m(x1) print(y.shape) # (1, 0, 1, 5) """ Using @tf.function(jit_compile=True) """ class Model(tf.keras.Model): def __init__(self): super(Model, self).__init__() self.conv2d = tf.keras.layers.Conv2D(5, 2, activation=tf.nn.relu) @tf.function(jit_compile=True) def call(self, x): conv2d = self.conv2d(x) return conv2d # Initializing the model m = Model() # Inputs to the model # This input results in a Conv2D kernel that has the shape (1, 2, 3, 5). x1 = tf.constant([[[[1., 2., 3.], [4., 5., 6.]]]], shape=[1, 1, 2, 3]) y = m(x1) """ ValueError: Exception encountered when calling layer 'conv2d_6' (type Conv2D). Negative dimension size caused by subtracting 2 from 1 for '{{node conv2d_6/Conv2D}} = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], explicit_paddings=[], padding="VALID", strides=[1, 1, 1, 1], use_cudnn_on_gpu=true](x, conv2d_6/Conv2D/ReadVariableOp)' with input shapes: [1,1,2,3], [2,2,3,5]. Call arguments received by layer 'conv2d_6' (type Conv2D): • inputs=tf.Tensor(shape=(1, 1, 2, 3), dtype=float32) Call arguments received by layer 'model_10' (type Model): • x=tf.Tensor(shape=(1, 1, 2, 3), dtype=float32) """ ``` ### Relevant log output _No response_
{ "url": "https://api.github.com/repos/tensorflow/tensorflow/issues/61879/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/tensorflow/tensorflow/issues/61879/timeline
null
null
false