MCPcopy Create free account
hub / github.com/OpenDriveLab/ReSim / divide

Function divide

SwissArmyTransformer/sat/mpu/utils.py:27–31  ·  view source on GitHub ↗

Ensure that numerator is divisible by the denominator and return the division value.

(numerator, denominator)

Source from the content-addressed store, hash-verified

25
26
27def divide(numerator, denominator):
28 """Ensure that numerator is divisible by the denominator and return
29 the division value."""
30 ensure_divisibility(numerator, denominator)
31 return numerator // denominator
32
33
34def split_tensor_along_last_dim(tensor, num_partitions,

Callers 15

__init__Method · 0.90
repartitionMethod · 0.90
__init__Method · 0.90
repartitionMethod · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.85
repartitionMethod · 0.85
partitionMethod · 0.85
__init__Method · 0.85
repartitionMethod · 0.85

Calls 1

ensure_divisibilityFunction · 0.85

Tested by

no test coverage detected