Skip to content Skip to sidebar Skip to footer

Colab TPU Error When Calling Model.fit() : UnimplementedError

I'm trying to classify cifar10 images with Google colab TPU, according to the official tutorial. However I got the following error. UnimplementedError: 6 root error(s) found. Wit

Solution 1:

if you look to the error, it says File system scheme '[local]' not implemented.

tfds often doesn't host all the datasets and downloads some from the original source to your local machine, which TPU can't access.

Cloud TPUs can only access data in GCS as only the GCS file system is registered. Please see: https://cloud.google.com/tpu/docs/troubleshooting#cannot_use_local_filesystem for more details.

You can make tfds to download the data to your gs bucket (details are here):

# Authenticate your account to access GCS.
from google.colab import auth
auth.authenticate_user()

...

# download cifar10 data to a gs bucket.
ds_test, ds_train = tfds.load('cifar10', split=['test', 'train'], try_gcs=True, data_dir="gs://YOUR_BUCKET_NAME")

Note that recently introduced TPU VMs can access local files. And you can create TPU VMs in GCP but not yet in Colab/Kaggle.


Post a Comment for "Colab TPU Error When Calling Model.fit() : UnimplementedError"