``` import torch import numpy as np import torch.nn as nn import torch.nn.functional as F import cv2 import matplotlib.pyplot as plt from PIL import I... ...
分类:
其他好文 时间:
2020-01-17 22:42:17
阅读次数:
207
代码: import cv2 import numpy as np from matplotlib import pyplot as plt import win32gui, win32ui, win32con from ctypes import windll from PIL import Im ...
分类:
编程语言 时间:
2020-01-17 19:26:39
阅读次数:
83
原文:https://www.cnblogs.com/gezhuangzhuang/p/10724769.html import cv2 import numpy as np from matplotlib import pyplot as plt # 读取图片 big.jpg img = cv2. ...
分类:
编程语言 时间:
2020-01-16 10:57:15
阅读次数:
118
1.图 2.代码 import pandas as pd import matplotlib as mpl import matplotlib.pyplot as plt import matplotlib.ticker as ticker import matplotlib.animation a ...
分类:
编程语言 时间:
2020-01-13 23:40:58
阅读次数:
160
1:第一种方法 # method1: subplot2grid ################# ''' 第一个参数(3, 3) 是把图分成3行3列 第二个参数是位置 (0, 0)表示从0行0列开始 第三个参数 colspan=3 表示列占3列 , 第四个参数 rowspan=1 表示行占一行 ' ...
分类:
其他好文 时间:
2020-01-12 18:29:20
阅读次数:
92
import numpy as npimport matplotlib.pyplot as pltfrom mpl_toolkits.mplot3d import Axes3D fig = plt.figure() ax = Axes3D(fig) x = np.arange(-4, 4, 0.25 ...
分类:
其他好文 时间:
2020-01-12 18:23:43
阅读次数:
76
# -*- coding: utf-8 -*- import matplotlib.pyplot as plt import random as r p=0.495 p1=0.095 p2=0.745 a=3 b=2 s=0 a1=[0]*100 a2=[0]*100 a32=[0]*100 a22 ...
分类:
其他好文 时间:
2020-01-12 11:21:40
阅读次数:
77
一 figure使用 1 import numpy as np 2 import matplotlib.pyplot as plt 3 4 # 从-3到中取50个数 5 x = np.linspace(-3, 3, 50) 6 print(x) 7 y1 = 2*x+1 8 y2 = x**2 9 ...
分类:
其他好文 时间:
2020-01-12 00:21:40
阅读次数:
64
1、定义绘图函数 import numpy as np import matplotlib.pyplot as plt def plot_square(center=(3, 3),length=5, width=2): x_left = center[0] - length/2 x_right = ...
分类:
其他好文 时间:
2020-01-11 20:29:15
阅读次数:
112
matplotlib 在python下一般使用matplotlib包下的pyplot,所以在import的时候: 一般import matplotlib.pyplot as plt方便使用它的绘图函数。 show()函数: 显示绘图窗口,把要画的图显示在窗口中。 subplot()函数: 用于添加子 ...
分类:
编程语言 时间:
2020-01-11 16:48:51
阅读次数:
113