Use this tag for Tensor Processing Unit (TPU). TPU is an application-specific integrated circuit developed by Google.
Questions tagged [tpu]
421 questions
5
votes
3 answers
ValueError: None values not supported. Code working properly on CPU/GPU but not on TPU
I am trying to train a seq2seq model for language translation, and I am copy-pasting code from this Kaggle Notebook on Google Colab. The code is working fine with CPU and GPU, but it is giving me errors while training on a TPU. This same question…

Adarsh Wase
- 1,727
- 3
- 12
- 26
5
votes
2 answers
Kaggle TPU Unavailable: failed to connect to all addresses
I'm a newbie to ML. When trying to complete digit recognition with TPU method, I encountered following problems.
resolver =…

Dacian Peng
- 75
- 1
- 6
5
votes
1 answer
What does 'with strategy.scope():' or 'with tf.distribute.experimental.TPUStrategy(tpu).scope():' do to the creation of a NN?
In the code here:
https://www.kaggle.com/ryanholbrook/detecting-the-higgs-boson-with-tpus
Before the model is compiled, the model is made using this code:
with strategy.scope():
# Wide Network
wide = keras.experimental.LinearModel()
#…

user11945129
- 63
- 1
- 7
5
votes
2 answers
Unable to find the relevant tensor remote_handle: Op ID: 14738, Output num: 0
I am using a colab pro TPU instance for the purpose of patch image classification.
i'm using tensorflow version 2.3.0.
When calling model.fit I get the following error: InvalidArgumentError: Unable to find the relevant tensor remote_handle: Op ID:…

Pooya448
- 63
- 4
5
votes
1 answer
In google colab, is there a way to check what TPU verison is running?
colab offers free TPUs. It's easy to see how many cores are given, but I was wondering if its possible to see how much memory per core?

SantoshGupta7
- 5,607
- 14
- 58
- 116
5
votes
2 answers
ValueError: Trying to create optimizer slot variable under the scope for tf.distribute.Strategy
Please find below code for the image classification into 2 class, which I am trying to execute using Kaggle TPU's. Could you please help to figure the problem here?
I have followed the guideline from the Kaggle website in order to use the GPU, but…

Nitin
- 396
- 7
- 18
5
votes
1 answer
Hard-swish for TFLite
I have a custom neural network written in Tensorflow.Keras and apply the hard-swish function as activation (as used in the MobileNetV3 paper):
Implementation:
def swish(x):
return x * tf.nn.relu6(x+3) / 6
I am running quantization aware…

anki
- 765
- 5
- 14
5
votes
2 answers
RuntimeError:Mixing different tf.distribute.Strategy objects
Hello!I have encountered some problems when compiling the model using TPU.Some part of codes as follows:
resolver = tf.contrib.cluster_resolver.TPUClusterResolver(TF_MASTER)
tf.contrib.distribute.initialize_tpu_system(resolver)
strategy =…

o sy
- 71
- 5
5
votes
1 answer
Convert Keras model to quantized Tensorflow Lite model that can be used on Edge TPU
I have a Keras model that I want to run on the Coral Edge TPU device. To do this, it needs to be a Tensorflow Lite model with full integer quantization. I was able to convert the model to a TFLite model:
model.save('keras_model.h5')
converter =…

Merlin04
- 1,837
- 4
- 23
- 27
5
votes
1 answer
How to solve "Propagation of dynamic dimension failed" error in tf.keras with tpu?
I have this error when I try to train an image detector with my own images on google colab with TPU :
From /job:worker/replica:0/task:0:
Compilation failure: Asked to propagate a dynamic dimension from hlo %convert.283 = f32[1,80,80,32]{3,2,1,0}…

aa bb
- 411
- 1
- 5
- 17
5
votes
1 answer
Quantization-aware training in Tensorflow using the highlevel keras api
I built my first covnet using the process described in this colab. Now I would like to run the model on Googles shiny new edge tpu.
But according to the Model Requirments described here, I need to use quantization-aware training (post-training…

DrkStr
- 1,752
- 5
- 38
- 90
5
votes
2 answers
Cannot connect to Coral Dev Board (Edge TPU)
While following the instructions on Get Started with Edge TPU Dev Board, I can't get past Step 2:
$ screen /dev/ttyUSB0 115200
The issue is that screen immediately returns
[screen is terminating]
I have verified the contents of…

user3076252
- 1,919
- 13
- 13
4
votes
1 answer
OSError: libmkl_intel_lp64.so.1: cannot open shared object file: No such file or directory
I am trying to run a model on TPU as given in colab notebook. The model was working fine, but today I could not run the model.
I used the following code to install pytorch-xla.
VERSION = "nightly" #@param ["1.5" , "20200325", "nightly"]
!curl…

programming123
- 79
- 1
- 7
4
votes
0 answers
Dynamic Spatial Convolution is not supported on TPU
I'm trying to fit a Keras (TF 2.3.1) model for image classification with multiple binary labels as output. The model consists of an Xception CNN + attention layer + dense classifier, and hitting an error on some TPUs only:
UnimplementedError:…

Diego Roscardi
- 66
- 4
4
votes
1 answer
tensorflow error: "No OpKernel was registered to support Op 'TPUReplicatedInput'" when restoring model
(Novice question; sorry in advance.)
I have a pretrained (BigGAN) tensorflow model that another user developed to create images, and I would like to use it to generate new images. (If it helps to simplify the process, I do not need to train the…

jspi
- 51
- 5