1d936f7ff3ab938d2712870f9f36d59c40df8f00,catalyst/rl/core/trainer.py,TrainerSpec,_run_loader,#TrainerSpec#Any#,150

Before Change


            metrics.update(**metrics_)

            for key, value in metrics.items():
                if isinstance(value, (float, int)):
                    self.logger.add_scalar(key, value, self.update_step)

        elapsed_time = time.time() - start_time
        elapsed_num_updates = len(loader) * loader.batch_size
        self.num_updates += elapsed_num_updates
        fps = elapsed_num_updates / elapsed_time

After Change



            metrics = dict(
                (key, value)
                for key, value in metrics.items()
                if isinstance(value, (float, int))
            )

            for key, value in metrics.items():
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: catalyst-team/catalyst
Commit Name: 1d936f7ff3ab938d2712870f9f36d59c40df8f00
Time: 2019-08-30
Author: scitator@gmail.com
File Name: catalyst/rl/core/trainer.py
Class Name: TrainerSpec
Method Name: _run_loader


Project Name: microsoft/nni
Commit Name: 10d7ece1c34c5533262a54d20d974a3d04f0b7ce
Time: 2020-09-15
Author: 40699903+liuzhe-lz@users.noreply.github.com
File Name: src/sdk/pynni/nni/compression/tensorflow/compressor.py
Class Name:
Method Name: _instrument_model


Project Name: deepmipt/DeepPavlov
Commit Name: 3de066d408d811db29161d90c1c81c43d08f7efc
Time: 2018-11-01
Author: yoptar@gmail.com
File Name: deeppavlov/download.py
Class Name:
Method Name: deep_download