NotFoundError: iris_training.csv - google-colaboratory

I am using Colab to repeat the exercise provided here: https://nbviewer.jupyter.org/gist/yufengg/a6dff912ab48f7a273f5704ad9ab1311
I changed the Tensorflow to version 1.3.0, However, I got the error as shown like this:
enter image description here
Any help will be gratefully appreciated.

You need to download the data too.
Try adding this
!wget https://raw.githubusercontent.com/h2oai/h2o-2/master/smalldata/iris/iris_train.csv

Related

I'm having a minor problem running Tensorflow with Colab

I am a beginner who just learned about TensorFlow using Google Colab.
As in the attached image file, numbers 10 to 13 are underlined in tensorflow.keras~, what is the problem?
It's probably a function that indicates a typo, but there's nothing wrong with running it.
enter image description here
This underline error was an ongoing issue earlier in Google Colab, which is resolved now. Please try again replicating the same code in Google colab what you mentioned in the screen shot and let us know if the issue still persists at your end.
Please check the code below: (I replicated the same in Google Colab with python 3.8.10 and TensorFlow 2.9.2)
from keras.preprocessing import Sequence will show the error as you are not giving proper alias to import the Sequence API which is provided correctly in next line (using tensorflow.keras.preprocessing prefix or tensorflow.keras.utils).

Could not open 'model/model_dir/export/export_m2/model.tflite'

I just try code On-device recommendation with TensorFlow Lite in Google Colab. I get an error in Create TFLite interpreter. The error message is Could not open 'model/model_dir/export/export_m2/model.tflite'. Can anyone solve this?
Thank you.
Link for code: https://github.com/tensorflow/examples/blob/master/lite/examples/recommendation/ml/ondevice_recommendation.ipynb

Unable to download .h5 weights file trained on Google Colab (approx 500 mb in size)

I have re-trained a VGG model on google colab.
However when I try to save the model using the below code it throws the following error:
Code:
from google.colab import files
files.download('vgg_retrained_colab_24epochs_loss_0_47_accuracy_76_88.h5')
Error report:
error report link
how can I overcome this? The same code works for smaller files
Maybe it's too late now. However, may this answer help someone else at least. I faced a similar problem with checkpoint file, you can find the solution that worked for me here
Your question can be found here: https://stackoverflow.com/a/48774782/5544055
just change "file_name.csv" to
"file_vgg_retrained_colab_24epochs_loss_0_47_accuracy_76_88.h5"

Tensorflow Datalab 'module' object has no attribute 'feature_column'

So, I literally copied and pasted the code from this quickstart:
https://www.tensorflow.org/get_started/estimator
into a new datalab notebook.... this code has worked for me many times in the past but now I'm getting an error that says the tf module does not contain the attribute 'feature_column'... this thing
https://www.tensorflow.org/api_docs/python/tf/feature_column
really sorta at a loss as to what I should do from here, any ideas? I've found this question
'module' object has no attribute 'feature_column'
and the OP said it had something to do with version control? Perhaps there's a way to ensure datalab is using the latest version of Tensorflow? Not sure where to begin looking through datalab's version controls... google searching hasn't returned anything that has jumped out at me so far...
It's probably because of different TensorFlow version. The sample on https://www.tensorflow.org/get_started/estimator is based on tf 1.3. So install 1.3 in your Datalab instance by running the following in a cell:
!pip install tensorflow==1.3
See if it works. Note that Datalab's preinstalled TF is 1.0 (will be updated soon). So if you create a new instance of Datalab you'll need to install it again.

RNN file is missed from tensorflow

I'm following the RNN tutorial on Tensorflow site. However, I couldn't find the rnn file named ptb_word_lm.py.
In my ptb folder, there is only reader.py there. Where I can find ptb_word_lm.py?
Many thanks.
I believe this is a bug, which we're tracking at https://github.com/tensorflow/tensorflow/issues/6196
The short answer is that the code is now here: https://github.com/tensorflow/models/tree/master/tutorials/rnn/ptb
I found it here, by searching "ptb_word_lm.py" in Google.
It seems it was removed from the official repository in version recently, one can still find it in 0.12 revision branch here.