sayands / sgaligner

[ICCV 2023] SGAligner : 3D Scene Alignment with Scene Graphs
https://sayands.github.io/sgaligner/
MIT License
81 stars 4 forks source link

Preprocess run failure #8

Closed glennliu closed 4 months ago

glennliu commented 4 months ago

Hi,

I'm running preprocessing/scan3r/preprocess.py. It says a file is missing,

Exception has occurred: FileNotFoundError
[Errno 2] No such file or directory: '/data2/sgalign_data/out/files/relationships_subscenes_val.json'
  File "/home/cliuci/code_ws/sgaligner/utils/common.py", line 24, in load_json
    file = open(filename)
  File "/home/cliuci/code_ws/sgaligner/preprocessing/scan3r/preprocess.py", line 230, in process_data
    rel_json = common.load_json(osp.join(data_dir, 'files', rel_json_filename))['scans']
  File "/home/cliuci/code_ws/sgaligner/preprocessing/scan3r/preprocess.py", line 365, in <module>
    data_dir, data_write_dir, mode = process_data(args, cfg, rel2idx)
FileNotFoundError: [Errno 2] No such file or directory: '/data2/sgalign_data/out/files/relationships_subscenes_val.json'
sayands commented 4 months ago

This happens because you might not have run dataset generation which generates the subscans using 3RScan and dumps the scene graphs as triplets. Please have a look at dataset generation section in the readme.

glennliu commented 4 months ago

I tried to generate the data again. For some reasons, the generated out/files/objects_subscenes_val.json does not have any valid scans. I use the original parameters. Is there any selection on generate scans in the file?

sayands commented 4 months ago

Can you show an example of how does an entry in the file look like? Is it only in objects_subscenes_val.json or the others as well?

glennliu commented 4 months ago

In val_scans_subscenes.txt, it has

0988ea72-eb32-2e61-8344-99e2283c2728_1
0988ea72-eb32-2e61-8344-99e2283c2728_3
0988ea72-eb32-2e61-8344-99e2283c2728_4
0988ea72-eb32-2e61-8344-99e2283c2728_6
0988ea72-eb32-2e61-8344-99e2283c2728_11
0988ea72-eb32-2e61-8344-99e2283c2728_7
0988ea72-eb32-2e61-8344-99e2283c2728_13
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_13
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_57
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_28
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_75
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_81
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_21
0cac7540-8d6f-2d13-8eee-36ba2a428e3f_1

In relationships_subscenes_val.json and ``objects_subscenes_val.json```, they are both empty.

sayands commented 4 months ago

Hi I am not sure what exactly are you running, but I just ran bash scripts/generate_subscans_scan3r_gt.sh after uncommenting out the first 2 lines (to generate the subscans) afresh on the first 2 validation scans and it seems to have the relevant data. Can you tell me which steps you follow?

glennliu commented 4 months ago

Hi

I followed the instruction and run bash scripts/generate_subscans_scan3r_gt.sh. I cleaned up the entire dataset space and run the script again. It is now solved. I can process the generated data now.

In evaluation, I meet another dependency issue. I run /src/trainers/trainval_eva.py. It says I didn't install pointnet2_utils. The pct.py used pointnet backbone I believe. So, which version of pointnet2_util do you use? I didn't see pointnet in the install instruction.

Thanks

sayands commented 4 months ago

Glad to know it works and thanks for the catch, I have updated the readme. Please follow PointCloudTransformer repository for installing pointnet2_ops_lib.