python - 移动图形时 matplotlib trisurf 缓慢

标签 python linux matplotlib data-visualization

共有4186个数据点。

这是我的电脑配置。移动图形非常慢。用类似数据的矩阵绘制曲面图有什么更快的方法吗?谢谢。

而且我的电脑还不错。磁盘是三星SSD EVO 840 500g

enter image description here

enter image description here

按照 mrcl 的建议使用 mayavi2 冲浪图,我的代码如下:

import pandas as pd
a = pd.read_csv('result.csv')
import numpy as np
from mayavi import mlab
x,y,z = a.fast.values, a.slow.values, a.profit.values
mlab.points3d(x,y,z)
mlab.show()

enter image description here

最佳答案

如何在 mayavi 中使用冲浪绘图的示例。

import numpy
from mayavi.mlab import *

def f(x, y):
    sin, cos = numpy.sin, numpy.cos
    return sin(x + y) + sin(2 * x - y) + cos(3 * x + 4 * y)

x, y = numpy.mgrid[-7.:7.05:0.1, -5.:5.05:0.05]
s = surf(x, y, f(x,y))
#cs = contour_surf(x, y, f, contour_z=0)
show()

干杯

关于python - 移动图形时 matplotlib trisurf 缓慢,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22263745/

相关文章:

linux - NPTL 默认堆栈大小问题

python - matplotlib.pyplot.legend() 出现类型错误 : zip argument #2 must support iteration,

python - 使用表面和线框通过 Matplotlib 为小行星建模

java - 我需要在 3 维空间中绘制一个简单的动画箭头 vector

python - 在 Selenium 中找不到项目时如何引发错误并转到其他功能

Python:无法访问通过多处理更改的内存

python - ClientForm.AmbiguityError : more than one control matching name

linux - 我应该在哪个线程处理 RxTx SerialEvent.DATA_AVAILABLE 事件?

python - 计算每个值本身的大于操作的有效方法

c - 在linux中检索EBP寄存器的内容