Description
The data location field is a piece of metadata scoped to an experiment,
so one would expect it to be returned by experiment_metadata
. But it
is not so: data_location
is a separate call. This forces two separate
database queries, which is unnecessary since core_plugin
calls them
consecutively at the unique call site. Thus, it’s more than just a
cleanliness issue.
Suggest migrating by first making ExperimentMetadata
more malleable:
- Make
ExperimentMetadata.__init__
take kwargs only, and provide
default values for all fields/arguments. - Update data providers to always return a non-
None
value.
While this loses the ability to distinguish whether the metadata is
present, we already weren’t able to distinguish between whether
individual fields were present. For instance, TensorBoard.dev
experiments that were created prior to the introduction of experiment
names and descriptions still returned metadata with creation time
but with experiment_name=""
.
Then:
- Add a new
data_location
field with default value""
. - Update data providers to populate the new field, and update
core_plugin
to prefer that field if populated. - Remove the
data_location
method. - Remove dead
data_location
implementations from data providers.