apuaaChen / gcnLib

10 stars 4 forks source link

import errors in gcnlib_cuda and fuseGNN #2

Open fishmingyu opened 3 years ago

fishmingyu commented 3 years ago

We run install.sh in src file, only to find we couldn't import the fuseGNN module. In pip list we could find the following module:

fuseGNN                           0.0.1

However, we can not import the fuseGNN in python REPL.

>>> import fuseGNN
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'fuseGNN'

What's more, when we try to run the model with python training_main.py --model GAT --data CiteSeer --mode gas, it will also lead to another import error in gcnlib_cuda.

Traceback (most recent call last):
  File "training_main.py", line 7, in <module>
    from fuseGNN.modules import GCN, gcn_config, GAT, gat_config
  File "/home/yzm18/gcnLib/fuseGNN/modules/__init__.py", line 1, in <module>
    from fuseGNN.modules.gcn import GCN, gcn_config
  File "/home/yzm18/gcnLib/fuseGNN/modules/gcn.py", line 3, in <module>
    from fuseGNN.convs import geoGCNConv, refGCNConv, garGCNConv, gasGCNConv
  File "/home/yzm18/gcnLib/fuseGNN/convs/__init__.py", line 1, in <module>
    from fuseGNN.convs.gcn_conv import geoGCNConv, refGCNConv, garGCNConv, gasGCNConv
  File "/home/yzm18/gcnLib/fuseGNN/convs/gcn_conv.py", line 3, in <module>
    import gcnlib_cuda
ModuleNotFoundError: No module named 'gcnlib_cuda'

We expect that the detailed running configuration could be shown in the README.md to help us reproduce experimental results easily.

apuaaChen commented 3 years ago

I fixed the import error, you may try it again. For the fuseGNN module, I didn't pack the fuseGNN into the pip package. You may try something like

import torch
import fgnn_agg

For the running configuration, the training_main.py along with other source files should be a good example. I will add more instructions when I have some bandwidth.

fishmingyu commented 3 years ago

Thanks for your update. But what about gcnlib_cuda.dropout in gcnLib/fuseGNN/dropout.py?

fishmingyu commented 3 years ago

Thanks for your update. But what about gcnlib_cuda.dropout in gcnLib/fuseGNN/dropout.py?

I mean this code below is still puzzling. https://github.com/apuaaChen/gcnLib/blob/06b518f45df41d0e03163d2acda1a2c8df61e7e3/fuseGNN/functional/dropout.py#L10

apuaaChen commented 3 years ago

It is only used in the reference module for debugging. So it is not important

fishmingyu commented 3 years ago

By the way, you seem to forget to change the default data_path in the following code https://github.com/apuaaChen/gcnLib/blob/06b518f45df41d0e03163d2acda1a2c8df61e7e3/training_main.py#L20