RELNOTES: Add the capacity for hparams.parse_values to parse strings involving...
RELNOTES: Add the capacity for hparams.parse_values to parse strings involving assignment to specific list positions (e.g. "arr[1]=abc".) The returned dictionary is identical to the previous version w.r.t. variable assignments, but for position assignments the key will map to a dictionary mapping specified indices to values (e.g. {'arr': {1:'abc'}}). The type_map must have a key corresponding to the variable name, not the index (e.g. type_map={'arr':int}, not type_map={'arr[1]'=int}. NOTE: No longer allows multi-assignment to the same name. (e.g. 'x=10,x=20' will now raise a ValueError, where it would previously ignore the 'x=10'.)
PiperOrigin-RevId: 162940437
Loading
Please sign in to comment