MCPcopy Create free account

hub / github.com/deepspeedai/DeepSpeed / functions

Functions15,468 in github.com/deepspeedai/DeepSpeed

↓ 4 callersMethodinsert_tensor
(self, tensor, swap_path, aligned_numel)
deepspeed/runtime/swap_tensor/utils.py:50
↓ 4 callersMethodis_decoupled
(self)
deepspeed/runtime/checkpoint_engine/checkpoint_engine.py:50
↓ 4 callersMethodis_deepcompile_active
(self)
tests/unit/v1/compile/test_z3_eager_fallback.py:165
↓ 4 callersMethodis_first_stage
True if the configured ``stage_id`` is the first stage in the pipeline.
deepspeed/runtime/pipe/schedule.py:102
↓ 4 callersFunctionis_moe_param_group
(param_group)
deepspeed/moe/utils.py:152
↓ 4 callersMethodis_parameter
(self, parameter)
deepspeed/runtime/swap_tensor/pipelined_optimizer_swapper.py:31
↓ 4 callersFunctionis_release_node
(n: Node)
deepspeed/compile/util.py:454
↓ 4 callersFunctionis_setup
()
deepspeed/compile/custom_ops/sp_dp_registry.py:26
↓ 4 callersMethodis_zenflow_select_boundary
(self)
deepspeed/runtime/zenflow/zenflow_stage_1_and_2.py:159
↓ 4 callersMethodisend
(self, tensor, dst, group=None, tag=0)
deepspeed/comm/torch.py:556
↓ 4 callersFunctionlink_hp_params
(lp_param_list, flat_hp_partition, gradient_dict, off
deepspeed/utils/mixed_precision_linkage.py:11
↓ 4 callersMethodload_moe_state_dict
(checkpoint_path, tag, state_dict,
deepspeed/runtime/engine.py:4298
↓ 4 callersMethodload_universal_checkpoint
(self)
deepspeed/runtime/engine.py:1799
↓ 4 callersFunctionlocal_folding_ranks
(global_rank: int, spec: ParallelFoldingSpec)
deepspeed/module_inject/auto_ep_folding.py:161
↓ 4 callersMethodlog_level
(self)
deepspeed/runtime/engine.py:1802
↓ 4 callersFunctionmake_cpp_batch_wrapper
deepspeed/inference/v2/kernels/ragged_ops/ragged_helpers/ragged_kernel_helpers.cpp:8
↓ 4 callersFunctionmark_autoep_folding_router_parameter
Tag a router/gate parameter as the *replicated* folded family (AVERAGE). This is the ONLY family marker applied on the live forward path today:
deepspeed/module_inject/auto_ep_folding.py:275
↓ 4 callersFunctionmask_nan_or_inf_with_val_inplace
(input, device=None, val=-1.)
deepspeed/runtime/utils.py:958
↓ 4 callersMethodmax_memory_allocated
(self)
tests/unit/v1/compile/test_graph_profile.py:36
↓ 4 callersFunctionmaybe_loss_for_backward
Check if the value is a loss tensor. Conditions: - The value must be a tensor. - The tensor must have exactly one element. - The tenso
deepspeed/runtime/utils.py:1327
↓ 4 callersFunctionmerge_state
(state_a, state_b, key_list=[])
deepspeed/checkpoint/reshape_utils.py:100
↓ 4 callersMethodmetric
(self)
deepspeed/autotuning/autotuner.py:238
↓ 4 callersFunctionmove_primals_to_head
(graph: Graph)
deepspeed/compile/fx.py:58
↓ 4 callersFunctionmove_to_device
Move tensor on to specified device by changing the storage. Works on individual tensors, and tensors contained/nested in lists, tuples, and d
deepspeed/runtime/utils.py:175
↓ 4 callersFunctionnhwc_bias_add
(activation: torch.Tensor, bias: torch.Tensor, other: Optional[torch.Tenso
deepspeed/ops/transformer/inference/bias_add.py:13
↓ 4 callersFunctionomp_set_num_threads
csrc/includes/reflow_cpu_adam.h:17
↓ 4 callersMethodparallel_for
Split [0, total) into one chunk per thread. Chunk boundaries are rounded up to a multiple of `align` so each slice's AVX/scalar split lines up with th
csrc/adam/cpu_adam_impl.cpp:558
↓ 4 callersFunctionpartition_uniform
(num_items, num_parts)
deepspeed/runtime/utils.py:681
↓ 4 callersFunctionpatch_compiled_func
()
deepspeed/compile/patch_compiled_func.py:81
↓ 4 callersFunctionprint_object
(obj, name, exclude_list=[])
deepspeed/runtime/swap_tensor/utils.py:29
↓ 4 callersFunctionprint_rank_0
(message, debug=False, force=False)
deepspeed/runtime/swap_tensor/partitioned_param_swapper.py:21
↓ 4 callersFunctionprobe_is_compatible
Report whether an op can be built, treating a probe that itself fails as "not compatible". Compatibility is probed for every op when deepspeed is
op_builder/builder.py:117
↓ 4 callersFunctionproduct
(shape: Sequence[int])
deepspeed/checkpoint/affine_geometry.py:18
↓ 4 callersFunctionquantization_test_helper
(pre_quant_type: torch.dtype, num_bits: int)
tests/unit/inference/quantization/test_intX_quantization.py:36
↓ 4 callersMethodquantize
(self, input, q_bits=8, q_mantisa_bits=3,
deepspeed/ops/fp_quantizer/quantize.py:30
↓ 4 callersMethodquantize
(self, input, q_bits=8, q_mantisa_bits=3,
deepspeed/ops/fp_quantizer/quantize.py:67
↓ 4 callersMethodrandom
(self)
tests/unit/v1/compile/test_graph_profile.py:50
↓ 4 callersFunctionrandom_dataset
(total_samples, hidden_dim, device, dtype=preferred_dtype())
tests/unit/simple_model.py:245
↓ 4 callersMethodrecord_forward_graph
Record a grad-bearing forward whose fallback gathers must survive until backward.
deepspeed/compile/z3_eager_fallback.py:163
↓ 4 callersMethodreduce_ready_partitions_and_remove_grads
(self, param)
deepspeed/runtime/zero/stage3.py:2399
↓ 4 callersFunctionreference_geglu_implementation
(input: torch.Tensor, bias: Optional[torch.Tensor] = None,
tests/unit/inference/v2/kernels/core_ops/test_gated_activation.py:22
↓ 4 callersFunctionreference_jsd
(student_logits, teacher_logits, beta)
tests/unit/v1/sequence_parallelism/test_vocab_parallel_ops.py:38
↓ 4 callersFunctionreference_logprobs
(logits, index, ignore_index=-100)
tests/unit/v1/sequence_parallelism/test_vocab_parallel_ops.py:18
↓ 4 callersFunctionreflow_ready_loop
csrc/includes/reflow_ready.h:197
↓ 4 callersFunctionrepack_expert_weights
Repack expert weights from HF format to TorchTitan grouped format. Returns (w1, w2, w3) where: w1: [E_local, ffn_hidden_size, hidden_size
deepspeed/moe/ep_repack.py:46
↓ 4 callersFunctionreplicated_kv_query_widths
Per-rank query-row widths for a replicated-K/V fused qkv layout, or None without n_embd.
deepspeed/module_inject/fusedqkv_utils.py:95
↓ 4 callersMethodreport_ipg_memory_usage
(self, tag, param_elems, dtype=None)
deepspeed/runtime/base_optimizer.py:413
↓ 4 callersMethodreset
csrc/includes/deepcompile.h:171
↓ 4 callersMethodreset_peak_memory_stats
(self, device_index=None)
accelerator/hpu_accelerator.py:144
↓ 4 callersFunctionrotary_pos_embs
(q: torch.Tensor, k: torch.Tensor, seq_descs: List[DSSequenceDescripto
tests/unit/inference/v2/kernels/ragged_ops/test_blocked_rotary_emb.py:29
↓ 4 callersFunctionrotate_half
(x: torch.Tensor)
tests/unit/inference/v2/kernels/ragged_ops/test_blocked_rotary_emb.py:51
↓ 4 callersMethodrun
(self)
deepspeed/autotuning/scheduler.py:158
↓ 4 callersFunctionrun_fragmented_model
(model, config_dict, hidden_dim, dtype, validate_after_bwd, validate_after_step)
tests/unit/runtime/zero/test_zero_tensor_fragment.py:154
↓ 4 callersFunctionrun_frozen_checkpoint_comparison
Shared driver for the frozen-param + checkpoint regression tests. Each iteration checks: (1) backward runs without CheckpointError, (2) grads mat
tests/unit/v1/zero/test_zero_user_backward.py:267
↓ 4 callersMethodrun_test
(self, test_config)
tests/model/Megatron_GPT2/run_perf_baseline.py:84
↓ 4 callersMethodrun_test
(self, test_config)
tests/model/Megatron_GPT2/run_perf_test.py:88
↓ 4 callersFunctionsafe_get_local_fp32_param
Get the local partition of a ZeRO-3 partitioned parameter in fp32 precision. Args: param (``torch.nn.Parameter``): A model parame
deepspeed/utils/tensor_fragment.py:289
↓ 4 callersMethodscaled_global_norm
(self, norm_type=2)
deepspeed/runtime/zero/stage_1_and_2.py:3058
↓ 4 callersMethodschedule_experiments
(self, exp_paths)
deepspeed/autotuning/scheduler.py:58
↓ 4 callersFunctionschedule_transfers
The schedule ``execute_transfers`` would run for a batch, without buffers or communication. ``plans`` are the batch's plans in request order, sin
deepspeed/checkpoint/affine_transfer_executor.py:487
↓ 4 callersFunctionselect_topk
Select the ``topk`` keys of every query row. Runs in blocks of ``block_rows`` query rows so that the float32 logits, ``[block_rows, tokens_kv]``,
deepspeed/models/glm_moe_dsa/kernels/indexer.py:13
↓ 4 callersMethodset_dataiterator
Store an iterator to sample for training data.
deepspeed/runtime/pipe/engine.py:644
↓ 4 callersFunctionset_log_level_from_string
Sets a log level in the passed `logger` and its handlers from string. e.g. "info" => `logging.INFO` Args: log_level_str: one of 'debug',
deepspeed/utils/logging.py:193
↓ 4 callersFunctionshard_attn_out_param
Utility method for sharding an attention output parameter.
deepspeed/inference/v2/model_implementations/sharding/attn_out.py:14
↓ 4 callersFunctionshard_mlp_1_param
Utility method for sharding an MLP 1 parameter. Both biases and weights are supported, as well as for fused weights for MoE. Args:
deepspeed/inference/v2/model_implementations/sharding/mlp.py:14
↓ 4 callersFunctionshard_mlp_2_param
Utility method for sharding an MLP 2 parameter. Args: param (torch.Tensor): The parameter to shard. shard_rank (int): Which
deepspeed/inference/v2/model_implementations/sharding/mlp.py:42
↓ 4 callersFunctionshard_tensor_node
(gm: GraphModule, tensor_node: Node)
deepspeed/compile/util.py:596
↓ 4 callersFunctionshard_value_with_share_qk
( weight, bias, rank, world_size, shard_value, # True -> shard_value;
deepspeed/module_inject/fusedqkv_utils.py:343
↓ 4 callersFunctionshared_exchange
The buffer for this scope and geometry, building it on first ask. Collective on construction, and every rank asks in the same order because t
deepspeed/module_inject/auto_ep_comm.py:108
↓ 4 callersMethodsources
Returns list of source files for your op, relative to root of deepspeed package (i.e., DeepSpeed/deepspeed)
op_builder/builder.py:229
↓ 4 callersMethodstep
(self, last_batch_iteration=None)
deepspeed/runtime/lr_schedules.py:930
↓ 4 callersMethodswap_in
(self, aio_handle, async_op=False)
deepspeed/runtime/swap_tensor/utils.py:163
↓ 4 callersFunctionterminate_aws_instance
(instance: AwsInstance, run_command: Any = _default_command)
ci/torch_latest.py:1561
↓ 4 callersFunctionto_torch_tensor
Convert state_dict of GatheredTensor to torch tensor
deepspeed/utils/zero_to_fp32.py:586
↓ 4 callersFunctiontop2gating
Implements Top2Gating on logits.
deepspeed/moe/sharded_moe.py:322
↓ 4 callersMethodtransform
(self, param: torch.Tensor)
tests/unit/inference/v2/model_implementations/parameters/utils.py:55
↓ 4 callersMethodtransform_qkv_param
Passes a QKV parameter to the underlying implementation for any necessary transformations. Args: param (torch.Te
deepspeed/inference/v2/model_implementations/inference_transformer_base.py:381
↓ 4 callersMethodtranspose_impl
(self, data)
deepspeed/module_inject/containers/base.py:297
↓ 4 callersFunctionunpatch_compiled_func
Restore torch.autograd.Function and discard inputs captured for this compile cycle.
deepspeed/compile/patch_compiled_func.py:101
↓ 4 callersMethodupdate_records
(self, space_name, exp, metric_val, num_exps)
deepspeed/autotuning/autotuner.py:709
↓ 4 callersMethodupdate_scale
(self, overflow)
deepspeed/runtime/fp16/loss_scaler.py:159
↓ 4 callersMethodvalidate
(**settings)
tests/unit/v1/moe/test_autoep_expert_activation.py:366
↓ 4 callersFunctionvalidate_autoep_post_detection
Post-detection validation: ep_size vs num_experts constraints.
deepspeed/module_inject/auto_ep_config.py:413
↓ 4 callersFunctionvalidate_inferred_shape
Validate that the leading dim of the shard is of the expected size and aligns with the sharding logic for the attention computation itself.
tests/unit/inference/v2/model_implementations/sharding/test_qkv_sharding.py:31
↓ 4 callersFunctionview_as_uint8
(tensor)
deepspeed/runtime/utils.py:51
↓ 4 callersMethodwait
(self)
ci/test_torch_latest.py:229
↓ 4 callersMethodwait
(self, **kwargs)
tests/unit/runtime/zero/test_zero_context.py:88
↓ 4 callersFunctionwarn_consumer_ssd_writes
csrc/aio/py_lib/deepspeed_aio_op_desc.cpp:25
↓ 4 callersFunctionwarp_uniform
csrc/deepspeed4science/evoformer_attn/gemm_kernel_utils.h:217
↓ 4 callersMethodwas_step_applied
Returns True if the latest ``step()`` produced in parameter updates. Note that a ``False`` return is not an error condition. Steps are frequen
deepspeed/runtime/engine.py:2957
↓ 3 callersMethodConfig
csrc/includes/gelu.h:18
↓ 3 callersFunctionCreateLossScaler
(dtype, static_loss_scale, dynamic_scaling, dynamic_loss_args)
deepspeed/runtime/fp16/loss_scaler.py:299
↓ 3 callersMethodFloatTensor
(self, values)
tests/unit/v1/moe/test_autoep_unit.py:925
↓ 3 callersMethodGetNumHeads
csrc/transformer/inference/includes/inference_context.h:194
↓ 3 callersMethodIntTensor
(self)
accelerator/hpu_accelerator.py:227
↓ 3 callersMethodQuantize
(self, value_list, quantize_bits, groups, key, merge_dim=0)
deepspeed/runtime/weight_quantizer.py:42
↓ 3 callersMethod__init__
(self, phase: str, timeout_seconds: int)
ci/torch_latest.py:278
↓ 3 callersMethod__init__
(self)
tests/unit/v1/zero/test_zero3_unused_param_grads.py:278
↓ 3 callersMethod__init__
(self)
tests/unit/v1/half_precision/test_keep_in_fp32_modules.py:30
↓ 3 callersMethod__init__
(self, *args)
tests/unit/runtime/zero/test_zero_context_ancestry.py:46
← previousnext →1,301–1,400 of 15,468, ranked by callers