MCPcopy Create free account

hub / github.com/VizuaraAILabs/truly-open-gpt-oss / functions

Functions69 in github.com/VizuaraAILabs/truly-open-gpt-oss

↓ 19 callersFunctionrank0_print
(*args, **kwargs)
train.py:76
↓ 13 callersFunctionis_dist
()
train.py:73
↓ 9 callersFunctionis_dist
()
export_to_safetensors.py:50
↓ 8 callersMethodreset_parameters
(self)
model.py:335
↓ 7 callersFunctionis_dist
()
sample.py:55
↓ 5 callersMethod__init__
(self, cfg: ModelConfig)
model.py:310
↓ 3 callersMethodget_batch
(self)
train.py:90
↓ 3 callersFunctionrank0_print
(*args, **kwargs)
sample.py:58
↓ 3 callersFunctionsharded_ckpt_path
(prefix: str, rank: int)
train.py:287
↓ 3 callersFunctionsharded_path
(in_dir, prefix, rank)
export_to_safetensors.py:57
↓ 2 callersMethod_kv_expand
(self, kv: torch.Tensor)
model.py:230
↓ 2 callersFunction_massage_cfg_for_model
Turn nested dicts into expected types (e.g., rope_scaling dict -> RopeScalingConfig).
export_to_safetensors.py:79
↓ 2 callersMethodapply
(self, x: torch.Tensor, positions: torch.Tensor)
model.py:169
↓ 2 callersFunctionencode_corpus
(texts: List[str], enc)
prepare.py:48
↓ 2 callersFunctiongpt_oss_20b_config
()
model.py:510
↓ 2 callersFunctionrank0_print
(*a, **k)
export_to_safetensors.py:53
↓ 2 callersFunctionsave_ckpt_sharded
(prefix: str, iter_n: int, best_v: float)
train.py:290
↓ 2 callersFunctionsharded_path
(out_dir, prefix, rank)
sample.py:76
↓ 2 callersFunctionwrite_memmap
(path: str, tokens: np.ndarray)
prepare.py:57
↓ 1 callersMethod_build_local_mask
(T: int, device, win: int)
model.py:239
↓ 1 callersFunction_massage_cfg_for_model
Normalize nested fields so model.py (RotaryEmbedding etc.) gets attribute-like objects.
sample.py:109
↓ 1 callersMethod_update_cache
(self, seqlen: int, device, dtype)
model.py:153
↓ 1 callersFunctionapply_repetition_penalty
(logits, generated_ids, penalty)
sample.py:98
↓ 1 callersMethodbuild_causal_mask
(T: int, device, dtype=torch.bool)
model.py:451
↓ 1 callersFunctionbuild_config
(name: str)
train.py:109
↓ 1 callersFunctionbuild_model_from_cfg
(cfg_dict: dict, device: str, args)
export_to_safetensors.py:94
↓ 1 callersFunctionbuild_model_from_config
(cfg: dict, device: str, args)
sample.py:121
↓ 1 callersFunctionevaluate
()
train.py:378
↓ 1 callersFunctiongenerate_collective
All ranks participate in forward passes (FSDP requirement). Rank 0 samples next token id and broadcasts to all ranks so sequences stay in syn
sample.py:165
↓ 1 callersFunctionget_args
()
train.py:32
↓ 1 callersFunctionget_args
()
sample.py:27
↓ 1 callersFunctionget_args
()
export_to_safetensors.py:37
↓ 1 callersFunctionget_lr
(it: int)
train.py:369
↓ 1 callersFunctionget_o200k_harmony_tokenizer
Try to get 'o200k_harmony'. If not present, fall back to 'o200k_base' and warn, but write the actual tokenizer name into meta.json so the
prepare.py:24
↓ 1 callersFunctioninit_dist
()
sample.py:62
↓ 1 callersFunctionload_ckpt_full
(single_path: str)
train.py:335
↓ 1 callersFunctionload_ckpt_sharded
(prefix: str)
train.py:316
↓ 1 callersFunctionload_tokenizer
(meta_path: str)
train.py:97
↓ 1 callersFunctionmain
()
train.py:160
↓ 1 callersFunctionmain
()
sample.py:232
↓ 1 callersFunctionmain
()
prepare.py:64
↓ 1 callersFunctionmain
()
export_to_safetensors.py:170
↓ 1 callersFunctionparse_size
(s: str)
export_to_safetensors.py:61
↓ 1 callersMethodreset_parameters
(self)
model.py:142
↓ 1 callersMethodreset_parameters
(self)
model.py:216
↓ 1 callersMethodreset_parameters
(self)
model.py:456
↓ 1 callersFunctionsample_text_collective
All ranks enter (so FSDP collectives don't deadlock). Only rank 0 returns the decoded text; others return "".
train.py:120
↓ 1 callersFunctionshard_state_dict_for_hf
Split a full weights dict into shards <= max_shard_bytes. Returns: shards: { filename -> {param_name: tensor, ...} } index: {"me
export_to_safetensors.py:127
↓ 1 callersFunctionswiglu
(x: torch.Tensor, clip: Optional[float] = None)
model.py:114
↓ 1 callersFunctiontop_k_filter
(logits, k)
sample.py:79
↓ 1 callersFunctiontop_p_filter
(logits, top_p)
sample.py:85
Method__init__
(self, data_dir: str, split: str, block_size: int, batch_size: int, device: str, seed: int)
train.py:81
Method__init__
(self, dim: int, eps: float = 1e-5)
model.py:98
Method__init__
(self, head_dim: int, rope_theta: float, scale_cfg: RopeScalingConfig)
model.py:127
Method__init__
(self, cfg: ModelConfig)
model.py:184
Method__init__
(self, cfg: ModelConfig)
model.py:400
Method__init__
(self, cfg: ModelConfig)
model.py:430
Method__post_init__
(self)
model.py:77
Function_fsdp_param_init_fn
(m: torch.nn.Module)
train.py:211
Function_param_init_fn
(m: torch.nn.Module)
sample.py:148
Function_param_init_fn
(m: torch.nn.Module)
export_to_safetensors.py:111
Methodforward
(self, x: torch.Tensor)
model.py:103
Methodforward
( self, x: torch.Tensor, # (B,T,H) positions: torch.Tensor, # (B,T
model.py:246
Methodforward
(self, x: torch.Tensor)
model.py:345
Methodforward
( self, x: torch.Tensor, positions: torch.Tensor, causal_mask: torch.Tensor,
model.py:414
Methodforward
( self, input_ids: torch.Tensor, # (B,T) labels: Optional[torch.Tenso
model.py:469
Methodgroup_size
(self)
model.py:89
Methodreset_parameters
(self)
model.py:109
Methodreset_parameters
(self)
model.py:407