Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/zai-org/CodeGeeX
/ functions
Functions
1,098 in github.com/zai-org/CodeGeeX
⨍
Functions
1,098
◇
Types & classes
154
↳
Endpoints
1
Method
get_code
(self)
codegeex/megatron/code_generation_utils.py:628
Method
get_data
Return the data currently in use.
codegeex/megatron/memory.py:114
Function
get_data_parallel_world_size
Return world size for the data parallel group.
codegeex/megatron/mpu/initialize.py:386
Method
get_doc_idx
(self)
codegeex/megatron/data/indexed_dataset.py:547
Function
get_embedding_group
Get the embedding group the caller rank belongs to.
codegeex/megatron/mpu/initialize.py:223
Function
get_forward_backward_func
()
codegeex/megatron/schedules.py:31
Function
get_indexed_dataset_
(data_prefix, data_impl, skip_warmup)
codegeex/megatron/data/dataset_utils.py:429
Function
get_linear_layer
Simple linear layer with weight initialization.
codegeex/megatron/model/utils.py:47
Method
get_loss_scale
(self)
codegeex/megatron/optimizer/optimizer.py:281
Function
get_mem_buff
Get the memory buffer.
codegeex/megatron/memory.py:31
Function
get_model
( backend: str = "megatron", quantized: bool = False, )
codegeex/__init__.py:8
Function
get_model_parallel_group
Get the model parallel group the caller rank belongs to.
codegeex/megatron/mpu/initialize.py:195
Function
get_model_parallel_rank
()
codegeex/megatron/mpu/initialize.py:284
Function
get_model_parallel_world_size
()
codegeex/megatron/mpu/initialize.py:249
Method
get_next_buffer
(self)
codegeex/megatron/memory.py:145
Function
get_op_support_info
get_op_support_info
codegeex/mindspore/scripts/layer_norm_x_backprop_v2.py:36
Function
get_op_support_info
get_op_support_info
codegeex/mindspore/scripts/layer_norm.py:43
Function
get_pipeline_model_parallel_first_rank
()
codegeex/megatron/mpu/initialize.py:353
Function
get_pipeline_model_parallel_last_rank
()
codegeex/megatron/mpu/initialize.py:360
Function
get_pipeline_model_parallel_next_rank
()
codegeex/megatron/mpu/initialize.py:368
Function
get_pipeline_model_parallel_prev_rank
()
codegeex/megatron/mpu/initialize.py:377
Function
get_samples_mapping
Get a list that maps a sample index to a starting sentence index, end sentence index, and length
codegeex/megatron/data/dataset_utils.py:477
Function
get_token_stream
( model, tokenizer, seq_length, out_seq_length, context_tokens,
codegeex/oneflow/inference.py:158
Function
get_token_stream
( model, tokenizer, seq_length, out_seq_length, context_tokens,
codegeex/paddle/inference.py:158
Method
get_word_embedding_weight
(self)
codegeex/mindspore/src/pangu_alpha.py:105
Method
get_word_embedding_weight
(self)
codegeex/mindspore/src/pangu_alpha_fp16_predict.py:101
Function
half_conversion
(val)
codegeex/megatron/model/module.py:134
Function
init_
(tensor)
codegeex/megatron/model/utils.py:25
Function
init_checkpointed_activations_memory_buffer
Initializ the memory buffer for the checkpointed activations.
codegeex/megatron/mpu/random.py:44
Function
initialize_model_parallel
Initialize model data parallel groups. Arguments: tensor_model_parallel_size: number of GPUs used to parallelize model tensor.
codegeex/megatron/mpu/initialize.py:54
Method
initialize_word_embeddings
(self, init_method_normal)
codegeex/megatron/model/module.py:64
Function
inspect_result
( input_dir: str = None, input_file: str = None, output_dir: str = None, pass_
codegeex/benchmark/inspect_result.py:73
Method
inv_scale
(self)
codegeex/megatron/optimizer/grad_scaler.py:35
Method
inv_vocab
Dictionary from vocab id token to text token.
codegeex/megatron/tokenizer/tokenizer.py:138
Method
inv_vocab
(self)
codegeex/megatron/tokenizer/tokenizer.py:203
Method
inv_vocab
(self)
codegeex/megatron/tokenizer/tokenizer.py:249
Function
is_pipeline_first_stage
Return True if in the first pipeline model-parallel stage, False otherwise.
codegeex/megatron/mpu/initialize.py:299
Function
is_pipeline_last_stage
Return True if in the last pipeline model-parallel stage, False otherwise.
codegeex/megatron/mpu/initialize.py:310
Function
is_unitialized
Useful for code segments that may be accessed with or without mpu initialization
codegeex/megatron/mpu/initialize.py:49
Function
layer_norm
layernorm operator interface implementation calculating: x, gamma, beta mean = np.mean(x, reduce_axis, keepdims=True) varian
codegeex/mindspore/scripts/layer_norm.py:726
Function
layer_norm_x_backprop_v2
algorithm: layernorm_grad calculating: gradient of layernorm compute partial derivation of x, gamma and beta pd_xl
codegeex/mindspore/scripts/layer_norm_x_backprop_v2.py:1027
Function
load_biencoder_checkpoint
selectively load retrieval models for indexing/retrieving from saved checkpoints
codegeex/megatron/checkpointing.py:508
Function
load_deepspeed_state
(model)
codegeex/megatron/checkpointing.py:282
Method
load_embedding_from_ckpt
r"""load the weights from the checkpoint
codegeex/mindspore/src/pangu_alpha.py:427
Method
load_embedding_from_ckpt
r"""load the weights from the checkpoint
codegeex/mindspore/src/pangu_alpha_fp16_predict.py:430
Method
load_param
(path)
codegeex/mindspore/src/pangu_alpha.py:430
Method
load_param
(path)
codegeex/mindspore/src/pangu_alpha_fp16_predict.py:433
Method
load_state_dict
Customized load.
codegeex/torch/codegeex_model.py:803
Method
load_state_dict
Customized load.
codegeex/torch/codegeex_model.py:912
Method
load_state_dict
Customized load.
codegeex/torch/codegeex_model.py:1006
Method
load_state_dict
(self, state_dict, strict=True)
codegeex/megatron/model/distributed.py:76
Method
load_state_dict
Customized load.
codegeex/megatron/model/language_model.py:406
Method
load_state_dict
Customized load.
codegeex/megatron/model/language_model.py:593
Method
load_state_dict
(self, state_dict, strict=True)
codegeex/megatron/model/module.py:198
Method
load_state_dict
(self, state_dict)
codegeex/megatron/optimizer/optimizer.py:120
Method
load_state_dict
(self, state_dict)
codegeex/megatron/optimizer/optimizer.py:416
Method
load_state_dict
(self, state_dict)
codegeex/megatron/optimizer/grad_scaler.py:47
Method
load_state_dict
(self, state_dict)
codegeex/megatron/optimizer/grad_scaler.py:58
Method
load_state_dict
(self, state_dict)
codegeex/megatron/optimizer/grad_scaler.py:129
Method
load_state_dict
Customized load.
codegeex/oneflow/codegeex_model.py:895
Method
load_state_dict
Customized load.
codegeex/oneflow/codegeex_model.py:1003
Method
load_state_dict
Customized load.
codegeex/oneflow/codegeex_model.py:1097
Function
loss_func
(loss_mask, output_tensor)
codegeex/megatron/tools/pretrain_codegeex.py:152
Function
lru_cache
()
codegeex/megatron/tokenizer/gpt2_tokenization.py:33
Function
main
Main program.
codegeex/benchmark/humaneval-x/generate_humaneval_x.py:202
Function
main
Main program.
codegeex/benchmark/humaneval-x/translate_humaneval_x.py:228
Function
main
( tokenizer_path: str, dataset_path: Union[str, List[str]], output_prefix: str, language: str
codegeex/data/process_pretrain_dataset.py:81
Method
main
(String[] args)
api/codegeex-api-example-java/src/main/java/cn/aminer/codegeex/example/CodeGenerationExample.java:22
Function
make_builder
(out_file, impl, vocab_size=None)
codegeex/megatron/data/indexed_dataset.py:55
Function
make_dataset
(path, impl, skip_warmup=False)
codegeex/megatron/data/indexed_dataset.py:64
Method
mask
(self)
codegeex/megatron/tokenizer/tokenizer.py:176
Method
merge_file_
(self, another_file)
codegeex/megatron/data/indexed_dataset.py:315
Method
merge_file_
(self, another_file)
codegeex/megatron/data/indexed_dataset.py:579
Function
model_parallel_cuda_manual_seed
Initialize model parallel cuda seed. This function should be called after the model parallel is initialized. Also, no torch.cuda.manual_seed
codegeex/megatron/mpu/random.py:220
Function
model_parallel_is_initialized
Check if model and data parallel groups are initialized.
codegeex/megatron/mpu/initialize.py:184
Function
model_provider
Build the model.
codegeex/megatron/tools/finetune_codegeex.py:19
Function
model_provider
Build the model.
codegeex/megatron/tools/pretrain_codegeex.py:20
Function
model_provider
Build the model.
tests/test_inference_megatron.py:26
Method
num_tokens
(self, index)
codegeex/megatron/data/indexed_dataset.py:216
Method
numel_in_use
Return number of elements in use.
codegeex/megatron/memory.py:86
Function
op_select_format
function of selecting dynamic format Parameters ---------- input_dy : dict shape and dtype of input dy, only support float16
codegeex/mindspore/scripts/layer_norm_x_backprop_v2.py:100
Function
op_select_format
select format dynamically
codegeex/mindspore/scripts/layer_norm.py:121
Function
openai_gelu
(x)
codegeex/megatron/model/utils.py:69
Function
pad_and_convert_to_numpy
Pad sequences and convert them to numpy.
codegeex/megatron/data/dataset_utils.py:396
Method
param_hook
(*unused)
codegeex/megatron/model/distributed.py:166
Function
predict
( prompt, lang, seed, out_seq_length, temperature, top_k,
deployment/server_gradio.py:108
Method
prefetch
(self, indices)
codegeex/megatron/data/indexed_dataset.py:243
Method
print_average_usage
Print memory usage average over time. We would like this value to be as high as possible.
codegeex/megatron/memory.py:121
Function
print_params_min_max_norm
Print min, max, and norm of all parameters.
codegeex/megatron/utils.py:108
Method
process_sample_
(self, sample)
codegeex/data/processor.py:75
Method
process_sample_
(self, sample)
codegeex/data/processor.py:152
Method
readable
Returns True if the IO object can be read.
codegeex/benchmark/execution.py:453
Function
rebuild_tokenizer
(args)
codegeex/megatron/global_vars.py:125
Function
recv_backward
Receive tensor from next rank in pipeline (backward receive).
codegeex/megatron/p2p_communication.py:168
Function
recv_forward
Receive tensor from previous rank in pipeline (forward receive).
codegeex/megatron/p2p_communication.py:150
Method
reload_model_params
Refreshes any internal state from the current model parameters. Call whenever the parameters are changed outside of the optimizer. For
codegeex/megatron/optimizer/optimizer.py:107
Method
reload_model_params
(self)
codegeex/megatron/optimizer/optimizer.py:357
Method
report
(self)
codegeex/data/processor.py:79
Method
report
(self)
codegeex/data/processor.py:156
Method
reset
Reset the buffer start index to the beginning of the buffer.
codegeex/megatron/memory.py:78
← previous
next →
901–1,000 of 1,098, ranked by callers