MCPcopy Create free account
hub / github.com/pytorch/pytorch / testFCwithAxis2

Method testFCwithAxis2

caffe2/python/layers_test.py:326–345  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

324
325
326 def testFCwithAxis2(self):
327 input_dim = 10
328 output_dim = 30
329 max_length = 20
330 input_record = self.new_record(
331 schema.Struct(
332 ('history_sequence', schema.Scalar((np.float32, (max_length,
333 input_dim)))),
334 )
335 )
336 fc_out = self.model.FC(
337 input_record.history_sequence, output_dim,
338 axis=2)
339 self.model.output_schema = fc_out
340 self.assertEqual(
341 schema.Scalar((np.float32, (max_length, output_dim))),
342 fc_out
343 )
344
345 train_init_net, train_net = self.get_training_nets()
346
347 def testFCTransposed(self):
348 input_dim = 10

Callers

nothing calls this directly

Calls 4

new_recordMethod · 0.80
FCMethod · 0.80
get_training_netsMethod · 0.80
assertEqualMethod · 0.45

Tested by

no test coverage detected