thartbm / PyVMEC

A Python-based GUI to create and run visuo-motor experiments.
GNU General Public License v3.0
1 stars 3 forks source link

Clean up JSON files #68

Open thartbm opened 6 years ago

thartbm commented 6 years ago

Reach tasks have parameters that are specifically for pause tasks and vice versa, and for some reason the participants are stored in the JSON as well. That stuff should be removed.

For example, when opening an older experiment definition and looking at all the tasks, each time I click on a task, the CLI shows a KeyError: 'pause_instruction' which doesn't make sense as I have no pause tasks in there. Apparently, previously we didn't store instructions for tasks that were not pause tasks, but now we expect them to be in the file.

Additionally, it didn't show the correct minimum and maximum target angle, probably because that KeyError stopped it from moving on.

Maybe, when reading in the JSON, it should be checked and missing keys set to default values and superfluous keys removed. If this has been done once (or more), we show a warning that tells the user that the experiment definition was changed. That way we can still open, inspect and use old experiment definition JSONs.

thartbm commented 5 years ago

There's still stuff in the JSONs that shouldn't be there. For reach tasks, remove all the pause things:

As well as variables that are only necessary in the GUI to restrict definitions:

Or stuff that should only matter at run-time and not be pre-determined:

For pause tasks, remove everything but the pause task definitions.

From the experiment settings, remove all the old (unused) custom stimuli stuff: