MLX: An array framework for Apple silicon
This report presents the forensic synthetic code analysis of ml-explore/mlx, a C++ project with 27,543 GitHub stars. SynthScan v2.0 examined 194,324 lines of code across 652 source files, recording 550 pattern matches distributed across 13 syntactic categories. The overall adjusted score of 2.8 places this repository in the Likely human-written band.
The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).
This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 550 distinct pattern matches across 13 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 17 | def cuda_toolkit_major_version(): | CODE |
| LOW | python/tests/test_fast_sdpa.py | 120 | def test_sdpa_vector_kv_transposed_head_seq(self): | CODE |
| LOW | python/tests/test_fast_sdpa.py | 307 | def test_sdpa_vector_value_dims(self): | CODE |
| LOW | python/tests/test_fast_sdpa.py | 448 | def test_sdpa_long_masked_sequence(self): | CODE |
| LOW | python/tests/test_fast_sdpa.py | 501 | def test_sdpa_noncontiguous_inputs(self): | CODE |
| LOW | python/tests/test_fast_sdpa.py | 556 | def test_sdpa_attention_sinks(self): | CODE |
| LOW | python/tests/test_losses.py | 79 | def test_binary_cross_entropy(self): | CODE |
| LOW | python/tests/test_losses.py | 138 | def _test_tiny_probs_as_inputs(): | CODE |
| LOW | python/tests/test_losses.py | 430 | def test_cosine_similarity_loss(self): | CODE |
| LOW | python/tests/test_fast.py | 187 | def test_rope_dims_validation(self): | CODE |
| LOW | python/tests/test_fast.py | 405 | def test_rope_with_large_offset(self): | CODE |
| LOW | python/tests/test_fast.py | 528 | def test_layer_norm_dim_check(self): | CODE |
| LOW | python/tests/test_fast.py | 625 | def test_slice_into_layer_norm(self): | CODE |
| LOW | python/tests/test_fast.py | 676 | def test_layer_norm_grad_no_bias(self): | CODE |
| LOW | python/tests/test_fast.py | 712 | def test_layer_norm_grad_no_params(self): | CODE |
| LOW | python/tests/test_fast.py | 723 | def test_layer_norm_grad_params(self): | CODE |
| LOW | python/tests/test_fast.py | 869 | def test_custom_kernel_strides(self): | STRING |
| LOW | python/tests/test_fast.py | 923 | def test_custom_kernel_helper(self): | STRING |
| LOW | python/tests/test_fast.py | 969 | def test_custom_kernel_attributes(self): | STRING |
| LOW | python/tests/test_fast.py | 995 | def test_custom_kernel_caching(self): | STRING |
| LOW | python/tests/test_fast.py | 1030 | def test_custom_metal_kernel_math_mode(self): | STRING |
| LOW | python/tests/test_fast.py | 1091 | def test_custom_kernel_mixed_dtypes(self): | STRING |
| LOW | python/tests/test_array.py | 260 | def test_list_not_equals_array(self): | CODE |
| LOW | python/tests/test_array.py | 283 | def test_tuple_not_equals_array(self): | CODE |
| LOW | python/tests/test_array.py | 293 | def test_obj_inequality_array(self): | CODE |
| LOW | python/tests/test_array.py | 453 | def test_construction_from_lists(self): | CODE |
| LOW | python/tests/test_array.py | 509 | def test_double_keeps_precision(self): | CODE |
| LOW | python/tests/test_array.py | 517 | def test_construction_from_lists_of_mlx_arrays(self): | CODE |
| LOW | python/tests/test_array.py | 676 | def test_array_repr_precision(self): | CODE |
| LOW | python/tests/test_array.py | 805 | def test_array_np_dtype_conversion(self): | CODE |
| LOW | python/tests/test_array.py | 837 | def test_array_from_noncontiguous_np(self): | CODE |
| LOW | python/tests/test_array.py | 844 | def test_array_np_shape_dim_check(self): | CODE |
| LOW | python/tests/test_array.py | 896 | def test_dtype_python_scalar_promotion(self): | CODE |
| LOW | python/tests/test_array.py | 1551 | def test_array_at_slice_update_extensive(self): | CODE |
| LOW | python/tests/test_array.py | 1806 | def test_np_array_conversion_copies_by_default(self): | CODE |
| LOW | python/tests/test_array.py | 1888 | def test_buffer_protocol_ref_counting(self): | CODE |
| LOW | python/tests/test_array.py | 1898 | def test_array_view_ref_counting(self): | CODE |
| LOW | python/tests/test_array.py | 2045 | def test_inplace_preserves_ids(self): | CODE |
| LOW | python/tests/test_array.py | 2060 | def test_load_from_pickled_np(self): | CODE |
| LOW | python/tests/test_array.py | 2143 | def test_dlpack_cpu_dtype_mapping(self): | CODE |
| LOW | python/tests/test_array.py | 2209 | def test_from_dlpack_cpu_strided(self): | CODE |
| LOW | python/tests/test_array.py | 2240 | def test_torch_mps_dlpack_import(self): | CODE |
| LOW | python/tests/test_array.py | 2254 | def test_torch_mps_array_copies_dlpack_input(self): | CODE |
| LOW | python/tests/test_array.py | 2265 | def test_torch_mps_asarray_copy_true_copies_dlpack_input(self): | CODE |
| LOW | python/tests/test_array.py | 2276 | def test_torch_mps_dlpack_zero_copy_shares_updates(self): | CODE |
| LOW | python/tests/test_array.py | 2291 | def test_torch_mps_dlpack_matching_dtype_argument_shares_updates(self): | CODE |
| LOW | python/tests/test_array.py | 2303 | def test_torch_mps_dlpack_different_dtype_argument_copies(self): | CODE |
| LOW | python/tests/test_array.py | 2321 | def test_torch_mps_dlpack_data_offset(self): | CODE |
| LOW | python/tests/test_array.py | 2329 | def test_torch_mps_dlpack_strided_view(self): | CODE |
| LOW | python/tests/test_array.py | 2358 | def test_torch_mps_dlpack_stepped_view(self): | CODE |
| LOW | python/tests/test_array.py | 2376 | def test_torch_mps_dlpack_broadcast_stride(self): | CODE |
| LOW | python/tests/test_array.py | 2403 | def test_torch_mps_array_operand(self): | CODE |
| LOW | python/tests/test_array.py | 2414 | def test_mlx_dlpack_exports_mps_tensor_to_torch(self): | CODE |
| LOW | python/tests/test_array.py | 2426 | def test_mlx_dlpack_exports_mps_tensor_to_torch_tensor(self): | CODE |
| LOW | python/tests/test_array.py | 2438 | def test_mlx_dlpack_export_torch_update_writes_mlx_buffer(self): | CODE |
| LOW | python/tests/test_array.py | 2453 | def test_from_dlpack_torch_mps_copy_none_shares_updates(self): | CODE |
| LOW | python/tests/test_array.py | 2468 | def test_from_dlpack_torch_mps_copy_false_shares_updates(self): | CODE |
| LOW | python/tests/test_array.py | 2479 | def test_from_dlpack_torch_mps_copy_true_copies(self): | CODE |
| LOW | python/tests/test_array.py | 2551 | def test_setitem_with_boolean_mask(self): | CODE |
| LOW | python/tests/test_array.py | 2588 | def test_array_namespace_asarray(self): | CODE |
| 129 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 261 | install_requires = [] | COMMENT |
| LOW | python/src/ops.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/utils.h | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/distributed.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | python/src/transforms.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/fast.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/convert.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | python/src/load.h | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/fft.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/array.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/export.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | python/src/buffer.h | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | python/src/load.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | python/src/metal.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | tests/allocator_tests.cpp | 1 | // Copyright © 2023-2026 Apple Inc. | COMMENT |
| LOW | tests/random_tests.cpp | 281 | key = array({0u, 0u, 0u}, {3, 1}); | COMMENT |
| LOW | tests/gpu_tests.cpp | 641 | // LayerNormVJP::eval_gpu (mlx/backend/metal/normalization.cpp). | COMMENT |
| LOW | tests/autograd_tests.cpp | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | examples/extensions/axpby/axpby.cpp | 1 | // Copyright © 2023-2025 Apple Inc. | COMMENT |
| LOW | mlx/mlx.h | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/mlx.h | 21 | #include "mlx/random.h" | COMMENT |
| LOW | mlx/ops.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/utils.h | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/transforms.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/transforms.cpp | 1021 | // We use the passed vjp function or compute it from the inputs and | COMMENT |
| LOW | mlx/threadpool.h | 1 | // This code was modified from https://github.com/progschj/ThreadPool | COMMENT |
| LOW | mlx/threadpool.h | 21 | // 3. This notice may not be removed or altered from any source | COMMENT |
| LOW | mlx/small_vector.h | 1 | // Copyright © 2025 Apple Inc. | COMMENT |
| LOW | mlx/small_vector.h | 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | COMMENT |
| LOW | mlx/small_vector.h | 41 | #else | COMMENT |
| LOW | mlx/small_vector.h | 81 | // Minimal SmallVector implementation. Uses inline storage first, switches to | COMMENT |
| LOW | mlx/scheduler.h | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/api.h | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/api.h | 21 | #define MLX_API __declspec(dllexport) | COMMENT |
| LOW | mlx/export.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/compile.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/compile.cpp | 801 | // Go through the tape in reverse order and check for fusable sub-graphs | COMMENT |
| LOW | mlx/stream.cpp | 1 | // Copyright © 2026 Apple Inc. | COMMENT |
| LOW | mlx/primitives.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/primitives.cpp | 5701 | // - tm = (K + block_size - 1) // block_size; KP = tk * block_size; | COMMENT |
| LOW | mlx/array.h | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/graph_utils.cpp | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/einsum.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/distributed/jaccl/lib/jaccl/mesh_impl.h | 81 | buff++; | COMMENT |
| LOW | mlx/distributed/jaccl/lib/examples/allreduce_bench.cpp | 1 | // Copyright © 2025 Apple Inc. | COMMENT |
| LOW | mlx/distributed/jaccl/lib/examples/allreduce_bench.cpp | 21 | // | COMMENT |
| LOW | mlx/distributed/jaccl/lib/examples/CMakeLists.txt | 1 | cmake_minimum_required(VERSION 3.24) | COMMENT |
| LOW | mlx/distributed/nccl/nccl.cpp | 1 | // NCCL distributed support currently requires Unix socket APIs | COMMENT |
| LOW | mlx/distributed/mpi/mpi_declarations.h | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/distributed/ring/ring.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/io/load.h | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/io/safetensors.cpp | 1 | // Copyright © 2023 Apple Inc. | COMMENT |
| LOW | mlx/io/safetensors.cpp | 21 | #define ST_BOOL "BOOL" | COMMENT |
| LOW | mlx/io/load.cpp | 1 | // Copyright © 2023-2026 Apple Inc. | COMMENT |
| LOW | mlx/backend/gpu/primitives.cpp | 1 | // Copyright © 2025 Apple Inc. | COMMENT |
| LOW | mlx/backend/metal/quantized.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/backend/metal/distributed.cpp | 1 | // Copyright © 2024 Apple Inc. | COMMENT |
| LOW | mlx/backend/metal/device.h | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/backend/metal/matmul.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| LOW | mlx/backend/metal/compiled.cpp | 1 | // Copyright © 2023-2024 Apple Inc. | COMMENT |
| 63 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | python/tests/test_fast_sdpa.py | 8 | CODE | |
| LOW | python/tests/test_linalg.py | 5 | CODE | |
| LOW | python/tests/test_conv_transpose.py | 5 | CODE | |
| LOW | python/tests/test_tree.py | 3 | CODE | |
| LOW | python/tests/test_losses.py | 3 | CODE | |
| LOW | python/tests/test_double.py | 4 | CODE | |
| LOW | python/tests/test_double.py | 5 | CODE | |
| LOW | python/tests/test_array.py | 4 | CODE | |
| LOW | python/tests/test_optimizers.py | 18 | CODE | |
| LOW | python/tests/test_nn.py | 5 | CODE | |
| LOW | python/tests/test_quantized.py | 3 | CODE | |
| LOW | python/tests/test_blas.py | 4 | CODE | |
| LOW | python/tests/test_blas.py | 5 | CODE | |
| LOW | python/tests/test_threads.py | 4 | CODE | |
| LOW | python/tests/test_reduce.py | 3 | CODE | |
| LOW | python/tests/test_bf16.py | 3 | CODE | |
| LOW | python/tests/test_bf16.py | 5 | CODE | |
| LOW | python/tests/test_einsum.py | 3 | CODE | |
| LOW | python/tests/test_graph.py | 4 | CODE | |
| LOW | python/tests/test_init.py | 3 | CODE | |
| LOW | python/tests/test_constants.py | 3 | CODE | |
| LOW | python/tests/test_vmap.py | 4 | CODE | |
| LOW | python/tests/test_eval.py | 4 | CODE | |
| LOW | python/tests/test_random.py | 4 | CODE | |
| LOW | python/tests/test_conv.py | 6 | CODE | |
| LOW | python/mlx/nn/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/__init__.py | 4 | CODE | |
| LOW | python/mlx/nn/__init__.py | 5 | CODE | |
| LOW | python/mlx/nn/__init__.py | 5 | CODE | |
| LOW | python/mlx/nn/__init__.py | 5 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| LOW | python/mlx/nn/layers/__init__.py | 3 | CODE | |
| 91 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | python/tests/test_fast_sdpa.py | 364 | CODE | |
| LOW | python/tests/test_fast_sdpa.py | 653 | CODE | |
| LOW | python/tests/test_linalg.py | 13 | CODE | |
| LOW | python/tests/test_linalg.py | 88 | CODE | |
| LOW | python/tests/test_upsample.py | 21 | CODE | |
| LOW | python/tests/test_fast.py | 383 | CODE | |
| LOW | python/tests/test_double.py | 115 | CODE | |
| LOW | python/tests/test_array.py | 1812 | CODE | |
| LOW | python/tests/test_export_import.py | 501 | CODE | |
| LOW | python/tests/test_export_import.py | 513 | CODE | |
| LOW | python/tests/test_fft.py | 62 | CODE | |
| LOW | python/tests/test_blas.py | 311 | CODE | |
| LOW | python/tests/test_blas.py | 488 | CODE | |
| LOW | python/tests/test_blas.py | 1242 | CODE | |
| LOW | python/tests/mpi_test_distributed.py | 31 | CODE | |
| LOW | python/tests/test_reduce.py | 12 | CODE | |
| LOW | python/tests/test_reduce.py | 29 | CODE | |
| LOW | python/tests/test_reduce.py | 50 | CODE | |
| LOW | python/tests/test_reduce.py | 86 | CODE | |
| LOW | python/tests/test_reduce.py | 156 | CODE | |
| LOW | python/tests/test_bf16.py | 127 | CODE | |
| LOW | python/tests/test_ops.py | 1639 | CODE | |
| LOW | python/tests/test_ops.py | 1706 | CODE | |
| LOW | python/tests/test_ops.py | 1801 | CODE | |
| LOW | python/tests/test_ops.py | 2450 | CODE | |
| LOW | python/tests/test_autograd.py | 823 | CODE | |
| LOW | python/tests/test_load.py | 41 | CODE | |
| LOW | python/tests/test_load.py | 91 | CODE | |
| LOW | python/tests/test_load.py | 132 | CODE | |
| LOW | python/tests/test_load.py | 385 | CODE | |
| LOW | python/tests/test_load.py | 423 | CODE | |
| LOW | python/mlx/nn/layers/quantized.py | 22 | CODE | |
| LOW | python/mlx/nn/layers/quantized.py | 69 | CODE | |
| LOW | python/mlx/nn/layers/base.py | 619 | CODE | |
| LOW | python/mlx/nn/layers/base.py | 656 | CODE | |
| LOW | python/mlx/nn/layers/base.py | 304 | CODE | |
| LOW | python/mlx/nn/layers/base.py | 325 | CODE | |
| LOW | python/mlx/_distributed_utils/config.py | 337 | CODE | |
| LOW | python/mlx/_distributed_utils/config.py | 486 | CODE | |
| LOW | python/mlx/_distributed_utils/config.py | 515 | CODE | |
| LOW | python/mlx/_distributed_utils/launch.py | 170 | CODE | |
| LOW | python/mlx/_distributed_utils/launch.py | 457 | CODE | |
| LOW | python/mlx/optimizers/optimizers.py | 31 | CODE | |
| LOW | python/mlx/optimizers/optimizers.py | 53 | CODE | |
| LOW | examples/python/qqmm.py | 22 | CODE | |
| LOW | benchmarks/python/hadamard_bench.py | 22 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | python/mlx/nn/losses.py | 31 | Computes the cross entropy loss. Args: logits (array): The unnormalized logits. targets (array | STRING |
| HIGH | python/mlx/nn/losses.py | 127 | Computes the binary cross entropy loss. By default, this function takes the pre-sigmoid logits, which results | STRING |
| HIGH | python/mlx/nn/losses.py | 569 | Calculate the margin ranking loss that loss given inputs :math:`x_1`, :math:`x_2` and a label :math:`y` (contai | STRING |
| HIGH | python/mlx/nn/layers/linear.py | 80 | Return a quantized approximation of this layer. If ``quantize_input`` is ``False``, returns a :obj:`QuantizedLi | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | python/mlx/_distributed_utils/launch.py | 159 | script += "if ps -p $pid >/dev/null; then " | CODE |
| HIGH⚡ | python/mlx/_distributed_utils/common.py | 51 | {"ssh": "hostname1", "ips": ["123.123.123.1"], "rdma": [null, "rdma_en2", "rdma_en3"]}, | STRING |
| HIGH⚡ | python/mlx/_distributed_utils/common.py | 52 | {"ssh": "hostname2", "ips": ["123.123.123.2"], "rdma": ["rdma_en2", null, "rdma_en3"]}, | STRING |
| HIGH⚡ | python/mlx/_distributed_utils/common.py | 54 | {"ssh": "hostnameN", "ips": ["123.123.123.N"], "rdma": ["rdma_en2", "rdma_en3", null]}, | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | python/tests/test_compile.py | 82 | def worker(): | CODE |
| LOW | python/tests/test_compile.py | 88 | except Exception as e: | CODE |
| LOW | python/tests/test_threads.py | 75 | except Exception as e: | CODE |
| LOW | python/tests/test_threads.py | 87 | except Exception as e: | CODE |
| LOW | python/tests/test_threads.py | 99 | except Exception as e: | CODE |
| MEDIUM | python/tests/test_threads.py | 66 | def grad_worker(): | CODE |
| MEDIUM | python/tests/test_threads.py | 78 | def compile_worker(): | CODE |
| MEDIUM | python/tests/test_threads.py | 90 | def vmap_worker(): | CODE |
| LOW | python/mlx/_distributed_utils/common.py | 85 | except Exception as e: | CODE |
| LOW | benchmarks/python/masked_scatter.py | 36 | except Exception: | CODE |
| LOW | benchmarks/python/masked_scatter.py | 45 | except Exception: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | python/tests/test_einsum.py | 192 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 193 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 195 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 196 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 197 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 198 | CODE | |
| MEDIUM | python/tests/test_einsum.py | 199 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | python/mlx/utils.py | 162 | # Create the function to update the destination. We are taking advantage of | COMMENT |
| MEDIUM | python/mlx/_distributed_utils/config.py | 256 | # Create a reverse index to be able to map uuids to (host, port) quickly | COMMENT |
| MEDIUM | python/src/stream.cpp | 175 | # Create a context manager for the default device and stream. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 147 | # Set CMAKE_BUILD_PARALLEL_LEVEL to control the parallel build level | COMMENT |
| LOW | python/tests/test_constants.py | 12 | # Check if mlx constants match expected values | COMMENT |
| LOW⚡ | python/tests/test_constants.py | 25 | # Check if mlx constants are available | COMMENT |
| LOW | python/mlx/extension.py | 53 | # Set CMAKE_BUILD_PARALLEL_LEVEL to control the parallel build level | COMMENT |
| LOW | python/mlx/_distributed_utils/launch.py | 267 | # Check if all are running and terminate otherwise | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | python/tests/test_quantized.py | 946 | CODE | |
| LOW | python/tests/test_blas.py | 1060 | CODE | |
| LOW | python/tests/test_conv.py | 701 | CODE | |
| LOW | python/mlx/nn/layers/transformer.py | 314 | CODE | |
| LOW | python/mlx/optimizers/optimizers.py | 742 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | mlx/distributed/jaccl/lib/jaccl/rdma.h | 337 | // Twice has proven to be more robust to initialization issues. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | python/mlx/nn/layers/base.py | 569 | def _set_training_mode(self, mode: bool) -> None: | CODE |