close

How to run Tensorflow on CPU

Hello Guys, How are you all? Hope You all Are Fine. Today We Are Going To learn about How to run Tensorflow on CPU in Python. So Here I am Explain to you all the possible Methods here.

Without wasting your time, Let’s start This Article.

Table of Contents

How to run Tensorflow on CPU?

  1. How to run Tensorflow on CPU?

    You can also set the environment variable to
    CUDA_VISIBLE_DEVICES=""
    without having to modify the source code.

  2. run Tensorflow on CPU

    You can also set the environment variable to
    CUDA_VISIBLE_DEVICES=""
    without having to modify the source code.

Method 1

You can also set the environment variable to

CUDA_VISIBLE_DEVICES=""

without having to modify the source code.

Method 2

If the above answers don’t work, try:

os.environ['CUDA_VISIBLE_DEVICES'] = '-1'

Summery

It’s all About this issue. Hope all Methods helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which Method worked for you? Thank You.

Also, Read