


How to import python library in vscode? The following article will show you how to use anaconda to import the python library in vscode. I hope it will be helpful to you!
#When I first started learning to write python using vscode, I encountered many problems.
This time the code needs to import numpy, pandas and other libraries. After browsing many methods on the Internet, I found what I thought was the easiest method: Use anaconda to import the library.
It also facilitates the import of other libraries in the future. [Recommended learning: vscode tutorial, Programming teaching]
Existing environment: vs code has been installed and the plug-in used to run python
Install anaconda
##Introduction to Anacond
Anacond download and installation
Official website download address:You can refer to this article to download and install. There are several points to note:Test
Reference article:
link 1. Open cmd [WIN R /cmd]
Enter -conda list.
As shown in the figure below, Anaconda is installed successfully. 2. Create an environment
#Modify the Python version according to the version number, such as your python If the version is 3.7, change it to -conda create -n test python=3.7 pip #You can see the Python version in the lower left corner of the vs code page
Proceed (y/[n])? will appear, enter y
The rest of the steps are explained clearly in the article linked above
vscode configuration environment
Problems encountered: The current code needs to import the numpy library
1. Still click on the version number in the lower left corner of vs code , the options in the figure below will appear, select the interpreter as test: conda version 2. At this time, the error is still reported when running, saying that there is no numpy library, we need to install this library
3. Open cmd, enter -conda install numpy, run it again after successfully installing the numpy library, and solve the problem
Reference article for the process of installing the library:
link
Conclusion
#1. You can use the above method to install various libraries, which is simple and convenient.
2. By learning other people’s methods and then summarizing records, I hope to be able to help others
vscode Basic Tutorial!
The above is the detailed content of A brief analysis of how to use anaconda to import python library in vscode. For more information, please follow other related articles on the PHP Chinese website!

2022年了,该学会用VSCode debug了!下面本篇文章手把手带大家会习VSCode debug,希望对大家有所帮助!

本篇是VSCode配置文章,手把手教大家怎么在VSCode中配置使用 Geant4 和 Root,希望对大家有所帮助!

本篇文章扒拉一下vscode Prettier的选项,总结分享16个让你的代码变漂亮的属性,希望对大家有所帮助!

“工欲善其事,必先利其器!”,vscode作为前端开发的重要工具,其插件能大幅提升战斗力,精心收集12个插件,总有几款你还未曾拥有。

VSCode中如何开发uni-app?下面本篇文章给大家分享一下VSCode中开发uni-app的教程,这可能是最好、最详细的教程了。快来看看!

VScode中怎么开发置C/C++?怎么配置C/C++环境?下面本篇文章给大家分享一下Windows系统下VScode配置C/C++环境图文教程,希望对大家有所帮助!


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

SublimeText3 Chinese version
Chinese version, very easy to use

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

SublimeText3 Linux new version
SublimeText3 Linux latest version