python 3.6.4由bit32 换成bit64位带来的问题

由于bit32 的python3.6.4 在安装tensorflow时, 遇到问题,报错内容为:

Collecting tensorflow
  Could not find a version that satisfies the requirement tensorflow (from versions: )
No matching distribution found for tensorflow
You are using pip version 10.0.1, however version 19.1.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

一番搜索之后发现只有64bit 的python3.5或者python3.6 才有匹配的tensorflow版本, 于是卸载掉自己本机上32bit的python , 下载了64bit的。下载地址为:https://repo.anaconda.com/archive/
下载的是在这里插入图片描述
一路安装成功~
安装好以后,第一件事情就是把tensflow安装好, 安装步骤如下:
step01 下载一个对应版本的TensorFlow包,下载地址为: https://www.lfd.uci.edu/~gohlke/pythonlibs/

ste把该文件放到Python安装路径下的Scripts文件夹下,如D:\Python36\Scripts

3 .打开cmd, 进入该路径,输入 pip install tensorflow-1.4.0-cp36-cp36m-win_amd64.whl

参考博客为: https://blog.csdn.net/yz960611/article/details/78538488
安装成功了~

安装以后发现了以下几个问题:
1 import numpy时 总是报错说没有numpy模块, 可是pip install numpy时却已经有了这个包,numpy包在python 中占有至关重要的地位,很多包都依赖他。 于是缺了他, 很多包都引不进来。于是索性删除原有的numpy包,然后在cmd在pip install numpy, 测试,成功~
2 原有的访问oracle 的读取DataFrame的代码也开始报错,报错内容为:

DatabaseError: DPI-1047: Cannot locate a 64-bit Oracle Client library: "e:\app\product\11.2.0\dbhome_1\bin\oci.dll is not the correct architecture". See https://oracle.github.io/odpi/doc/installation.html#windows for help

解决方案如下面这个连接所示:
参考博客: https://www.jianshu.com/p/440c726cc516
测试成功~
3 Pandas 写入Oracle也有了问题,报错内容为:

Could not parse rfc1738 URL from string '用户名/密码@ip:端口/实例名'

解决方案为把地址改成:‘oracle+cx_oracle://用户名:密码@IP:端口/实例名’
参考博客为: https://blog.csdn.net/chg1226/article/details/82995671
测试成功~

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值