Ask questionsModuleNotFoundError: No module named 'tflite_runtime'


I am working a x86 Laptop and have installed tensorflow using Following is the list of tflite installed

ankit@HP:~$ pip3 list | grep tflite
tflite                        1.15.0                       
tflite-runtime                1.14.0 

my aim is to get a Google coral example running from this link

When I execute the command for inference I get the folllowing error

Traceback (most recent call last):
  File "", line 36, in <module>
    import tflite_runtime.interpreter as tflite
ModuleNotFoundError: No module named 'tflite_runtime'

Is there anything else that I need to install. I already have installed the libedgetpu1-std.


Answer questions aselle

Ah, it makes sense from your commands what happened when you run with sudo pip install you install in /usr/local/lbi

conda create --name myenv conda activate myenv pip install tensorflow (or whatever)

The point is that you need to activate the conda environment. Then you don't need "sudo pip"


Related questions

Error occurred when finalizing GeneratorDataset iterator
ModuleNotFoundError: No module named 'tensorflow.contrib'
ModuleNotFoundError: No module named 'tensorflow.contrib' hot 4
When importing TensorFlow, error loading Hadoop hot 4
The flag 'log_dir' is defined twice. hot 3
[TF 2.0] Dataset has no attribute 'make_one_shot_iterator' hot 3
Lossy conversion from float32 to uint8. Range [0, 1]. Convert image to uint8 prior to saving to suppress this warning. hot 3
TF2.0 AutoGraph issue hot 3
Error loading tensorflow hot 3
AttributeError: module 'tensorflow' has no attribute 'set_random_seed' hot 3
No tf.lite.experimental.nn.bidirectional_dynamic_rnn ops is finded hot 3
Incorrect Error TypeError: padded_batch() missing 1 required positional argument: &#39;padded_shapes&#39; hot 3
tensorflow2.0 detected 'xla_gpu' , but 'gpu' expected hot 2
Using tensorflow gpu 2.1 with Cuda 10.2 hot 2
Restoring Keras model fails inside a distribution strategy scope hot 2
Github User Rank List