anaconda 安装 pymc3 ,theano

项目背景:

环境 anaconda python=3.8.8
安装pymc3,theano 包

问题描述

之前使用python3.11。无法使用pymc3,看了写网上的资料,依赖也很多。记录一下。


安装步骤:

提示:这里填写该问题的具体解决方案:

  1. 管理员打开anaconda prompt 添加清华镜像源-永久

镜像文件:.condarc
引用:https://blog.csdn.net/run_success/article/details/124841938

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
  1. 安装minGW和libpython

引用:https://zhuanlan.zhihu.com/p/420748136?utm_id=0

conda install mingw libpython
  1. 安装theano
pip install theano-pymc==1.1.2

此时运行 import theano 会报错:
AttributeError: partially initialized module ‘theano’ has no attribute ‘gof’ (most likely due to a circular import)

  1. numpy降级

引用:https://blog.csdn.net/u011868279/article/details/124584391
https://blog.csdn.net/wangzhaoqi_818/article/details/130548325?utm_medium=distribute.pc_relevant.none-task-blog-2defaultbaidujs_baidulandingword~default-5-130548325-blog-71080865.235v43pc_blog_bottom_relevance_base8&spm=1001.2101.3001.4242.4&utm_relevant_index=8

conda install m2w64-toolchain
pip install numpy==1.23.1
  1. import theano
    在这里插入图片描述
  2. 解决:WARNING (theano.tensor.blas): Using NumPy C-API based implementation for BLAS functions.
conda install theano pygpu

在这里插入图片描述
7. 安装pymc3

conda install pymc3

测试都没有问题
在这里插入图片描述

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值