MCPcopy Create free account
hub / github.com/THUDM/GLM / ensure_divisibility

Function ensure_divisibility

mpu/utils.py:20–23  ·  view source on GitHub ↗

Ensure that numerator is divisible by the denominator.

(numerator, denominator)

Source from the content-addressed store, hash-verified

18
19
20def ensure_divisibility(numerator, denominator):
21 """Ensure that numerator is divisible by the denominator."""
22 assert numerator % denominator == 0, '{} is not divisible by {}'.format(
23 numerator, denominator)
24
25
26def divide(numerator, denominator):

Callers 2

divideFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected