因此,查看write_feather的文档,我应该能够编写如下箭头表
import pyarrow as pa
import pyarrow.feather as fe
fe.write_feather(
pa.Table.from_arrays([ pa.array([1,2,3]) ], names=['value']), 'file.feather'
)
但我得到了以下错误:
File "pyarrow/feather.py", line 89, in write
if not df.columns.is_unique:
AttributeError: 'list' object has no attribute 'is_unique'
拼花地板文件的编写似乎和预期的一样,所以我认为可能存在缺陷。有什么想法吗
这里的问题是
pyarrow.feather.write_feather
在您使用的pyarrow
版本中需要的是pandas.DataFrame
,而不是pyarrow.Table
。如果您直接想要编写pyarrow.Table
,您需要升级到更新的版本,因为这个支持是最近才添加的相关问题 更多 >
编程相关推荐