in common/memory.py [0:0]
def _base_unit_multiple(self, unit: MemoryUnit) -> int:
if unit == MemoryUnit.B:
return 1
elif unit == MemoryUnit.KB:
return 1024
elif unit == MemoryUnit.MB:
return 1024 ** 2
elif unit == MemoryUnit.GB:
return 1024 ** 3
elif unit == MemoryUnit.TB:
return 1024 ** 4
else:
raise NotImplementedError("Programmer failed to add a enum option.")