6e5cf676b113af8d70e34224f23bc8eace618856,mloop/nnlearner.py,SingleNeuralNet,fit,#SingleNeuralNet#Any#Any#,120

Before Change


                                               })

        self.log.debug("Fit neural network with total training cost "
                + str(self.tf_session.run(
                        self.loss_func,
                        feed_dict={self.input_placeholder: params,
                                   self.output_placeholder: [[c] for c in costs],
                                   self.regularisation_coefficient_placeholder: self.regularisation_coefficient,
                                   }))
                + ", with unregularized cost "
                + str(self.tf_session.run(
                        self.loss_func,
                        feed_dict={self.input_placeholder: params,

After Change


            (l, ul) = self._loss(params, costs)
            self.log.debug("Fit neural network with total training cost " + str(l)
                    + ", with unregularized cost " + str(ul))
            if l > threshold:
                break
            self.log.debug("Cost decreased by a lot, train again")

    def cross_validation_loss(self, params, costs):
        """
        Returns the loss of the network on a cross validation set.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: michaelhush/M-LOOP
Commit Name: 6e5cf676b113af8d70e34224f23bc8eace618856
Time: 2017-05-02
Author: harry.slatyer@gmail.com
File Name: mloop/nnlearner.py
Class Name: SingleNeuralNet
Method Name: fit


Project Name: catalyst-cooperative/pudl
Commit Name: ead53c9bd3205abfe3fdec30f8e6c8b39ea04329
Time: 2020-11-12
Author: cgosnell@catalyst.coop
File Name: src/pudl/extract/excel.py
Class Name: GenericExtractor
Method Name: load_excel_file


Project Name: catalyst-cooperative/pudl
Commit Name: d22b0ccbccd7c8659c8ec87556a60a8321ccab1c
Time: 2020-11-12
Author: cgosnell@catalyst.coop
File Name: src/pudl/extract/excel.py
Class Name: GenericExtractor
Method Name: load_excel_file


Project Name: deepfakes/faceswap
Commit Name: 286f6b28b3ccccad983b462b9e0279b4cc50ce5a
Time: 2019-07-29
Author: 36920800+torzdf@users.noreply.github.com
File Name: lib/model/backup_restore.py
Class Name: Backup
Method Name: snapshot_models