Windows下安装pymc3遇bleach、html5lib版本不兼容问题求助
Hey there, I’ve run into similar dependency hiccups before—let’s break down how to fix this conflict between tensorflow-tensorboard 1.5.0 and your current bleach/html5lib versions.
方案1:降级冲突包到指定版本
Since tensorflow-tensorboard 1.5.0 has strict version requirements for bleach and html5lib, you can explicitly install the required versions first:
- Uninstall the current conflicting packages:
pip uninstall -y bleach html5lib - Install the versions required by
tensorflow-tensorboard 1.5.0:pip install bleach==1.5.0 html5lib==0.9999999 - Now try installing pymc3 again:
pip install git+https://github.com/pymc-devs/pymc3
Note: This might affect other tools in your global environment that rely on newer versions of bleach or html5lib. If you’re working on multiple projects, I’d recommend the next option.
方案2:用虚拟环境隔离依赖(更推荐)
Virtual environments keep project dependencies separate, so you won’t mess up your global setup. Here’s how to do it on Windows 10:
- Create a new virtual environment (replace
pymc3_envwith your preferred name):python -m venv pymc3_env - Activate the environment:
pymc3_env\Scripts\activate - Once activated, install the required dependency versions first, then pymc3:
pip install bleach==1.5.0 html5lib==0.9999999 pip install git+https://github.com/pymc-devs/pymc3
When you’re done working, just run deactivate to exit the virtual environment.
方案3:尝试安装兼容Python 3.5的pymc3版本
Python 3.5 is pretty old, and the latest pymc3 versions might not support it well. Try installing a specific older version of pymc3 that’s known to work with Python 3.5 and older tensorflow-tensorboard:
pip install pymc3==3.11.5
You can cross-check pymc3’s release notes if this version doesn’t fit—look for tags explicitly marked as compatible with Python 3.5.
内容的提问来源于stack exchange,提问作者이성령

