你需要在你做的图中添加图例,比如label = 'hdjddjdjdjdjdjjjjdjdjd',不然python不知道你的图例是什么
请问[No handles with labels found to put in legend.]是什么错误,如何修改?
5是要画这样两个图表,记录眨眼来检测是否是真视频(没眨眼说明是假视频)
调用了以下函数出错
def plot_by_fid(self, i):
# Vis plots
max_X = self.frame_num / self.fps
params = {}
params['title'] = 'Eye-state-probability'
params['colors'] = ['b-']
params['markers'] = [None]
params['linewidth'] = 3
params['markersize'] = None
params['figsize'] = None
x_axis = np.arange(self.frame_num) / self.fps
# Vis plots
prob_plot_1 = plot.draw2D([x_axis[:i + 1]],
[self.total_eye1_prob],
order=[''],
xname='time',
yname='eye state',
params=params,
xlim=[0, max_X],
ylim=[-1, 2])
prob_plot_2 = plot.draw2D([x_axis[:i + 1]],
[self.total_eye2_prob],
order=[''],
xname='time',
yname='eye state',
params=params,
xlim=[0, max_X],
ylim=[-1, 2])
vis = np.concatenate([prob_plot_1, prob_plot_2], axis=1)
scale = float(self.output_height) / vis.shape[0]
# Resize plot size to same size with video
vis = cv2.resize(vis, None, None, fx=scale, fy=scale)
self.plot_vis_list.append(vis)
return self.plot_vis_list
- 点赞
- 收藏
- 复制链接分享
1条回答
为你推荐
- 是什么导致空的Go for循环锁定程序?
- loops
- background-process
- 2个回答
- 运行dev_appserver.py时,如何强制gcloud cli不监视某些目录?
- reactjs
- 1个回答
- 转到r.Use并返回错误的Gorilla Mux MiddlewareFunc
- IT行业问题
- 计算机技术
- it技术
- 编程语言问答
- 互联网问答
- 1个回答
- 在PHP类中使用实用程序函数的最佳实践是什么? [关闭]
- oop
- php
- 1个回答
- 如何将Node.js服务器连接到Apache服务器?
- node.js
- apache
- apache
- php
- websocket
- javascript
- 3个回答
- 使用json内容类型的PUT请求
- 登录不工作...... PHP中的错误在哪里? [关闭]
- InvalidArgumentError: Input to reshape is a tensor with 152000 values, but the requested shape requires a multiple of 576
- 我怎样才能预编译jade.php模板?
- php
- wordpress
- npm
- 2个回答
- 什么会导致isset()和in_array()错误地评估?
- php
- evaluation
- 1个回答
- MATLAB GUI handles 无法传递?!!
- 开发语言
- 2个回答
- 什么是 Node.js? [打烊]
- node.js
- v8
- evented-io
- javascript
- 0个回答
- 3. Node.js + Nginx-现在怎么办?
- 什么是 c? ! ? ! 接线员怎么说?
- c
- trigraphs
- operators
- 0个回答