关于python通过新建环境安装tfx的问题
作者:totobey 时间:2022-06-28 19:47:21
问题:想装tfx,但是提示不支持python3.9。
解决方案:新建一个环境tfx专门用来运行流水线,这个环境安装python3.8。
1.查看自己的python版本(jupyter notebook):
import sys
sys.version #查看python版本
2.新建一个名为tfx的环境(Anaconda Prompt)
首先查看当前已有环境:
conda env list
创建一个名为【tfx】的环境:
conda create --name tfx python==3.8
输入y
创建完毕
代码:
#激活环境
conda activate tfx
#退出环境
conda deactivate
#删除环境
conda remove -n tfx --all
#查看环境
conda env list
3.Anaconda选择新环境
需要安装jupyter
4.安装tfx
进入新环境,python版本已经变成3.8了
安装tensorflow和tfx:
(安装tfx的时候报错提示pywinpty版本太高,于是先装一个低版本的pywinpty)
pip install tensorflow
pip install pywinpty==1.1.6
pip install tfx==1.7.0
查看版本
import tensorflow as tf
print('TensorFlow version: {}'.format(tf.__version__))
from tfx import v1 as tfx
print('TFX version: {}'.format(tfx.__version__))
https://tensorflow.google.cn/tfx/guide
来源:https://blog.csdn.net/totobey/article/details/124784433
标签:python,安装,tfx
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
SQL Server数据库管理常用SQL和T-SQL语句
2009-05-07 14:01:00
Python编解码问题及文本文件处理方法详解
2021-04-13 07:52:06
![](https://img.aspxhome.com/file/2023/9/72999_0s.png)
ORACLE 10g 安装教程[图文]
2009-05-24 19:12:00
![](https://img.aspxhome.com/file/UploadPic/20095/26/200952620153777.jpg)
Pycharm最常用的快捷键及使用技巧
2022-12-13 11:33:25
![](https://img.aspxhome.com/file/2023/6/75116_0s.png)
关于爬虫中scrapy.Request的更多参数用法
2023-10-14 02:20:26
php支持中文字符串分割的函数
2023-11-18 21:42:04
javascript trim、left、right等函数,兼容IE,FireFox
2009-09-18 14:55:00
人性化设计用文字注入情感
2007-08-22 08:59:00
![](https://img.aspxhome.com/file/UploadPic/20078/22/20078229220647s.jpg)
利用Python进行数据可视化常见的9种方法!超实用!
2021-10-05 23:11:58
![](https://img.aspxhome.com/file/2023/2/82632_0s.jpg)
python实现生成Word、docx文件的方法分析
2021-03-01 07:49:53
Python函数中的作用域规则详解
2023-02-14 04:32:28
block 和 inline 的区别是?
2009-12-08 13:00:00
![](https://img.aspxhome.com/file/UploadPic/200912/8/203330321-54s.gif)
Python实现公历(阳历)转农历(阴历)的方法示例
2021-08-02 09:54:44
![](https://img.aspxhome.com/file/2023/0/77750_0s.png)
python pandas时序处理相关功能详解
2023-07-25 12:03:18
python3利用Dlib19.7实现人脸68个特征点标定
2021-05-05 19:13:06
![](https://img.aspxhome.com/file/2023/4/76034_0s.jpg)
python数组排序方法之sort、sorted和argsort详解
2021-02-01 19:26:12
Python机器学习之决策树
2022-02-24 07:19:01
![](https://img.aspxhome.com/file/2023/6/79416_0s.png)
详解配置Django的Celery异步之路踩坑
2022-11-25 22:06:45
django文档学习之applications使用详解
2021-09-11 11:15:12
![](https://img.aspxhome.com/file/2023/2/107112_0s.png)
如何用 Python 子进程关闭 Excel 自动化中的弹窗
2023-10-16 15:47:32
![](https://img.aspxhome.com/file/2023/2/71452_0s.png)