Skip to content
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

Plot runtime of map_fn, vectorized_map, and a true vectorized implementation for RandomErasing #160

Closed
LukeWood opened this issue Mar 1, 2022 · 6 comments
Assignees

Comments

@LukeWood
Copy link
Contributor

LukeWood commented Mar 1, 2022

This will help us determine which flows we need to support/how important each improvement is on the previous.

@LukeWood LukeWood self-assigned this Mar 1, 2022
@bhack
Copy link
Contributor

bhack commented Mar 1, 2022

Do we need to add also XLA jit_compile? As nobody clarified on #146 if it was or not orthogonal to vectorized_map and to a true vectorized implementation.

@bhack
Copy link
Contributor

bhack commented Mar 1, 2022

For jit_compile we could check if we want to suggest users to enable with tf.config.optimizer.set_jit like in https://www.tensorflow.org/xla/tutorials/autoclustering_xla instead of enforcing ourself in the @tf.function decorator.

We have already some layers performance tests in Keras with tf.function vs XLA jit_compile matrix in:

https://github.com/keras-team/keras/blob/master/keras/benchmarks/layer_benchmarks/layer_benchmarks_test.py

@LukeWood
Copy link
Contributor Author

LukeWood commented Mar 1, 2022

The purpose of this experiment is to gather performance numbers so we can make a decision. I'll be doing benchmarking as thoroughly as possible to get this data.

@bhack
Copy link
Contributor

bhack commented Mar 1, 2022

Yes I just meant if we want to collect also some performance with jit_compile in the performance matrix.

@chjort
Copy link
Contributor

chjort commented Mar 3, 2022

@LukeWood
I have made some performance improvements to keras_cv.utils.fill_utils in PR #159. So I would recommend benchmarking with these improvements. I could include these performance improvements in its own PR without the GridMask changes if you would like.

You can see the new fill_utils.py here: https://github.com/keras-team/keras-cv/blob/796cdd2af4dbeef27f973f67b1c9dcc37e5f8b27/keras_cv/utils/fill_utils.py

@LukeWood
Copy link
Contributor Author

LukeWood commented Mar 3, 2022

the goal is to determine how good vectorized_map is more than anything, so I think the benchmark is fine.

freedomtan pushed a commit to freedomtan/keras-cv that referenced this issue Jul 20, 2023
* Add Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint

* Adds Model Checkpoint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants