hucvl / craft

CRAFT: A Benchmark for Causal Reasoning About Forces and inTeractions
MIT License
13 stars 0 forks source link

controller.json in the data generation folder #5

Open thaolmk54 opened 2 years ago

thaolmk54 commented 2 years ago

Hi there,

Thank you for the interesting work. I am wondering if the controller.json file in the data generation folder is missing? I would appreciate if you can provide a bit more details on how to run the simulator.

Kind regards, Th-

shamilatesoglu commented 2 years ago

Hi!

Thanks for pointing that out. Will provide better explanations about that.

I can say this, the controller.json files are automatically generated by scripts inside question_generation folder and are read by the simulation runner executable built from the project at data_generation folder. All you have to do to generate a dataset is to built this C++ project into a simulation runner executable, and supply its location to the dataset generation config file and run Python scripts in question_generation folder.

Sample dataset generation framework usage can be accessed here. Sample config files for dataset generation can be viewed here. For running a single simulation instance to generate 1 video and its questions (without dataset balancing or other post-processing), refer to here.

If you just want to run simulation runner without the question generation step, sample controller JSON file is like below:

{
    "simulationID": 1,
    "offline": false,
    "outputVideoPath": "output.mpg",
    "outputJSONPath": "output.json",
    "width": 256,
    "height": 256,
    "inputScenePath":  "",  // This is for replaying the same scene by using its output
    "stepCount": 600
}

Which then, you would run like this:

$ ./Testbed controller.json

Let us know if you have any questions.

Kind regards, Samil

P.S. I will also provide build instructions for the simulation runner.

thaolmk54 commented 2 years ago

Thank you for your reply.

May I know which FFmpeg have you used? Apparently, the code does not work with the latest version of ffmpeg. Could you please send me a copy of your FFmpeg if possible?

thaolmk54 commented 2 years ago

Also, I still have no luck in building Testbed as I'm facing some missing headers such as Test.h. I'm using Linux. I would appreciate if you can help me identify the problem. Many thanks in advance!

ilkerkesen commented 2 years ago

@shamilatesoglu could you please take a look at this again? I ran into the same problem also as well, where I couldn't simply build the project due to lack of the Test.h file.

shamilatesoglu commented 2 years ago

Hi again, it was on my mind, but I was really busy these days. I will look into it as soon as possible.