AI Slop Code RIsk Monitor

google-ai-edge/LiteRT

LiteRT, successor to TensorFlow Lite. is Google's On-device framework for high-performance ML & GenAI deployment on edge platforms, via efficient conversion, runtime, and optimization

13.1 Moderate pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for google-ai-edge/LiteRT, a C++ project with 3,485 GitHub stars. SynthScan examined 615,769 lines of code across 3532 source files, recording 6053 pattern matches distributed across 22 syntactic categories. The legacy adjusted pattern signal is 13.1 (Moderate pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

13.1
Adjusted Signal
13.1
Raw Pattern Score
100%
Time Factor
2026-10-11
Last Push
3.5K
Stars
C++
Language
615.8K
Lines of Code
3.5K
Files
6.1K
Pattern Hits
2026-10-12
Scan Date
0.05
HC Hit Rate

Risk Review · v3

Use each vector to guide manual verification of the underlying findings.

Cognitive Ownership Risk 36.8/100 · MEDIUM

Can maintainers explain intent, assumptions, and trade-offs? 4974 finding(s).

Hallucinated Dependency & Supply Chain Risk 4.3/100 · LOW

Are imports declared and package/API names verified? 464 finding(s).

Agent Over-Engineering Ratio 21.9/100 · LOW

Are wrappers, guards, and repeated structures necessary? 1794 finding(s).

PR Review Velocity Impact 48.9/100 · MEDIUM

Which changes need focused human review? 6053 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 20HIGH 157MEDIUM 629LOW 5247

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 6053 distinct pattern matches across 22 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. 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 configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Over-Commented Block3331 hits · 3250 pts
SeverityFileLineSnippetContext
LOWconfigure.py1# Copyright 2024 The AI Edge LiteRT Authors.COMMENT
LOWrequirements_lock_3_14_freethreaded.txt1#COMMENT
LOWrequirements_lock_3_14_freethreaded.txt541 # ml-dtypesCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt561 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt601 # viaCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt641 # viaCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt681 # viaCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt721 --hash=sha256:ecd0a012051abc20c1aa87328841efa8cade3ced65803046e38c2f03c0891feaCOMMENT
LOWrequirements_lock_3_14_freethreaded.txt741 # -r ci/official/requirements_updater/nvidia-requirements.txtCOMMENT
LOWrequirements_lock_3_14.txt1#COMMENT
LOWrequirements_lock_3_14.txt541 # ml-dtypesCOMMENT
LOWrequirements_lock_3_14.txt561 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_14.txt601 # viaCOMMENT
LOWrequirements_lock_3_14.txt641 # viaCOMMENT
LOWrequirements_lock_3_14.txt681 # viaCOMMENT
LOWrequirements_lock_3_14.txt721 --hash=sha256:8ce1b8213f61f2bfac132e6df890af6450b77cbd140c6ce4e98cb0c2d8e678c9COMMENT
LOWrequirements_lock_3_14.txt741 # nvidia-cufftCOMMENT
LOWrequirements_lock_3_13.txt1#COMMENT
LOWrequirements_lock_3_13.txt441 --hash=sha256:e6ecde441aaf0bb74ed538cfb3b18aa374f452aebf0162088bcb10942f7bbc33 \COMMENT
LOWrequirements_lock_3_13.txt601 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_13.txt621 --hash=sha256:ca786ffa5a647c75d4d1f5cc72a6c4f537947e2ba8823d7c8aaf768e7a7b9f77 \COMMENT
LOWrequirements_lock_3_13.txt641 --hash=sha256:f9b37bc5c8cf7509665cb6ada5aaa0ce65618f2332b7d3e78e9790511f111212COMMENT
LOWrequirements_lock_3_12.txt1#COMMENT
LOWrequirements_lock_3_12.txt441 --hash=sha256:e6ecde441aaf0bb74ed538cfb3b18aa374f452aebf0162088bcb10942f7bbc33 \COMMENT
LOWrequirements_lock_3_12.txt601 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_12.txt621 --hash=sha256:ca786ffa5a647c75d4d1f5cc72a6c4f537947e2ba8823d7c8aaf768e7a7b9f77 \COMMENT
LOWrequirements_lock_3_12.txt641 --hash=sha256:f9b37bc5c8cf7509665cb6ada5aaa0ce65618f2332b7d3e78e9790511f111212COMMENT
LOWrequirements_lock_3_12.txt1081 --hash=sha256:29b23c360f22f414dc7336bb39178cc7bcbf6021ed2733cde173f09dba19abb3COMMENT
LOWrequirements_lock_3_10.txt1#COMMENT
LOWrequirements_lock_3_10.txt441 --hash=sha256:e6ecde441aaf0bb74ed538cfb3b18aa374f452aebf0162088bcb10942f7bbc33 \COMMENT
LOWrequirements_lock_3_10.txt601 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_10.txt621 --hash=sha256:ca786ffa5a647c75d4d1f5cc72a6c4f537947e2ba8823d7c8aaf768e7a7b9f77 \COMMENT
LOWrequirements_lock_3_10.txt641 --hash=sha256:f9b37bc5c8cf7509665cb6ada5aaa0ce65618f2332b7d3e78e9790511f111212COMMENT
LOWrequirements_lock_3_11.txt1#COMMENT
LOWrequirements_lock_3_11.txt441 --hash=sha256:e6ecde441aaf0bb74ed538cfb3b18aa374f452aebf0162088bcb10942f7bbc33 \COMMENT
LOWrequirements_lock_3_11.txt601 # -r ci/official/requirements_updater/nvidia-constraints.txtCOMMENT
LOWrequirements_lock_3_11.txt621 --hash=sha256:ca786ffa5a647c75d4d1f5cc72a6c4f537947e2ba8823d7c8aaf768e7a7b9f77 \COMMENT
LOWrequirements_lock_3_11.txt641 --hash=sha256:f9b37bc5c8cf7509665cb6ada5aaa0ce65618f2332b7d3e78e9790511f111212COMMENT
LOWrequirements_lock_3_11.txt1081 --hash=sha256:29b23c360f22f414dc7336bb39178cc7bcbf6021ed2733cde173f09dba19abb3COMMENT
LOWPackage.swift1// swift-tools-version: 5.9COMMENT
LOW…t_ats_op_generator/references/primitive_op_patterns.md221#include <type_traits>COMMENT
LOWtflite/generate-pc.sh1#!/usr/bin/env bashCOMMENT
LOWtflite/version.h21// semantic versioning https://semver.org/COMMENT
LOWtflite/version.h41 TF_PATCH_VERSION) TF_VERSION_SUFFIX)COMMENT
LOWtflite/portable_type_to_tflitetype.h21COMMENT
LOWtflite/CMakeLists.txt1#COMMENT
LOWtflite/CMakeLists.txt101 set(_TFLITE_ENABLE_NNAPI OFF)COMMENT
LOWtflite/minimal_logging.h81#define TFLITE_LOG TFLITE_LOG_PRODCOMMENT
LOWtflite/string_util.h21// [(N+1)*4, (N+1)*4+3] 4 bytes: length of the whole char buffer.COMMENT
LOWtflite/arena_planner.h21#include <unordered_map>COMMENT
LOWtflite/arena_planner.h41// share some of the buffer if a tensor B is to be allocated after anotherCOMMENT
LOWtflite/arena_planner.h81 int output_id, bool tensor_changed);COMMENT
LOWtflite/memory_planner.h41 // ExecuteAllocations() is called.COMMENT
LOWtflite/namespace.h21// To avoid potential violation of the C++ "one definition rule" (ODR) forCOMMENT
LOWtflite/interpreter_options.h41 /// inference speed.COMMENT
LOWtflite/interpreter_options.h121 // Controls to update Tensor names with Signature input & output names.COMMENT
LOWtflite/simple_memory_arena.h121COMMENT
LOWtflite/simple_memory_arena.h161COMMENT
LOWtflite/external_cpu_backend_context.h41};COMMENT
LOWtflite/external_cpu_backend_context.h61//COMMENT
3271 more matches not shown…
Decorative Section Separators520 hits · 1566 pts
SeverityFileLineSnippetContext
MEDIUMconfigure.py14# ==============================================================================COMMENT
MEDIUMtflite/generate-pc.sh14# ==============================================================================COMMENT
MEDIUM…eleration/compatibility/convert_binary_to_cc_source.py14# ==============================================================================COMMENT
MEDIUM…end/python/kernel_tests/audio_microfrontend_op_test.py14# ==============================================================================COMMENT
MEDIUM…tal/microfrontend/python/ops/audio_microfrontend_op.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/convert_image_to_csv.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/build_aar.sh15# ==============================================================================COMMENT
MEDIUMtflite/tools/test_utils.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/convert_image_to_csv_test.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/flatbuffer_utils.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/randomize_weights.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/zip_files.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/strip_strings.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/visualize.py15# ==============================================================================COMMENT
MEDIUMtflite/tools/build_aar_with_docker.sh15# ==============================================================================COMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/reverse_xxd_dump_from_cc.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/visualize_test.py14# ==============================================================================COMMENT
MEDIUM…ize/sparsity/format_converter_wrapper_pybind11_test.py14# =============================================================================COMMENT
MEDIUM…ols/optimize/python/modify_model_interface_lib_test.py14# ==============================================================================COMMENT
MEDIUM…te/tools/optimize/python/modify_model_interface_lib.py14# ==============================================================================COMMENT
MEDIUM…ls/optimize/python/modify_model_interface_constants.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/optimize/python/modify_model_interface.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/optimize/debugging/python/debugger_test.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/optimize/debugging/python/debugger.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/cmake/download_toolchains.sh15# ==============================================================================COMMENT
MEDIUMtflite/tools/pip_package/setup_with_binary.py14# ==============================================================================COMMENT
MEDIUMtflite/tools/pip_package/update_sources.sh15# ==============================================================================COMMENT
MEDIUM…lite/tools/pip_package/build_pip_package_with_cmake.sh15# ==============================================================================COMMENT
MEDIUM…lite/tools/pip_package/build_pip_package_with_bazel.sh15# ==============================================================================COMMENT
MEDIUMtflite/converter/python/wrap_converter.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_saved_model.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_file_to_c_source_test.sh15# ==============================================================================COMMENT
MEDIUMtflite/python/schema_util.py14# ==============================================================================COMMENT
MEDIUMtflite/python/wrap_toco.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_saved_model_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/util.py14# ==============================================================================COMMENT
MEDIUMtflite/python/op_hint.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite_v2_test_util.py14# ==============================================================================COMMENT
MEDIUM⚡tflite/python/analyzer.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_phase.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/test_util.py14# ==============================================================================COMMENT
MEDIUMtflite/python/util_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/interpreter.py14# ==============================================================================COMMENT
MEDIUMtflite/python/interpreter_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite_flex_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/analyzer_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite_v2_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/test_util_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/tflite_keras_util.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_file_to_c_source.py14# ==============================================================================COMMENT
MEDIUMtflite/python/convert_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/lite_constants.py14# ==============================================================================COMMENT
MEDIUMtflite/python/metrics/metrics_nonportable_test.py14# ==============================================================================COMMENT
MEDIUMtflite/python/metrics/metrics_portable_test.py14# ==============================================================================COMMENT
MEDIUM⚡tflite/python/metrics/metrics_interface.py14# ==============================================================================COMMENT
MEDIUM⚡tflite/python/metrics/metrics_portable.py14# ==============================================================================COMMENT
460 more matches not shown…
Hyper-Verbose Identifiers1146 hits · 1168 pts
SeverityFileLineSnippetContext
LOWconfigure.py114def write_action_env_to_bazelrc(var_name, var):CODE
LOWconfigure.py118def write_repo_env_to_bazelrc(config_name, var_name, var):CODE
LOWconfigure.py255def reset_tf_configure_bazelrc():CODE
LOWconfigure.py535def get_from_env_or_user_or_default(CODE
LOWconfigure.py561def prompt_loop_or_load_from_env(CODE
LOWconfigure.py631def set_clang_cuda_compiler_path(environ_cp):CODE
LOWconfigure.py822def set_gcc_host_compiler_path(environ_cp):CODE
LOWconfigure.py908def set_clang_compiler_path_win(environ_cp):CODE
LOWconfigure.py984def disable_clang_offsetof_extension(clang_version):CODE
LOWconfigure.py989def set_hermetic_cuda_version(environ_cp):CODE
LOWconfigure.py1005def set_hermetic_cudnn_version(environ_cp):CODE
LOWconfigure.py1021def set_hermetic_cuda_compute_capabilities(environ_cp):CODE
LOWconfigure.py1128def system_specific_test_config(environ_cp):CODE
LOW…eleration/compatibility/convert_binary_to_cc_source.py30def _convert_bytes_to_cc_source(data,CODE
LOWtflite/tools/test_utils.py26def build_mock_flatbuffer_model():CODE
LOWtflite/tools/test_utils.py273def build_operator_with_options() -> schema_fb.Operator:CODE
LOWtflite/tools/test_utils.py289def load_model_from_flatbuffer(flatbuffer_model):CODE
LOWtflite/tools/flatbuffer_utils.py39def convert_bytearray_to_object(model_bytearray):CODE
LOWtflite/tools/flatbuffer_utils.py65def read_model_from_bytearray(model_bytearray):CODE
LOWtflite/tools/flatbuffer_utils.py97def read_model_with_mutable_tensors(input_tflite_file):CODE
LOWtflite/tools/flatbuffer_utils.py119def convert_object_to_bytearray(model_object, extra_buffer=b''):CODE
LOWtflite/tools/flatbuffer_utils.py358def byte_swap_tflite_model_obj(model, from_endiness, to_endiness):CODE
LOW⚡tflite/tools/flatbuffer_utils_test.py278 def test_get_options_not_schema_type_raises(self):CODE
LOW⚡tflite/tools/flatbuffer_utils_test.py282 def test_get_options_not_object_type_raises(self):CODE
LOW⚡tflite/tools/flatbuffer_utils_test.py286 def test_get_options_op_type_does_not_match(self):CODE
LOW…ols/optimize/python/modify_model_interface_lib_test.py27def build_tflite_model_with_full_integer_quantization(CODE
LOW…ols/optimize/python/modify_model_interface_lib_test.py41 def representative_dataset_gen():CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py258 def test_layer_direct_compare_metrics(self, quantized_io):CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py348 def test_denylisted_ops_from_option_setter(self, quantized_io):CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py373 def test_denylisted_ops_from_option_constructor(self, quantized_io):CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py392 def test_denylisted_nodes_from_option_setter(self, quantized_io):CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py413 def test_denylisted_nodes_from_option_constructor(self, quantized_io):CODE
LOWtflite/tools/optimize/debugging/python/debugger.py247 def get_nondebug_quantized_model(self) -> bytes:CODE
LOWtflite/tools/optimize/debugging/python/debugger.py261 def get_debug_quantized_model(self) -> bytes:CODE
LOWtflite/tools/optimize/debugging/python/debugger.py306 def _set_converter_options_for_float(CODE
LOWtflite/tools/optimize/debugging/python/debugger.py313 def _set_converter_options_for_calibration(CODE
LOWtflite/tools/optimize/debugging/python/debugger.py332 def _collect_layer_statistics(self) -> Dict[str, Dict[str, float]]:CODE
LOWtflite/tools/optimize/debugging/python/debugger.py386 def _collect_model_statistics(self) -> Dict[str, float]:CODE
LOWtflite/tools/optimize/debugging/python/debugger.py490 def _get_numeric_verify_tensor_details(self) -> List[str]:CODE
LOWtflite/tools/optimize/debugging/python/debugger.py506 def _get_operand_name_and_index(self,CODE
LOWtflite/converter/python/wrap_converter.py40def wrapped_convert_mlir_bytecode(CODE
LOWtflite/converter/python/wrap_converter.py53def wrapped_experimental_mlir_quantize(CODE
LOW⚡tflite/converter/python/wrap_converter.py86def wrapped_experimental_mlir_sparsify(input_data_str):CODE
LOW⚡tflite/converter/python/wrap_converter.py91def wrapped_register_custom_opdefs(custom_opdefs_list):CODE
LOW⚡tflite/converter/python/wrap_converter.py96def wrapped_retrieve_collected_errors():CODE
LOW⚡tflite/converter/python/wrap_converter.py101def wrapped_flat_buffer_file_to_mlir(CODE
LOWtflite/converter/python/wrap_converter.py115def wrapped_mlir_to_flat_buffer(CODE
LOWtflite/python/schema_util.py20def get_builtin_code_from_operator_code(opcode):CODE
LOW⚡tflite/python/util.py568def get_dequantize_opcode_idx(model):CODE
LOW⚡tflite/python/util.py578def _update_signature_def_tensors(tensor_maps, map_old_to_new_tensors):CODE
LOW⚡tflite/python/util.py586def _remove_tensors_from_model(model, remove_tensors_idxs):CODE
LOWtflite/python/util.py84def _convert_tflite_enum_type_to_tf_type(tflite_enum_type):CODE
LOWtflite/python/util.py130def get_tensors_from_tensor_names(graph, tensor_names):CODE
LOWtflite/python/util.py262def _convert_op_hints_if_present(sess, graph_def, output_tensors,CODE
LOWtflite/python/util.py421def convert_bytes_to_c_source(data,CODE
LOWtflite/python/util.py549def _convert_model_from_object_to_bytearray(model_object):CODE
LOWtflite/python/util.py649def _modify_model_input_type_per_subgraph(model, subgraph_index,CODE
LOWtflite/python/util.py741def _modify_model_output_type(model, inference_output_type=dtypes.float32):CODE
LOWtflite/python/util.py756def _modify_model_output_type_per_subgraph(model, subgraph_index,CODE
LOWtflite/python/util.py864def _remove_redundant_quantize_ops(model):CODE
1086 more matches not shown…
Docstring Block Structure104 hits · 520 pts
SeverityFileLineSnippetContext
HIGHconfigure.py284Get boolean input from user. If var_name is not set in env, ask user to enable query_item or not. If the response iSTRING
HIGHconfigure.py572Loop over user prompts for an ENV param until receiving a valid response. For the env param var_name, read from the eSTRING
HIGH…tal/microfrontend/python/ops/audio_microfrontend_op.py51Audio Microfrontend Op. This Op converts a sequence of audio data into one or more feature vectors containing filteSTRING
HIGHtflite/tools/flatbuffer_utils.py46Reads a tflite model as a python object. Args: input_tflite_file: Full path name to the input tflite file RaisSTRING
HIGHtflite/tools/flatbuffer_utils.py98Reads a tflite model as a python object with mutable tensors. Similar to read_model() with the addition that the retuSTRING
HIGHtflite/tools/flatbuffer_utils.py272Converts xxd output C++ source file to bytes (immutable). Args: input_cc_file: Full path name to th C++ source fiSTRING
HIGHtflite/tools/flatbuffer_utils.py311Converts xxd output C++ source file to object. Args: input_cc_file: Full path name to th C++ source file dumped bSTRING
HIGHtflite/tools/flatbuffer_utils.py471Get the options of an operator as the specified type. Requested type must be an object-api type (ends in 'T'). ArgSTRING
HIGHtflite/tools/visualize.py461Returns html description with the given tflite model. Args: tflite_input: TFLite flatbuffer model path or model oSTRING
HIGH…te/tools/optimize/python/modify_model_interface_lib.py23Converts a tflite type to it's integer representation. Args: dtype: tf.DType representing the inference type. STRING
HIGHtflite/tools/optimize/debugging/python/debugger.py138Runs the TFLite debugging model with given debug options. Args: quant_debug_model_path: Path to the quantizedSTRING
HIGHtflite/python/convert_saved_model.py29Validate saved_model and extract MetaGraphDef. Args: saved_model_dir: saved_model path to convert. tag_set: SSTRING
HIGHtflite/python/convert_saved_model.py46Get the signature def from meta_graph with given signature_key. Args: meta_graph: meta_graph_def. signature_kSTRING
HIGHtflite/python/convert_saved_model.py92Gets the tensors associated with the tensor names. Either signature_def_tensor_names or user_tensor_names should be pSTRING
HIGHtflite/python/convert_saved_model.py136Converts a SavedModel to a frozen graph. Args: saved_model_dir: SavedModel directory to convert. input_arraysSTRING
HIGHtflite/python/util.py85Converts tflite enum type (eg: 0) to tf type (eg: tf.float32). Args: tflite_enum_type: tflite enum type (eg: 0, tSTRING
HIGHtflite/python/util.py131Gets the Tensors associated with the `tensor_names` in the provided graph. Args: graph: TensorFlow Graph. tenSTRING
HIGHtflite/python/util.py944Modify the input/output type of a tflite model. Args: model: A tflite model. inference_input_type: tf.DType rSTRING
HIGHtflite/python/op_hint.py200Return the next unused argument index in order or use an override. Args: index_override: An index to use STRING
HIGHtflite/python/op_hint.py226Return a wrapped tensor of an input tensor as an argument. Args: arg: A TensorFlow tensor that should be STRING
HIGHtflite/python/op_hint.py480This adds the node(s) to out_graphdef and returns the input node name. Args: out_graphdef: A graphdef that isSTRING
HIGHtflite/python/op_hint.py496Add node(s) to graph representing output operands and returns type. Args: fused_op_name: name of the fused opSTRING
HIGHtflite/python/op_hint.py1246Find all Ophints output nodes in the graph. This is used to get all the output nodes those are ophinted, it is importSTRING
HIGHtflite/python/op_hint.py1302Converts a graphdef with LiteOp hints into stub operations. This is used to prepare for toco conversion of complex inSTRING
HIGHtflite/python/convert.py67Convert tensor type from tf type to tflite type. Args: tf_type: TensorFlow type. usage: Text describing the rSTRING
HIGHtflite/python/convert.py111Convert inference type from tf type to tflite type. Args: tf_type: TensorFlow type. usage: Text describing thSTRING
HIGHtflite/python/convert.py361Converts `input_data_str` to a TFLite model. Args: model_flags: Proto describing model properties, see `model_flaSTRING
HIGHtflite/python/convert.py417Converts `model_dir` to a TFLite model file directly. Args: conversion_flags: Proto describing conversion propertSTRING
HIGHtflite/python/convert.py550Builds protocol buffer describing a conversion of a model. Typically this is to convert from TensorFlow GraphDef to TSTRING
HIGHtflite/python/convert.py850Convert a frozen GraphDef that can't be loaded in TF. Conversion can be customized by providing arguments that are foSTRING
HIGHtflite/python/convert.py916Convert a frozen GraphDef model using the TF Lite converter. Conversion can be customized by providing arguments thatSTRING
HIGHtflite/python/convert.py1046Convert a TensorFlow GraphDef to TFLite. This function is deprecated. Please use `tf.lite.TFLiteConverter` API insteaSTRING
HIGHtflite/python/convert_phase.py166The decorator to identify converter component and subcomponent. Args: component: Converter component name. suSTRING
HIGHtflite/python/interpreter.py139Returns loaded Delegate object. Example usage: ``` import tensorflow as tf try: delegate = tf.lite.experiSTRING
HIGHtflite/python/interpreter.py637Gets tensor details. Args: tensor_index: Tensor index of tensor to query. subgraph_index: Index of the STRING
HIGHtflite/python/interpreter.py889Gets callable for inference of specific SignatureDef. Example usage, ``` interpreter = tf.lite.Interpreter(STRING
HIGHtflite/python/lite.py1482Converts a TensorFlow GraphDef based on instance variables. Args: graph_def: Frozen TensorFlow GraphDef. STRING
HIGHtflite/python/lite.py2262Creates a TFLiteConverter object from ConcreteFunctions. Args: funcs: List of TensorFlow ConcreteFunctions. TSTRING
HIGHtflite/python/lite.py2304Creates a TFLiteConverter object from a SavedModel directory. Args: saved_model_dir: SavedModel directory to STRING
HIGHtflite/python/lite.py3274Creates a TFLiteConverter class from a file containing a frozen GraphDef. Args: graph_def_file: Full filepathSTRING
HIGHtflite/python/tflite_keras_util.py193Trace the model call to create a tf.function for exporting a Keras model. Args: model: A Keras model. input_sSTRING
HIGHtflite/testing/zip_test_utils.py260Given a dictionary of `examples`, write a text format representation. The file format is protocol-buffer-like, even tSTRING
HIGHtflite/testing/zip_test_utils.py375Helper to make a zip file of a bunch of TensorFlow models. This does a cartesian product of the dictionary of test_paSTRING
HIGHtflite/schema/upgrade_schema.py103Read a tflite model assuming the given flatbuffer schema. If `input_file` is in bin, then we must use flatc to convSTRING
HIGHtflite/schema/upgrade_schema.py229Remap operator structs from old names to new names. Args: operator_type: String representing the builtin STRING
HIGHlitert_quantizer/litert_quantizer/params_generator.py75Generate the quantization parameters for the model. Args: model_recipe_manager: The recipe manager for the moSTRING
HIGHlitert_quantizer/litert_quantizer/params_generator.py336Check buffer sharing for the tensor against itself. Args: tensor: The tensor to check. Returns: WhSTRING
HIGHlitert_quantizer/litert_quantizer/params_generator.py369Checks that self-compatible tensors have the same quantization params. Self-compatible means that all tensor's consSTRING
HIGH…rt_quantizer/litert_quantizer/algorithm_manager_api.py301Returns the list of supported ops for the given algorithm. Args: alg_key: Algorithm key. Returns: STRING
HIGHlitert_quantizer/litert_quantizer/quantizer.py376Calibrates the float model (required by static range quantization). Args: calibration_data: Calibration data STRING
HIGHlitert_quantizer/litert_quantizer/quantizer.py448Quantizes the float model. Also prints a report summarizing the quantization process after the process is done.STRING
HIGHlitert_quantizer/litert_quantizer/calibrator.py220Creates a new instance of the appropriate calibrator subclass. Args: float_tflite: The path to the TFLite modSTRING
HIGH…tert_quantizer/transformation_instruction_generator.py705Split the instructions into subsets by tensor duplication. Splits the instructions into subsets based on which tensSTRING
HIGH…er/litert_quantizer/transformations/insert_multiply.py26Inserts an elementwise MUL op on this tensor for activation scaling. This function works for float32 tensors. It inseSTRING
HIGH…_quantizer/transformations/insert_hadamard_rotation.py63Inserts a custom aeq.hadamard_rotation op on this tensor. This function works for float32 tensors only. Args: STRING
HIGH…transformations/insert_decomposed_hadamard_rotation.py61Generates a Hadamard matrix of the given size. Args: size: The size of the Hadamard matrix. Must be a power of 2.STRING
HIGH…transformations/insert_decomposed_hadamard_rotation.py87Inserts a decomposed pattern of Hadamard rotation on this tensor. This function works for float32 tensors only. InsteSTRING
HIGH…/litert_quantizer/algorithms/uniform_quantize/oscar.py466Returns the quantization parameters for a tensor. For weight tensors, replaces the max-abs bound with OSCAR's activSTRING
HIGH…tizer/algorithms/uniform_quantize/hadamard_rotation.py49Generates a Hadamard matrix of the given size. Hadamard matrices are square matrices with entries +1 or -1 and orthogSTRING
HIGH…tizer/algorithms/uniform_quantize/hadamard_rotation.py98Quantizes the given float array using the diagonal Hadamard algorithm. Args: tensor_content: The float array to qSTRING
44 more matches not shown…
Unused Imports434 hits · 298 pts
SeverityFileLineSnippetContext
LOWtflite/converter/python/wrap_converter.py18CODE
LOWtflite/python/wrap_toco.py18CODE
LOWtflite/python/lite.py34CODE
LOWtflite/python/lite.py37CODE
LOWtflite/python/lite.py38CODE
LOWtflite/python/lite.py49CODE
LOWtflite/python/lite.py52CODE
LOWtflite/python/lite.py54CODE
LOWtflite/python/lite.py59CODE
LOWtflite/python/lite.py60CODE
LOWtflite/python/lite.py61CODE
LOWtflite/python/lite.py63CODE
LOWtflite/python/lite.py65CODE
LOWtflite/python/lite.py87CODE
LOWtflite/python/lite.py88CODE
LOWtflite/python/metrics/wrapper/metrics_wrapper.py19CODE
LOWtflite/testing/generate_examples_lib.py41CODE
LOWtflite/testing/generate_examples_lib.py42CODE
LOWtflite/testing/generate_examples_lib.py43CODE
LOWtflite/testing/generate_examples_lib.py44CODE
LOWtflite/testing/generate_examples_lib.py45CODE
LOWtflite/testing/generate_examples_lib.py46CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py47CODE
LOWtflite/testing/generate_examples_lib.py48CODE
LOWtflite/testing/generate_examples_lib.py49CODE
LOWtflite/testing/generate_examples_lib.py50CODE
LOWtflite/testing/generate_examples_lib.py51CODE
LOWtflite/testing/generate_examples_lib.py52CODE
LOWtflite/testing/generate_examples_lib.py53CODE
LOWtflite/testing/generate_examples_lib.py54CODE
LOWtflite/testing/generate_examples_lib.py55CODE
LOWtflite/testing/generate_examples_lib.py56CODE
LOWtflite/testing/generate_examples_lib.py57CODE
LOWtflite/testing/generate_examples_lib.py58CODE
LOWtflite/testing/generate_examples_lib.py59CODE
LOWtflite/testing/generate_examples_lib.py60CODE
LOWtflite/testing/generate_examples_lib.py61CODE
LOWtflite/testing/generate_examples_lib.py62CODE
LOWtflite/testing/generate_examples_lib.py63CODE
LOWtflite/testing/generate_examples_lib.py64CODE
LOWtflite/testing/generate_examples_lib.py64CODE
LOWtflite/testing/generate_examples_lib.py64CODE
LOWtflite/testing/generate_examples_lib.py65CODE
LOWtflite/testing/generate_examples_lib.py66CODE
LOWtflite/testing/generate_examples_lib.py67CODE
LOWtflite/testing/generate_examples_lib.py68CODE
LOWtflite/testing/generate_examples_lib.py69CODE
LOWtflite/testing/generate_examples_lib.py71CODE
LOWtflite/testing/generate_examples_lib.py72CODE
LOWtflite/testing/generate_examples_lib.py73CODE
LOWtflite/testing/generate_examples_lib.py74CODE
LOWtflite/testing/generate_examples_lib.py75CODE
LOWtflite/testing/generate_examples_lib.py76CODE
374 more matches not shown…
Self-Referential Comments86 hits · 284 pts
SeverityFileLineSnippetContext
MEDIUMtflite/tools/visualize.py32 # This file is part of tensorflow package.COMMENT
MEDIUMtflite/tools/visualize.py35 # This file is part of tflite_runtime package.COMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py34 # Define the initial modelCOMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py79 # Define the initial modelCOMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py127 # Define the initial modelCOMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py167 # Define the initial modelCOMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py211 # Define the initial modelCOMMENT
MEDIUMtflite/tools/flatbuffer_utils_test.py243 # Define the initial modelCOMMENT
MEDIUM…ols/optimize/python/modify_model_interface_lib_test.py56 # Define the temporary directory and filesCOMMENT
MEDIUM…ols/optimize/python/modify_model_interface_lib_test.py91 # Define the temporary directory and filesCOMMENT
MEDIUM…ols/optimize/python/modify_model_interface_lib_test.py128 # Define the temporary directory and filesCOMMENT
MEDIUMtflite/tools/optimize/debugging/python/debugger_test.py75 # Create a TFLite model with new quantizer and numeric verify ops.COMMENT
MEDIUMtflite/python/util.py828 # Create a quantize operator, if none existCOMMENT
MEDIUMtflite/python/op_hint.py1022 # Create the functionCOMMENT
MEDIUMtflite/python/convert.py1172 # Create a map of duplicate buffers (same size and same type).COMMENT
MEDIUM⚡tflite/python/analyzer.py22 # This file is part of tensorflow package.COMMENT
MEDIUM⚡tflite/python/analyzer.py27 # This file is part of tflite_runtime package.COMMENT
MEDIUMtflite/python/util_test.py229 # Define a pseudo MNIST dataset (as downloading the dataset on-the-fly causesCOMMENT
MEDIUMtflite/python/interpreter.py28 # This file is part of tensorflow package.COMMENT
MEDIUMtflite/python/interpreter.py33 # This file is part of tflite_runtime package.COMMENT
MEDIUMtflite/python/interpreter.py44# This file is part of the ai_edge_litert package.COMMENT
MEDIUMtflite/python/lite_flex_test.py78 # Create a graph that has one L2Loss op.COMMENT
MEDIUMtflite/python/lite_flex_test.py212 # Create a graph that has one add op.COMMENT
MEDIUMtflite/python/lite_flex_test.py254 # Create a graph that has one double op.COMMENT
MEDIUM⚡tflite/python/lite_v2_test.py1289 # Create a TFLite model with new quantizer.COMMENT
MEDIUM⚡tflite/python/lite_v2_test.py1293 # Create a TFLite model with new quantizer and numeric verify ops.COMMENT
MEDIUMtflite/python/lite_v2_test.py1887 # Create a v1 saved model with hash table initializers.COMMENT
MEDIUMtflite/python/lite_v2_test.py1976 # Create a v1 saved model with mutable hash table.COMMENT
MEDIUMtflite/python/lite_v2_test.py3315 # Create a simple Keras model.COMMENT
MEDIUMtflite/python/lite_v2_test.py3347 # Create a simple Keras model.COMMENT
MEDIUMtflite/python/lite_v2_test.py3388 # Create a simple Keras model.COMMENT
MEDIUMtflite/python/lite_v2_test.py5170 # Create a graph that has one double op.COMMENT
MEDIUMtflite/python/metrics/metrics_nonportable_test.py436 # Create a graph that has one add op.COMMENT
MEDIUM⚡tflite/python/metrics/metrics_portable.py22 # This file is part of tensorflow package.COMMENT
MEDIUM⚡tflite/python/metrics/metrics_portable.py25 # This file is part of tflite_runtime package.COMMENT
MEDIUM⚡tflite/python/optimize/calibrator_test.py248 # Define a simple model to run calibration with.COMMENT
MEDIUMtflite/testing/op_tests/fully_connected_4bit_hybrid.py52 # Create a float filter with no quantization loss.COMMENT
MEDIUMlitert_quantizer/litert_quantizer/litert_quantizer.py94 # Create the output directory if it doesn't already exist.COMMENT
MEDIUMlitert_quantizer/litert_quantizer/litert_quantizer.py139 # Create a filename for the quantized TFLite model.COMMENT
MEDIUMlitert_quantizer/litert_quantizer/litert_quantizer.py208 # Create the output directory if it doesn't already exist.COMMENT
MEDIUMlitert_quantizer/litert_quantizer/calibrator_test.py272 # Create a legacy format file (just the dict)COMMENT
MEDIUMlitert_quantizer/litert_quantizer/calibrator_test.py291 # Create a file with custom metadataCOMMENT
MEDIUM⚡…tert_quantizer/transformations/transformation_utils.py153 # Create a new `qtyping.BufferT` object.COMMENT
MEDIUM…er/algorithms/uniform_quantize/common_quantize_test.py167 # Create a mock tfl_op with inputs and outputsCOMMENT
MEDIUM…litert_quantizer/algorithms/utils/common_utils_test.py503 # Create a mock op with multiple outputs.COMMENT
MEDIUM…ntizer/litert_quantizer/utils/constrained_ops_utils.py85 # Create a dummy op info to trigger the materialization.COMMENT
MEDIUMlitert_quantizer/litert_quantizer/utils/recipe_utils.py38# Create a mapping of recipe names to parsed JSON files.COMMENT
MEDIUM…ert_quantizer/litert_quantizer/utils/litertlm_utils.py235 # Create a memory-mapped file in which we will pack the LiteRTLM file.COMMENT
MEDIUM⚡…_quantizer/litert_quantizer/utils/recipe_utils_test.py72 # Create a copy of the original recipe and mark it as such.COMMENT
MEDIUM⚡…_quantizer/litert_quantizer/utils/recipe_utils_test.py75 # Create an output directory outside of `cwd` and `recipes/` that willCOMMENT
MEDIUM⚡…_quantizer/litert_quantizer/utils/recipe_utils_test.py82 # Create a litertlm recipe mapping.COMMENT
MEDIUMlitert/support_lib/metadata/python/metadata.py159 # Creating the deleting such a tempfile is handled by the class,COMMENT
MEDIUMlitert/support_lib/metadata/python/metadata.py793# Create an individual method for getting the metadata json file, so that it canCOMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py66 # Create a model with two inputs and one output, which matches the metadataCOMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py100 # Create a model with two inputs and one output.COMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py429 # Create a model with two inputs and one output.COMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py493 # Create a dummy metadata without Subgraph.COMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py509 # Create a dummy metadata with no input tensor metadata, while the expectedCOMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py530 # Create a dummy metadata with no output tensor metadata, while the expectedCOMMENT
MEDIUM…ert/support_lib/metadata/python/tests/metadata_test.py551 # Create a src model with metadata and two associated files.COMMENT
26 more matches not shown…
Hallucination Indicators20 hits · 220 pts
SeverityFileLineSnippetContext
CRITICAL⚡tflite/python/lite.py3189 session. converter = tf.compat.v1.lite.TFLiteConverter.from_session( sess,STRING
CRITICAL⚡tflite/python/lite.py3193 tf.compat.v1.lite.TFLiteConverter.from_frozen_graph( graph_def_file,STRING
CRITICAL⚡tflite/python/lite.py3197 tf.compat.v1.lite.TFLiteConverter.from_saved_model( saved_model_dir)STRING
CRITICAL⚡tflite/python/lite.py3200 tf.compat.v1.lite.TFLiteConverter.from_keras_model_file( keras_model)STRING
CRITICAL⚡tflite/python/lite_v2_test.py1906 tensor_info_x = tf.compat.v1.saved_model.utils.build_tensor_info(x)CODE
CRITICAL⚡tflite/python/lite_v2_test.py1907 tensor_info_y = tf.compat.v1.saved_model.utils.build_tensor_info(y)CODE
CRITICAL⚡tflite/python/lite_v2_test.py1911 'serving_default': tf.compat.v1.saved_model.signature_def_utils.build_signature_def( # pylint: disable=lineCODE
CRITICAL⚡tflite/python/lite_v2_test.py1997 tensor_info_x = tf.compat.v1.saved_model.utils.build_tensor_info(x)CODE
CRITICAL⚡tflite/python/lite_v2_test.py1998 tensor_info_y = tf.compat.v1.saved_model.utils.build_tensor_info(y)CODE
CRITICAL⚡tflite/python/lite_v2_test.py2002 'serving_default': tf.compat.v1.saved_model.signature_def_utils.build_signature_def( # pylint: disable=lineCODE
CRITICALtflite/python/lite_v2_test.py1924 builder = tf.compat.v1.saved_model.builder.SavedModelBuilder(CODE
CRITICALtflite/python/lite_v2_test.py2014 builder = tf.compat.v1.saved_model.builder.SavedModelBuilder(CODE
CRITICALtflite/testing/zip_test_utils.py356 tensor_info = tf.compat.v1.saved_model.utils.build_tensor_info(tensor)CODE
CRITICALtflite/testing/zip_test_utils.py598 tf.compat.v1.saved_model.signature_def_utils.build_signature_def(CODE
CRITICALtflite/testing/zip_test_utils.py605 builder = tf.compat.v1.saved_model.builder.SavedModelBuilder(CODE
CRITICALtflite/testing/op_tests/dynamic_rnn.py49 lstm_cell = tf.compat.v1.nn.rnn_cell.BasicLSTMCell(CODE
CRITICALtflite/testing/op_tests/unfused_gru.py39 cell_fw = tf.compat.v1.nn.rnn_cell.GRUCell(parameters["units"])CODE
CRITICALtflite/testing/op_tests/unfused_gru.py40 cell_bw = tf.compat.v1.nn.rnn_cell.GRUCell(parameters["units"])CODE
CRITICALtflite/testing/op_tests/lstm.py57 lstm_cell = tf.compat.v1.nn.rnn_cell.BasicLSTMCell(CODE
CRITICAL…te/testing/op_tests/static_rnn_with_control_flow_v2.py54 lstm_cell = tf.compat.v1.nn.rnn_cell.BasicLSTMCell(CODE
Cross-File Repetition36 hits · 180 pts
SeverityFileLineSnippetContext
HIGHtflite/tools/flatbuffer_utils.py0converts a numerical enum value to a readable tensor type.STRING
HIGHtflite/tools/visualize.py0converts a numerical enum value to a readable tensor type.STRING
HIGHlitert/python/tools/flatbuffer_utils.py0converts a numerical enum value to a readable tensor type.STRING
HIGHtflite/tools/pip_package/setup_with_binary.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/setup_with_binary.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/vendor_sdk/qualcomm/setup.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/vendor_sdk/samsung/setup.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/vendor_sdk/mediatek/setup.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/vendor_sdk/google_tensor/setup.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/wheel/setup_with_binary.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGHci/tools/python/wheel/converter_setup_with_binary.py0litert is for mobile and embedded devices. litert is the official solution for running machine learning models on mobileSTRING
HIGH…quantizer/tests/end_to_end_tests/concatenation_test.py0e2e tests for the quantizer for model with transpose.STRING
HIGH…ert_quantizer/tests/end_to_end_tests/transpose_test.py0e2e tests for the quantizer for model with transpose.STRING
HIGH…/litert_quantizer/tests/end_to_end_tests/split_test.py0e2e tests for the quantizer for model with transpose.STRING
HIGH…er/litert_quantizer/tests/end_to_end_tests/sum_test.py0e2e tests for the quantizer for model with transpose.STRING
HIGH…r_sdk/qualcomm/ai_edge_litert_sdk_qualcomm/__init__.py0returns the absolute path to the root of the downloaded sdk files.STRING
HIGH…dor_sdk/samsung/ai_edge_litert_sdk_samsung/__init__.py0returns the absolute path to the root of the downloaded sdk files.STRING
HIGH…r_sdk/mediatek/ai_edge_litert_sdk_mediatek/__init__.py0returns the absolute path to the root of the downloaded sdk files.STRING
HIGH…le_tensor/ai_edge_litert_sdk_google_tensor/__init__.py0returns the absolute path to the root of the downloaded sdk files.STRING
HIGH…b/metadata/python/metadata_writers/image_classifier.py0creates metadatawriter based on general/input/output information. args: model_buffer: valid buffer of the model file. geSTRING
HIGH…_lib/metadata/python/metadata_writers/nl_classifier.py0creates metadatawriter based on general/input/output information. args: model_buffer: valid buffer of the model file. geSTRING
HIGH…metadata/python/metadata_writers/bert_nl_classifier.py0creates metadatawriter based on general/input/output information. args: model_buffer: valid buffer of the model file. geSTRING
HIGH…b/metadata/python/metadata_writers/audio_classifier.py0creates metadatawriter based on general/input/output information. args: model_buffer: valid buffer of the model file. geSTRING
HIGH…b/metadata/python/metadata_writers/image_classifier.py0creates mandatory metadata for litert support inference. the parameters required in this method are mandatory when usingSTRING
HIGH…ib/metadata/python/metadata_writers/object_detector.py0creates mandatory metadata for litert support inference. the parameters required in this method are mandatory when usingSTRING
HIGH…ib/metadata/python/metadata_writers/image_segmenter.py0creates mandatory metadata for litert support inference. the parameters required in this method are mandatory when usingSTRING
HIGHlitert/python/tools/model_utils/dialect/tfl/_arg_min.py0returns the axis value if 'dim' is constant, otherwise the ssavalue.STRING
HIGH…t/python/tools/model_utils/dialect/tfl/_expand_dims.py0returns the axis value if 'dim' is constant, otherwise the ssavalue.STRING
HIGHlitert/python/tools/model_utils/dialect/tfl/_arg_max.py0returns the axis value if 'dim' is constant, otherwise the ssavalue.STRING
HIGHlitert/python/aot/vendors/qualcomm/qualcomm_backend.py0backend implementation for the example compiler plugin..STRING
HIGHlitert/python/aot/vendors/example/example_backend.py0backend implementation for the example compiler plugin..STRING
HIGHlitert/python/aot/vendors/mediatek/mediatek_backend.py0backend implementation for the example compiler plugin..STRING
HIGHlitert/python/aot/vendors/qualcomm/qualcomm_backend.py0backend implementation for the example compiler plugin.STRING
HIGHlitert/python/aot/vendors/example/example_backend.py0backend implementation for the example compiler plugin.STRING
HIGHlitert/python/aot/vendors/samsung/samsung_backend.py0backend implementation for the example compiler plugin.STRING
HIGHlitert/python/aot/vendors/mediatek/mediatek_backend.py0backend implementation for the example compiler plugin.STRING
Redundant / Tautological Comments65 hits · 105 pts
SeverityFileLineSnippetContext
LOWconfigure.py196 # Check if the path is validCOMMENT
LOWconfigure.py456 # Check if current bazel version can be detected properly.COMMENT
LOWconfigure.py969 # Check if current clang version can be detected properly.COMMENT
LOWtflite/tools/build_aar.sh59 # Check if the file exist.COMMENT
LOWtflite/tools/build_aar.sh170# Check if users already run configureCOMMENT
LOWtflite/python/util.py1135 # Check if metadata has already been populated.COMMENT
LOWtflite/python/lite.py508 # Check if representative_dataset is specified.COMMENT
LOWtflite/python/lite.py3338 # Check if graph is frozen.COMMENT
LOW⚡tflite/python/lite_v2_test.py1302 # Check if adding debug mode should output a different flatbuffer.COMMENT
LOW⚡tflite/python/lite_v2_test.py1305 # Check if newly added ops are numeric verify ops.COMMENT
LOWtflite/schema/upgrade_schema.py256 # Check if builtin_code is the appropriate string typeCOMMENT
LOWlitert_quantizer/litert_quantizer/params_generator.py438 # Check if any of the tensors needs to be duplicated.COMMENT
LOWlitert_quantizer/litert_quantizer/params_generator.py444 # Check if the buffer needs to be duplicated.COMMENT
LOW…rt_quantizer/litert_quantizer/algorithm_manager_api.py175 # Check if an op quantization config is supported for a given algorithm.COMMENT
LOWlitert_quantizer/litert_quantizer/recipe_test.py172 # Check if the quantized models match.COMMENT
LOW⚡litert_quantizer/litert_quantizer/calibrator_test.py238 # Check if internal counter is updated.COMMENT
LOW⚡litert_quantizer/litert_quantizer/quantizer_test.py435 # Check if the quant config is supported by default policy.COMMENT
LOW⚡litert_quantizer/litert_quantizer/quantizer_test.py442 # Check if the quant config fails on dummy policy.COMMENT
LOWlitert_quantizer/litert_quantizer/quantizer_test.py457 # Check if the quant config is supported by example policy in *.json file.COMMENT
LOW…tert_quantizer/transformations/quantize_tensor_test.py253 # Check if the scale and zero point tensors are inserted correctly.COMMENT
LOW⚡…tert_quantizer/transformations/transformation_utils.py139 # Check if the model has a buffer lookup mapping, and if not, add one.COMMENT
LOW⚡…tert_quantizer/transformations/transformation_utils.py147 # Check if we already have a buffer for this data.COMMENT
LOW…ithms/uniform_quantize/uniform_quantize_tensor_test.py391 # Check if it is safe to cast int64 bias to int32. We save the int32COMMENT
LOW…ert_quantizer/algorithms/uniform_quantize/gptq_test.py247 # Check if scales and zp are correctly calculated.COMMENT
LOW…ert_quantizer/algorithms/uniform_quantize/gptq_test.py375 # Check if scales and zp are correctly calculated.COMMENT
LOW…antizer/algorithms/uniform_quantize/common_quantize.py338 # Check if SRQ.COMMENT
LOW…antizer/algorithms/uniform_quantize/common_quantize.py385 # Check if SRQ.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py94 # Check if SRQ.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py153 # Check if SRQ.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py387 # Check if SRQ.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py404 # Check if WEIGHT_ONLY.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py429 # Check if SRQ.COMMENT
LOW…s/uniform_quantize/op_architecture_tests/test_utils.py448 # Check if SRQ.COMMENT
LOW…rm_quantize/op_architecture_tests/batch_matmul_test.py215 # Check if SRQ.COMMENT
LOW…rm_quantize/op_architecture_tests/batch_matmul_test.py278 # Check if SRQ.COMMENT
LOW…quantize/op_architecture_tests/fully_connected_test.py111 # Check if SRQ.COMMENT
LOW…izer/litert_quantizer/algorithms/utils/common_utils.py125 # Check if find op_config in policy config_check_policy.COMMENT
LOW…izer/litert_quantizer/algorithms/utils/common_utils.py1096 # Check if SRQ.COMMENT
LOW…izer/litert_quantizer/algorithms/utils/common_utils.py1109 # Check if DRQ.COMMENT
LOW…izer/litert_quantizer/algorithms/utils/common_utils.py1118 # Check if WEIGHT_ONLY.COMMENT
LOW⚡…litert_quantizer/algorithms/utils/common_utils_test.py435 # Check if DRQ.COMMENT
LOW⚡…litert_quantizer/algorithms/utils/common_utils_test.py443 # Check if WEIGHT_ONLY.COMMENT
LOW⚡…litert_quantizer/algorithms/utils/common_utils_test.py449 # Check if SRQ.COMMENT
LOW…litert_quantizer/algorithms/utils/common_utils_test.py63 # Check if WEIGHT_ONLY.COMMENT
LOW…litert_quantizer/algorithms/utils/common_utils_test.py81 # Check if DRQ.COMMENT
LOW…litert_quantizer/algorithms/utils/common_utils_test.py93 # Check if SRQ.COMMENT
LOW…litert_quantizer/algorithms/utils/common_utils_test.py419 # Check if DRQ and CONV_2D.COMMENT
LOW…antizer/algorithms/nonlinear_quantize/float_casting.py66 # Check if WEIGHT_ONLY.COMMENT
LOWlitert_quantizer/litert_quantizer/tests/mnist_test.py275 # Check if the output model has `integer-only` tensors.COMMENT
LOW⚡…r/litert_quantizer/utils/tfl_interpreter_utils_test.py401 # Check if we cover a reasonable range (probability check)COMMENT
LOWlitert/integration_test/device_script_common.sh41# Print message and exit.COMMENT
LOWlitert/support_lib/metadata/python/metadata.py569 # Check if metadata has already been populated.COMMENT
LOWlitert/support_lib/metadata/python/metadata.py624 # Verify if the number of tensor metadata matches the number of tensors.COMMENT
LOW…ert/support_lib/metadata/python/tests/metadata_test.py274 # Check if the model buffer read from file is the same as that read fromCOMMENT
LOW…ert/support_lib/metadata/python/tests/metadata_test.py328 # Check if the model buffer read from file is the same as that read fromCOMMENT
LOW…/python/tests/metadata_writers/metadata_writer_test.py178 # Verify if the metadata populated is correct.COMMENT
LOW…/python/tests/metadata_writers/metadata_writer_test.py185 # Verify if the associated file is packed as expected.COMMENT
LOWlitert/python/tools/flatbuffer_utils_test.py335 # Check if the pack model's data is updated.COMMENT
LOWlitert/python/tools/mmap_utils.py167 # Write the file in chunks to avoid creating large internal buffers.COMMENT
LOWlitert/python/tools/model_utils/core/utils.py108 # Check if the type is signless (or signed)COMMENT
5 more matches not shown…
Structural Annotation Overuse60 hits · 94 pts
SeverityFileLineSnippetContext
LOW…litert/_agents/skills/litert_ats_op_generator/SKILL.md57### Step 0: Classify the Op & Verify PrerequisitesCOMMENT
LOW…litert/_agents/skills/litert_ats_op_generator/SKILL.md144### Step 1: Author the Generator (`test/generators/<op>.h` & `test/generators/BUILD`)COMMENT
LOW…litert/_agents/skills/litert_ats_op_generator/SKILL.md249### Step 2: Export in `generators.h` & `test/generators/BUILD`COMMENT
LOW…litert/_agents/skills/litert_ats_op_generator/SKILL.md261### Step 3: Register the Op in ATS (`litert/ats/`)COMMENT
LOW…litert/_agents/skills/litert_ats_op_generator/SKILL.md299### Step 4: Run Mandatory Verification Gates & Configure Backend ExclusionsCOMMENT
LOWtflite/CMakeLists.txt19# WARNING: This is an experimental that is subject to change.COMMENT
LOWtflite/kernels/internal/runtime_shape.h204 // NOTE: This function does not handle potential integer overflow. UseCOMMENT
LOWtflite/core/subgraph.h561 // NOTE: This function is expected to be paired with ReleaseSubgraphContext()COMMENT
LOWtflite/core/subgraph.h574 // NOTE: This function is expected to be used after AcquireSubgraphContext()COMMENT
LOWtflite/core/subgraph.h591 // NOTE: This function is expected to be called only when the subgraph thatCOMMENT
LOWtflite/core/subgraph.h622 // NOTE: This function is expected to be called only when this subgraph willCOMMENT
LOWtflite/core/interpreter.h241 /// NOTE: This function does not affect cancellation triggered by the callbackCOMMENT
LOWtflite/core/async/c/task.h60/// NOTE: This method does not check tensor index is pointing to a valid tensor.COMMENT
LOWtflite/core/async/c/task.h118/// NOTE: This method does not check tensor index is pointing to aCOMMENT
LOWtflite/core/c/c_api.h542/// NOTE: This function is similar to TfLiteInterpreterResizeInputTensorStrict()COMMENT
LOWtflite/core/c/c_api.h547/// NOTE: This function makes a copy of the input dimensions, so the caller canCOMMENT
LOWtflite/core/c/c_api_opaque.h559/// NOTE: This function is expected to be paired withCOMMENT
LOWtflite/core/c/c_api_opaque.h572/// NOTE: This function is expected to be used afterCOMMENT
LOWtflite/core/c/c_api_opaque.h590/// NOTE: This function is expected to be called only when the subgraph thatCOMMENT
LOW⚡tflite/core/c/common.h1573// NOTE: This function is part of the TensorFlow Lite Extension APIs, see above.COMMENT
LOW⚡tflite/core/c/common.h1579// NOTE: This function is part of the TensorFlow Lite Extension APIs, see above.COMMENT
LOW⚡tflite/core/c/common.h1585// NOTE: This function is part of the TensorFlow Lite Extension APIs, see above.COMMENT
LOWtflite/core/c/common.h1134 /// NOTE: This function is expected to be paired with ReleaseSubgraphContext()COMMENT
LOWtflite/core/c/common.h1145 /// NOTE: This function is expected to be used after AcquireSubgraphContext()COMMENT
LOWtflite/converter/kernels/internal/runtime_shape.h202 // NOTE: This function does not handle potential integer overflow.COMMENT
LOWtflite/python/convert.py177 # WARNING: These ops are currently experimental and have not yet beenCOMMENT
LOWtflite/delegates/utils.h47// NOTE: This function is expected to be paired with ReleaseSubgraphContext()COMMENT
LOWtflite/delegates/utils.h56// NOTE: This function is expected to be used after AcquireSubgraphContext()COMMENT
LOWtflite/delegates/utils.h70// NOTE: This function is expected to be called only when the subgraph thatCOMMENT
LOW…le_delegate/sample_stable_delegate_with_control_flow.h70 // NOTE: This function is expected to be called recursively to gather all theCOMMENT
LOWlitert_quantizer/README.md214### Step 1: Initialize Quantizer with Source ModelCOMMENT
LOWlitert_quantizer/README.md225### Step 2: Choose & Load a Quantization RecipeCOMMENT
LOWlitert_quantizer/README.md267### Step 3: Calibrate with Representative Data (Static Quantization Only)COMMENT
LOWlitert_quantizer/README.md353### Step 4: Quantize & Export the ModelCOMMENT
LOWlitert_quantizer/README.md366### Step 5: Validate Numerical AccuracyCOMMENT
LOWlitert_quantizer/README.md401### Step 6: Visualize Models with Model ExplorerCOMMENT
LOWlitert_quantizer/README.md414### Step 7: Deploy on Edge HardwareCOMMENT
LOW…tert_quantizer/experimental/skills/auto_quant/SKILL.md94### Step 1: Context & Role DeclarationCOMMENT
LOW…tert_quantizer/experimental/skills/auto_quant/SKILL.md105### Step 2: Technical Design & File ListCOMMENT
LOW…tert_quantizer/experimental/skills/auto_quant/SKILL.md113### Step 3: Experiment Harness ArchitectureCOMMENT
LOW…tert_quantizer/experimental/skills/auto_quant/SKILL.md130### Step 4: Verification PlanCOMMENT
LOW…tert_quantizer/experimental/skills/auto_quant/SKILL.md140### Step 5: Post-Execution WalkthroughCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md33### Step 1: Install DependenciesCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md57### Step 2: Clone and BuildCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md71### Step 3: Verify InstallationCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md82### Step 1: Install PrerequisitesCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md95### Step 2: Build for macOSCOMMENT
LOW⚡docs/instructions/BUILD_INSTRUCTIONS.md115### Step 1: Install PrerequisitesCOMMENT
LOW⚡docs/instructions/BUILD_INSTRUCTIONS.md121### Step 2: Configure EnvironmentCOMMENT
LOW⚡docs/instructions/BUILD_INSTRUCTIONS.md131### Step 3: Build for WindowsCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md161### Step 1: Install Android Development ToolsCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md179### Step 2: Build for Android with BazelCOMMENT
LOWdocs/instructions/BUILD_INSTRUCTIONS.md201### Step 3: Test Accelerator Support for AndroidCOMMENT
LOWdocs/instructions/GPU_BUILD_INSTRUCTIONS.md19## Step 1: Clone the LiteRT RepositoryCOMMENT
LOWdocs/instructions/GPU_BUILD_INSTRUCTIONS.md33## Step 2: Build the Android GPU AcceleratorCOMMENT
LOWdocs/instructions/GPU_BUILD_INSTRUCTIONS.md47## Step 3: Locate Build Artifacts & Deploy to DeviceCOMMENT
LOWtensor/backends/testing/README.md30### Step 1: Implement `TestBackendBridge`COMMENT
LOWtensor/backends/testing/README.md83### Step 2: Define Backend TraitsCOMMENT
LOWtensor/backends/testing/README.md97### Step 3: Instantiate the SuiteCOMMENT
LOWtensor/backends/testing/README.md113### Step 4: Update the BUILD targetCOMMENT
Deep Nesting104 hits · 86 pts
SeverityFileLineSnippetContext
LOWconfigure.py260CODE
LOWconfigure.py275CODE
LOWconfigure.py1021CODE
LOWconfigure.py1128CODE
LOWconfigure.py1262CODE
LOWtflite/tools/flatbuffer_utils.py358CODE
LOWtflite/tools/randomize_weights.py49CODE
LOWtflite/tools/zip_files.py27CODE
LOWtflite/tools/visualize.py318CODE
LOWtflite/tools/visualize.py422CODE
LOWtflite/tools/optimize/debugging/python/debugger.py332CODE
LOWtflite/python/util.py173CODE
LOWtflite/python/util.py332CODE
LOWtflite/python/util.py649CODE
LOWtflite/python/util.py756CODE
LOWtflite/python/util.py876CODE
LOWtflite/python/util.py1013CODE
LOWtflite/python/util.py1116CODE
LOWtflite/python/util.py343CODE
LOWtflite/python/op_hint.py828CODE
LOWtflite/python/op_hint.py932CODE
LOWtflite/python/op_hint.py1059CODE
LOWtflite/python/op_hint.py1168CODE
LOWtflite/python/op_hint.py558CODE
LOWtflite/python/convert.py915CODE
LOWtflite/python/convert.py1071CODE
LOWtflite/python/util_test.py301CODE
LOWtflite/python/lite.py596CODE
LOWtflite/python/lite.py1355CODE
LOWtflite/python/lite.py1649CODE
LOWtflite/python/lite.py2550CODE
LOWtflite/python/lite.py3271CODE
LOWtflite/python/lite_v2_test.py3580CODE
LOWtflite/python/lite_v2_test.py4875CODE
LOWtflite/python/lite_v2_test.py4876CODE
LOWtflite/python/tflite_keras_util.py55CODE
LOWtflite/python/optimize/calibrator.py97CODE
LOWtflite/testing/zip_test_utils.py114CODE
LOWtflite/testing/zip_test_utils.py145CODE
LOWtflite/testing/zip_test_utils.py259CODE
LOWtflite/testing/zip_test_utils.py368CODE
LOWtflite/testing/mlir_convert.py30CODE
LOWtflite/testing/mlir_convert.py143CODE
LOWtflite/schema/upgrade_schema.py147CODE
LOWtflite/schema/upgrade_schema.py265CODE
LOWlitert_quantizer/litert_quantizer/recipe_manager.py157CODE
LOW…quantizer/litert_quantizer/transformation_performer.py148CODE
LOWlitert_quantizer/litert_quantizer/params_generator.py69CODE
LOWlitert_quantizer/litert_quantizer/params_generator.py210CODE
LOWlitert_quantizer/litert_quantizer/calibrator.py501CODE
LOWlitert_quantizer/litert_quantizer/model_validator.py280CODE
LOWlitert_quantizer/litert_quantizer/qtyping.py447CODE
LOWlitert_quantizer/litert_quantizer/model_modifier.py219CODE
LOW…tert_quantizer/transformation_instruction_generator.py247CODE
LOW…tert_quantizer/transformation_instruction_generator.py407CODE
LOW…tert_quantizer/transformation_instruction_generator.py701CODE
LOWlitert_quantizer/litert_quantizer/default_policy.py326CODE
LOW…rt_quantizer/litert_quantizer/params_generator_test.py608CODE
LOW…tert_quantizer/transformations/transformation_utils.py80CODE
LOW…algorithms/uniform_quantize/uniform_quantize_tensor.py48CODE
44 more matches not shown…
AI Slop Vocabulary22 hits · 56 pts
SeverityFileLineSnippetContext
MEDIUMtflite/types/half.h24// known to be at least a robust f16<->f32 conversion, which generally means aCOMMENT
MEDIUMtflite/python/convert.py780 # leverage defaults specified in proto definition.COMMENT
MEDIUMtflite/python/lite_v2_test.py596 # the bias tensor should be 32 bits to utilize optimized kernels,COMMENT
MEDIUM…delegates/gpu/common/tasks/mean_stddev_normalization.h68// provide more stable and robust resultsCOMMENT
MEDIUM…delegates/gpu/common/tasks/mean_stddev_normalization.h133// provide more stable and robust resultsCOMMENT
MEDIUMlitert_quantizer/litert_quantizer/calibrator_test.py606 # operator and rank of the tensor. We flatten them here for robustCOMMENT
LOW…tert_quantizer/transformations/transformation_utils.py100 # If the model already has the op code, just return the index.COMMENT
LOWci/run_bazel_build.sh240 # buildable. To avoid creating new TAP targets, simply add benchmarkCOMMENT
LOWci/tools/python/vendor_sdk/google_tensor/setup.py106 # If we simply return None, the build process will continue, which isCOMMENT
LOW⚡ci/tools/python/vendor_sdk/google_tensor/setup.py213 # If we simply return None, the build process will continue, whichCOMMENT
LOW⚡ci/tools/python/vendor_sdk/google_tensor/setup.py229 # If we simply return None, the build process will continue, which is notCOMMENT
MEDIUM…/vendors/intel_openvino/dispatch/weight_bank_runtime.h59 // are matched by the Parameter's friendly_name, so binding is robust to inputCOMMENT
MEDIUM…endors/intel_openvino/compiler/weights_to_parameters.h36// its pool buffer by friendly_name (robust to input reordering across import).COMMENT
MEDIUMlitert/vendors/intel_openvino/compiler/global_graph.h38// at dispatch (matched by name so binding is robust to input reordering acrossCOMMENT
MEDIUM…ndors/intel_openvino/compiler/alias_shared_constants.h46// robust guard -- no need to enumerate which transforms alter content.COMMENT
MEDIUMlitert/vendors/google_tensor/dispatch/sb_api.h91// implementation to utilize a proprietary fence, which generally have superiorCOMMENT
MEDIUMlitert/core/dispatch_op_schema.h21// functions leverage the flexbuffer api under the hood which allows for inplaceCOMMENT
LOW⚡litert/python/tools/mmap_utils_test.py242 # This should not raise any exception and should just return.COMMENT
LOWlitert/python/tools/mmap_utils_test.py306 # This should not raise any exception and should just return.COMMENT
LOWlitert/python/aot/ai_pack/export_lib.py164 # Skip non-MTK targets, just create a placeholder file.COMMENT
MEDIUMlitert/cc/internal/litert_c_types_printing.h33/// @todo Migrate the code in `tools/dump.h` to leverage the Abseil stringifyCOMMENT
MEDIUMml_drift_delegate/delegate/delegate_options.h215 // If true, the weights rearrangement, if supported, will utilize GPU.COMMENT
Empty Error Handlers10 hits · 50 pts
SeverityFileLineSnippetContext
HIGHtflite/python/convert.py146except UnicodeDecodeError:CODE
HIGHtflite/python/interpreter.py734except ValueError:CODE
HIGHtflite/python/lite_v2_test.py5311except ValueError:CODE
HIGH…/vendor_sdk/intel/ai_edge_litert_sdk_intel/__init__.py110except OSError:CODE
HIGH…/vendor_sdk/intel/ai_edge_litert_sdk_intel/__init__.py125except OSError:CODE
HIGHlitert/python/tools/benchmark_litert_model.py86except ImportError:CODE
HIGH…n/aot/vendors/intel_openvino/intel_openvino_backend.py51except FileNotFoundError:CODE
HIGH…n/aot/vendors/intel_openvino/intel_openvino_backend.py63except (ModuleNotFoundError, TypeError):CODE
HIGH…n/aot/vendors/intel_openvino/intel_openvino_backend.py190except ImportError:CODE
HIGHlitert/python/aot/core/apply_plugin.py170except OSError:CODE
Excessive Try-Catch Wrapping42 hits · 46 pts
SeverityFileLineSnippetContext
MEDIUMconfigure.py1286 print('Error retrieving bazel version: ', e.output.decode('UTF-8').strip())CODE
LOWtflite/python/util.py1151 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/convert.py386 except Exception as e:CODE
LOWtflite/python/convert.py437 except Exception as e:CODE
LOWtflite/python/convert_phase.py213 except Exception as error:CODE
MEDIUMtflite/python/convert_phase.py203def wrapper(*args, **kwargs):CODE
LOWtflite/python/lite.py1202 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py1714 except Exception as error: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py1794 except Exception as e: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py1957 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py2120 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py2639 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/lite.py2974 except Exception: # pylint: disable=broad-exceptCODE
LOWtflite/python/optimize/calibrator.py80 except Exception as e:CODE
LOWtflite/testing/mlir_convert.py137 except Exception as e: # pylint: disable=broad-exceptCODE
LOW…izer/litert_quantizer/algorithms/utils/common_utils.py288 except Exception as e:CODE
MEDIUMci/tools/python/vendor_sdk/sdist_wrapper.py174 print("Error running setup.py sdist:", file=sys.stderr)CODE
LOWci/tools/python/vendor_sdk/intel/setup.py303 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/vendor_sdk/intel/setup.py326 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/vendor_sdk/qualcomm/setup.py85 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/vendor_sdk/qualcomm/setup.py186 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOW…r_sdk/qualcomm/ai_edge_litert_sdk_qualcomm/__init__.py57 except Exception as e: # pylint: disable=broad-exception-caughtCODE
MEDIUM…r_sdk/qualcomm/ai_edge_litert_sdk_qualcomm/__init__.py58 print(f"Error determining SDK path: {e}", file=sys.stderr)CODE
LOWci/tools/python/vendor_sdk/samsung/setup.py73 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/vendor_sdk/samsung/setup.py174 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOW…dor_sdk/samsung/ai_edge_litert_sdk_samsung/__init__.py59 except Exception as e: # pylint: disable=broad-exception-caughtCODE
MEDIUM…dor_sdk/samsung/ai_edge_litert_sdk_samsung/__init__.py60 print(f"Error determining SDK path: {e}", file=sys.stderr)CODE
LOWci/tools/python/vendor_sdk/mediatek/setup.py71 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/vendor_sdk/mediatek/setup.py176 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOW…r_sdk/mediatek/ai_edge_litert_sdk_mediatek/__init__.py78 except Exception as e: # pylint: disable=broad-exception-caughtCODE
MEDIUM…r_sdk/mediatek/ai_edge_litert_sdk_mediatek/__init__.py79 print(f"Error determining SDK path: {e}", file=sys.stderr)CODE
LOWci/tools/python/vendor_sdk/google_tensor/setup.py99 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOW⚡ci/tools/python/vendor_sdk/google_tensor/setup.py223 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOW…le_tensor/ai_edge_litert_sdk_google_tensor/__init__.py61 except Exception as e: # pylint: disable=broad-exception-caughtCODE
MEDIUM…le_tensor/ai_edge_litert_sdk_google_tensor/__init__.py62 print(f"Error determining SDK path: {e!r}", file=sys.stderr)CODE
LOWci/tools/python/wheel/setup_with_binary.py80 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/wheel/setup_with_binary.py131 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWci/tools/python/wheel/converter_setup_with_binary.py71 except Exception as e: # pylint: disable=broad-exception-caughtCODE
LOWlitert/vendors/nvidia/run_head.sh285 except Exception as exc: errors.append(str(exc))CODE
MEDIUMlitert/vendors/nvidia/run_head.sh266def sample():CODE
LOWlitert/python/litert_wrapper/simple_accel_smoke_test.py192 except Exception as exc:CODE
LOW.github/workflows/clang_tidy.yml138 except Exception:CODE
Synthetic Comment Markers5 hits · 38 pts
SeverityFileLineSnippetContext
HIGHlitert/vendors/broadcom/example/CMakeLists.txt2# Portions generated by AICOMMENT
HIGHlitert/vendors/broadcom/dispatch/CMakeLists.txt2# Portions generated by AICOMMENT
HIGHlitert/vendors/broadcom/common/CMakeLists.txt2# Portions generated by AICOMMENT
HIGHlitert/vendors/broadcom/compiler/CMakeLists.txt2# Portions generated by AICOMMENT
HIGHlitert/python/tools/model_utils/dialect/tfl/_fill.py102 # Do not check ndim as requestedCOMMENT
AI Structural Patterns33 hits · 27 pts
SeverityFileLineSnippetContext
LOW…tal/microfrontend/python/ops/audio_microfrontend_op.py28CODE
LOWtflite/tools/optimize/debugging/python/debugger_test.py46CODE
LOWtflite/python/convert.py263CODE
LOWtflite/python/convert.py490CODE
LOWtflite/python/convert.py909CODE
LOWtflite/python/convert.py997CODE
LOWtflite/python/convert.py1013CODE
LOWtflite/python/convert.py1040CODE
LOWtflite/python/interpreter.py402CODE
LOWtflite/python/lite_v2_test.py293CODE
LOWtflite/python/lite_v2_test.py919CODE
LOWtflite/python/lite_v2_test.py1425CODE
LOWtflite/python/lite_v2_test.py5341CODE
LOWtflite/python/lite_v2_test.py5379CODE
LOWtflite/python/metrics/metrics_nonportable_test.py192CODE
LOWtflite/testing/op_tests/conv_activation.py146CODE
LOWtflite/testing/op_tests/conv_bias_activation.py73CODE
LOWtflite/testing/op_tests/conv_bias_activation.py78CODE
LOWlitert_quantizer/litert_quantizer/tests/mnist_test.py51CODE
LOW…quantizer/tests/end_to_end_tests/strided_slice_test.py45CODE
LOW…/litert_quantizer/tests/end_to_end_tests/rsqrt_test.py47CODE
LOW…quantizer/tests/end_to_end_tests/concatenation_test.py45CODE
LOW…er/litert_quantizer/tests/end_to_end_tests/add_test.py52CODE
LOW…tert_quantizer/tests/end_to_end_tests/logistic_test.py43CODE
LOW…/litert_quantizer/tests/end_to_end_tests/split_test.py45CODE
LOW…_quantizer/tests/end_to_end_tests/input_output_test.py49CODE
LOW…r/litert_quantizer/tests/end_to_end_tests/mean_test.py45CODE
LOW…ntizer/tests/end_to_end_tests/conv2d_transpose_test.py44CODE
LOW…on/tools/model_utils/dialect/tfl/_depthwise_conv_2d.py50CODE
LOWlitert/python/tools/model_utils/dialect/tfl/_conv_2d.py50CODE
LOWtensor/examples/gemma4/helpers/reference/attention.py42CODE
LOW…nsor/examples/gemma4/helpers/reference/gemma4_graph.py81CODE
LOWtensor/examples/gemma4/helpers/reference/transformer.py29CODE
Example Usage Blocks15 hits · 23 pts
SeverityFileLineSnippetContext
LOW…imental/acceleration/compatibility/gpu_compatibility.h39// Example usage:COMMENT
LOW⚡tflite/testing/zip_test_utils.py47# Usage:COMMENT
LOWtflite/delegates/gpu/api.h19// Usage example:COMMENT
LOWtflite/delegates/gpu/common/task/util.h60// Example usage:COMMENT
LOWtflite/delegates/gpu/cl/api.h33// Usage example:COMMENT
LOWlitert/rust/example/segmentation_async_main.rs19/// Example usage:COMMENT
LOWlitert/rust/example/segmentation_main.rs19/// Example usage:COMMENT
LOWlitert/rust/src/environment.rs63/// Example usage:COMMENT
LOWlitert/tflite_support/op_resolver/op_resolver.h31/// Example usage:COMMENT
LOWlitert/tflite_support/custom_op/custom_op.h29/// Example usage:COMMENT
LOWlitert/tflite_support/custom_op/custom_op.h44/// Example usage:COMMENT
LOWlitert/cc/litert_options.h340 /// Example usage:COMMENT
LOWlitert/c/options/litert_runtime_options.h25// Example usage:COMMENT
LOWdocker_build/build_wheel_with_docker.sh21# Usage:COMMENT
LOWdocker_build/setup_bazel_env.sh21# Usage:COMMENT
Fake / Example Data8 hits · 10 pts
SeverityFileLineSnippetContext
LOW⚡tflite/testing/op_tests/mirror_pad.py46 "type": ["placeholder"],CODE
LOW⚡tflite/testing/op_tests/mirror_pad.py53 "type": ["placeholder"],CODE
LOW⚡tflite/testing/op_tests/mirror_pad.py60 "type": ["placeholder"],CODE
LOWtflite/testing/op_tests/mirror_pad.py82 "type": ["placeholder"],CODE
LOW⚡…ntizer/litert_quantizer/utils/constrained_ops_utils.py54 dummy_value = [qtyping.TensorTransformationParams("")] * 2CODE
LOW⚡…ntizer/litert_quantizer/utils/constrained_ops_utils.py55 return dummy_valueCODE
LOWlitert/python/tools/mmap_utils_test.py52 b'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod'CODE
LOWlitert/python/tools/mmap_utils_test.py52 b'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod'CODE
Cross-Language Confusion2 hits · 8 pts
SeverityFileLineSnippetContext
HIGHtflite/tools/visualize.py158 d.fx = d.fy = null;CODE
HIGH…t_quantizer/litert_quantizer/utils/validation_utils.py166 KL(data2 || data1) = sum(data2 * log(data2 / data1)).STRING
Modern Structural Boilerplate7 hits · 7 pts
SeverityFileLineSnippetContext
LOWlitert/python/tools/model_utils/model_builder.py25__all__ = [CODE
LOW…/python/tools/model_utils/core/_op_building_context.py23__all__ = ["OpBuildingContext"]CODE
LOWlitert/python/tools/model_utils/core/dialect_base.py27__all__ = [CODE
LOWlitert/python/tools/model_utils/core/pass_base.py24__all__ = ["ModulePassBase", "RewritePatternPassBase"]CODE
LOWlitert/python/tools/model_utils/core/utils.py21__all__ = [CODE
LOW…ython/tools/model_utils/match/_match_dag/tblgen_def.py25__all__ = ["registry"]CODE
LOWlitert/python/mlir/__init__.py20__all__ = []CODE
Slop Phrases2 hits · 3 pts
SeverityFileLineSnippetContext
LOWtflite/python/lite.py1595 # We make sure to clear the saved_model_dir as there is someCOMMENT
LOWlitert/c/internal/litert_runtime_c_api.h42// don't forget to also bump the ABI version number.COMMENT
Modern AI Meta-Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMlitert/vendors/qualcomm/README.md93 1. [Bring state-of-the-art agentic skills to the edge with Gemma 4](https://developers.googleblog.com/bring-state-oCODE