Generalize usage of Metric.from_dict for clarity