keras-team / keras-io

Keras documentation, hosted live at keras.io
Apache License 2.0
2.69k stars 2.01k forks source link

tutorial bug in consistency_training #1864

Closed 0x1orz closed 2 days ago

0x1orz commented 1 month ago

Issue Type

Documentation Bug

Source

source

Keras Version

keras 2

Custom Code

Yes

OS Platform and Distribution

No response

Python version

No response

GPU model and memory

No response

Current Behavior?

A bug happened!

examples/vision/consistency_training.py in google colab


ModuleNotFoundError Traceback (most recent call last) in <cell line: 1>() ----> 1 from official.vision.image_classification.augment import RandAugment 2 from tensorflow.keras import layers 3 4 import tensorflow as tf 5 import tensorflow_addons as tfa

ModuleNotFoundError: No module named 'official.vision.image_classification'

Standalone code to reproduce the issue or tutorial link

https://colab.research.google.com/github/keras-team/keras-io/blob/master/examples/vision/ipynb/consistency_training.ipynb#scrollTo=vis6pLvU4jAc

Relevant log output

No response

chunduriv commented 1 month ago

@0x1orz,

I would like to suggest using the following import statement:

from official.vision.ops.augment import RandAugment

instead of this one:

from official.vision.image_classification.augment import RandAugment

This change will make your code more consistent with the models.official.vision

github-actions[bot] commented 2 weeks ago

This issue is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.

github-actions[bot] commented 2 days ago

This issue was closed because it has been inactive for 28 days. Please reopen if you'd like to work on this further.

github-actions[bot] commented 2 days ago

Are you satisfied with the resolution of your issue? Yes No