-
Notifications
You must be signed in to change notification settings - Fork 74k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Performance regression: Tensorflow 2.5.0 #51145
Comments
Performance
Something broke between 2.4 and 2.5 |
Hy! I am processing matrix multiplication operations on TensorFlow and NumPy to check the processing time difference on CPU and GPU. It's taking more time to process operation on GPU than on CPU On Cpu its taking:1.15 sec On GPU it's taking: 34 sec why so? According to my understanding GPU should perform fast operations than CPU.. CPU CODE
GPU Code
|
@rmothukuru Was able to reproduce on colab using TF v2.3,v2.4, v2.5 & tf-nightly,please find the gists attached here. |
Try using the Intel Tensor Flow 2.5, pip install intel-tensorflow==2.5.0 |
@ImtiazSajwani Intel TensorFlow doesn't have any optimization for |
@penpornk , do you have a plan to patch the performance fix of Eigen and TF to master or any version of release? |
@liyinhgqw Currently there is no plan. But I can investigate if the issue can be fixed in the master branch. (The patch for v2.5 alone requires reverting / changing 5 commits between 2.3 and 2.5. There could be more commits after 2.5 which affects compiler optimization.) |
@penpornk that would be super helpful - thank you! ideally, we could get a fix for this onto master for the 2.8 release (and future versions). do you think that would be possible? |
I was able to reproduce the issue in |
Please make sure that this is an issue related to performance of TensorFlow.
As per our
GitHub Policy,
we only address code/doc bugs, performance issues, feature requests and
build/installation issues on GitHub. tag:performance_template
System information
You can collect some of this information using our environment capture
script
You can also obtain the TensorFlow version with:
python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)"
python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"
Describe the current behavior
I observed significant performance regression (+20% latency) using TF 2.5.0 compared to TF 2.3.0 on CPU.
One op to highlight is
sparse_tensor_dense_matmul
.The cause could be Eigen or change of this kernel.
Describe the expected behavior
Performance on parity with TF 2.3.0.
Standalone code to reproduce the issue
Provide a reproducible test case that is the bare minimum necessary to generate
the problem. If possible, please share a link to Colab/Jupyter/any notebook.
https://colab.research.google.com/drive/1gNaQsRZzhmKYFQGMxOO9vzSR6AFpVMci?usp=sharing
The text was updated successfully, but these errors were encountered: