Pycharm中Python版本的设置

Pycharm中Python版本的设置ChineseandEn nbsp toobothering Soi lljustuseEng nbsp SetPythonEnv

Chinese and English word transferring are too bothering for me. So i’ll just use Eng after.

 

Set Python Env

Before open or creat any project you can find preference button below the Pycharm window. It will be setted in every Proj not just specific one. I used Python 2.7 before because my ML teacher told us to and I now realize 2.7 will be dead in 2020 and it’s already stop releasing updates. So adding a new env for Pycharm is needed. I downloaded Python 3.7(24/11/18 newest) on its offical website and found it compatible with Python 2.7 on my Mac so it’s easier for me not to uninstall the old version, and it may helps for future project, who know XD.

 

Change Pycharm Setting

Find the “Project Interpreter” button on the side bar, and click the slide down button on the right. You wont find new Python3 on the table but that’s totally fine. Click on the “show all” and then the “+” button to add your new envs. You’ll get to pick add remote or localy. Since i dont use docker or not participate in any composing proj right now I’ll choose “add localy“. Let’s just put add remotely for further discussion okay?(//TODO! biggest joke ever XD)

Pycharm中Python版本的设置

Then you’ll find three options. 

  1. First i dont know, it looks like a virtual enviroment maybe a docker or cloud env. I’ll find that out in the future. This is honestly.
  2. Second is the thing i use. It’s from Anaconda Navigator. I too created an env for Python3 cuz i used 2 on it once and then i have to get this new version on everywhere. I picked “Existing env” and directed it into my Python3 env.
  3. Third one is from System. Choose third one. It’s added from the moment you install the P3. So it will automatically shows on the side and you get to choose more. I think most user should pick that. Cuz anaconda is really a burden for newbees(me) from my point.

Pycharm中Python版本的设置

 

Error I get

I tried to re-create that error for getting a snap picture but it magically gone, well, okay anyway…

After picked an env, i got an error says:

Cannot Save Settings please use a different SDK name

  1. I first rename my new interpreter to “Pythona 3.7” but it seems doesnt help.
  2. Then I deleted all red interpreter which all shows[invalid] on the side and they are all Python. Then it works out.

 

Other way to fix[or If you want to get rid of “venv”]

If you dont want to change interpreter for every proj or want to developing new way. You can try to initalize it from any begining of a proj. It will create an file called “venv” in proj. This will answer the question from[1] and it’s new in pycharm. If you want to stick to old fashioned way(i like to), and dont want your file system having something you dont even know, just choose below “Existing interpreter”.

Pycharm中Python版本的设置

 

I’ve only learnt it for two days so if there are anything wrong please let me know. Much Appreciated!❤️

 

references:

[1]https://stackoverflow.com/questions//configuring-interpreter-in-pycharm-please-use-a-different-sdk-name

 

 

 

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/173358.html原文链接:https://javaforall.net

(0)
上一篇 2026年3月27日 上午8:57
下一篇 2026年3月27日 上午8:58


相关推荐

  • 一元三次方程求根公式详细逐步推导

    一元三次方程求根公式详细逐步推导注 颜色为代数置换标记 推导后期需将前面的设定值回代 注 颜色为代数置换标记 推导后期需将前面的设定值回代 注 颜色为代数置换标记 推导后期需将前面的设定值回代已知 ax3 bx2 cx d 0a 0a b c d 已知 ax 3 bx 2 cx d 0 uada neq0 uada b c d in Re 已知 ax3 bx2 cx d 0a 0a b c d

    2026年3月19日
    3
  • 栈和队列经典面试题

    栈和队列经典面试题目录 1 括号匹配问题 2 用队列实现栈 3 用栈实现队列 4 设计循环队列 1 括号匹配问题链接直达 有效的括号题目 思路 2 用队列实现栈 3 用栈实现队列 4 设计循环队列

    2026年3月19日
    2
  • Python创建列表的4种方式

    Python创建列表的4种方式一 基本语法 创建 a print a 结果 创建空的列表 b 1 2 abc print b 结果 1 2 abc print b 2 结果 abc 二 list 创建 c list print c 结果 创建一个空的列表 c append 1 print c 结果 1 c

    2026年3月26日
    2
  • Bug驱动开发(Bug-driven development)

    Bug驱动开发(Bug-driven development)

    2021年12月5日
    45
  • rpa文件解包_py封装exe

    rpa文件解包_py封装exe用cxfreeze打包py文件为exe文件全过程:必须全部看完,正确在后面注意:当前环境是Play_Craw,pipinstallcx-freeze时自然安装到了C:\Users\xiaosalang\Anaconda3\envs\Play_Craw\Scripts处检验是否安装成功:cxfreeze-h将路径切换到.py文件处:如桌面文件cx1.py内容是:whil…

    2022年4月19日
    47
  • pycharm安装第三方库报错[通俗易懂]

    pycharm安装第三方库报错[通俗易懂]清华源网址https://pypi.tuna.tsinghua.edu.cn/simple/阿里源https://mirrors.aliyun.com/pypi/simple/删除一个源,保留另一个

    2022年8月26日
    8

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号