Repository Analysis

deepseek-ai/DeepEP

DeepEP: an efficient expert-parallel communication library

5.1 Low AI signal View on GitHub
5.1
Adjusted Score
5.1
Raw Score
100%
Time Factor
2026-05-26
Last Push
9,686
Stars
Cuda
Language
12,766
Lines of Code
66
Files
59
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 2LOW 57

Pattern Findings

59 matches across 8 categories. Click a row to expand file-level details.

Hyper-Verbose Identifiers19 hits · 20 pts
SeverityFileLineSnippet
LOWsetup.py42def get_nvshmem_host_lib_name(base_dir):
LOWdeep_ep/buffers/legacy.py176 def get_low_latency_rdma_size_hint(num_max_dispatch_tokens_per_rank: int, hidden: int, num_ranks: int, num_experts:
LOWdeep_ep/buffers/legacy.py672 def low_latency_update_mask_buffer(self, rank_to_mask: int, mask: bool = False):
LOWdeep_ep/buffers/legacy.py683 def low_latency_query_mask_buffer(self, mask_status: torch.Tensor):
LOWdeep_ep/buffers/legacy.py693 def low_latency_clean_mask_buffer(self):
LOWdeep_ep/buffers/legacy.py700 def get_next_low_latency_combine_buffer(self, handle: object):
LOWdeep_ep/buffers/elastic.py281 def get_engram_storage_size_hint(num_entries: int, hidden: int,
LOWdeep_ep/buffers/elastic.py330 def get_agrs_num_max_session_bytes(group: dist.ProcessGroup,
LOWdeep_ep/buffers/elastic.py351 def get_agrs_buffer_size_hint(group: dist.ProcessGroup,
LOWdeep_ep/utils/envs.py183def check_torch_deterministic() -> None:
LOWdeep_ep/utils/envs.py223def check_fast_rdma_atomic_support(nic_name: str = _DEFAULT_NIC_NAME) -> bool:
LOWdeep_ep/utils/comm.py74def destroy_all_managed_nccl_comm() -> None:
LOWdeep_ep/utils/gate.py116def get_precise_unbalanced_scores(num_tokens: int, num_experts: int, num_ranks: int, num_topk: int, ratio: float):
LOWdeep_ep/utils/gate.py148def map_unbalanced_ratio_to_factor(num_tokens: int, num_experts: int, num_ranks: int, num_topk: int, ratio: float) -> fl
LOWdeep_ep/utils/gate.py167def get_random_unbalanced_scores(num_tokens: int, num_experts: int, num_ranks: int, num_topk: int, ratio: float):
LOWdeep_ep/utils/refs.py126def generate_pre_combine_data(src_token_global_idx: torch.Tensor,
LOWtests/elastic/test_ep.py279 def get_unique_and_valid_dst_count(dst_idx: torch.Tensor,
LOWtests/legacy/test_low_latency.py14def simulate_failure_and_skip(rank: int, api: Literal["dispatch", "combine", "clean"], expected_masked_ranks: Set[int]):
LOWtests/legacy/test_low_latency.py33def query_mask_buffer_and_check(api: Literal["dispatch", "combine", "clean"], buffer: deep_ep.Buffer, mask_status: torch
Unused Imports13 hits · 13 pts
SeverityFileLineSnippet
LOWdeep_ep/__init__.py5
LOWdeep_ep/__init__.py88
LOWdeep_ep/__init__.py89
LOWdeep_ep/__init__.py89
LOWdeep_ep/__init__.py91
LOWdeep_ep/__init__.py91
LOWdeep_ep/__init__.py92
LOWdeep_ep/__init__.py92
LOWdeep_ep/__init__.py95
LOWdeep_ep/__init__.py95
LOWdeep_ep/buffers/elastic.py5
LOWdeep_ep/utils/__init__.py3
LOWtests/elastic/test_agrs.py2
Deep Nesting11 hits · 11 pts
SeverityFileLineSnippet
LOWdeep_ep/utils/envs.py145
LOWdeep_ep/utils/testing.py111
LOWdeep_ep/utils/find_pkgs.py8
LOWtests/elastic/test_ep.py22
LOWtests/elastic/test_ep.py59
LOWtests/elastic/test_agrs.py89
LOWtests/legacy/test_low_latency.py39
LOWtests/legacy/test_intranode.py17
LOWtests/legacy/test_internode.py18
LOWtests/legacy/test_internode.py318
LOWtests/utils/test_gate.py7
Over-Commented Block8 hits · 8 pts
SeverityFileLineSnippet
LOWformat.sh1#!/usr/bin/env bash
LOWcsrc/python_api.cpp1#include <pybind11/pybind11.h>
LOWcsrc/kernels/elastic/api.hpp1#pragma once
LOWcsrc/elastic/buffer.hpp1#pragma once
LOWcsrc/legacy/buffer.hpp1#pragma once
LOWcsrc/utils/system.hpp1#pragma once
LOWcsrc/utils/format.hpp1#pragma once
LOWcsrc/jit/compiler.hpp1#pragma once
Self-Referential Comments2 hits · 6 pts
SeverityFileLineSnippet
MEDIUMdeep_ep/utils/comm.py68 # Create a new communicator
MEDIUMdeep_ep/utils/gate.py20 # Create the mask
Excessive Try-Catch Wrapping4 hits · 4 pts
SeverityFileLineSnippet
LOWdeep_ep/__init__.py38 except Exception:
LOWdeep_ep/utils/envs.py217 except Exception as e:
LOWdeep_ep/utils/envs.py241 except Exception:
LOWdeep_ep/utils/envs.py266 except Exception as e:
Example Usage Blocks1 hit · 2 pts
SeverityFileLineSnippet
LOWformat.sh2# Usage:
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippet
LOWformat.sh179# Check if there are any uncommitted changes after all formatting steps.