Skip to content
This repository has been archived by the owner on Dec 11, 2023. It is now read-only.

AttributeError: 'DataFrame' object has no attribute 'type'. Did you mean: 'astype'? #9

Open
Hapluckyy opened this issue Nov 29, 2023 · 2 comments

Comments

@Hapluckyy
Copy link

您好!我在尝试运行您的测评程序时,在完成所有题目的测评后遇到了这个问题:
您有空的时候方便帮忙看一看吗

python run_cmmlu.py

ld_religions
100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 160/160 [00:52<00:00,  3.07it
100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 67/67 [1:11:30<00:00, 64.03s/it]
]
Traceback (most recent call last):
  File "/home/edge2/aigc_evals/auto_eval/run_cmmlu.py", line 50, in <module>
    compute_match_metric(subjects,output_path,output_path_metric,data_type,MODEL)
  File "/home/edge2/aigc_evals/auto_eval/../auto_eval/mymetrics.py", line 28, in compute_match_metric
    for i, r in pd.json_normalize(events_df[events_df.type == "match"].data).iterrows():
                                            ^^^^^^^^^^^^^^
  File "/home/edge2/miniconda3/lib/python3.11/site-packages/pandas/core/generic.py", line 5989, in __getattr__
    return object.__getattribute__(self, name)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'DataFrame' object has no attribute 'type'. Did you mean: 'astype'?

@ssbuild ssbuild added bug Something isn't working and removed bug Something isn't working labels Nov 29, 2023
@ssbuild
Copy link
Owner

ssbuild commented Nov 29, 2023

使用main 分支

@Hapluckyy
Copy link
Author

谢谢,问题解决啦!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants