0db94786a7a463fed49825811fac903f1f1fc3c8,python/caffe/classifier.py,Classifier,predict,#Classifier#,49
Before Change
inputs = inputs[:, crop[0]:crop[2], crop[1]:crop[3], :]
// Classify
caffe_in = np.asarray([self.preprocess(self.inputs[0], in_)
for in_ in inputs])
out = self.forward_all(**{self.inputs[0]: caffe_in})
predictions = out[self.outputs[0]].squeeze(axis=(2,3))
// For oversampling, average predictions across crops.
After Change
for N images and C classes.
// Scale to standardize input dimensions.
input_ = np.zeros((len(inputs),
self.image_dims[0], self.image_dims[1], inputs[0].shape[2]) ,
dtype=np.float32)
for ix, in_ in enumerate(inputs):
input_[ix] = caffe.io.resize_image(in_, self.image_dims)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: BVLC/caffe
Commit Name: 0db94786a7a463fed49825811fac903f1f1fc3c8
Time: 2014-08-05
Author: shelhamer@imaginarynumber.net
File Name: python/caffe/classifier.py
Class Name: Classifier
Method Name: predict
Project Name: librosa/librosa
Commit Name: 85e89ae2495998ae69ab34abf5400164f909a548
Time: 2013-12-21
Author: brm2132@columbia.edu
File Name: librosa/core.py
Class Name:
Method Name: cqt
Project Name: BVLC/caffe
Commit Name: 0db94786a7a463fed49825811fac903f1f1fc3c8
Time: 2014-08-05
Author: shelhamer@imaginarynumber.net
File Name: python/caffe/detector.py
Class Name: Detector
Method Name: detect_windows