GoogleCloudPlatform / GoogleCloudPlatform/training-data-analyst

ImportError: cannot import name 'transpose_shape` in TFRecord and tf.example lab

Open
#1,515 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
8.6k
Forks
6.1k
Avg merge
4h 44m
Merged PRs (30d)
2

Description

In training-data-analyst/courses/machine_learning/deepdive2/introduction_to_tensorflow/labs/tfrecord-tf.example.ipynb, first step of "Walkthrough: Reading and writing image data" fails with the following error:

```
ImportError: cannot import name 'transpose_shape' from 'keras.utils.generic_utils' (/opt/conda/lib/python3.7/site-packages/keras/utils/generic_utils.py)
```
Running on TensorFlow version: 2.6.0-dev20210616 (why does the lab use tf-nightly!?).

Contributor guide

Open the contributing guide

Research direction

Open training-data-analyst/courses/machine_learning/deepdive2/introduction_to_tensorflow/labs/tfrecord-tf.example.ipynb and reproduce the first step of “Walkthrough: Reading and writing image data” with TensorFlow 2.6.0-dev20210616. Inspect the import path and the lab’s tf-nightly dependency assumptions; done means the walkthrough passes that step without the reported ImportError.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook, keras, python, tensorflow
Domain
machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.