Returns the quotient of `self` and `other` rounded down. Dimensions are divided as follows: ```python tf.compat.v1.Dimension(m) // tf.compat.v1.Dimension(n) == tf.compat.v1.Dimension(m // n) tf.compat.v1.Dimension(m) // tf.compat.v1.Dimension(None) # equiv. to tf
(self, other)
| 446 | return self * other |
| 447 | |
| 448 | def __floordiv__(self, other): |
| 449 | """Returns the quotient of `self` and `other` rounded down. |
| 450 | |
| 451 | Dimensions are divided as follows: |
| 452 | |
| 453 | ```python |
| 454 | tf.compat.v1.Dimension(m) // tf.compat.v1.Dimension(n) == |
| 455 | tf.compat.v1.Dimension(m // n) |
| 456 | tf.compat.v1.Dimension(m) // tf.compat.v1.Dimension(None) # equiv. to |
| 457 | tf.compat.v1.Dimension(None) |
| 458 | tf.compat.v1.Dimension(None) // tf.compat.v1.Dimension(n) # equiv. to |
| 459 | tf.compat.v1.Dimension(None) |
| 460 | tf.compat.v1.Dimension(None) // tf.compat.v1.Dimension(None) # equiv. to |
| 461 | tf.compat.v1.Dimension(None) |
| 462 | ``` |
| 463 | |
| 464 | Args: |
| 465 | other: Another Dimension, or a value accepted by `as_dimension`. |
| 466 | |
| 467 | Returns: |
| 468 | A `Dimension` whose value is the integer quotient of `self` and `other`. |
| 469 | """ |
| 470 | try: |
| 471 | other = as_dimension(other) |
| 472 | except (TypeError, ValueError): |
| 473 | return NotImplemented |
| 474 | if self._value is None or other.value is None: |
| 475 | return Dimension(None) |
| 476 | else: |
| 477 | return Dimension(self._value // other.value) |
| 478 | |
| 479 | def __rfloordiv__(self, other): |
| 480 | """Returns the quotient of `other` and `self` rounded down. |
nothing calls this directly
no test coverage detected