Holoviews 核心选项异常

问题描述

我正在使用 Plotly 创建仪表板,通过将镶木地板文件读取到 Pandas 数据框中,然后创建温度、压力和湿度与温度的全息视图对象来从传感器收集数据。

该图最初按预期呈现文件,但我很快收到以下错误 -

Exception: Cleanup of custom options tree with id 'nonetype' object has no attribute '_options_context' Failed with the following exception: 0,an unreferenced orphan tree may persist in memory.

我的代码如下 -

path = r'/path/to/logs'
    
df = pd.read_parquet(path+r'//'+r'sensors.parquet.gzip')
df['timestamp'] = pd.to_datetime(df['timestamp'])
ds = hv.Dataset(df)

tempPlot = ds.to(hv.Curve,'timestamp','temperature','mac').overlay()
tempPlot.opts(title="Temperature vs timestamp")

pressurePlot = ds.to(hv.Curve,'pressure','mac').overlay()
pressurePlot.opts(title="Pressure vs timestamp")

humidityPlot = ds.to(hv.Curve,'humidity','mac').overlay()
humidityPlot.opts(title="Humidity vs timestamp")

    
app.layout = html.Div(components.children)
app.run_server(debug=True)

这给出了附加的仪表板

Dashboard

但是在终端窗口中,我看到了上述异常并希望解决它。另外,有人可以指导我如何使 x 轴显示时间戳而不是 int 值吗?

谢谢 花椒

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)