hisfog / SfMNeXt-Impl

[AAAI 2024] Official implementation of "SQLdepth: Generalizable Self-Supervised Fine-Structured Monocular Depth Estimation", and more.
MIT License
91 stars 12 forks source link

Trouble with inference #15

Open IsaacGreenMachine opened 1 year ago

IsaacGreenMachine commented 1 year ago

I am trying to run inference on some images using the KITTI (ConvNeXt-L) linked on the README.

the model runs without error, but outputs look like this: 0000000000

I believe something is going wrong since this doesn't match the supposed results.

I read some of this repo's previous issues that had similar images, but didn't find any full configuration setups that fixed the issue.

I am running inference with this command from the README python test_simple_SQL_config.py ./args_files/args_test_simple_kitti_320x1024.txt

Where can I find a combination of:

Thanks!

hisfog commented 1 year ago

For the ConvNeXt model, the args_file is ./conf/cvnXt.txt, and the command should be

python test_simple_SQL_config.py ./conf/cvnXt.txt
IsaacGreenMachine commented 1 year ago

Thanks for the fast response! That worked. Thank you!

lilong-epfl commented 11 months ago

Hi, I have the same issue when I run inference with KITTI(ResNet-50) , the results look like this: 08c4032c0ac9410c9bd6919ae5772306_000002

I am running inference with this command from the README python test_simple_SQL_config.py ./args_files/args_test_simple_kitti_320x1024.txt

with the following contents: --load_weights_folder ./pretrained/KITTI_320x1024_models/ --image_path ./images/ --height 320 --width 1024 --model_dim 32 --patch_size 20 --dim_out 128 --query_nums 128 --min_depth 0.001 --max_depth 80.0 --ext jpg

the weights is download from KITTI (ResNet-50)

Thanks!

hisfog commented 11 months ago

You should set --load_pretrained_weights, and set --load_weights_folder to /path/to/your/model.

lilong-epfl commented 11 months ago

Thank you very much fro your quick replay!

I add the --load_pretrained_model to the config, and set --load_pt_folder to my/model/path, the full config like this: --height 320 --width 1024 --model_dim 32 --patch_size 20 --dim_out 100 --query_nums 128 --min_depth 0.01 --max_depth 80.0 --load_pretrained_model --load_pt_folder ./pretrained/KITTI_320x1024_models/ --image_path ./images/ --ext jpg

But got the following error: log.txt

Any idea? Thanks again!

hisfog commented 11 months ago

Em, set --backbone to resnet_lite should fix this. I will update the README.

lilong-epfl commented 11 months ago

When I add --model_name resnet_320x1024 to the config, it starts to download something from 'rwightman/gen-efficientnet-pytorch', and timed out. I cannot figure out what it download, so I cannot download by hand.

Here is the log: log 2.txt

Best wishes!

hisfog commented 11 months ago

When I add --model_name resnet_320x1024 to the config, it starts to download something from 'rwightman/gen-efficientnet-pytorch', and timed out. I cannot figure out what it download, so I cannot download by hand. Check out this, https://github.com/hisfog/SfMNeXt-Impl/issues/15#issuecomment-1837342744, set --backbone to resnet_lite

nanakoMI commented 4 months ago

--model_type cvnxt_L --model_dim 32 --patch_size 32 --dim_out 64 --query_nums 64 --dec_channels 1024 512 256 128 --min_depth 0.001 --max_depth 80.0 --load_pretrained_model /data1/hanmina/SfMNeXt-Impl-main/ConvNeXt_Large_SQLdepth/encoder.pth --load_pt_folder /data1/hanmina/GAN/GAN_10.7/result/LLVIP/images/val/ --height 320 --width 1024 --image_path /data1/hanmina/GAN/GAN_10.7/result/LLVIP/images/val/ --ext jpg

这样设置是有问题的吗?报错信息是:test_simple_SQL_config.py: error: unrecognized arguments: /data1/hanmina/SfMNeXt-Impl-main/ConvNeXt_Large_SQLdepth/encoder.pth

Moyago commented 4 months ago

When I add --model_name resnet_320x1024 to the config, it starts to download something from 'rwightman/gen-efficientnet-pytorch', and timed out. I cannot figure out what it download, so I cannot download by hand.

Here is the log: log 2.txt

Best wishes!

after add following parameters, this script would be works(commit id: 6a1e997). --dim_out 128 --num_features 256