(self)
| 313 | dtype=dtype)) |
| 314 | |
| 315 | def testMultiply(self): |
| 316 | for dtype in self.numeric_types: |
| 317 | self._testBinary( |
| 318 | math_ops.multiply, |
| 319 | np.array([1, 20], dtype=dtype), |
| 320 | np.array([10, 2], dtype=dtype), |
| 321 | expected=np.array([10, 40], dtype=dtype)) |
| 322 | self._testBinary( |
| 323 | math_ops.multiply, |
| 324 | dtype(5), |
| 325 | np.array([1, 20], dtype=dtype), |
| 326 | expected=np.array([5, 100], dtype=dtype)) |
| 327 | self._testBinary( |
| 328 | math_ops.multiply, |
| 329 | np.array([[10], [2]], dtype=dtype), |
| 330 | dtype(7), |
| 331 | expected=np.array([[70], [14]], dtype=dtype)) |
| 332 | |
| 333 | if dtype not in self.int_types: |
| 334 | self._testBinary( |
| 335 | math_ops.multiply, |
| 336 | np.array([1.9131952969218875, 1.596299504298079], dtype=dtype), |
| 337 | np.array([1.1137667913355869, 1.7186636469261405], dtype=dtype), |
| 338 | expected=np.array([2.130853387051026, 2.743501927643327], |
| 339 | dtype=dtype), |
| 340 | rtol=1e-14) |
| 341 | |
| 342 | def testPow(self): |
| 343 | for dtype in self.float_types: |
nothing calls this directly
no test coverage detected