问题描述
我想在 hdfstore 中存储大量数据(约 500 万行)。
我收到此性能警告Ö
sys:1: PerformanceWarning:
your performance may suffer as PyTables will pickle object types that it cannot
map directly to c-types [inferred_type->mixed,key->block1_values] [items->Index(['cards','position','points'],dtype='object')]
import pandas as pd
protocol = [[None,None],[0,2],None,None]
game = [0,2]
position = 2
result = 111
cards = [[0,0],[1,3],[3,7],6],1]]
columns = ['cards','protocol','label','points']
tupel = [(protocol,game,position,result,cards),(protocol,cards)]
games_data = pd.DataFrame(data=tupel,columns=columns)
print(games_data.info())
store = pd.hdfstore(f'store.h5')
store['games_data_str'] = games_data
store.close()
感谢您的帮助!
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)