1344dee35dbacaaaaabdaf452f0dfe74e3ab50e4,torchsample/modules/example.py,,,#,35

Before Change


s = time.time()
model.fit(torch.from_numpy(x_train[:10000]), 
          torch.from_numpy(y_train[:10000]), 
          val_data=(torch.from_numpy(x_test), torch.from_numpy(y_test)),
          nb_epoch=2, 
          batch_size=128)
e = time.time()

After Change



// evaluation loop
val_loss = model.evaluate(x_test, y_test)
print("Val Loss: " , val_loss)

// prediction and manual evaluation
from torch.autograd import Variable
y_pred = model.predict(x_test)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 2

Instances


Project Name: ncullen93/torchsample
Commit Name: 1344dee35dbacaaaaabdaf452f0dfe74e3ab50e4
Time: 2017-04-19
Author: ncullen@modv-vlan533.0288.apn.wlan.wireless-pennnet.upenn.edu
File Name: torchsample/modules/example.py
Class Name:
Method Name:


Project Name: lcswillems/torch-rl
Commit Name: 2143ec0e8e6a02fade949bf15d9670500ce06234
Time: 2018-04-18
Author: lcswillems@gmail.com
File Name: scripts/enjoy.py
Class Name:
Method Name:


Project Name: geomstats/geomstats
Commit Name: a9b58d07768ec06f8718ec2777f2b0293359f5b4
Time: 2020-04-09
Author: hadizaatiti@gmail.com
File Name: geomstats/learning/frechet_mean.py
Class Name:
Method Name: _ball_gradient_descent