Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to solve the problem that python installs tfx through the new environment

2025-03-30 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)05/31 Report--

In this article, the editor introduces in detail "how to solve the problem of python installing tfx through the new environment". The content is detailed, the steps are clear, and the details are handled properly. I hope that this article "python installs tfx through the new environment how to solve the problem" can help you solve your doubts.

Problem: want to install tfx, but the hint does not support python3.9.

Solution: create a new environment tfx dedicated to running the pipeline, which installs python3.8.

1. Check your own python version (jupyter notebook): import syssys.version # View python version

two。 Create a new environment named tfx (Anaconda Prompt)

First take a look at the existing environment:

Conda env list

Create an environment called [tfx]:

Conda create-name tfx python==3.8

Enter y

Created

Code:

# activate environment conda activate tfx# exit environment conda deactivate# delete environment conda remove-n tfx-- all# view environment conda env list3.Anaconda select a new environment

Jupyter needs to be installed

4. Install tfx

Entering the new environment, the python version has become 3.8.

Install tensorflow and tfx:

(when installing tfx, an error indicates that the pywinpty version is too high, so install a lower version of pywinpty first)

Pip install tensorflowpip install pywinpty==1.1.6pip install tfx==1.7.0

View version

Import tensorflow as tfprint ('TensorFlow version: {}' .format (tf.__version__)) from tfx import v1 as tfxprint ('TFX version: {}' .format (tfx.__version__))

After reading this, the article "how to solve the problem of python installing tfx through a new environment" has been introduced. If you want to master the knowledge points of this article, you still need to practice and use it yourself to understand it. If you want to know more about related articles, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report