Coder Social home page Coder Social logo

Comments (14)

fitsumreda avatar fitsumreda commented on July 29, 2024

Remove the 'clean' from validation_dataset_root.
It will be added by mpisintelclean dataloader

from flownet2-pytorch.

kimj09 avatar kimj09 commented on July 29, 2024

Thanks for your reply.
When I remove the 'clean' from validation_dataset_root,
I get this error saying,

main.py: error: argument insta--schedule_lr_frequency: invalid int value: 'FlyingChairs'

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

To help debugging this, Can you post the complete command and stdouts here?

from flownet2-pytorch.

kimj09 avatar kimj09 commented on July 29, 2024

This is my input :

python main.py --batch_size 8 --model FlowNet2C --optimizer=Adam --optimizer_lr=1e-4 --loss=MultiScale --loss_norm=L1
--loss_numScales=5 --loss_startScale=4 --optimizer_lr=1e-4 --crop_size 384 512
--training_dataset FlyingChairs --training_dataset_root /home/projects/flownet2-pytorch/FlyingChairs/FlyingChairs_release/data
--validation_dataset MpiSintelClean --validation_dataset_root /home/projects/flownet2-pytorch/MPI-Sintel-complete/training

the the output comes out as :

usage: main.py [-h] [--start_epoch START_EPOCH] [--total_epochs TOTAL_EPOCHS]
[--batch_size BATCH_SIZE] [--train_n_batches TRAIN_N_BATCHES]
[--crop_size CROP_SIZE [CROP_SIZE ...]]
[--gradient_clip GRADIENT_CLIP]
[--schedule_lr_fraction SCHEDULE_LR_FRACTION]
[--rgb_max RGB_MAX] [--number_workers NUMBER_WORKERS]
[--number_gpus NUMBER_GPUS] [--no_cuda] [--seed SEED]
[--name NAME] [--save SAVE]
[--validation_frequency VALIDATION_FREQUENCY]
[--validation_n_batches VALIDATION_N_BATCHES]
[--render_validation] [--inference]
[--inference_size INFERENCE_SIZE [INFERENCE_SIZE ...]]
[--inference_batch_size INFERENCE_BATCH_SIZE]
[--inference_n_batches INFERENCE_N_BATCHES] [--save_flow]
[--resume PATH] [--log_frequency LOG_FREQUENCY]
[--skip_training] [--skip_validation] [--fp16]
[--fp16_scale FP16_SCALE]
[--model {FlowNet2C,tofp32,FlowNet2CS,FlowNet2SD,ChannelNorm,FlowNet2CSS,tofp16,FlowNet2S,FlowNet2,Resample2d}]
insta--schedule_lr_frequency
main.py: error: argument insta--schedule_lr_frequency: invalid int value: 'FlyingChairs'

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

i tested your command, it works fine for me.
I'm not able to reproduce your errors.
i'd suggest to pull again to make sure you've the latest updates.

from flownet2-pytorch.

kimj09 avatar kimj09 commented on July 29, 2024

These are the steps I have made to run the code. Please tell me if I have missed any steps

get flownet2-pytorch source

git clone https://github.com/NVIDIA/flownet2-pytorch.git
cd flownet2-pytorch

install custom layers

bash install.sh

Build and launch docker image

bash launch_docker.sh

Example on MPISintel Final and Clean, with L1Loss on FlowNet2 model

python main.py --batch_size 8 --model FlowNet2 --loss=L1Loss --optimizer=Adam --optimizer_lr=1e-4
--training_dataset MpiSintelFinal --training_dataset_root home/projects/flownet2-pytorch/FlyingChairs/FlyingChairs_release/data
--validation_dataset MpiSintelClean --validation_dataset_root /home/projects/flownet2-pytorch/MPI-Sintel-complete/training

Are there any steps I am missing?

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

That looks correct.
You may need to verify the data for flyingchair and mpisintel are indeed accessible inside the launched docker container.
I'd also make sure the python command is submitted as a single line command, they may be broken into several lines, and interpretted as several commands by bash or shell

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

A correction, there is somthing off about your steps.
the bash install.sh must be done inside the container, i.e. after bash launch_docker.sh

from flownet2-pytorch.

kimj09 avatar kimj09 commented on July 29, 2024

Thanks for your reply. I reinstalled and followed your direction as you pointed out but unfortunately, it keeps showing me
main.py: error: argument insta--schedule_lr_frequency: invalid int value: 'FlyingChairs'

I would have to figure it out what is wrong with mine.

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

In python you can use, os.path.exists

from flownet2-pytorch.

msieb1 avatar msieb1 commented on July 29, 2024

I am getting the same error.

"
File "/../libs/flownet2-pytorch/datasets.py", line 66, in __init__
self.frame_size = frame_utils.read_gen(self.image_list[0][0]).shape
IndexError: list index out of range
"

I am running

python main.py --inference --model FlowNet2 --save_flow --inference_dataset MpiSintelClean
--inference_dataset_root ../MPI-Sintel-testing/test/

from flownet2-pytorch.

borkarra avatar borkarra commented on July 29, 2024

I am also getting this error. Does the MPI-Sintel dataset directory structure need to be modified in anyway after downloading? It seems like that would be the most likely source of this issue.

from flownet2-pytorch.

TusharNimbhorkar avatar TusharNimbhorkar commented on July 29, 2024

@msieb1 I think you forgot to put the checkpoint/weights. (--resume /path/to/checkpoints)

@borkarra I don't think Sintel directory needs to be modified.

For inference
--inference_dataset_root should contain a folder name clean

Hope it works

from flownet2-pytorch.

fitsumreda avatar fitsumreda commented on July 29, 2024

image

this is the folder structure of the opensource MPI-Sintel dataset that the code expects
e.g. --inference_dataset_root ./flow/training

from flownet2-pytorch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.