Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/deepspeedai/DeepSpeed
/ functions
Functions
12,000 in github.com/deepspeedai/DeepSpeed
⨍
Functions
12,000
◇
Types & classes
1,989
↳
Endpoints
37
↓ 13 callers
Method
all_reduce
(tensor, op)
tests/unit/v1/compile/test_offload_activation.py:313
↓ 13 callers
Method
coalesce_grad_reduction
r"""Coalesce ZeRO 1/2/3 gradient reduction across multiple engine.backward() calls. One with-block == one optimizer step: every backward insid
deepspeed/runtime/engine.py:3151
↓ 13 callers
Method
commit
(self, message: str)
ci/test_tests_fetcher.py:98
↓ 13 callers
Method
convert
Convert HF tp_plan to DeepSpeed layer specs. A style outside SUPPORTED_STYLES raises ValueError and invalidates the whole plan, so a
deepspeed/module_inject/tp_plan_converter.py:20
↓ 13 callers
Method
device_count
(self)
accelerator/hpu_accelerator.py:72
↓ 13 callers
Method
get_rng_state
(self, device_index=None)
accelerator/hpu_accelerator.py:85
↓ 13 callers
Method
gradient_accumulation_steps
(self)
deepspeed/runtime/engine.py:1475
↓ 13 callers
Function
installed_cuda_version
(name="")
op_builder/builder.py:47
↓ 13 callers
Method
is_synchronized_device
(self)
accelerator/hpu_accelerator.py:44
↓ 13 callers
Function
make_autoep_config
(zero_stage=0, ep_size=1, load_balance_coeff=UNSET, mixed_precision=True)
tests/unit/v1/moe/autoep_test_utils.py:191
↓ 13 callers
Function
print_rank_0
(message, debug=False, force=False)
deepspeed/runtime/zero/linear.py:32
↓ 13 callers
Function
reset_random
(seed=1234)
tests/unit/inference/quantization/test_intX_quantization.py:29
↓ 13 callers
Method
train_micro_batch_size_per_gpu
(self)
deepspeed/runtime/engine.py:1267
↓ 13 callers
Method
wait
deepspeed/runtime/zero/mics.py:40
↓ 13 callers
Method
wait
(self)
deepspeed/runtime/swap_tensor/pipelined_optimizer_swapper.py:34
↓ 12 callers
Method
Event
(self)
accelerator/hpu_accelerator.py:115
↓ 12 callers
Function
_assert_close
(ref, test, label, tol=1e-6)
tests/unit/v1/zero/test_zero_coalesce_grad_reduction.py:71
↓ 12 callers
Function
_get_hf_tp_plan
Extract tp_plan from HuggingFace model. Merge plans from the model config, model class, and runtime instance. HuggingFace may replace the ins
deepspeed/runtime/tensor_parallel/config.py:149
↓ 12 callers
Method
_get_param_partition_group
(self, param)
deepspeed/runtime/zero/stage3.py:630
↓ 12 callers
Function
_resolve_autotp_partition
(current_param, ckpt_dict, full_hp_param, tp_rank, tp_world_size)
deepspeed/checkpoint/universal_checkpoint.py:74
↓ 12 callers
Method
clear
< Efficiently disables all accesses guarded by mask
csrc/deepspeed4science/evoformer_attn/iterators/predicated_tile_iterator_atomic.h:544
↓ 12 callers
Method
close
(self)
deepspeed/io/py_file_writer.py:17
↓ 12 callers
Method
dump
(self, path)
deepspeed/compile/profilers/graph_profile.py:450
↓ 12 callers
Function
init_tp_engine
(tp_size, partition_config=None)
tests/unit/model_parallelism/test_autotp_custom_patterns.py:128
↓ 12 callers
Function
is_model_parallel_parameter
(p)
deepspeed/runtime/utils.py:154
↓ 12 callers
Method
is_pinned
(self, tensor)
deepspeed/utils/pin_memory.py:77
↓ 12 callers
Function
is_zero_param
(parameter)
deepspeed/runtime/zero/utils.py:149
↓ 12 callers
Function
make_builder
(**overrides)
tests/unit/ops/test_op_builder.py:45
↓ 12 callers
Method
max_memory_allocated
(self, device_index=None)
accelerator/hpu_accelerator.py:126
↓ 12 callers
Function
print_rank_0
(message, debug=False, force=False)
deepspeed/runtime/zero/stage3.py:63
↓ 12 callers
Method
put
Store real inputs Args: real_inputs: The real inputs to store (can be tensors, lists, tuples, etc.)
deepspeed/compile/input_storage.py:154
↓ 12 callers
Function
recursive_getattr
Recursively get the attribute of a module. Args: model (`torch.nn.Module`) The model to get the attribute from. m
deepspeed/compression/helper.py:17
↓ 12 callers
Method
recv
(self, tensor, src, group=None, tag=0)
deepspeed/comm/ccl.py:128
↓ 12 callers
Method
seed
(self)
accelerator/mps_accelerator.py:81
↓ 12 callers
Method
selector
(self)
ci/test_tests_fetcher.py:102
↓ 12 callers
Method
send
(self, tensor, dst, group=None, tag=0)
deepspeed/comm/ccl.py:125
↓ 12 callers
Method
set_non_transformer_params
(self, container: LayerContainer)
deepspeed/inference/v2/model_implementations/inference_policy_base.py:52
↓ 12 callers
Method
set_transformer_params
(self, prefixes: Union[str, Iterable[str]], containers: List[LayerContainer])
deepspeed/inference/v2/model_implementations/inference_policy_base.py:43
↓ 12 callers
Method
set_unmapped_params
(self, prefixes: Union[str, Iterable[str]])
deepspeed/inference/v2/model_implementations/inference_policy_base.py:55
↓ 12 callers
Function
set_z3_leaf_modules
Sets a flag within a module in `model` to instruct ZeRO3 to stop setting hooks recursively when it encounters a module class listed in `leaf_module_cl
deepspeed/utils/z3_leaf_module.py:149
↓ 12 callers
Method
stats
(self)
deepspeed/compile/z3_eager_fallback.py:242
↓ 12 callers
Method
strip_empty_entries
Drop any empty strings from the list of compile and link flags
op_builder/builder.py:419
↓ 12 callers
Method
unpin_memory
(self, tensor)
accelerator/abstract_accelerator.py:310
↓ 11 callers
Method
GetCublasHandle
csrc/transformer/inference/includes/inference_context.h:250
↓ 11 callers
Method
__init__
(self, hidden_dim)
tests/unit/v1/zero/test_zero_user_backward.py:2213
↓ 11 callers
Function
_assert_rejects
(match, **kwargs)
tests/unit/v1/moe/test_autoep_autotp_folding_config.py:79
↓ 11 callers
Function
_init
(config, hidden_dim, seed=42, nlayers=2)
tests/unit/v1/zero/test_zero_coalesce_grad_reduction.py:61
↓ 11 callers
Method
_start_timer
(self, name)
deepspeed/runtime/swap_tensor/optimizer_utils.py:519
↓ 11 callers
Method
_stop_timer
(self, name)
deepspeed/runtime/swap_tensor/optimizer_utils.py:523
↓ 11 callers
Method
_tp_partition
(self, params_list)
deepspeed/module_inject/layers.py:889
↓ 11 callers
Function
_zero_module_with_param
()
tests/unit/v1/compile/test_z3_eager_fallback.py:21
↓ 11 callers
Function
build_batch_and_manager
Will construct and populate a batch and KVCache with the given sequence parameters. Arguments: seq_params (List[Tuple[int, int]]): A
tests/unit/inference/v2/kernels/ragged_ops/ragged_testing_utils.py:89
↓ 11 callers
Function
build_managed_gas_config
fp32 config toggling managed_gradient_accumulation; micro-batch 1 so total_samples == micro-batch count.
tests/unit/v1/zero/test_zero_user_backward.py:1836
↓ 11 callers
Function
build_simple_batch
Construct a simple batch with the given sequence lengths. This method should not be used for for testing scenarios that require information a
tests/unit/inference/v2/kernels/ragged_ops/ragged_testing_utils.py:25
↓ 11 callers
Function
bwc_tensor_model_parallel_world_size
Backwards-compatible way of querying the tensor model parallel world size. Similar to bwc_tensor_model_parallel_rank.
deepspeed/utils/bwc.py:45
↓ 11 callers
Method
compute_capability_args
Returns nvcc compute capability compile flags. 1. Under ``jit_mode``, the precedence is: a. preserved ``TORCH_CUDA_ARCH_L
op_builder/builder.py:656
↓ 11 callers
Method
cuda_capability_major
Compute-capability major of CUDA device 0, or ``None`` when it cannot be read without side effects. ``torch.cuda.get_device_propertie
op_builder/builder.py:638
↓ 11 callers
Method
elapsed
(self, **kwargs)
deepspeed/utils/timer.py:177
↓ 11 callers
Method
elapsed_time
(self, end_event)
tests/unit/v1/compile/test_graph_profile.py:75
↓ 11 callers
Method
get_coord
Return the coordinate owned by a process rank. The axes of the returned namedtuple can be directly accessed as members. For example:
deepspeed/runtime/pipe/topology.py:110
↓ 11 callers
Method
get_data
(self, pp_index=None, tp_index=None)
deepspeed/checkpoint/reshape_meg_2d.py:31
↓ 11 callers
Method
get_data_parallel_group
The group of ranks within the same stage of all pipelines.
deepspeed/runtime/pipe/topology.py:436
↓ 11 callers
Method
get_lr
Calculates the learning rate at batch index. This function treats `self.last_batch_iteration` as the last batch index.
deepspeed/runtime/lr_schedules.py:629
↓ 11 callers
Function
group_gemm_triton
Autograd-aware Triton grouped GEMM (2D x 3D), drop-in for ``torch._grouped_mm``. Args: mat_a: ``[M, K]`` float16/bfloat16/float32.
deepspeed/ops/triton_ops/group_gemm_triton.py:437
↓ 11 callers
Function
is_gated
Return True if the given activation function is gated.
deepspeed/inference/v2/inference_utils.py:81
↓ 11 callers
Function
iter_params
(module: Module, recurse=False)
deepspeed/runtime/zero/partitioned_param_coordinator.py:49
↓ 11 callers
Method
load
(self, mp_world_size, mp_rank, module_key=AUTO_MODULE_KEY,
deepspeed/runtime/state_dict_factory.py:57
↓ 11 callers
Method
manual_seed_all
(self, seed)
accelerator/hpu_accelerator.py:91
↓ 11 callers
Method
parameter_id
(param)
deepspeed/runtime/swap_tensor/optimizer_utils.py:162
↓ 11 callers
Method
partition
(param_list=None, hierarchy=0, has_been_updated=False, free_data=True)
deepspeed/runtime/zero/partition_parameters.py:1576
↓ 11 callers
Method
train
(self, mode=True)
tests/unit/hybrid_engine/test_he_lora.py:90
↓ 11 callers
Method
write
(self, args, tid)
deepspeed/nvme/torch_io.py:29
↓ 11 callers
Method
zero_optimization
(self)
deepspeed/runtime/engine.py:1300
↓ 10 callers
Method
__init__
(self, hidden_dim, empty_grad=False, nlayers=1)
tests/unit/simple_model.py:22
↓ 10 callers
Method
__init__
(self)
tests/unit/modelingpreln.py:98
↓ 10 callers
Function
_assert_checkpoint_state_clean
Assert no recompute params / active consumers remain and params are partitioned.
tests/unit/v1/zero/test_zero_activation_checkpoint_lifecycle.py:104
↓ 10 callers
Function
_train
(config, hidden_dim, num_chunks, num_steps, use_no_sync, seed=42, nlayers=2)
tests/unit/v1/zero/test_zero_coalesce_grad_reduction.py:92
↓ 10 callers
Function
assert_valid_partition
(weights, parts, P)
tests/unit/runtime/utils/test_partition.py:82
↓ 10 callers
Function
auto_wrap_model_for_sp
Inject sequence-parallel wrappers into *model* in-place. Scans the model's named modules and replaces recognised attention layers with their
deepspeed/sequence/auto_sp.py:42
↓ 10 callers
Function
create_mmap_dataset_builder
(fname, dtype)
deepspeed/runtime/data_pipeline/data_sampling/utils.py:44
↓ 10 callers
Method
flush
(self)
deepspeed/io/py_file_writer.py:25
↓ 10 callers
Method
from_config
(*args, **kwargs)
deepspeed/linear/context_manager.py:72
↓ 10 callers
Function
func
()
deepspeed/inference/quantization/layers.py:36
↓ 10 callers
Method
gather_params
(self, params_list)
deepspeed/module_inject/layers.py:875
↓ 10 callers
Function
get_output_node
(graph: Graph)
deepspeed/compile/fx.py:16
↓ 10 callers
Method
get_partition_dp_group
(self, param)
deepspeed/runtime/zero/partition_parameters.py:2290
↓ 10 callers
Function
instrument_w_nvtx
Decorator that records an NVTX range for the duration of the function call. Skips NVTX instrumentation when torch.compile is active to avoid gr
deepspeed/utils/nvtx.py:25
↓ 10 callers
Method
irecv
(self, tensor, src=None, group=None, tag=0)
deepspeed/comm/torch.py:458
↓ 10 callers
Method
is_gradient_accumulation_boundary
True if the engine is executing a gradient reduction or optimizer step instruction. This is overridden from :class:`DeepSpeedEngine` to force
deepspeed/runtime/pipe/engine.py:682
↓ 10 callers
Method
is_triton_supported
(self)
accelerator/hpu_accelerator.py:191
↓ 10 callers
Method
load
csrc/deepspeed4science/evoformer_attn/kernel_backward.h:140
↓ 10 callers
Method
move
(self, tensor)
deepspeed/module_inject/layers.py:542
↓ 10 callers
Method
pin_device_tensor
csrc/gds/py_lib/deepspeed_py_gds_handle.cpp:92
↓ 10 callers
Method
train_batch_size
(self)
deepspeed/runtime/engine.py:1264
↓ 10 callers
Method
transform_param
Perform any necessary transformations of the parameters of this module. Parameters: param (torch.Tensor): Weight or bias
deepspeed/inference/v2/modules/interfaces/linear_base.py:37
↓ 10 callers
Method
write
(self, sizes, doc_idx)
deepspeed/runtime/data_pipeline/data_sampling/indexed_dataset.py:400
↓ 9 callers
Method
ByteTensor
(self)
accelerator/hpu_accelerator.py:211
↓ 9 callers
Method
FloatTensor
(self)
accelerator/hpu_accelerator.py:219
↓ 9 callers
Method
__init__
(self)
tests/unit/modeling.py:102
↓ 9 callers
Method
__init__
(self, parameter, observations)
tests/unit/v1/zero/test_zero_activation_checkpoint_lifecycle.py:32
← previous
next →
201–300 of 12,000, ranked by callers