Closed bjuergens closed 3 years ago
i am very unsatisfied by the name get_individual_slices
. Does someone have a better idea for what this function should be called? (edit: i have changed it to get_free_parameter_metadata
, but I am still not satisfied)
I am not sure if the added complexity is worth the benefit of this PR.
I have simplified the generation of the output. Now it doesn't have custom code to generate the output, and instead writes the dict to the log.
Now the output looks like this:
INFO: Individual size for this experiment: 2337
INFO: consumption of free parameter: {'CNN': {'conv1': 375, 'conv2': 625}, 'CTRNN': {'V': 1215, 'W': 60, 'T': 60, 'optimize_state_boundaries': 2}, '_cnn_output_space': Box(-1.0, 1.0, (8, 8, 5), float32)}
before this change it looked like this:
INFO: Individual size for this experiment: 2337
INFO: CNN: conv1: 375, conv2: 625, CTRNN: V: 1215, W: 60, T: 60, optimize_state_boundaries: 2, _cnn_output_space: Box(-1.0, 1.0, (8, 8, 5), float32),
Is this still readable?
Is this still readable?
Yes for me its good, the added code which would be needed for the "prettier" log is not justified imho. I'll review now
adds a info-message to the begging of the experiments, which tells the user how the free parameters are used in a brain.
example (last line):
For LNN it looks like this
For CNN+CTRNN it looks like this
For code that calls
get_individual_size
nothing changes.For Classes that inherit from
IBrain
, they leaveget_individual_size
untouched and instead have to implementget_free_parameter_metadata
, which is basically the same asget_individual_size
used to be, except that the return value is now adict
instead of anint