f26ee72ff530d6d4ef552de13f8fdeeeac0e4a18,dvalib/indexer.py,BaseIndexer,apply,#BaseIndexer#Any#,20

Before Change



    def apply(self,path):
        self.load()
        tensor = self.transform(PIL.Image.open(path).convert("RGB"))
        return self.net(Variable(tensor.unsqueeze_(0))).data.numpy()

    def load_index(self,path):
        temp_index = []

After Change



    def apply(self,path):
        self.load()
        tensor = self.transform(PIL.Image.open(path).convert("RGB")).unsqueeze_(0)
        if torch.cuda.is_available():
            tensor = tensor.cuda()
        return self.net(Variable(tensor)).data.numpy()

    def load_index(self,path):
        temp_index = []
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: AKSHAYUBHAT/DeepVideoAnalytics
Commit Name: f26ee72ff530d6d4ef552de13f8fdeeeac0e4a18
Time: 2017-02-03
Author: AKSHAYUBHAT@GMAIL.COM
File Name: dvalib/indexer.py
Class Name: BaseIndexer
Method Name: apply


Project Name: keras-team/autokeras
Commit Name: c6510936c8dc44cdeb19d674ce89548cc21ae431
Time: 2019-10-05
Author: jhfjhfj1@gmail.com
File Name: autokeras/hypermodel/node.py
Class Name: StructuredDataInput
Method Name: transform


Project Name: keras-team/autokeras
Commit Name: c839a9501f5b7312cdbeef637f8e580bc23cb261
Time: 2018-05-01
Author: jin@tamu.edu
File Name: autokeras/search.py
Class Name: BayesianSearcher
Method Name: search