6f8f7608d6d603b49bef0249f169ef413d6e7371,src/codebase/tasks.py,Task,_evaluate,#Task#Any#Any#,38
Before Change
"""
Method for scoring model predictions against targets
"""
raise NotImplementedError
def validate(self, model):
"""
Get validation scores for model
After Change
for ins, targs in data:
outs = model(ins, self.pred_layer, self.pair_input)
_, preds = outs.max(1)
pdb.set_trace()
score += torch.sum(torch.eq(preds.long(), targs)).data[0]
return score / len(data)
def validate(self, model):
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 3
Instances Project Name: jsalt18-sentence-repl/jiant
Commit Name: 6f8f7608d6d603b49bef0249f169ef413d6e7371
Time: 2017-11-07
Author: wang.alex.c@gmail.com
File Name: src/codebase/tasks.py
Class Name: Task
Method Name: _evaluate
Project Name: NifTK/NiftyNet
Commit Name: f360de0fa4454122d665b9c32f4d5911a4ebec0c
Time: 2017-08-19
Author: wenqi.li@ucl.ac.uk
File Name: niftynet/application/autoencoder_application.py
Class Name: AutoencoderApplication
Method Name: connect_data_and_network
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: 1d4d8b5896cd413add8d37217d46bd63ff1b2d22
Time: 2020-05-20
Author: hesseltuinhof@users.noreply.github.com
File Name: art/defences/preprocessor/jpeg_compression.py
Class Name: JpegCompression
Method Name: __call__
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: 116e41cc7a8748c6b1b781846d14b4ca5ff32fd7
Time: 2020-05-14
Author: hesseltuinhof@users.noreply.github.com
File Name: art/defences/preprocessor/jpeg_compression.py
Class Name: JpegCompression
Method Name: __call__