RError.com

RError.com Logo RError.com Logo

RError.com Navigation

  • 主页

Mobile menu

Close
  • 主页
  • 系统&网络
    • 热门问题
    • 最新问题
    • 标签
  • Ubuntu
    • 热门问题
    • 最新问题
    • 标签
  • 帮助
主页 / 问题

问题[andas]

Martin Hope
Vasyl Kolomiets
Asked: 2022-08-06 18:17:38 +0000 UTC

尝试将 Modin[Dask] 应用于工作项目 - 读取 pd.read_csv() 文件时失败

  • 0

有一个工作项目。
由于读取 1+ GB 的 csv 文件和各种groupby() + apply(). 承诺只取代一条线的广告吸引了人们。
在 Anaconda / Python 3.9.12 中从头开始安装所有必要的包。只安装了 Dask 以防万一。

我运行它,它是:

    UserWarning: Dask execution environment not yet initialized. Initializing...
To remove this warning, run the following python code before doing dataframe operations:

    from distributed import Client

    client = Client()


    2022-06-06 13:00:20,340 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-75ktabxn', purging
    2022-06-06 13:00:20,365 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-97o0hmer', purging
    2022-06-06 13:00:20,370 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-ck5pxauy', purging
    2022-06-06 13:00:20,377 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-qswh4ton', purging
    2022-06-06 13:00:20,386 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-vmsc68w6', purging
    2022-06-06 13:00:20,390 - distributed.diskutils - INFO - Found stale lock file and directory 'D:\\OD\\OneDrive\\Projects\\Chud_Amaz\\Soft_in_dev\\moduled_way_OOP\\dask-worker-space\\worker-ys_mgy6k', purging
    OD ---> Cant read csv D:\_\OD\AD__OD_04.06.22\AD__RET.csv. Error is index 0 is out of bounds for axis 0 with size 0
    Traceback (most recent call last):
  File D:\OD\OneDrive\Projects\Chud_Amaz\Soft_in_dev\moduled_way_OOP\izi_report_main_foldered.py:108 in <module>
    main_foldered()

  File D:\OD\OneDrive\Projects\Chud_Amaz\Soft_in_dev\moduled_way_OOP\izi_report_main_foldered.py:81 in main_foldered
    assert False, "Bad input files"

AssertionError: Bad input files

由于我不明白 Dask 想从我这里得到什么,所以我想问 - 那会是什么?嗯,也就是说,一切正常。在模块中添加了以下内容:

try:
    import modin.pandas as pd
except:
    import pandas as pd

而我被骗了。告诉我——去哪里跑?
是的。我有Windows10,AMD。

所以,简而言之,问题是:

安装后modin[dask]运行代码报错:

Error is index 0 is out of bounds for axis 0 with size 0
Traceback (most recent call last):

他自己read_csv() 有这些参数:

            readed_into_df = pd.read_csv(
                str(file_path),
                skiprows=skiprows_list,
                sep=separator,
                encoding=en_cod_,
                thousands=",",  # TODO: chek it
                on_bad_lines="skip",
                usecols=columns_dtype.keys(),
                dtype=columns_dtype,
            )
python andas
  • 1 个回答
  • 33 Views

Sidebar

Stats

  • 问题 10021
  • Answers 30001
  • 最佳答案 8000
  • 用户 6900
  • 常问
  • 回答
  • Marko Smith

    我看不懂措辞

    • 1 个回答
  • Marko Smith

    请求的模块“del”不提供名为“default”的导出

    • 3 个回答
  • Marko Smith

    "!+tab" 在 HTML 的 vs 代码中不起作用

    • 5 个回答
  • Marko Smith

    我正在尝试解决“猜词”的问题。Python

    • 2 个回答
  • Marko Smith

    可以使用哪些命令将当前指针移动到指定的提交而不更改工作目录中的文件?

    • 1 个回答
  • Marko Smith

    Python解析野莓

    • 1 个回答
  • Marko Smith

    问题:“警告:检查最新版本的 pip 时出错。”

    • 2 个回答
  • Marko Smith

    帮助编写一个用值填充变量的循环。解决这个问题

    • 2 个回答
  • Marko Smith

    尽管依赖数组为空,但在渲染上调用了 2 次 useEffect

    • 2 个回答
  • Marko Smith

    数据不通过 Telegram.WebApp.sendData 发送

    • 1 个回答
  • Martin Hope
    Alexandr_TT 2020年新年大赛! 2020-12-20 18:20:21 +0000 UTC
  • Martin Hope
    Alexandr_TT 圣诞树动画 2020-12-23 00:38:08 +0000 UTC
  • Martin Hope
    Air 究竟是什么标识了网站访问者? 2020-11-03 15:49:20 +0000 UTC
  • Martin Hope
    Qwertiy 号码显示 9223372036854775807 2020-07-11 18:16:49 +0000 UTC
  • Martin Hope
    user216109 如何为黑客设下陷阱,或充分击退攻击? 2020-05-10 02:22:52 +0000 UTC
  • Martin Hope
    Qwertiy 并变成3个无穷大 2020-11-06 07:15:57 +0000 UTC
  • Martin Hope
    koks_rs 什么是样板代码? 2020-10-27 15:43:19 +0000 UTC
  • Martin Hope
    Sirop4ik 向 git 提交发布的正确方法是什么? 2020-10-05 00:02:00 +0000 UTC
  • Martin Hope
    faoxis 为什么在这么多示例中函数都称为 foo? 2020-08-15 04:42:49 +0000 UTC
  • Martin Hope
    Pavel Mayorov 如何从事件或回调函数中返回值?或者至少等他们完成。 2020-08-11 16:49:28 +0000 UTC

热门标签

javascript python java php c# c++ html android jquery mysql

Explore

  • 主页
  • 问题
    • 热门问题
    • 最新问题
  • 标签
  • 帮助

Footer

RError.com

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

帮助

© 2023 RError.com All Rights Reserve   沪ICP备12040472号-5