ba28f13e3c6bbeb8521feef63af72557ac08781b,opennmt/utils/checkpoint.py,,_restore_v1_checkpoint,#Any#Any#Any#,189

Before Change


      del v1_structure[_V1_OPTIM_SCOPE]
      v1_structure = _merge_optimizer_slots(v1_structure, slots)
  mapping = model.map_v1_weights(v1_structure)
  missing_mapping = set(model.variables).difference(set(six.iterkeys(mapping)))
  if missing_mapping:
    raise ValueError("The following variables were not mapped: %s" % (
        ", ".join(var.name for var in missing_mapping)))
  // Assign each variable and possibly the optimizer slots.

After Change


      v1_structure = _merge_optimizer_slots(v1_structure, slots)
  mapping = model.map_v1_weights(v1_structure)
  existing_variables = set(variable.experimental_ref() for variable in model.variables)
  mapped_variables = set(variable.experimental_ref() for variable, _ in mapping)
  missing_mapping = existing_variables.difference(mapped_variables)
  if missing_mapping:
    raise ValueError("The following variables were not mapped: %s" % (
        ", ".join(var.name for var in missing_mapping)))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: OpenNMT/OpenNMT-tf
Commit Name: ba28f13e3c6bbeb8521feef63af72557ac08781b
Time: 2019-08-26
Author: guillaume.klein@systrangroup.com
File Name: opennmt/utils/checkpoint.py
Class Name:
Method Name: _restore_v1_checkpoint


Project Name: catalyst-cooperative/pudl
Commit Name: 7135f4e1e3d0ca80a65aaaf8dbfd9ce159bf80be
Time: 2020-03-17
Author: rousik@gmail.com
File Name: src/pudl/extract/excel.py
Class Name: GenericExtractor
Method Name: extract


Project Name: pantsbuild/pants
Commit Name: 0dd24234c4f20a27540e1b02bfff1c21cdeda358
Time: 2016-12-07
Author: ndh@baroquebobcat.com
File Name: src/python/pants/engine/rules.py
Class Name: GraphMaker
Method Name: full_graph