当前位置:网站首页>Installation tutorial and simple call of Matplotlib
Installation tutorial and simple call of Matplotlib
2022-07-02 18:11:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
Catalog
1.matplotlib The download
Our normal download method is to enter :pip install matplotlib, So you can download it from the official , But the download speed is very slow , We are The most detailed Anaconda Installers Installation 【numpy,jupyter】( chart + writing ) This blog once wrote , Can be in pip install matplotlib Add after -i https://pypi.tuna.tsinghua.edu.cn/simple, This is to download from the address of Tsinghua , Download much faster , If we add a new module every time we download it -i https://pypi.tuna.tsinghua.edu.cn/simple, It's really a troublesome big project , So is there a way to do it once and for all ? That is, how to specify the download from Tsinghua University ?
We find C disc , Find our users , Click in user name , And then create a pip Folder :
Then open the downloaded compressed package , find pip.ini file Download zip : link :https://pan.baidu.com/s/1y32LXxZ9Yx8GOn6YYlvwfw Extraction code :6sl5
Drag this file into the newly created pip In the folder :
such , We will configure the download address , We can type in pip install matplotlib, The default installed website is the website of Tsinghua University , There is no need to write -i https://pypi.tuna.tsinghua.edu.cn/simple
️ notes : If you have followed the blogger according to the blog : The most detailed Anaconda Installers Installation 【numpy,jupyter】( chart + writing ) Installed Anaconda Installers, So before you enter pip install matplotlib after , Will be displayed :
This is because you have already installed matplotlib, There is no need to repeat the installation , Can be used directly
After installed , We can log in to our jupyter To run :
2. The roses
Our data :
link :https://pan.baidu.com/s/1VaPHJa6YttfnedO0ewDRtQ Extraction code :5u92
After downloading the data , Move it into our folder :( Download directly to the desktop , Find the location of the folder , Then drag it in ), It is suggested to compare this picture with jupyter Created on Python3 The code is in the same folder , In this way, you can operate according to the blogger's figure below , Otherwise, you need to find the path of the image file by yourself .
We call our imread Methods to check the flower before us .
It can be seen that , This is a three-dimensional array , We can also use shape Or is it ndim To view the :
Why are there three dimensions ? This is because a picture has : Height , Width , Color Where is calling shape The three parameters displayed :(1200, 1920, 4) Represent the : Height pixel , Width pixels , Color channel .
Now? , Let's call imshow() Function to display this flower :
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/148246.html Link to the original text :https://javaforall.cn
边栏推荐
猜你喜欢

开发一个禁止删除namespace的控制器

Develop a controller that prohibits deleting namespaces

Taiwan Feiling fm8pb513b MCU provides MCU program development product design

Outsourcing for five years, abandoned

微信小程序视频分享平台系统毕业设计毕设(1)开发概要

Modbus protocol communication exception

Easyai notes - machine learning

切换变换的时候记得使用三元表达式

finally详解

深入理解ThreadLocal
随机推荐
Web聊天工具
Calculation of favorable comment rate
微信小程序视频分享平台系统毕业设计毕设(8)毕业设计论文模板
Huimang micro IO MCU ft60f011a-rb
Typescript
win10 kms activator
自定义一个loading指令
Two pieces of nature a day! Duan Fengfeng, an alumnus of the University of science and technology of China, was the third Chinese winner of the belby medal
Simple understanding of cardinality sorting
MySQL installation and configuration
A4988与42步进电机
Solution pour arrêter automatiquement les paquets Jar en cours d'exécution en éteignant le serveur de connexion xshell
Pfc232-sop8/14/16 should be wide-ranging and can be tape programmed with burning program
Intelligent hydropower meter energy consumption monitoring cloud platform
Troubleshooting ideas that can solve 80% of faults
架构设计——ID生成器「建议收藏」
如何开启IDEA的Run Dashboard功能
如何下载微信支付证书(API证书)
Experience Alibaba cloud character recognition OCR
vimium映射键