MCPcopy
hub / github.com/openai/gpt-oss / write_padding

Function write_padding

gpt_oss/metal/scripts/create-local-model.py:136–141  ·  view source on GitHub ↗
(out_file, alignment_multiple=16384)

Source from the content-addressed store, hash-verified

134
135
136def write_padding(out_file, alignment_multiple=16384):
137 offset = out_file.tell()
138 alignment_size = -offset % alignment_multiple
139 if alignment_size != 0:
140 alignment = bytes(alignment_size)
141 out_file.write(alignment)
142
143
144def write_embedding_weight(out_file, weight):

Callers 5

write_embedding_weightFunction · 0.85
write_rmsnorm_gainFunction · 0.85
write_attn_sinkFunction · 0.85
write_linear_weightFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected