THUMNLab / AutoGL

An autoML framework & toolkit for machine learning on graphs.
http://mn.cs.tsinghua.edu.cn/AutoGL/
Apache License 2.0
1.09k stars 119 forks source link

[BUG]v0.4.1 'DataFrame' has no attribute 'append'. Did you mean '_append'? #144

Open Gankuaidian opened 11 months ago

Gankuaidian commented 11 months ago

Describe the bug Traceback (most recent call last): File "/home/xxx/autoGL/ai1.py", line 6, in custom_static_homogeneous_graph = GeneralStaticGraphGenerator.create_homogeneous_static_graph( File "/home/xxx/.pyenv/versions/3.10.13/lib/python3.10/site-packages/autogl-0.4.1-py3.10.egg/autogl/data/graph/_general_static_graph/_general_static_graph_generator.py", line 73, in create_homogeneous_static_graph _heterogeneous_edges_aggregation[('', '', '')] = ( File "/home/xxx/.pyenv/versions/3.10.13/lib/python3.10/site-packages/autogl-0.4.1-py3.10.egg/autogl/data/graph/_general_static_graph/_general_static_graph_default_implementation.py", line 494, in setitem self._set_edges(edge_t, edges) File "/home/xxx/.pyenv/versions/3.10.13/lib/python3.10/site-packages/autogl-0.4.1-py3.10.egg/autogl/data/graph/_general_static_graph/_general_static_graph_default_implementation.py", line 683, in _set_edges self.heterogeneous_edges_data_frame.append( File "/home/xxx/.pyenv/versions/3.10.13/lib/python3.10/site-packages/pandas-2.1.4-py3.10-linux-x86_64.egg/pandas/core/generic.py", line 6204, in getattr return object.getattribute__(self, name) AttributeError: 'DataFrame' object has no attribute 'append'. Did you mean: '_append'?

To Reproduce Steps to reproduce the behavior:

  1. Use the provided example code from AutoGL documentation to produce a customized dataset image

  2. The pip installed old version does not have this problem.

After changing the line in the file" _general_static_graph_default_implementation.py", line 683, in _set_edges: self.__heterogeneous_edges_data_frame.append( into: self.__heterogeneous_edges_data_frame._append( there's no error message again.

Martins6 commented 9 months ago

I had the same error! Commenting here for better visibility. The same code change, fixed it for me! Thanks, @Gankuaidian Ideally the code in AutoGL should be changed to be used with pd.concat