MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / test_config

Method test_config

tensorflow/python/keras/metrics_test.py:797–805  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

795class HingeTest(test.TestCase):
796
797 def test_config(self):
798 hinge_obj = metrics.Hinge(name='hinge', dtype=dtypes.int32)
799 self.assertEqual(hinge_obj.name, 'hinge')
800 self.assertEqual(hinge_obj._dtype, dtypes.int32)
801
802 # Check save and restore config
803 hinge_obj2 = metrics.Hinge.from_config(hinge_obj.get_config())
804 self.assertEqual(hinge_obj2.name, 'hinge')
805 self.assertEqual(hinge_obj2._dtype, dtypes.int32)
806
807 def test_unweighted(self):
808 hinge_obj = metrics.Hinge()

Callers

nothing calls this directly

Calls 2

from_configMethod · 0.45
get_configMethod · 0.45

Tested by

no test coverage detected