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

Fix base image aug layer for non-TF backend in tf.data pipeline. #2281

Merged

Conversation

sampathweb
Copy link
Collaborator

When we have Image Aug Layers in JAX or Torch backend used in tf.data pipeline, the ops.convert_to_tensor breaks since it cannot convert a TF Symbolic tensor in the graph. This fix only does the conversion when its not part of a TF graph. Also, the conversion steps are skipped for TF backend since its not necessary.

Added unit test to verfy the failing under tf.data pipeline.

@divyashreepathihalli divyashreepathihalli merged commit e25de5e into keras-team:master Jan 8, 2024
10 checks passed
@sampathweb sampathweb deleted the fix-base-img-aug-tf branch January 8, 2024 03:10
divyashreepathihalli added a commit that referenced this pull request Jan 8, 2024
* Update base image aug layer tensor conversion (#2281)

* Update version to 0.8.1 (#2282)

* Fix YOLOv8Detector deserialization (#2283)

* Fix YOLOv8Detector deserialization

* Fix nit

* Deserialize preditction decoder

* Bump the python group with 4 updates (#2277)

Bumps the python group with 4 updates: [tf-nightly-cpu](https://github.com/tensorflow/tensorflow), torch, torchvision and [tf-nightly[and-cuda]](https://github.com/tensorflow/tensorflow).


Updates `tf-nightly-cpu` from 2.16.0.dev20231221 to 2.16.0.dev20240104
- [Release notes](https://github.com/tensorflow/tensorflow/releases)
- [Changelog](https://github.com/tensorflow/tensorflow/blob/master/RELEASE.md)
- [Commits](https://github.com/tensorflow/tensorflow/commits)

Updates `torch` from 2.1.2 to 2.1.2+cu121

Updates `torchvision` from 0.16.2 to 0.16.2+cu121

Updates `tf-nightly[and-cuda]` from 2.16.0.dev20231221 to 2.16.0.dev20240104
- [Release notes](https://github.com/tensorflow/tensorflow/releases)
- [Changelog](https://github.com/tensorflow/tensorflow/blob/master/RELEASE.md)
- [Commits](https://github.com/tensorflow/tensorflow/commits)

---
updated-dependencies:
- dependency-name: tf-nightly-cpu
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: python
- dependency-name: torch
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: python
- dependency-name: torchvision
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: python
- dependency-name: tf-nightly[and-cuda]
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: python
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Add Scorecard Action (#2267)

Signed-off-by: Pedro Kaj Kjellerup Nacht <pnacht@google.com>

* version bump to 0.8.1.dev0

---------

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Pedro Kaj Kjellerup Nacht <pnacht@google.com>
Co-authored-by: Ramesh Sampath <1437573+sampathweb@users.noreply.github.com>
Co-authored-by: Neel Kovelamudi <60985914+nkovela1@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pedro Kaj Kjellerup Nacht <pnacht@google.com>
Co-authored-by: Divyashree Sreepathihalli <divyashreepathihalli>
yuvraj-wale pushed a commit to yuvraj-wale/keras-cv that referenced this pull request Feb 8, 2024
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

Successfully merging this pull request may close these issues.

3 participants