当前位置:网站首页>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
边栏推荐
- 【Golang | gRPC】使用gRPC实现简单远程调用
- Finally detailed explanation
- 微信小程序视频分享平台系统毕业设计毕设(3)后台功能
- php获取两个时间戳之间相隔多少天多少小时多少分多少秒
- Experience Alibaba cloud character recognition OCR
- 1288_ Implementation analysis of vtask resume() interface and interrupt Security version interface in FreeRTOS
- 515. Find the maximum value in each tree row
- Editor编辑器扩展在Scene View添加按钮和logo
- vi/vim 删除:一行, 一个字符, 单词, 每行第一个字符 命令
- D构造函数问题
猜你喜欢
随机推荐
Mb10m-asemi rectifier bridge mb10m
微信小程序视频分享平台系统毕业设计毕设(5)任务书
WPS inserts a picture and displays it completely
如何开启IDEA的Run Dashboard功能
wait_for_gap -- 从主库归档备库恢复归档
1288_FreeRTOS中vTaskResume()接口以及中断安全版本接口实现分析
vi/vim 删除:一行, 一个字符, 单词, 每行第一个字符 命令
Embedded ~ introduction
C # detect whether the picture is rotated and modified to the true rotation
Three methods of MySQL backup
The price is only 40 yuan. Pico development board of raspberry pie is added with WiFi module, and it is out of stock as soon as it comes into the market
In Linux, MySQL sets the job task to start automatically
567.字符串中的排列
MySQL installation and configuration
Detailed explanation of map set
微信小程序视频分享平台系统毕业设计毕设(4)开题报告
wps插入图片后使图片完整显示
Graduation summary
Hbuilderx runs to the mobile phone or simulator and prompts that the device is not found
架构设计——ID生成器「建议收藏」







