无法在 Arcgis notebook (GIS) 中运行 python 包

问题描述

我正在尝试在 Arcgis 笔记本中运行 python 可视化包 (altair),但出现此错误

RuntimeError                              Traceback (most recent call last)
In  [1]:
Line 17:    color='z:Q'

RuntimeError: make_tuple(): unable to convert arguments to Python object (compile in debug mode for details)

这是我的代码

import altair as alt
import numpy as np
import pandas as pd

# Compute x^2 + y^2 across a 2D grid
x,y = np.meshgrid(range(-5,5),range(-5,5))
z = x ** 2 + y ** 2

# Convert this grid to columnar data expected by altair
source = pd.DataFrame({'x': x.ravel(),'y': y.ravel(),'z': z.ravel()})

alt.Chart(source).mark_rect().encode(
    x='x:O',y='y:O',color='z:Q'
)

解决方法

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

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

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