vllm_gaudi.extension.scales
¶
EXP_BIAS_SETS
module-attribute
¶
EXP_BIAS_SETS = {
("GAUDI2", torch.float8_e4m3fn): [3, 7, 11, 15],
("GAUDI2", torch.float8_e5m2): [15],
("GAUDI3", torch.float8_e4m3fn): range(0, 63),
("GAUDI3", torch.float8_e5m2): range(0, 63),
}
EXP_WIDTH
module-attribute
¶
FP8_143_SCALES
module-attribute
¶
FP8_143_SCALES = {
device: (
get_fp8_hw_alligned_scales(
torch.float8_e4m3fn, device
)
)
for device in (DEVICES_SCALE_FACTORS.keys())
}
FP8_143_SCALES_TRAITS
module-attribute
¶
FP8_143_SCALES_TRAITS = {
device: (
min(FP8_143_SCALES[device]),
max(FP8_143_SCALES[device]),
DEVICES_SCALE_FACTORS[device],
)
for device in (DEVICES_SCALE_FACTORS.keys())
}
MAX_RANGE
module-attribute
¶
MAX_RANGE = {
torch.float32: torch.finfo(torch.float32).max,
torch.bfloat16: torch.finfo(torch.bfloat16).max,
torch.float8_e4m3fn: torch.finfo(
torch.float8_e4m3fn
).max,
torch.float8_e5m2: torch.finfo(torch.float8_e5m2).max,
}