{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D6","name":"Cohesion (LCOM4)","shortDescription":{"text":"Cohesion (LCOM4)"},"helpUri":"https://codehealth.canine.dev/dimensions/D6"},{"id":"D11","name":"Test Reliability","shortDescription":{"text":"Test Reliability"},"helpUri":"https://codehealth.canine.dev/dimensions/D11"},{"id":"D12","name":"Dependency Hygiene","shortDescription":{"text":"Dependency Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/D12"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"],"owasp":"A07:2025"}},{"id":"D14","name":"License Compliance","shortDescription":{"text":"License Compliance"},"helpUri":"https://codehealth.canine.dev/dimensions/D14"},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D17","name":"Explicit Debt","shortDescription":{"text":"Explicit Debt"},"helpUri":"https://codehealth.canine.dev/dimensions/D17"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"id":"D27","name":"Navigability","shortDescription":{"text":"Navigability"},"helpUri":"https://codehealth.canine.dev/dimensions/D27"},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"],"owasp":"A05:2025"}},{"id":"D30","name":"Dependency Vulnerabilities","shortDescription":{"text":"Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D30","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"],"owasp":"A03:2025"}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D36","name":"Supply-chain Provenance \u0026 Signing","shortDescription":{"text":"Supply-chain Provenance \u0026 Signing"},"helpUri":"https://codehealth.canine.dev/dimensions/D36","relationships":[{"target":{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1357","CWE-494"],"owasp":"A03:2025"}},{"id":"D43","name":"Malicious Dependencies","shortDescription":{"text":"Malicious Dependencies"},"helpUri":"https://codehealth.canine.dev/dimensions/D43","relationships":[{"target":{"id":"CWE-506","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-506"],"owasp":"A08:2025"}},{"id":"D44","name":"Platform End-of-Life","shortDescription":{"text":"Platform End-of-Life"},"helpUri":"https://codehealth.canine.dev/dimensions/D44"},{"id":"AX10","name":"Code composition","shortDescription":{"text":"Code composition"},"helpUri":"https://codehealth.canine.dev/dimensions/AX10"},{"id":"AX3","name":"Project dependency cycles","shortDescription":{"text":"Project dependency cycles"},"helpUri":"https://codehealth.canine.dev/dimensions/AX3"},{"id":"AX4","name":"Dependency direction","shortDescription":{"text":"Dependency direction"},"helpUri":"https://codehealth.canine.dev/dimensions/AX4"},{"id":"AXB2","name":"Runtime readiness","shortDescription":{"text":"Runtime readiness"},"helpUri":"https://codehealth.canine.dev/dimensions/AXB2"},{"id":"ED5","name":"Idempotency","shortDescription":{"text":"Idempotency"},"helpUri":"https://codehealth.canine.dev/dimensions/ED5"},{"id":"M1","name":"Documentation (README)","shortDescription":{"text":"Documentation (README)"},"helpUri":"https://codehealth.canine.dev/dimensions/M1"},{"id":"M2","name":"Architecture documentation","shortDescription":{"text":"Architecture documentation"},"helpUri":"https://codehealth.canine.dev/dimensions/M2"},{"id":"M3","name":"Folder \u0026 project structure","shortDescription":{"text":"Folder \u0026 project structure"},"helpUri":"https://codehealth.canine.dev/dimensions/M3"},{"id":"P1","name":"CI/CD gates","shortDescription":{"text":"CI/CD gates"},"helpUri":"https://codehealth.canine.dev/dimensions/P1"},{"id":"P10","name":"Library API \u0026 versioning","shortDescription":{"text":"Library API \u0026 versioning"},"helpUri":"https://codehealth.canine.dev/dimensions/P10"},{"id":"P12","name":"CI test-gate honesty","shortDescription":{"text":"CI test-gate honesty"},"helpUri":"https://codehealth.canine.dev/dimensions/P12"},{"id":"P3","name":"Security \u0026 performance tooling","shortDescription":{"text":"Security \u0026 performance tooling"},"helpUri":"https://codehealth.canine.dev/dimensions/P3"},{"id":"P4","name":"Deployment \u0026 Rollback","shortDescription":{"text":"Deployment \u0026 Rollback"},"helpUri":"https://codehealth.canine.dev/dimensions/P4"},{"id":"P6","name":"Release Hygiene","shortDescription":{"text":"Release Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/P6"},{"id":"PF1","name":"Benchmark discipline","shortDescription":{"text":"Benchmark discipline"},"helpUri":"https://codehealth.canine.dev/dimensions/PF1"},{"id":"PF3","name":"Async \u0026 latency hygiene","shortDescription":{"text":"Async \u0026 latency hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/PF3"},{"id":"S1","name":"Web-Security Posture","shortDescription":{"text":"Web-Security Posture"},"helpUri":"https://codehealth.canine.dev/dimensions/S1"},{"id":"X1","name":"Async correctness","shortDescription":{"text":"Async correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/X1"},{"id":"X10","name":"Duplicated predicate","shortDescription":{"text":"Duplicated predicate"},"helpUri":"https://codehealth.canine.dev/dimensions/X10"},{"id":"X12","name":"Unreachable branch","shortDescription":{"text":"Unreachable branch"},"helpUri":"https://codehealth.canine.dev/dimensions/X12"},{"id":"X13","name":"Undrained process stream","shortDescription":{"text":"Undrained process stream"},"helpUri":"https://codehealth.canine.dev/dimensions/X13"},{"id":"X14","name":"Bypassable address classification","shortDescription":{"text":"Bypassable address classification"},"helpUri":"https://codehealth.canine.dev/dimensions/X14"},{"id":"X15","name":"Unvalidated length from an untrusted reader","shortDescription":{"text":"Unvalidated length from an untrusted reader"},"helpUri":"https://codehealth.canine.dev/dimensions/X15"},{"id":"X16","name":"Unfloored truncation loop","shortDescription":{"text":"Unfloored truncation loop"},"helpUri":"https://codehealth.canine.dev/dimensions/X16"},{"id":"X17","name":"Uncapped recursion over a caller-supplied document","shortDescription":{"text":"Uncapped recursion over a caller-supplied document"},"helpUri":"https://codehealth.canine.dev/dimensions/X17"},{"id":"X18","name":"Disposal-pattern correctness","shortDescription":{"text":"Disposal-pattern correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/X18"},{"id":"X19","name":"Unrestored process-global state","shortDescription":{"text":"Unrestored process-global state"},"helpUri":"https://codehealth.canine.dev/dimensions/X19"},{"id":"X2","name":"Cancellation propagation","shortDescription":{"text":"Cancellation propagation"},"helpUri":"https://codehealth.canine.dev/dimensions/X2"},{"id":"X20","name":"Mistyped argument guard","shortDescription":{"text":"Mistyped argument guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X20"},{"id":"X21","name":"Side-effecting pattern guard","shortDescription":{"text":"Side-effecting pattern guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X21"},{"id":"X22","name":"Contradicted release guard","shortDescription":{"text":"Contradicted release guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X22"},{"id":"X23","name":"Unguarded diagnostic materialisation","shortDescription":{"text":"Unguarded diagnostic materialisation"},"helpUri":"https://codehealth.canine.dev/dimensions/X23"},{"id":"X24","name":"Document value interpolated into markup unescaped","shortDescription":{"text":"Document value interpolated into markup unescaped"},"helpUri":"https://codehealth.canine.dev/dimensions/X24"},{"id":"X25","name":"Inert configuration knob","shortDescription":{"text":"Inert configuration knob"},"helpUri":"https://codehealth.canine.dev/dimensions/X25"},{"id":"X26","name":"Unsynchronised callback handoff","shortDescription":{"text":"Unsynchronised callback handoff"},"helpUri":"https://codehealth.canine.dev/dimensions/X26"},{"id":"X27","name":"Collection changed while being enumerated","shortDescription":{"text":"Collection changed while being enumerated"},"helpUri":"https://codehealth.canine.dev/dimensions/X27"},{"id":"X28","name":"Index access outside its own emptiness guard","shortDescription":{"text":"Index access outside its own emptiness guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X28"},{"id":"X29","name":"Per-element action decided by a fixed element","shortDescription":{"text":"Per-element action decided by a fixed element"},"helpUri":"https://codehealth.canine.dev/dimensions/X29"},{"id":"X3","name":"Exception handling","shortDescription":{"text":"Exception handling"},"helpUri":"https://codehealth.canine.dev/dimensions/X3"},{"id":"X30","name":"Support guard that admits what it rejects","shortDescription":{"text":"Support guard that admits what it rejects"},"helpUri":"https://codehealth.canine.dev/dimensions/X30"},{"id":"X32","name":"Type resolved by simple name across every loaded assembly","shortDescription":{"text":"Type resolved by simple name across every loaded assembly"},"helpUri":"https://codehealth.canine.dev/dimensions/X32"},{"id":"X4","name":"Structured logging","shortDescription":{"text":"Structured logging"},"helpUri":"https://codehealth.canine.dev/dimensions/X4"},{"id":"X6","name":"Hand-rolled structured-format parsing","shortDescription":{"text":"Hand-rolled structured-format parsing"},"helpUri":"https://codehealth.canine.dev/dimensions/X6"},{"id":"X7","name":"Silent fallback defaults","shortDescription":{"text":"Silent fallback defaults"},"helpUri":"https://codehealth.canine.dev/dimensions/X7"},{"id":"X9","name":"Subsumed condition operand","shortDescription":{"text":"Subsumed condition operand"},"helpUri":"https://codehealth.canine.dev/dimensions/X9"}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"KeyPoints.select (cyclomatic 42): KeyPoints.select has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1169}}}],"partialFingerprints":{"codehealthFindingId/v1":"31916a94a6c00e658846532ac62512b2796f5d7c33eaec1a5897923ce60fc2be"}},{"ruleId":"D1","level":"warning","message":{"text":"_video._mux_audio (cyclomatic 31): _video._mux_audio has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_video.py"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8af58e3e4a778ec80f221d0e25129efadb2050bc7d292042387caaeb27800e2"}},{"ruleId":"D1","level":"warning","message":{"text":"Detections.from_sam3 (cyclomatic 25): Detections.from_sam3 has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"9247dc11724dcea8718fb9e9a5905f681638dfba9a5a11bb1c9718deaf7fc2dd"}},{"ruleId":"D1","level":"warning","message":{"text":"_ConfusionMatrixMetric._compute (cyclomatic 25): _ConfusionMatrixMetric._compute has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"70eec4f12bec8d439691219e9cbc9dc36d655f498a67c27afdb2a8ccf30bb83e"}},{"ruleId":"D1","level":"warning","message":{"text":"InferenceSlicer.__call__ (cyclomatic 23): InferenceSlicer.__call__ has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"977a95e337e000f40b81432fa38f5154e5b531a32ab83930425588dd1fd0e82f"}},{"ruleId":"D1","level":"warning","message":{"text":"internal.process_roboflow_result (cyclomatic 22): internal.process_roboflow_result has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (internal.process_roboflow_result) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d50d7f39ff5b5e0b88734cbd4e26fa86266bb5bf9a05010e31b1b57f07f68a1"}},{"ruleId":"D1","level":"warning","message":{"text":"internal.process_roboflow_result (cyclomatic 22): internal.process_roboflow_result has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (internal.process_roboflow_result) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ea1711b5991773bdffe28ef7ee766b655125b31b8350a57e19b605c28e06d95"}},{"ruleId":"D1","level":"warning","message":{"text":"yolo.detections_to_yolo_annotations (cyclomatic 21): yolo.detections_to_yolo_annotations has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/yolo.py"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"e14b91fbbed899413724f4dbc0113a6910e2cec25f442cd0fac1aa6046472747"}},{"ruleId":"D1","level":"warning","message":{"text":"pycon_copy.document.addEventListener(\u0022DOMContentLoaded\u0022) (cyclomatic 21): pycon_copy.document.addEventListener(\u0022DOMContentLoaded\u0022) has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to 5 function items inside it that branch (handleSelectionCopy, a function literal at line 82, handleCopyButtonClick, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/javascripts/pycon_copy.js"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ce4f5724ce011d0566f1091e73617c8165e0c620194e630738bdd200a1203bd"}},{"ruleId":"D1","level":"warning","message":{"text":"coco.detections_to_coco_annotations (cyclomatic 20): coco.detections_to_coco_annotations has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/coco.py"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"71100a11ab5872a6ab4572d95b0dc7de613c449a851b8936555af6ec27d4ecac"}},{"ruleId":"D1","level":"warning","message":{"text":"labelme.labelme_shapes_to_detections (cyclomatic 20): labelme.labelme_shapes_to_detections has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/labelme.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"1acd8d3dfa8239079a8293afea7ca826af2a007f1a783bf0bf2f5a1a193942ab"}},{"ruleId":"D1","level":"warning","message":{"text":"COCOEvaluator._accumulate (cyclomatic 20): COCOEvaluator._accumulate has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1057}}}],"partialFingerprints":{"codehealthFindingId/v1":"75be87bb3ba2a2e9578ff8595fbe4d7c1d9f90c27114943b238d2f1f309310a9"}},{"ruleId":"D1","level":"warning","message":{"text":"_geometry._intersect_convex_convex (cyclomatic 19): _geometry._intersect_convex_convex has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_geometry.py"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4d3f8881038b48a1303da1e929adf18566917709472ab6ac9e5076e825a6d33"}},{"ruleId":"D1","level":"warning","message":{"text":"CompactMask.from_coco_rle (cyclomatic 19): CompactMask.from_coco_rle has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":976}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7009575448fa3f28584452e8abbc35da8f4a4d005066e6737c0407112bb1c0e"}},{"ruleId":"D1","level":"warning","message":{"text":"compact_mask._rle_split_cols (cyclomatic 19): compact_mask._rle_split_cols has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"e94b91a6219054256256f159a927f1cda21bfc0b5bb436928e7aa0742c2ba9ed"}},{"ruleId":"D1","level":"warning","message":{"text":"_contours._trace_borders (cyclomatic 17): _contours._trace_borders has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_contours.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c975c83f029a7455516954433ceb7c3609731254ad2266628ba75a98b01e0c6"}},{"ruleId":"D1","level":"warning","message":{"text":"_drawing._clip_line_endpoints (cyclomatic 17): _drawing._clip_line_endpoints has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4c8ff323255861e8b3f7c3d7eff13e1e9a91c20c99435407ea3883c1242263e"}},{"ruleId":"D1","level":"warning","message":{"text":"InferenceSlicer._run_callback_batch (cyclomatic 17): InferenceSlicer._run_callback_batch has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"881059e04a6cdea502f47fdc4e837ffa1f364db96950685776a77d9240b50a36"}},{"ruleId":"D1","level":"warning","message":{"text":"vlm.from_florence_2 (cyclomatic 17): vlm.from_florence_2 has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":518}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe6be75ab19a1572eece261663cf15b2aac0cfd636eff2cd5f44ca2e89c4babf"}},{"ruleId":"D1","level":"warning","message":{"text":"vlm.from_google_gemini_2_5 (cyclomatic 17): vlm.from_google_gemini_2_5 has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"05fa08e7f365661e804f5c708778e668aa2c705ab837d92f84d99fe13f68971b"}},{"ruleId":"D1","level":"warning","message":{"text":"EdgeAnnotator.annotate (cyclomatic 17): EdgeAnnotator.annotate has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"1be1f64face856f757b8ebfe6865e0b8c318553c37b0832cb0727e03a5436c18"}},{"ruleId":"D1","level":"warning","message":{"text":"_color._cvt_color (cyclomatic 16): _color._cvt_color has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_color.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"16c90128d24836bfcd7d4b3d2bb22e07b40cf39a6ac2f8c3e3eaaf8e1a550b00"}},{"ruleId":"D1","level":"warning","message":{"text":"vlm.from_qwen_2_5_vl (cyclomatic 16): vlm.from_qwen_2_5_vl has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"02a291a3cb7dca6b3e302ba9a7f7ba6d198915ca141eb8451c90fbbd2e7445c2"}},{"ruleId":"D1","level":"warning","message":{"text":"KeyPoints.from_mediapipe (cyclomatic 16): KeyPoints.from_mediapipe has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"8239b3320a6963cdbec62bea769b5a5eacff1ad60ad4228945273c36e216f647"}},{"ruleId":"D1","level":"warning","message":{"text":"KeyPoints._get_by_2d_bool_mask (cyclomatic 16): KeyPoints._get_by_2d_bool_mask has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1043}}}],"partialFingerprints":{"codehealthFindingId/v1":"01fe2c7534d91a8d2e7b519ed78b31fd32d80a94ce37a6f746594326ddf4b30e"}},{"ruleId":"D1","level":"warning","message":{"text":"MeanAveragePrecision._prepare_targets (cyclomatic 16): MeanAveragePrecision._prepare_targets has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1620}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4169ebceca5bee1b38a5c79606ba4f7d2f398276dce5b1e0773faf7b02ee916"}},{"ruleId":"D2","level":"warning","message":{"text":"Detections.from_sam3 (cognitive 60): Detections.from_sam3 has cognitive complexity 60 (threshold 15). Drivers by points: if/else 16 (47 pts), boolean chains 7, loops 3 (6 pts) (nesting depth added 34). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"291c17328e1890ab3de680514a4b90259b9c9901259b2341e89fbb88d5ee6cd5"}},{"ruleId":"D2","level":"warning","message":{"text":"_ConfusionMatrixMetric._compute (cognitive 60): _ConfusionMatrixMetric._compute has cognitive complexity 60 (threshold 15). Drivers by points: if/else 17 (51 pts), boolean chains 4, ternaries 1 (4 pts), loops 1 (nesting depth added 37). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"188b46c840712e8de53164c396569d501aa3f9abc56e4058f289cb9cb48cc6d7"}},{"ruleId":"D2","level":"warning","message":{"text":"COCOEvaluator._accumulate (cognitive 58): COCOEvaluator._accumulate has cognitive complexity 58 (threshold 15). Drivers by points: if/else 11 (31 pts), loops 7 (21 pts), ternaries 1 (5 pts), boolean chains 1 (nesting depth added 38). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1057}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f0a5f8b7ab4a1449c68f482e2bff70961ecb117a0b981ffee055e0ee45bf7ae"}},{"ruleId":"D2","level":"warning","message":{"text":"KeyPoints.select (cognitive 52): KeyPoints.select has cognitive complexity 52 (threshold 15). Drivers by points: if/else 23 (37 pts), boolean chains 13, loops 1, ternaries 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1169}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb95ef4e846b640d0a70d26bcf93d04cd581ac760da1d86df3d38c2157ce9171"}},{"ruleId":"D2","level":"warning","message":{"text":"_video._mux_audio (cognitive 48): _video._mux_audio has cognitive complexity 48 (threshold 15). Drivers by points: if/else 14 (24 pts), ternaries 6 (14 pts), boolean chains 7, loops 2, error handling 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_video.py"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"6af44b01ecfc01699893a9da087c084acd52e6f39ee04967538ed0a715d0a4c9"}},{"ruleId":"D2","level":"warning","message":{"text":"coco.detections_to_coco_annotations (cognitive 44): coco.detections_to_coco_annotations has cognitive complexity 44 (threshold 15). Drivers by points: if/else 15 (31 pts), boolean chains 5, error handling 1 (4 pts), ternaries 1 (3 pts), loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/coco.py"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"bff169e5af85017bc35358820445ac34d8be8c405b0e9a4a2a96d36dd326ce0f"}},{"ruleId":"D2","level":"warning","message":{"text":"InferenceSlicer.__call__ (cognitive 44): InferenceSlicer.__call__ has cognitive complexity 44 (threshold 15). Drivers by points: if/else 13 (26 pts), loops 5 (12 pts), boolean chains 6 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"648b06b8a485c5258e79d69b070b5fb0b54b8e35597c5b88958b07c024e4a0b8"}},{"ruleId":"D2","level":"warning","message":{"text":"_drawing._clip_line_endpoints (cognitive 43): _drawing._clip_line_endpoints has cognitive complexity 43 (threshold 15). Drivers by points: if/else 10 (27 pts), ternaries 4 (14 pts), boolean chains 2 (nesting depth added 27). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"55f9953b77ce2e4aa966e5b74e69731fdcce4e8bd34824815c07976be9192f45"}},{"ruleId":"D2","level":"warning","message":{"text":"compact_mask._rle_split_cols (cognitive 42): compact_mask._rle_split_cols has cognitive complexity 42 (threshold 15). Drivers by points: if/else 12 (32 pts), loops 4 (7 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c6ca4fee917b56093c6654cb96af99d1b12c4838d27847075f391031318e2eb"}},{"ruleId":"D2","level":"warning","message":{"text":"labelme.labelme_shapes_to_detections (cognitive 40): labelme.labelme_shapes_to_detections has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (34 pts), ternaries 1 (3 pts), boolean chains 2, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/labelme.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"be99d1733ae381fc5e2c106196d197333d82d4c82273cae0abff5dbd5d58951d"}},{"ruleId":"D2","level":"warning","message":{"text":"_contours._trace_borders (cognitive 39): _contours._trace_borders has cognitive complexity 39 (threshold 15). Drivers by points: if/else 8 (28 pts), loops 4 (7 pts), boolean chains 4 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_contours.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"8499b2b48cd20a89ad477eeee32c613186d4f8a0a474eba8af7db70f354d8b51"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.process_roboflow_result (cognitive 37): internal.process_roboflow_result has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (30 pts), ternaries 4, boolean chains 2, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (internal.process_roboflow_result) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d585a258f07f18abf26225d27836413dfbde35073f2397255417f377a51038a"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.process_roboflow_result (cognitive 37): internal.process_roboflow_result has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (30 pts), ternaries 4, boolean chains 2, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (internal.process_roboflow_result) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dafb093542c0dce6ced2c2c549b6ad429218d9d3f3d071c836fb01c98bafc15"}},{"ruleId":"D2","level":"warning","message":{"text":"yolo.detections_to_yolo_annotations (cognitive 36): yolo.detections_to_yolo_annotations has cognitive complexity 36 (threshold 15). Drivers by points: if/else 12 (25 pts), boolean chains 7, loops 2 (4 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/yolo.py"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6f138a6a2cc566003ae70e1ed25fb9f523ec8e7e8d2a06155e430d049cb9e1d"}},{"ruleId":"D2","level":"warning","message":{"text":"EdgeAnnotator.annotate (cognitive 35): EdgeAnnotator.annotate has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (26 pts), boolean chains 3, loops 2 (3 pts), ternaries 1 (3 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"277bef86ea83b4a36611274986214c147784647e80d06d1e59840457f08bbbc9"}},{"ruleId":"D2","level":"warning","message":{"text":"MeanAveragePrecision._prepare_targets (cognitive 34): MeanAveragePrecision._prepare_targets has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (28 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1620}}}],"partialFingerprints":{"codehealthFindingId/v1":"e33cc7ffe222bba0a5a4003506df603302f677bc5a01dcdc72325fa041c1f803"}},{"ruleId":"D2","level":"warning","message":{"text":"polygon_zone._detections_to_union_mask (cognitive 32): polygon_zone._detections_to_union_mask has cognitive complexity 32 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 3 (12 pts), boolean chains 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/polygon_zone.py"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"21712f4d8e54a69f4c024602eb98720e01e0a70957d86ff52292f2a3df18db7f"}},{"ruleId":"D2","level":"warning","message":{"text":"_drawing._clip_line (cognitive 31): _drawing._clip_line has cognitive complexity 31 (threshold 15). Drivers by points: if/else 7 (14 pts), ternaries 4 (14 pts), boolean chains 3 (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":802}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e8a8f2ec9a332026d737306e5a134105226b1b2aae8f0ec3f267d61ad8ec747"}},{"ruleId":"D2","level":"warning","message":{"text":"CompactMask.from_coco_rle (cognitive 31): CompactMask.from_coco_rle has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (24 pts), boolean chains 4, error handling 1 (2 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":976}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0013930f06352c1e1e9d5ed51a6fefcec21e6a325f61d341a4456010e024d66"}},{"ruleId":"D2","level":"warning","message":{"text":"ConfusionMatrix.plot (cognitive 30): ConfusionMatrix.plot has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 4 (12 pts), loops 2 (5 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/detection.py"},"region":{"startLine":1437}}}],"partialFingerprints":{"codehealthFindingId/v1":"465950d8bebdcecd2d29715e09414c93bdac5995eae42409d470cb233061774d"}},{"ruleId":"D2","level":"warning","message":{"text":"_geometry._intersect_convex_convex (cognitive 29): _geometry._intersect_convex_convex has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (16 pts), ternaries 4 (6 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_geometry.py"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab63f287e281b0ae93158c66cd5ef2bfa7959aaa1af549cfdd7b5fe8647278f1"}},{"ruleId":"D2","level":"warning","message":{"text":"coco.coco_annotations_to_masks (cognitive 29): coco.coco_annotations_to_masks has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (24 pts), loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/coco.py"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"68a70e2b8122843ef37f4dd4d965b90870ad693d3d70260d42c4348414278031"}},{"ruleId":"D2","level":"warning","message":{"text":"InferenceSlicer._run_callback_batch (cognitive 29): InferenceSlicer._run_callback_batch has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 3 (6 pts), boolean chains 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b2a1b69e178d458c03ef67ce1af65b7b4dcd14eb41f1a9ab49f74f17f9b6332"}},{"ruleId":"D2","level":"warning","message":{"text":"vlm.from_florence_2 (cognitive 27): vlm.from_florence_2 has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13 (20 pts), loops 2 (5 pts), ternaries 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":518}}}],"partialFingerprints":{"codehealthFindingId/v1":"974c7171efca775a1d52efe7abce668f3b4b3c824900657b4622c53ed169bf84"}},{"ruleId":"D2","level":"warning","message":{"text":"_drawing._fill_ellipse_arc_mask (cognitive 26): _drawing._fill_ellipse_arc_mask has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":599}}}],"partialFingerprints":{"codehealthFindingId/v1":"d65d3251ef7d45e3bec66f7cabf2bf8a0335d3ff5e50b25d0b4e70ead3e31b09"}},{"ruleId":"D2","level":"warning","message":{"text":"vlm.from_google_gemini_2_5 (cognitive 26): vlm.from_google_gemini_2_5 has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, error handling 1 (3 pts), loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7055948bd0e41234c922bb4f444c9a1fae3a68982222242fe2f249f609a8651"}},{"ruleId":"D2","level":"warning","message":{"text":"MeanAverageRecall._compute (cognitive 26): MeanAverageRecall._compute has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (24 pts), boolean chains 1, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_recall.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"47a2d1462354b82bdfab1fc11202c29769af2c7fb8fb651cb6ba5ca680814270"}},{"ruleId":"D2","level":"warning","message":{"text":"pycon_copy.document.addEventListener(\u0022DOMContentLoaded\u0022) (cognitive 26): pycon_copy.document.addEventListener(\u0022DOMContentLoaded\u0022) has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 4, loops 1, ternaries 1 (nesting depth added 6). None of this is in the body itself: all 26 points belong to 5 function items inside it that branch (a function literal at line 82, handleSelectionCopy, handleCopyButtonClick, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/javascripts/pycon_copy.js"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"c76a8aec2ca08bd0a55d43f096d71b1e6e6e4ac2ac4e3c3446ea5fe4a691c88e"}},{"ruleId":"D2","level":"warning","message":{"text":"_drawing._fill_convex_fixed_point (cognitive 25): _drawing._fill_convex_fixed_point has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":894}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ed66d54d0438a6e0c8ec3255c10180ad56c76fcc90f55bd70b444daa8ad32f0"}},{"ruleId":"D2","level":"warning","message":{"text":"core._merge_detection_group (cognitive 25): core._merge_detection_group has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (17 pts), ternaries 3 (5 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":3375}}}],"partialFingerprints":{"codehealthFindingId/v1":"945604eb63819816711028a7daaacf80578f5a8806d8fb1becc8c1c907f371aa"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.get_data_item (cognitive 25): internal.get_data_item has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (21 pts), ternaries 1 (3 pts), loops 1 (nesting depth added 15). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":977}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc985b9d7450bedbe18b92348d28401a9d4bfc757afa6460d5440417ac8900e5"}},{"ruleId":"D2","level":"warning","message":{"text":"KeyPointMeanAveragePrecision._prepare_targets (cognitive 25): KeyPointMeanAveragePrecision._prepare_targets has cognitive complexity 25 (threshold 15). Drivers by points: if/else 6 (14 pts), ternaries 2 (5 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/keypoint_mean_average_precision.py"},"region":{"startLine":570}}}],"partialFingerprints":{"codehealthFindingId/v1":"f53f5551820f90a50ef530dd5f6108a2b755c5facb8f91a2cf3e6a682fcbfd1b"}},{"ruleId":"D2","level":"warning","message":{"text":"yolo.yolo_annotations_to_detections (cognitive 23): yolo.yolo_annotations_to_detections has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (21 pts), boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/yolo.py"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c188692f135ab3d85e6b226370a856ca1638c2a88012f04a4febec8758e526c"}},{"ruleId":"D2","level":"warning","message":{"text":"vlm.from_qwen_2_5_vl (cognitive 23): vlm.from_qwen_2_5_vl has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (13 pts), error handling 3 (6 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"abf8849b8d1dfff5a8acb59f24875bf07ae3f6c7db4b5910f9ff342620bd952b"}},{"ruleId":"D2","level":"warning","message":{"text":"_color._cvt_color (cognitive 22): _color._cvt_color has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_color.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"b89784c0d5f4b21ba796d0ae4de8b4565df2315b93d4439c65b601c4cc30c148"}},{"ruleId":"D2","level":"warning","message":{"text":"_contours._follow_border (cognitive 22): _contours._follow_border has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_contours.py"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"3781a30fde23dd90175903c7035ebdf451b59070792aad5d2c016e2405c619f3"}},{"ruleId":"D2","level":"warning","message":{"text":"_drawing._fill_polygon_mask (cognitive 22): _drawing._fill_polygon_mask has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 4 (8 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":425}}}],"partialFingerprints":{"codehealthFindingId/v1":"f273ac9733933dd381154c5f1377c1da228ab9565bc4967bbac9713a3f67268e"}},{"ruleId":"D2","level":"warning","message":{"text":"masks.filter_segments_by_distance (cognitive 22): masks.filter_segments_by_distance has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/masks.py"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"29a400817de1d2ff139a5bafade628f51f43a083c88a51846c506d23f0b1e922"}},{"ruleId":"D2","level":"warning","message":{"text":"_geometry._simplify_slices (cognitive 21): _geometry._simplify_slices has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 3 (6 pts), boolean chains 1, ternaries 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_geometry.py"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"c421a096bbfbaadc1481138c20f62079d34a459e1dcfb62bd9c274cce38d04bd"}},{"ruleId":"D2","level":"warning","message":{"text":"TraceAnnotator.annotate (cognitive 21): TraceAnnotator.annotate has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (16 pts), error handling 1 (4 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":2331}}}],"partialFingerprints":{"codehealthFindingId/v1":"276321612bb4b97a5958108d3fc01582e545fe230b50044f99f18e835b72a339"}},{"ruleId":"D2","level":"warning","message":{"text":"yolo_pose.key_points_to_yolo_pose_annotations (cognitive 21): yolo_pose.key_points_to_yolo_pose_annotations has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (14 pts), ternaries 3 (5 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/yolo_pose.py"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"24b8feb1591b0f8ae23e8624f942f07d6fdf4eba4fb90945040673ef3548ba02"}},{"ruleId":"D2","level":"warning","message":{"text":"_BaseVertexEllipseAnnotator._iter_ellipse_params (cognitive 21): _BaseVertexEllipseAnnotator._iter_ellipse_params has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d6a33a28738e0d11abb6a6ea31d33ad9caec077c3442426ea35e37cd0325264"}},{"ruleId":"D2","level":"warning","message":{"text":"detection._split_detections_by_outcome (cognitive 21): detection._split_detections_by_outcome has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (18 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/detection.py"},"region":{"startLine":437}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cfc1d6e8e9cd75a4c17aab0584f30a3fbca95640422340605b8e97797a1d134"}},{"ruleId":"D2","level":"warning","message":{"text":"EvaluationDataset.get_annotation_ids (cognitive 21): EvaluationDataset.get_annotation_ids has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (16 pts), ternaries 2 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"795617a426000b84f230f0c60d2637bb53b61d90f0d240cf82c248c7316b1b27"}},{"ruleId":"D2","level":"warning","message":{"text":"MeanAveragePrecision._prepare_predictions (cognitive 21): MeanAveragePrecision._prepare_predictions has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1710}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e18fdb7a2379b82eeaad2d0a846c11f557efe4fece07f4a13b73f79aa35d3d7"}},{"ruleId":"D2","level":"warning","message":{"text":"file.list_files_with_extensions (cognitive 21): file.list_files_with_extensions has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 3 (7 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/file.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"f19b7007d65f8efab4f3ba967187521c661119966749ed314bf835af29efd66c"}},{"ruleId":"D2","level":"warning","message":{"text":"LineZone.trigger (cognitive 20): LineZone.trigger has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 1, loops 1, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/line_zone.py"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ca2421b985623009743d3531862b8d11fe6108bfd252106e0a2991d8b03f0e4"}},{"ruleId":"D2","level":"warning","message":{"text":"masks._masks_to_roi (cognitive 20): masks._masks_to_roi has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 5, ternaries 1 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/masks.py"},"region":{"startLine":589}}}],"partialFingerprints":{"codehealthFindingId/v1":"92b0834648e682fa5e67057cab421cd8b431d7db25839b5876ef03223388a1cb"}},{"ruleId":"D2","level":"warning","message":{"text":"video.get_video_frames_generator (cognitive 20): video.get_video_frames_generator has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2 (3 pts), error handling 2, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/video.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1028fdb0977fac33e3896472e52b959e0210e561ee1a6a3232eaee643ff14f4"}},{"ruleId":"D2","level":"warning","message":{"text":"pascal_voc.detections_to_pascal_voc (cognitive 19): pascal_voc.detections_to_pascal_voc has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/pascal_voc.py"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aa566ecb05a7b36ef438c22594aa7f1b69bd3e7838200819291eee6a956800a"}},{"ruleId":"D2","level":"warning","message":{"text":"Detections.select (cognitive 19): Detections.select has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 8 (12 pts), if/else 6 (7 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"b762f30060a57dcf895d63b1895754a1832d8a1c0b08364c674516810e9e8781"}},{"ruleId":"D2","level":"warning","message":{"text":"JSONSink.parse_detection_data (cognitive 19): JSONSink.parse_detection_data has cognitive complexity 19 (threshold 15). Drivers by points: loops 3 (7 pts), if/else 4 (6 pts), ternaries 3 (6 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/json_sink.py"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a2ada4cf1003b0f182e7cffd4ddf7c5f7f0cc1d44e8d69f1f619349827bb29c"}},{"ruleId":"D2","level":"warning","message":{"text":"vlm._recover_gemini_json_objects (cognitive 19): vlm._recover_gemini_json_objects has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (12 pts), error handling 1 (4 pts), boolean chains 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f9c3d71f3fe992b9dd2cdc17583a8d0842ff8f9469ef81ae3d6d68c991cd5dd"}},{"ruleId":"D2","level":"warning","message":{"text":"VertexLabelAnnotator.annotate (cognitive 19): VertexLabelAnnotator.annotate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 3 (4 pts), ternaries 1 (2 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":791}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8cc04b06f595f46e5727b34f14162ffc522fc71dbce00c6d16db4d19658d6cb"}},{"ruleId":"D2","level":"warning","message":{"text":"detection.detections_to_tensor (cognitive 19): detection.detections_to_tensor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/detection.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"380ec6410dfcd7b1c7f172d0e4353f74a283dc28464818a390dbc5f7091c765d"}},{"ruleId":"D2","level":"warning","message":{"text":"video._validate_and_setup_video (cognitive 19): video._validate_and_setup_video has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 5, error handling 2 (3 pts), loops 1 (2 pts), ternaries 1 (nesting depth added 4). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/video.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"da681dd3f7514e4f6e1961a0907c63a7eab61d7351177b23b496402853a33115"}},{"ruleId":"D2","level":"warning","message":{"text":"video.process_video (cognitive 19): video.process_video has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 2, error handling 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/video.py"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"7426bbc615509d312bb958a04eafcddf078a50c0f6d7fd812258abf46afe57d2"}},{"ruleId":"D2","level":"warning","message":{"text":"check_doctest_fences._check_content (cognitive 18): check_doctest_fences._check_content has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (14 pts), boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":".github/scripts/check_doctest_fences.py"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"342a1245a127beec2eb71b838715620c7946d361045518976a38c89e6578de95"}},{"ruleId":"D2","level":"warning","message":{"text":"Detections.from_azure_analyze_image (cognitive 18): Detections.from_azure_analyze_image has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":1188}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d19e22a0a4f60de8826fc80d62c756e65e79c028f5e7d9d550445f9d218b534"}},{"ruleId":"D2","level":"warning","message":{"text":"LineZoneAnnotatorMulticlass.annotate (cognitive 18): LineZoneAnnotatorMulticlass.annotate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 5 (8 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/line_zone.py"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fde384491802689a3a1c8926d05731bc4839f43cca08b1617ad7197012c1bc2"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.process_semantic_segmentation (cognitive 18): internal.process_semantic_segmentation has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 2, ternaries 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"99493276c67df83e84b2eec589eed3a1d80c49b63b80367c4922532c571d173d"}},{"ruleId":"D2","level":"warning","message":{"text":"iou_and_nms.compact_mask_iou_batch (cognitive 18): iou_and_nms.compact_mask_iou_batch has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 3 (7 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":909}}}],"partialFingerprints":{"codehealthFindingId/v1":"c93cb23dfa48ce490b8ef4505fdd22dcacfb618d26750f65822ca52e6ca82981"}},{"ruleId":"D2","level":"warning","message":{"text":"core._paint_masks_by_area (cognitive 17): core._paint_masks_by_area has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (13 pts), ternaries 2, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":508}}}],"partialFingerprints":{"codehealthFindingId/v1":"4539ad58b02095f2587c2b37a87cc89d6862a534d4e6894a6163a85a04f117fb"}},{"ruleId":"D2","level":"warning","message":{"text":"labelme.detections_to_labelme_shapes (cognitive 17): labelme.detections_to_labelme_shapes has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (9 pts), loops 2 (4 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/labelme.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"e80db06f3d5dc83ec4fc51ddda33d8320404d422104f619f990e97e71527a30a"}},{"ruleId":"D2","level":"warning","message":{"text":"CSVSink.parse_detection_data (cognitive 17): CSVSink.parse_detection_data has cognitive complexity 17 (threshold 15). Drivers by points: loops 3 (7 pts), ternaries 3 (6 pts), if/else 2 (4 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/csv_sink.py"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"701e579cf4f1d804c61657f8d288660a962bed3a9de300811eab1d0a9395d6b9"}},{"ruleId":"D2","level":"warning","message":{"text":"KeyPoints._get_by_2d_bool_mask (cognitive 17): KeyPoints._get_by_2d_bool_mask has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 3, loops 2, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1043}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fafc4c58afe06456971635259be49f69ea01745537f930f60b0bb3444e6fb1e"}},{"ruleId":"D2","level":"warning","message":{"text":"_image._resize (cognitive 16): _image._resize has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_image.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"d91ece7cebdd2c9438c3f917d87a4e0ca409dd44441a6e10f76e87ffdeb1e81f"}},{"ruleId":"D2","level":"warning","message":{"text":"Detections.remap_classes (cognitive 16): Detections.remap_classes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (16 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":3198}}}],"partialFingerprints":{"codehealthFindingId/v1":"255a6ffe1c6ad84937afd8201178a96477f7cfa225a12b0fd2ed06c875ff9f01"}},{"ruleId":"D2","level":"warning","message":{"text":"converters.xyxy_to_mask (cognitive 16): converters.xyxy_to_mask has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/converters.py"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e6a1a64797e0a176b1710c11bea1726a2216c7c0267bcfa5437a5d25be8285f"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.merge_data (cognitive 16): internal.merge_data has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (5 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fe80bae7e85c40b096171763fbc66fdfb3773bb0612b83ab5cf6bc793c4c1f4"}},{"ruleId":"D2","level":"warning","message":{"text":"internal.merge_metadata (cognitive 16): internal.merge_metadata has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":876}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a36f420d790bd8e3a5fc8b41a551dd05d4f2c3e2956f61d758a8504b3c08f79"}},{"ruleId":"D2","level":"warning","message":{"text":"vlm._parse_gemini_boxes (cognitive 16): vlm._parse_gemini_boxes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 1, ternaries 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":751}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6f057a48e4043e620667cfc417f5a4f2672b5f204cffc99a43ff0189c0f80ec"}},{"ruleId":"D2","level":"warning","message":{"text":"utils.draw_image (cognitive 16): utils.draw_image has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 2, ternaries 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/draw/utils.py"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"126cb034972a8a91bdbcb39f98b74e74b341fe7f677e2ad9d12b8f0ff1379800"}},{"ruleId":"D2","level":"warning","message":{"text":"aggregate.plot_aggregate_metric_results (cognitive 16): aggregate.plot_aggregate_metric_results has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/aggregate.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dddb537ab1208b5a61d16d0c8b095d2d01a00663cb254c77b6de22caa0f88c0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: annotators/core.py: FileTooLong \u2014 1794 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1294 over it, 3.59\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c53071cae2e627a665e7ac67aef69060eef2c9b12594ba2c48813939f130aacd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: detection/core.py: FileTooLong \u2014 1214 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 714 over it, 2.43\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c874064837f17eed7029a7dd4a2474d500d9884442b5f72fbc5279a2c055505d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: metrics/mean_average_precision.py: FileTooLong \u2014 1057 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 557 over it, 2.11\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a147ee80c5d137de2f8428267153e0040541d1b006eb18c2e34d93e1ebffed8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: utils/iou_and_nms.py: FileTooLong \u2014 1049 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 549 over it, 2.10\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f48a1d33ecbd32cf0ac750949f4d5bc1b3cfe2b672c297e42fc2d539e89c998d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: _cv2/_drawing.py: FileTooLong \u2014 857 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 357 over it, 1.71\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d089e9d9c5721ff7b0bca104fda448634b39b4952531536d3fe2f5e09765919"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: dataset/core.py: FileTooLong \u2014 794 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 294 over it, 1.59\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6d66072d370070c3264667334521abcda86d3cfb4f707c81f6e13eac5f52583"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: detection/compact_mask.py: FileTooLong \u2014 790 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 290 over it, 1.58\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c9ed373c3e20dca6cff800c5cd48897051ae5055372e09e638829683423497c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: metrics/detection.py: FileTooLong \u2014 769 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 269 over it, 1.54\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/detection.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"64d0709fd0975608d8ed3ee299b82da4451c9dfda1aa7c5daba3a537626a63d9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: detection/vlm.py: FileTooLong \u2014 679 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 179 over it, 1.36\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eb62532eb673cf1ac01f97d78a739c9d6ed0696bd59cb0cd5c8cc1eaa3639eb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: key_points/core.py: FileTooLong \u2014 678 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 178 over it, 1.36\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd7600a1a7ac146f7d2b7c1ed52a8b38db7867cb89a710e169d7a979ed922991"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: cookbooks-card.document.addEventListener(\u0022DOMContentLoaded\u0022): FunctionTooLong \u2014 document.addEventListener(\u0022DOMContentLoaded\u0022) runs 119 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 19 over it, 1.19\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/javascripts/cookbooks-card.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0ef9ee7f64cc78edf8abeaf9d9a8ff06df002a7cf496e94da93605332ad8e28"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: utils/internal.py: FileTooLong \u2014 592 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 92 over it, 1.18\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9442eaadbcbf3f46905318d9d571443697af3c8e9ad29e48c737eca1f894cd61"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: detection/line_zone.py: FileTooLong \u2014 577 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 77 over it, 1.15\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/line_zone.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d6f6accb2764f8d77a2e779acb9c5a753f7b1a7ed0a077d5ffbc5f6757aa3e9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: depth/core.py: FileTooLong \u2014 516 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 16 over it, 1.03\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/depth/core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c320ca38f26684bdfbde9113f1d9bdf97007da75a64d2073db7dde9d01d1a06b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): src/supervision/detection/utils/iou_and_nms.py:2248-2336 | src/supervision/detection/utils/iou_and_nms.py:2378-2467 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":2248}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5016532e1a77c97f383edab80e83071f818cf3246380e8a0b05e7848ccd71d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): src/supervision/metrics/_confusion_matrix_metric.py:452-462 | src/supervision/metrics/mean_average_recall.py:821-833 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"906e51c9ca0c7f10fb203343e5fa82c5c018b31b97afb491dc9a1683c03dcd3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): src/supervision/metrics/f1_score.py:106-129 | src/supervision/metrics/keypoint_mean_average_precision.py:435-496 | src/supervision/metrics/mean_average_precision.py:1544-1579 | src/supervision/metrics/mean_average_recall.py:340-363 | src/supervision/metrics/precision.py:109-132 | src/supervision/metrics/recall.py:134-157 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"abb66b0724edad7cac90a5ea7ceb30cd9efcca378e2d8ced39997fec0c2b3ae9"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): examples/time_in_zone/rfdetr_file_example.py:33-44 | examples/time_in_zone/rfdetr_naive_stream_example.py:33-44 | src/supervision/detection/utils/iou_and_nms.py:39-50 | src/supervision/detection/vlm.py:62-73 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bdbc5ddf2a35fbdf6e993488c7a32f83b885f9529417b0ea0476c44ff2f9345"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): src/supervision/detection/utils/iou_and_nms.py:1548-1595 | src/supervision/detection/utils/iou_and_nms.py:1719-1741 | src/supervision/detection/utils/iou_and_nms.py:1793-1827 | src/supervision/detection/utils/iou_and_nms.py:2345-2369 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":1548}}}],"partialFingerprints":{"codehealthFindingId/v1":"00deaff1ee1f850c6a94dee23890a265c87f73eea6aab964c7ff304866d275da"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): src/supervision/metrics/f1_score.py:132-149 | src/supervision/metrics/mean_average_recall.py:366-383 | src/supervision/metrics/precision.py:135-152 | src/supervision/metrics/recall.py:160-177 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"cff895493253bc1fdfc5f664e0c9aba79cdadb3d8364ec7f71c96173899c76e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (79 corresponding lines): src/supervision/detection/tools/inference_slicer.py:613-691 | src/supervision/detection/tools/inference_slicer.py:698-786 \u2014 These two members are one piece of code written twice and then edited apart: 79 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a56336efe1706e85ce5b00bf77d38e7bafbeab5cef38a8bd799a95c7fea15db"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (40 corresponding lines): src/supervision/_cv2/_drawing.py:291-350 | src/supervision/_cv2/_drawing.py:805-844 \u2014 These two members are one piece of code written twice and then edited apart: 40 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"59088ad01d5546c53f2f66598502ac690aeac01cacb9269af46978f66f9064b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): src/supervision/annotators/core.py:3141-3166 | src/supervision/annotators/core.py:3333-3370 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":3141}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bc850c09b1175f22b688643bdaa90163d74177fb80df78e0b235e0fbc9774b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (50 corresponding lines): src/supervision/metrics/_confusion_matrix_metric.py:367-416 | src/supervision/metrics/mean_average_recall.py:697-753 \u2014 These two members are one piece of code written twice and then edited apart: 50 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eed2379559c9b2c652d471bf179ad62c4032ea6857efbab8335667cfcd3dd57"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): src/supervision/metrics/core.py:86-115 | src/supervision/metrics/mean_average_recall.py:231-267 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/core.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"f390f04c2e13e99bc09cc5af8f8f3e3cd6180cbf51926e85a990b2838a77fdbf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): src/supervision/metrics/_confusion_matrix_metric.py:421-449 | src/supervision/metrics/mean_average_recall.py:790-818 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"2643859845ed2b9b469af4460c0feba76cada2629ace072c82f71dd356b01e16"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): src/supervision/detection/utils/boxes.py:375-417 | src/supervision/detection/utils/iou_and_nms.py:408-432 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/boxes.py"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b1588f9058cd47b6cb47c2bfc5d08fff76d3474fa757f63ee72a1301da9c8db"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (73 corresponding lines): src/supervision/annotators/core.py:1655-1729 | src/supervision/draw/utils.py:197-269 \u2014 These two members are one piece of code written twice and then edited apart: 73 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1655}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eda8a9a8aec2978dac9e0412866e7726cb2c3916521c3e946e76329fcf06b21"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): src/supervision/metrics/utils/object_size.py:326-370 | src/supervision/metrics/utils/object_size.py:376-434 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"aedc1eb6f5080d9dbb3cdf50a8739512d40e84805458888f9770a0e9324c9738"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (59 corresponding lines): src/supervision/annotators/core.py:1313-1371 | src/supervision/annotators/core.py:2807-2873 \u2014 These two members are one piece of code written twice and then edited apart: 59 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1313}}}],"partialFingerprints":{"codehealthFindingId/v1":"758ad25f2796ef5030cbaf0ef57783d0baae26d78a1f75eef8685d1c9870e1f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): src/supervision/detection/tools/transformers.py:140-184 | src/supervision/detection/tools/transformers.py:190-222 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/transformers.py"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff071ae157f5cb8201650552bc0c9dc339ccca9f2b64c813030219e9b43410ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (56 corresponding lines): src/supervision/detection/core.py:2957-3012 | src/supervision/detection/core.py:3120-3196 \u2014 These two members are one piece of code written twice and then edited apart: 56 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":2957}}}],"partialFingerprints":{"codehealthFindingId/v1":"e52af7a253551e4c1dd7c77d1b19c6bc8b6b7c7af7c937b75c09ec6d60c95e3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 28\u002B corresponding lines): src/supervision/metrics/f1_score.py:327-354 | src/supervision/metrics/mean_average_precision.py:230-262 | src/supervision/metrics/mean_average_recall.py:199-228 | src/supervision/metrics/precision.py:330-360 | src/supervision/metrics/recall.py:353-380 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc1c852760bb610efe16c5c1f82279ca7c15d0a54d87daa2c6449b20258561c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (44 corresponding lines): src/supervision/classification/core.py:58-101 | src/supervision/classification/core.py:134-185 \u2014 These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/classification/core.py"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"67286d5192a548471240298c8d8831d3a43a278de21dc84b14d4f122bc73819f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): src/supervision/validators/__init__.py:145-163 | src/supervision/validators/__init__.py:243-262 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/validators/__init__.py"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7809efe9c1a3a299258cc6cfc6718241f0f2e4c8a22e0521089a86811e7729b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (49 corresponding lines): src/supervision/annotators/core.py:275-323 | src/supervision/annotators/core.py:843-895 \u2014 These two members are one piece of code written twice and then edited apart: 49 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"859ae665064472ee85ef26652b9ccaf327cf64c5614fdad92cedd97a2361b02b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (68 corresponding lines): src/supervision/annotators/core.py:1435-1502 | src/supervision/annotators/core.py:1805-1874 \u2014 These two members are one piece of code written twice and then edited apart: 68 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1435}}}],"partialFingerprints":{"codehealthFindingId/v1":"d10dbe6dadc5df8759195fd4d2c50f42daf3ce648aab0df50a82f186bc08f99c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): src/supervision/metrics/f1_score.py:260-275 | src/supervision/metrics/precision.py:261-276 | src/supervision/metrics/recall.py:286-301 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"5061892f6bdb6bed1f530bd5e02cb63bcc9324b6e35a2826a073757bd77aaf42"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): src/supervision/metrics/utils/object_size.py:140-169 | src/supervision/metrics/utils/object_size.py:175-215 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e5cf6f489c4ebf9f47ac5880de49b19601383a0395400fd6668641d22807375"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (64 corresponding lines): src/supervision/key_points/annotators.py:440-504 | src/supervision/key_points/annotators.py:541-604 \u2014 These two members are one piece of code written twice and then edited apart: 64 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"a97abc23b8d54ae433e6bac5607dc936ec9521e11d1e984d699332785e5f2363"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (55 corresponding lines): src/supervision/utils/image.py:232-286 | src/supervision/utils/image.py:295-365 \u2014 These two members are one piece of code written twice and then edited apart: 55 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/image.py"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f8d9e7f3a4bd491c0e60dba9384c5ede47be2c6e0c2c5d4bf3e8ae1c3f42ae8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): src/supervision/dataset/utils.py:465-479 | src/supervision/dataset/utils.py:485-521 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/utils.py"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"d362981e56904663c79fabd6f1e6b948c645acc69897d6d888245f39ce87f1c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): src/supervision/metrics/f1_score.py:182-206 | src/supervision/metrics/mean_average_recall.py:759-785 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"3618c541bf9fdf39715ef3b5fd3d95cefb8f0de1eebe1f7955035b468384eb33"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): src/supervision/annotators/core.py:3631-3641 | src/supervision/annotators/core.py:3647-3656 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":3631}}}],"partialFingerprints":{"codehealthFindingId/v1":"f34e73405c2c7408135e5fdb37d42ae10b8aec1980689ea25c187970418964ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): examples/time_in_zone/rfdetr_stream_example.py:30-42 | src/supervision/detection/utils/iou_and_nms.py:74-85 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_stream_example.py"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"74ae7748bbb018b65e51ad1cdd8947987f85a8550b989609921cbc10e4149f8d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (38 corresponding lines): src/supervision/detection/utils/iou_and_nms.py:1446-1483 | src/supervision/detection/utils/iou_and_nms.py:1491-1539 \u2014 These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":1446}}}],"partialFingerprints":{"codehealthFindingId/v1":"53e71630fd6b4aac0f372a79f85a015787c9cb12a7a10039a8500461f4f862a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (47 corresponding lines): src/supervision/detection/core.py:2657-2708 | src/supervision/key_points/core.py:1413-1459 \u2014 These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":2657}}}],"partialFingerprints":{"codehealthFindingId/v1":"955a791d1cac3790f31ea025bb889691c1d5b5c58ee303f32832618abaea2fc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (47\u201348 lines \u00D7 2): src/supervision/annotators/core.py:2199-2245 | src/supervision/annotators/core.py:2689-2736 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/annotators/core.py:2199\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":2199}}}],"partialFingerprints":{"codehealthFindingId/v1":"a78521b94cfef9344273eb2a49766daca25e25338154ed614f28de0fb964b5e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (41\u201345 lines \u00D7 2): src/supervision/metrics/_confusion_matrix_metric.py:367-407 | src/supervision/metrics/mean_average_recall.py:697-741 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab64678451edf3f145de61edfcd57c8530b3a8f5db384d283544a0c07830094a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (40 lines \u00D7 2): src/supervision/annotators/core.py:1049-1088 | src/supervision/annotators/core.py:2913-2955 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/annotators/core.py:2913\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1049}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3cc492f01fb075a6d70c880fbb4f94461dacb8693c13667d02a6b3af24650b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19\u201332 lines \u00D7 6): src/supervision/metrics/f1_score.py:106-124 | src/supervision/metrics/keypoint_mean_average_precision.py:435-466 | src/supervision/metrics/mean_average_precision.py:1544-1562 | src/supervision/metrics/mean_average_recall.py:340-358 | src/supervision/metrics/precision.py:109-127 | src/supervision/metrics/recall.py:134-152 \u2014 before extracting anything, compare \u0060src/supervision/metrics/f1_score.py\u0060 and \u0060src/supervision/metrics/precision.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 85 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060predictions\u0060 to \u0060Detections | list[Detections]\u0060 in one and \u0060KeyPoints | list[KeyPoints]\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"8968d3467a4aac91355295420215f5c2d77400b0bdcd130bb7a9fdbd568f04d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (30\u201331 lines \u00D7 2): src/supervision/metrics/_confusion_matrix_metric.py:192-221 | src/supervision/metrics/mean_average_recall.py:435-465 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/_confusion_matrix_metric.py:192\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bf7e2cb6505cab78ff15552873fe64e5318e381ab78f9e605a0b1f206628848"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201329 lines \u00D7 4): src/supervision/detection/utils/iou_and_nms.py:1548-1576 | src/supervision/detection/utils/iou_and_nms.py:1719-1728 | src/supervision/detection/utils/iou_and_nms.py:1793-1817 | src/supervision/detection/utils/iou_and_nms.py:2345-2359 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":1548}}}],"partialFingerprints":{"codehealthFindingId/v1":"2987592df65b746c67708f0ff0cdffca0e1b9105e791719160f3b015708420ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26\u201327 lines \u00D7 2): src/supervision/annotators/core.py:1574-1600 | src/supervision/annotators/core.py:1980-2005 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1574}}}],"partialFingerprints":{"codehealthFindingId/v1":"26d4aff28f8d70f5806d3d6dfae098f4da6f0b8e1a7c9b4b4716bd12e3174511"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2): src/supervision/draw/color.py:213-238 | src/supervision/draw/color.py:242-267 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/draw/color.py"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"e10467bf150b283b43a668a741912a05efc4f97ea038b7e1fb06b3d0c30507de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): src/supervision/draw/color.py:159-181 | src/supervision/draw/color.py:186-208 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/draw/color.py"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"80e8d5969cafa31ce1234260215510feb2265dfa78a467fdbc540b0c6ecfa5ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): src/supervision/metrics/precision.py:185-207 | src/supervision/metrics/recall.py:210-232 \u2014 before extracting anything, compare \u0060src/supervision/metrics/precision.py\u0060 and \u0060src/supervision/metrics/recall.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 108 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/precision.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfffb4509b7e6841ea27bc59dcaecb7698f0accc5134d705e742ab84fc64c78d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): src/supervision/metrics/core.py:89-109 | src/supervision/metrics/mean_average_recall.py:241-261 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/core.py:89\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/core.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"2100ec264659802ce05d519e2fff553becb94e849b0685b99317441017a65b29"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): src/supervision/dataset/core.py:239-257 | src/supervision/dataset/core.py:1741-1759 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/core.py"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"245d0def85c016b5aa64f971288afe07d6de2516d6c1126dd1b0f4d4781c5633"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 4): src/supervision/metrics/f1_score.py:132-149 | src/supervision/metrics/mean_average_recall.py:366-383 | src/supervision/metrics/precision.py:135-152 | src/supervision/metrics/recall.py:160-177 \u2014 before extracting anything, compare \u0060src/supervision/metrics/f1_score.py\u0060 and \u0060src/supervision/metrics/precision.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 85 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"290933524203bf9b167c8345dc7e25031aa908d40b7e5d3216ef101d1f40c7bb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201317 lines \u00D7 2): src/supervision/metrics/mean_average_precision.py:1629-1645 | src/supervision/metrics/mean_average_precision.py:1715-1729 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1629}}}],"partialFingerprints":{"codehealthFindingId/v1":"c49c9469bda3e0ec50d085acb31e243f2de4355e985bdafdc14bfcd1ce80d1cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201317 lines \u00D7 2): src/supervision/metrics/utils/object_size.py:246-262 | src/supervision/metrics/utils/object_size.py:305-319 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"73dbfe7eb033a9928efc5e39475bcc77fbdde98f1db25f91aa2831417f193e13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): src/supervision/detection/utils/iou_and_nms.py:637-650 | src/supervision/detection/utils/iou_and_nms.py:2311-2324 | src/supervision/detection/utils/iou_and_nms.py:2438-2451 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":637}}}],"partialFingerprints":{"codehealthFindingId/v1":"70e0fdbeb9a1b8e7aaebfe2ada1ab3ad7e8c038551e47811c48034c20534fa55"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): src/supervision/metrics/_confusion_matrix_metric.py:658-671 | src/supervision/metrics/core.py:102-115 | src/supervision/metrics/mean_average_recall.py:254-267 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3e90a6fe1d05faa88cb126c5edd57e9ec121714a31d2121a1a44a5ba0618a47"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): src/supervision/dataset/core.py:732-745 | src/supervision/dataset/core.py:1626-1638 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060src/supervision/dataset/core.py:1641\u0060 calls \u0060_check_key_points_carry_class_id\u0060 and \u0060src/supervision/dataset/core.py:746\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/core.py"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"17b88e948f0f0c595c161f8a41e0f16004489ebcfc5696ecf733a0d15e6baa70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201314 lines \u00D7 2): src/supervision/detection/tools/inference_slicer.py:644-657 | src/supervision/detection/tools/inference_slicer.py:742-753 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/detection/tools/inference_slicer.py:644\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":644}}}],"partialFingerprints":{"codehealthFindingId/v1":"46f8985a9f9c94e5094f6fc37bfae918bc25f3c25e46117cf02a78812775d35e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): src/supervision/metrics/utils/aggregate.py:50-63 | src/supervision/metrics/utils/aggregate.py:111-124 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060src/supervision/metrics/utils/aggregate.py:47\u0060 calls \u0060ensure_pandas_installed\u0060 and \u0060src/supervision/metrics/utils/aggregate.py:109\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/aggregate.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"c07af64991cc0a79a759d168816f15975508eadb69ceead802358385ae55ea74"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): src/supervision/annotators/core.py:1509-1520 | src/supervision/annotators/core.py:1921-1933 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":1509}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0133f3579865b19b2e7024170c4037454d32cb30a387c8c3a5177d81cedfebb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): src/supervision/dataset/formats/pascal_voc.py:266-278 | src/supervision/dataset/formats/yolo.py:530-542 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/pascal_voc.py"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff7eb4327cdd4d70742222d14770c9ddc729c3bd8524e130e7ff3ea8281e9da3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): src/supervision/metrics/_confusion_matrix_metric.py:438-449 | src/supervision/metrics/mean_average_recall.py:806-818 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/_confusion_matrix_metric.py:438\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"c19b4237ad4dff93fe71c19900558dd7bd5a309930e1a68bc636df06365dcac7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): examples/time_in_zone/rfdetr_file_example.py:33-44 | examples/time_in_zone/rfdetr_naive_stream_example.py:33-44 | src/supervision/detection/utils/iou_and_nms.py:39-50 | src/supervision/detection/vlm.py:62-73 \u2014 before extracting anything, compare \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 71 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060value\u0060 to \u0060ModelSize | str\u0060 in one and \u0060OverlapFilter | str\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fb211a27fd5d5fb0d5237fb72851c267c2b45725c8e714c5b44c6ac79ee9933"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): src/supervision/_cv2/_drawing.py:1009-1022 | src/supervision/_cv2/_drawing.py:1274-1287 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":1009}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ca0ab8d6760415c4d35b482eeae08dc2e3c6588b483bc1c6ca613c03d74b2ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): src/supervision/detection/utils/iou_and_nms.py:1257-1267 | src/supervision/detection/utils/iou_and_nms.py:1352-1362 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":1257}}}],"partialFingerprints":{"codehealthFindingId/v1":"e85b64fc03cac964f953c6f96b3d89df069f31e581c29b8115b303e51183ca52"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201311 lines \u00D7 2): src/supervision/metrics/_confusion_matrix_metric.py:455-462 | src/supervision/metrics/mean_average_recall.py:823-833 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"7229e67454584d5959049695c7b31de43ac8d1fd372dcfa0cde8029fdadd5e0b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 3): src/supervision/metrics/f1_score.py:346-354 | src/supervision/metrics/precision.py:351-360 | src/supervision/metrics/recall.py:372-380 \u2014 before extracting anything, compare \u0060src/supervision/metrics/f1_score.py\u0060 and \u0060src/supervision/metrics/precision.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 85 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/f1_score.py:346\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"07090b1df10448460b9610b452ed0443698aac78f22d37dc358a0927df088594"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): src/supervision/metrics/mean_average_precision.py:1804-1818 | src/supervision/metrics/mean_average_precision.py:1819-1828 | src/supervision/metrics/mean_average_precision.py:1833-1842 | src/supervision/metrics/mean_average_precision.py:1847-1857 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/mean_average_precision.py:1804\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1804}}}],"partialFingerprints":{"codehealthFindingId/v1":"62b758a3ebb170ff0c7b3df2bdee5fc394520a40883fcd4828b4e730f174c410"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): src/supervision/validators/__init__.py:100-109 | src/supervision/validators/__init__.py:123-132 | src/supervision/validators/__init__.py:176-185 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/validators/__init__.py"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f8d35bdd8fcbf821bfa827a0c27ad7094d35df74ecf8eeb1b990e9276fc409d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): src/supervision/detection/utils/iou_and_nms.py:514-522 | src/supervision/detection/utils/iou_and_nms.py:523-532 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":514}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8a84a9a934dd8c18a5d5b9edf494fb4da826d8810ab861ce6b66fc4bdc80ae8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): src/supervision/detection/utils/masks.py:93-102 | src/supervision/detection/utils/masks.py:104-113 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/masks.py"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6dc606138f09545ef9dbed86c4ea843f7a44ee7f3a3c442f257e3fedb90c94e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): src/supervision/key_points/annotators.py:489-498 | src/supervision/key_points/annotators.py:590-599 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/key_points/annotators.py:489\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"86a9773e064f80cfca4e806e39ea60a4665d727511f6625a40455ffa064005df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): src/supervision/metrics/_confusion_matrix_metric.py:475-484 | src/supervision/metrics/mean_average_recall.py:887-896 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":475}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac7cbf4279a0980690de6845bd91a5c44a13a587e15b38de86b6b3a51a947497"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): src/supervision/dataset/formats/pascal_voc.py:268-276 | src/supervision/dataset/formats/yolo.py:532-540 | src/supervision/dataset/formats/yolo_pose.py:296-304 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/pascal_voc.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"0db0a90ee7a5f29f5876722903f58e156e143828ca61c241ab12807e1be4948f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): src/supervision/annotators/core.py:312-320 | src/supervision/annotators/core.py:880-888 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/annotators/core.py:312\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"56214405403072489180782df7223b3935f5102d8ea4b70fa4dfcbbe0ef65a79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): src/supervision/annotators/utils.py:419-427 | src/supervision/annotators/utils.py:430-438 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/utils.py"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"1240c6faea05ec9eb9de3f47b8ed1d63466eac80d76d4a135294d247a0521eb9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): src/supervision/key_points/annotators.py:119-127 | src/supervision/key_points/annotators.py:372-380 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"458203ce3870b1383b1a7d4fa878d9531df7129166038f384fafc16e00356911"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 2): src/supervision/detection/utils/boxes.py:403-410 | src/supervision/detection/utils/iou_and_nms.py:421-427 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/boxes.py"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e9beb54518969794caa5e7fa4078ff1ca53bc65b56ef0efe55fb779d9ad9cfc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): src/supervision/detection/core.py:3341-3347 | src/supervision/detection/utils/boxes.py:407-413 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":3341}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d5798f6afec267d0f9f15ad8a40cb0ba433e9dc947cd0bea8ed8bd8f316106a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): src/supervision/detection/core.py:2343-2348 | src/supervision/key_points/core.py:1596-1601 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":2343}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3e045ef8f8df59eedd9d7b5a5696a55317f4c1a92c6fb8ccf030c0cb96366c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): src/supervision/key_points/core.py:1237-1243 | src/supervision/key_points/core.py:1244-1250 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1237}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c7ac7f7f569d62888485c436dac9ef4c041bab9a6c0b9963f8d2be96c6c93ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): src/supervision/metrics/utils/object_size.py:129-134 | src/supervision/metrics/utils/object_size.py:164-169 | src/supervision/metrics/utils/object_size.py:210-215 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060src/supervision/metrics/utils/object_size.py:208\u0060 calls \u0060count_mask_pixels\u0060 and \u0060src/supervision/metrics/utils/object_size.py:162\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"e49ffa87cc7018234f68cc833c11285a08a2fd0cdd9eb1f4e48469a4721169ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): src/supervision/_cv2/_drawing.py:1000-1005 | src/supervision/_cv2/_drawing.py:1266-1271 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":1000}}}],"partialFingerprints":{"codehealthFindingId/v1":"00c587981c91733bf4ed8fa7a66be11bca47a5ae53744ab89bc206c604120f94"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): src/supervision/detection/utils/masks.py:343-349 | src/supervision/detection/utils/masks.py:358-364 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/masks.py"},"region":{"startLine":343}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5d7974e43b4331494966fd70981af412ac91daa1c78a3f83c7953e2644d8b7f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 4): src/supervision/depth/colormaps.py:54-83 | src/supervision/depth/core.py:61-88 | src/supervision/depth/core.py:121-142 | src/supervision/depth/core.py:168-189 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060value\u0060 to \u0060DepthColormap | str\u0060 in one and \u0060DepthKind | str\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/depth/colormaps.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a92a23936ea6c4a9c3a6c762839c43a2460d84fc0e310812caa45672de494da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): src/supervision/detection/tools/csv_sink.py:151-172 | src/supervision/detection/tools/json_sink.py:136-157 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/csv_sink.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab611bf78bda55082d8d83cfb8321b98a617f14a229522e8319053b0ce6ad650"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): src/supervision/metrics/f1_score.py:83-94 | src/supervision/metrics/precision.py:86-97 | src/supervision/metrics/recall.py:111-122 \u2014 before extracting anything, compare \u0060src/supervision/metrics/f1_score.py\u0060 and \u0060src/supervision/metrics/precision.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 85 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd61ad33e470038c954601f4d9e25f9fcf10018858ce9742d4e7d73bc9c7860"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): src/supervision/metrics/f1_score.py:164-176 | src/supervision/metrics/precision.py:167-179 | src/supervision/metrics/recall.py:192-204 \u2014 before extracting anything, compare \u0060src/supervision/metrics/f1_score.py\u0060 and \u0060src/supervision/metrics/precision.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 85 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/metrics/f1_score.py:164\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/f1_score.py"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e500a2b266b1b7143c37ac4794a15a0c00ca017debe5d0deb279b67699bd76c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): src/supervision/_cv2/_drawing.py:1033-1037 | src/supervision/_cv2/_drawing.py:1518-1522 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":1033}}}],"partialFingerprints":{"codehealthFindingId/v1":"66c8b2662ed151d3e80a84742058ff99a6081b8c08ca3ecb94ed473e28e9df18"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): src/supervision/detection/tools/inference_slicer.py:668-676 | src/supervision/detection/tools/inference_slicer.py:761-769 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bd61acdbe64da4af426885569ca48e865ab1ad4fffed9b7966a0fda7e2aa422"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): src/supervision/detection/utils/iou_and_nms.py:2304-2308 | src/supervision/detection/utils/iou_and_nms.py:2431-2435 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060src/supervision/detection/utils/iou_and_nms.py:2304\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060src/supervision/detection/utils/iou_and_nms.py:2303\u0060 calls \u0060_validate_iou_threshold\u0060 and \u0060src/supervision/detection/utils/iou_and_nms.py:2409\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":2304}}}],"partialFingerprints":{"codehealthFindingId/v1":"7598a55b6472c86048cf85dd2fcda5052b4aa8479744031f702356f99a42da82"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): src/supervision/metrics/utils/object_size.py:120-124 | src/supervision/metrics/utils/object_size.py:279-283 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060src/supervision/metrics/utils/object_size.py:286\u0060 calls \u0060asarray\u0060 and \u0060src/supervision/metrics/utils/object_size.py:125\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"53c0fb80f21959536d9741691a5695b88c33b5f4d3df326cc6156cdf02f9c591"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (6 members, 23 shared lines): examples/time_in_zone/inference_naive_stream_example.py:25-104 | examples/time_in_zone/inference_stream_example.py:41-83 | examples/time_in_zone/rfdetr_naive_stream_example.py:102-182 | examples/time_in_zone/rfdetr_stream_example.py:105-143 | examples/time_in_zone/ultralytics_naive_stream_example.py:25-108 | examples/time_in_zone/ultralytics_stream_example.py:42-83 \u2014 These 6 members are variants of one another: a block of 23 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_naive_stream_example.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8ca2f4104691650abb2b43bab85e9586a3b31f12c8e4f9f37901eaebd5ad611"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (4 members, 42 shared lines): examples/speed_estimation/inference_example.py:57-156 | examples/speed_estimation/rfdetr_example.py:58-148 | examples/speed_estimation/ultralytics_example.py:54-140 | examples/speed_estimation/yolo_nas_example.py:55-143 \u2014 These 4 members are variants of one another: a block of 42 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"76db547c5ac4b053b55ffc72d532a2782ee4f1c5d5e2b3044b2aa8d17db0b2cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (3 members, 40 shared lines): examples/time_in_zone/inference_file_example.py:25-94 | examples/time_in_zone/rfdetr_file_example.py:102-171 | examples/time_in_zone/ultralytics_file_example.py:87-192 \u2014 These 3 members are variants of one another: a block of 40 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"0afb749cce106ff12430e3e3fb96cbc4c6900004299c2a121722cdff604efb79"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (3 members, 17 shared lines): examples/traffic_analysis/inference_example.py:160-180 | examples/traffic_analysis/rfdetr_example.py:167-188 | examples/traffic_analysis/ultralytics_example.py:157-177 \u2014 These 3 members are variants of one another: a block of 17 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"706b7417bc6ded64f37680158437484ae099c652b736f48ee573a079c1dac69a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (79 corresponding lines): examples/heatmap_and_track/rfdetr_example.py:31-109 | examples/heatmap_and_track/script.py:26-113 \u2014 These two members are one piece of code written twice and then edited apart: 79 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/heatmap_and_track/rfdetr_example.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"4886eac9697a60de4566df379b739bc4dea2c0a0fba0deeab11dc1524994895a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 48\u002B corresponding lines): examples/count_people_in_zone/inference_example.py:135-192 | examples/count_people_in_zone/rfdetr_example.py:138-185 | examples/count_people_in_zone/ultralytics_example.py:133-180 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 48 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"edcc669824ce53f10d3286e86b3cd175aadd3cbf9e45483be7687ba445941c42"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 34\u002B corresponding lines): examples/tracking/inference_example.py:18-60 | examples/tracking/rfdetr_example.py:16-49 | examples/tracking/ultralytics_example.py:15-49 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 34 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/tracking/inference_example.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"c81e0355fb68d74da9a63e1cd1879bc7b0fbfd4e16e81631a83c80bf0564bc17"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 20\u002B corresponding lines): examples/traffic_analysis/inference_example.py:83-102 | examples/traffic_analysis/rfdetr_example.py:87-107 | examples/traffic_analysis/ultralytics_example.py:80-99 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"30b7d318e31e4b279ca36c7003782763a1e3c7d124e2ba6fec91125add9085cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): examples/time_in_zone/rfdetr_file_example.py:50-65 | examples/time_in_zone/rfdetr_naive_stream_example.py:50-65 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"693f9dca090f144601c3af3984c934265e7f9793959ad5723df83dc1fbe69082"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): examples/time_in_zone/rfdetr_stream_example.py:156-189 | examples/time_in_zone/ultralytics_stream_example.py:95-133 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_stream_example.py"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eeaf9c9098f1571e2a9c245ed95a48782095c59bbafe5e518050068f6c6d7f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): examples/count_people_in_zone/inference_example.py:67-90 | examples/count_people_in_zone/ultralytics_example.py:65-89 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"09d294cb006b816c5c0916c12c59f00f7612bca5c903a2d486b24e1652225650"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 2\u002B corresponding lines): examples/traffic_analysis/inference_example.py:31-32 | examples/traffic_analysis/rfdetr_example.py:33-35 | examples/traffic_analysis/ultralytics_example.py:29-30 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 2 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fc1350921baef4f9493d33a5764564ab934a32df3a20dd481de0eea72badf1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 3\u002B corresponding lines): examples/speed_estimation/inference_example.py:28-30 | examples/speed_estimation/rfdetr_example.py:28-31 | examples/speed_estimation/ultralytics_example.py:27-29 | examples/speed_estimation/yolo_nas_example.py:28-30 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 3 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a2f78ec1e6841981c5da61650e2deff7b4f7c3eae7b032dd474b79d013f293b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): examples/compact_mask/bench_inference_api.py:310-316 | examples/compact_mask/benchmark.py:241-252 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/compact_mask/bench_inference_api.py"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"91ca830e069b3258c8022c6be3a3b6ad1a13fc55cd001366bbb0f1caf8186a0b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (37 lines \u00D7 2): examples/heatmap_and_track/rfdetr_example.py:47-83 | examples/heatmap_and_track/script.py:42-78 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/heatmap_and_track/rfdetr_example.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1816e2abd68b829e0c9b19ff0dd033c251f819f93e5f2b2c04be848cc3720fb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u201335 lines \u00D7 4): examples/speed_estimation/inference_example.py:122-156 | examples/speed_estimation/rfdetr_example.py:119-122 | examples/speed_estimation/ultralytics_example.py:106-140 | examples/speed_estimation/yolo_nas_example.py:109-143 \u2014 before extracting anything, compare \u0060examples/speed_estimation/inference_example.py\u0060 and \u0060examples/speed_estimation/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 76 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"814ffe2985f72302b832a7bef6948009398fa40d77f27ae6cb6963bbfd4b19e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31 lines \u00D7 3): examples/traffic_analysis/inference_example.py:127-157 | examples/traffic_analysis/rfdetr_example.py:134-164 | examples/traffic_analysis/ultralytics_example.py:124-154 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/inference_example.py\u0060 and \u0060examples/traffic_analysis/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 98 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"84e145b0d35264d2e9299bc732a8f044619429a9cc0669e207ca0c03d7a25466"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (30 lines \u00D7 3): examples/count_people_in_zone/inference_example.py:163-192 | examples/count_people_in_zone/rfdetr_example.py:156-185 | examples/count_people_in_zone/ultralytics_example.py:151-180 \u2014 before extracting anything, compare \u0060examples/count_people_in_zone/inference_example.py\u0060 and \u0060examples/count_people_in_zone/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 93 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7314540aaaed9bdd8a63a494de3cc1c69690eb9bacd265573c8e99d0f1af3ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 4): examples/speed_estimation/inference_example.py:79-104 | examples/speed_estimation/rfdetr_example.py:72-97 | examples/speed_estimation/ultralytics_example.py:65-90 | examples/speed_estimation/yolo_nas_example.py:66-91 \u2014 before extracting anything, compare \u0060examples/speed_estimation/inference_example.py\u0060 and \u0060examples/speed_estimation/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 76 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"452f1c20527928bc138ae9acd03e92f72b93607f721b3bfa39ad7f4031487f7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 3): examples/count_people_in_zone/inference_example.py:35-58 | examples/count_people_in_zone/rfdetr_example.py:39-62 | examples/count_people_in_zone/ultralytics_example.py:33-56 \u2014 before extracting anything, compare \u0060examples/count_people_in_zone/inference_example.py\u0060 and \u0060examples/count_people_in_zone/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 93 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f8e663b5d50b532430b9a05b7cf5642316bab05a4f53d96e82771c0b260e123"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 3): examples/count_people_in_zone/inference_example.py:100-123 | examples/count_people_in_zone/rfdetr_example.py:104-127 | examples/count_people_in_zone/ultralytics_example.py:99-122 \u2014 before extracting anything, compare \u0060examples/count_people_in_zone/inference_example.py\u0060 and \u0060examples/count_people_in_zone/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 93 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"afcfb741ae52809326fbe2e64a6f78443cab1b5243aebb0b93afdffa66de5a65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): examples/heatmap_and_track/rfdetr_example.py:89-109 | examples/heatmap_and_track/script.py:93-113 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/heatmap_and_track/rfdetr_example.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f48a6999366afbcfe79e2335af994657eedd4da3c62ed603feda0a79e3c65f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): examples/time_in_zone/rfdetr_file_example.py:69-89 | examples/time_in_zone/rfdetr_naive_stream_example.py:69-89 \u2014 before extracting anything, compare \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 71 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab90a18c4462252dbadf789adfaf157590dc3ca54ef1baa30ea0744a1b9f21da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 3): examples/time_in_zone/inference_naive_stream_example.py:37-56 | examples/time_in_zone/rfdetr_naive_stream_example.py:116-135 | examples/time_in_zone/ultralytics_naive_stream_example.py:37-56 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_naive_stream_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 65 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_naive_stream_example.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"894d7b6ae6a1a3776a42dae2e863de1d0303e9bef0f5661ade126e6d98ab4b4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201319 lines \u00D7 9): examples/time_in_zone/inference_file_example.py:72-88 | examples/time_in_zone/inference_naive_stream_example.py:82-98 | examples/time_in_zone/inference_stream_example.py:65-81 | examples/time_in_zone/rfdetr_file_example.py:149-165 | examples/time_in_zone/rfdetr_naive_stream_example.py:159-175 | examples/time_in_zone/rfdetr_stream_example.py:126-141 | examples/time_in_zone/ultralytics_file_example.py:160-178 | examples/time_in_zone/ultralytics_naive_stream_example.py:86-102 | examples/time_in_zone/ultralytics_stream_example.py:65-81 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/inference_naive_stream_example.py\u0060 as WHOLE FILES: 84% of the shorter file\u0027s lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 2 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it \u2014 treat the file pair as the unit. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060examples/time_in_zone/ultralytics_file_example.py:184\u0060 calls \u0060write_frame\u0060 and \u0060examples/time_in_zone/inference_file_example.py:91\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ce26b5e3505486a3d022a3e7fda06011bc2236da87cad31966f725ee92882df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): examples/time_in_zone/inference_naive_stream_example.py:63-81 | examples/time_in_zone/rfdetr_naive_stream_example.py:140-158 | examples/time_in_zone/ultralytics_naive_stream_example.py:67-85 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_naive_stream_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 65 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_naive_stream_example.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"85f0fe842cd88f4a7511635128a197403ddbfa4b30b0c40c005343232019ff11"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 3): examples/traffic_analysis/inference_example.py:40-57 | examples/traffic_analysis/rfdetr_example.py:44-61 | examples/traffic_analysis/ultralytics_example.py:38-55 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/inference_example.py\u0060 and \u0060examples/traffic_analysis/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 98 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb0b509b6d497c041cd4ddbbe0965a15785988e07b5769eb215de738a569b1b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 3): examples/traffic_analysis/inference_example.py:105-122 | examples/traffic_analysis/rfdetr_example.py:111-128 | examples/traffic_analysis/ultralytics_example.py:102-119 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/inference_example.py\u0060 and \u0060examples/traffic_analysis/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 98 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"89e965574d3c38123244d14b579479b3bee5d0732883587e8a785b6ebcb44535"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): examples/time_in_zone/inference_file_example.py:37-54 | examples/time_in_zone/rfdetr_file_example.py:116-133 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 72 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b633fa671766ee5123bd6091af078fc94e45ca21d5ea9e8a191a2739234439a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 3): examples/traffic_analysis/inference_example.py:164-180 | examples/traffic_analysis/rfdetr_example.py:172-188 | examples/traffic_analysis/ultralytics_example.py:161-177 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/inference_example.py\u0060 and \u0060examples/traffic_analysis/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 98 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbec344f196a0d6a0ed559737e38a7548901ba00070d49a729a5efcf04efebde"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201316 lines \u00D7 3): examples/time_in_zone/inference_stream_example.py:45-60 | examples/time_in_zone/rfdetr_stream_example.py:107-121 | examples/time_in_zone/ultralytics_stream_example.py:45-60 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_stream_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_stream_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 56 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060examples/time_in_zone/inference_stream_example.py:45\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060examples/time_in_zone/inference_stream_example.py:44\u0060 calls \u0060from_inference\u0060 and \u0060examples/time_in_zone/rfdetr_stream_example.py:106\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_stream_example.py"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"831a7cbb1976ede681af1b67c7133597199f2b3eeaa6abf041e49a9b2584449a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201315 lines \u00D7 4): examples/speed_estimation/inference_example.py:113-127 | examples/speed_estimation/rfdetr_example.py:105-116 | examples/speed_estimation/ultralytics_example.py:97-111 | examples/speed_estimation/yolo_nas_example.py:100-114 \u2014 before extracting anything, compare \u0060examples/speed_estimation/inference_example.py\u0060 and \u0060examples/speed_estimation/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 76 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae78911ebb27517788407b20d19077c7e372f981be4246d0d8e1237020f97c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): examples/time_in_zone/inference_file_example.py:37-51 | examples/time_in_zone/rfdetr_file_example.py:116-130 | examples/time_in_zone/ultralytics_file_example.py:113-127 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 72 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"48827460a709276ba538f7c91bd604baccbb37105d3535d093d9fddb82ed8b61"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): examples/time_in_zone/inference_stream_example.py:25-38 | examples/time_in_zone/rfdetr_stream_example.py:89-102 | examples/time_in_zone/ultralytics_stream_example.py:26-39 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_stream_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_stream_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 56 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_stream_example.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"300da1a1c3faa85a2c612af7f49936e8c09a2dad9aad053acab76bc783ef5a7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): examples/traffic_analysis/inference_example.py:89-102 | examples/traffic_analysis/rfdetr_example.py:94-107 | examples/traffic_analysis/ultralytics_example.py:86-99 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/inference_example.py\u0060 and \u0060examples/traffic_analysis/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 98 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/inference_example.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"190a86e1f267264af2e8a2e91e20d84de87eb580bd3d2a01ead79e7a32b9b2a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): examples/time_in_zone/ultralytics_file_example.py:137-149 | examples/time_in_zone/ultralytics_naive_stream_example.py:58-70 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/ultralytics_file_example.py"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"29dc75815aaed25c9c9c5a5955e1bbffc8a843b94d7333fc23d37dea1ec7adc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 3): examples/time_in_zone/rfdetr_file_example.py:50-61 | examples/time_in_zone/rfdetr_naive_stream_example.py:50-61 | examples/time_in_zone/rfdetr_stream_example.py:48-58 \u2014 before extracting anything, compare \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 71 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a4e6a14fa66c97acbd2f644222198259f4c1143cbe518213f4f875a51f9d817"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): examples/tracking/inference_example.py:49-60 | examples/tracking/rfdetr_example.py:38-49 | examples/tracking/ultralytics_example.py:38-49 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/tracking/inference_example.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fd9bf5d926af243d709f0ed3a4b8c38afacc91ac2f1d3e3cb2da02b36be99b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): examples/time_in_zone/inference_file_example.py:61-71 | examples/time_in_zone/rfdetr_file_example.py:138-148 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 72 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"00604ec42853d14d5740c5739fce5982c87747502d4badffd97f1d68591bfd42"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201310 lines \u00D7 2): examples/time_in_zone/inference_file_example.py:59-66 | examples/time_in_zone/ultralytics_file_example.py:145-154 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/ultralytics_file_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 53 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060examples/time_in_zone/inference_file_example.py:59\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3f4b29f63d38909909ae8d238a398805a1afdfdce2ec9a7be7ee714a6272cdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): examples/time_in_zone/inference_file_example.py:55-63 | examples/time_in_zone/inference_naive_stream_example.py:58-66 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/inference_naive_stream_example.py\u0060 as WHOLE FILES: 84% of the shorter file\u0027s lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 2 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it \u2014 treat the file pair as the unit. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060examples/time_in_zone/inference_naive_stream_example.py:55\u0060 calls \u0060tick\u0060 and \u0060examples/time_in_zone/inference_file_example.py:54\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"75b470b1a36be8dc3c0efdec56369c960d691e6f66c3bb275c23f568f002c339"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): examples/time_in_zone/inference_file_example.py:60-67 | examples/time_in_zone/rfdetr_file_example.py:137-144 | examples/time_in_zone/ultralytics_file_example.py:146-154 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 72 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060examples/time_in_zone/inference_file_example.py:60\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_file_example.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"f42058b513eac6b6974488ec44d686e667bb7f2ec119083ecfedd3b795c5a56b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): examples/tracking/inference_example.py:37-44 | examples/tracking/rfdetr_example.py:27-34 | examples/tracking/ultralytics_example.py:26-33 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/tracking/inference_example.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"61976620d1d50b8180140d13b03d39152e10ed4d416fc97c33e18866bd32656a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): examples/compact_mask/bench_inference_api.py:332-339 | examples/compact_mask/benchmark.py:921-932 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/compact_mask/bench_inference_api.py"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"587339abced678b12488ef788aab8df600d78a178bdeb495982edac3f3bf5630"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 6): examples/time_in_zone/inference_naive_stream_example.py:67-73 | examples/time_in_zone/inference_stream_example.py:50-56 | examples/time_in_zone/rfdetr_naive_stream_example.py:144-150 | examples/time_in_zone/rfdetr_stream_example.py:111-117 | examples/time_in_zone/ultralytics_naive_stream_example.py:71-77 | examples/time_in_zone/ultralytics_stream_example.py:50-56 \u2014 before extracting anything, compare \u0060examples/time_in_zone/inference_naive_stream_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 65 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/inference_naive_stream_example.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cf82b7d1a8faa3f25ecf4b48802eb2e7dc2d4f61968164decd96edbabed3305"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): examples/time_in_zone/rfdetr_file_example.py:134-140 | examples/time_in_zone/rfdetr_naive_stream_example.py:137-143 \u2014 before extracting anything, compare \u0060examples/time_in_zone/rfdetr_file_example.py\u0060 and \u0060examples/time_in_zone/rfdetr_naive_stream_example.py\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 71 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060examples/time_in_zone/rfdetr_naive_stream_example.py:134\u0060 calls \u0060tick\u0060 and \u0060examples/time_in_zone/rfdetr_file_example.py:133\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/rfdetr_file_example.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e8ef430d142274bc1742ea17cf81cb1be046c06a29a6d0079adcfd084df4c38"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): examples/count_people_in_zone/inference_example.py:15-29 | examples/count_people_in_zone/rfdetr_example.py:18-32 | examples/count_people_in_zone/ultralytics_example.py:13-27 \u2014 before extracting anything, compare \u0060examples/count_people_in_zone/inference_example.py\u0060 and \u0060examples/count_people_in_zone/rfdetr_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 93 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/count_people_in_zone/inference_example.py"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"6126c451d9b347925d76771a85f84189c90d609783db296c7dce04bb32fee914"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): examples/speed_estimation/inference_example.py:33-38 | examples/speed_estimation/ultralytics_example.py:32-37 | examples/speed_estimation/yolo_nas_example.py:33-38 \u2014 before extracting anything, compare \u0060examples/speed_estimation/inference_example.py\u0060 and \u0060examples/speed_estimation/ultralytics_example.py\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/speed_estimation/inference_example.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f04f254da2e91e5902a0436705ee3304d4134643160f9b7696764655a7094e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): examples/traffic_analysis/rfdetr_example.py:198-214 | examples/traffic_analysis/ultralytics_example.py:187-203 \u2014 before extracting anything, compare \u0060examples/traffic_analysis/rfdetr_example.py\u0060 and \u0060examples/traffic_analysis/ultralytics_example.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 115 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/traffic_analysis/rfdetr_example.py"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"587a71325127f05b43694905c338eed21bcc7304b2f88d7ef8e3d40489768f67"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/key_points/core.py: src/supervision/key_points/core.py changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 42 in KeyPoints.select at line 1169. 17 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/key_points/core.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/core.py"},"region":{"startLine":1169}}}],"partialFingerprints":{"codehealthFindingId/v1":"b079ccb28705c66ccbe8bddfbd34acbd71d20f719932e569cdb49e74bfa98940"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/detection/core.py: src/supervision/detection/core.py changed 36 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in Detections.from_sam3 at line 1040. 16 of those changes were fix/bug commits, and the other 20 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/core.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/core.py"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7bb01953b43bc48ce12385270dee72fe1f194f2b10a7c633401a2cc71e4549f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/dataset/formats/yolo.py: src/supervision/dataset/formats/yolo.py changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in yolo.detections_to_yolo_annotations at line 615. 10 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/formats/yolo.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/yolo.py"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"50121540cb2ed0ac94f591d302900d51e62ee5699ce7e7c666e2057c7e1f1cf5"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/detection/utils/internal.py: src/supervision/detection/utils/internal.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in internal.process_roboflow_result at line 310. 7 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/utils/internal.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/internal.py"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"f319e31cca3f0eb31d2c746c18cadd31580b0a3277887cfad6773647dc1f3e59"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/metrics/mean_average_precision.py: src/supervision/metrics/mean_average_precision.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in COCOEvaluator._accumulate at line 1057. 6 of those changes were fix/bug commits, and the other 7 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/metrics/mean_average_precision.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_precision.py"},"region":{"startLine":1057}}}],"partialFingerprints":{"codehealthFindingId/v1":"186448abd77c43984a014cb74f106d3e3de3037e1e431cc20d9acd5f593fbec2"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/detection/vlm.py: src/supervision/detection/vlm.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in vlm.from_google_gemini_2_5 at line 921. 8 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/vlm.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"694157b45d158a5f8c248daa365b372460cbf9c27868592d761e40caeb85e546"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/dataset/formats/coco.py: src/supervision/dataset/formats/coco.py changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in coco.detections_to_coco_annotations at line 431. 7 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/formats/coco.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/coco.py"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"c455fda5ea3bb14538df7de5be6077632a51f317bd908ffb05a0f81a6147f827"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/detection/compact_mask.py: src/supervision/detection/compact_mask.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in compact_mask._rle_split_cols at line 435. 4 of those changes were fix/bug commits, and the other 5 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/compact_mask.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/compact_mask.py"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"99deb57efc5fbe5187c8bfdffff391276c2d62bd09655c75e3d54addcf0d6489"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/_cv2/_drawing.py: src/supervision/_cv2/_drawing.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in _drawing._clip_line_endpoints at line 288. 8 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/_cv2/_drawing.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_drawing.py"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8d96427b6559591b1377cf7343b4bb85c8dd60dd6449504664f1b88b4e0e1c4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/detection/tools/inference_slicer.py: src/supervision/detection/tools/inference_slicer.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in InferenceSlicer.__call__ at line 316. 4 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/tools/inference_slicer.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/inference_slicer.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"0df67bcfca2f2574c06b5447fd8e86ace9dede026aaeb96adc114ebdbd8d8b1c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/key_points/annotators.py: src/supervision/key_points/annotators.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in EdgeAnnotator.annotate at line 170. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/key_points/annotators.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/key_points/annotators.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7d3c4159ad9fe90730fbc4571a4822af4342aacc4a52701c0a279f5f8a4a91c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/dataset/formats/labelme.py: src/supervision/dataset/formats/labelme.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in labelme.labelme_shapes_to_detections at line 63. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/formats/labelme.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/labelme.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcca0373cc5206676a19acf885b2efe3ce1a34ad486f4ed8d07d4572f78282ff"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: src/supervision/_cv2/_color.py: src/supervision/_cv2/_color.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in _color._cvt_color at line 21. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/_cv2/_color.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_color.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc50e8f8f5e37dbf5ca4d4456bcbdf1badb8c257848ac6b3c6809153a8ccadad"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/_cv2/_image.py: src/supervision/_cv2/_image.py changed 20 times in last 90 days and 17 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is _image._resize at line 235), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(cv2): scale in float32 in the convertScaleAbs fallback like OpenCV (#2935)\u201D; \u201Cfix(cv2): write non-uint8 images like OpenCV in the imwrite fallback (#2901)\u201D; \u201Cfix(cv2): saturate and round drawing colors and border values like OpenCV (#2854)\u201D; \u201Cfix(cv2): honor grayscale image read flags (#2841)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/_cv2/_image.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_image.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb86760a6719e901aaa2941301554b2d0bd4519f0f355aebea0fff63382689b"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/annotators/core.py: src/supervision/annotators/core.py changed 23 times in last 90 days and 12 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is TraceAnnotator.annotate at line 2331), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(annotators): keep labels wider than the frame at its left edge (#2940)\u201D; \u201Cfix(annotators): draw rich labels on grayscale scenes (#2916)\u201D; \u201Cfix(annotators): draw heat maps on grayscale scenes (#2872)\u201D; \u201Cfix: shape Arabic and Hebrew labels in \u0060RichLabelAnnotator\u0060 (#2864)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/annotators/core.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":2331}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e777a3e57bc5139d685d95443dd6e18139c3fe9ae718d5c1dbc949d3bdfe22e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/utils/boxes.py: src/supervision/detection/utils/boxes.py changed 14 times in last 90 days and 11 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is boxes.pad_boxes at line 54), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: prevent integer overflow in XYWH box conversion (#2922)\u201D; \u201Cfix(detection): preserve finite corners across overflowing box spans (#2853)\u201D; \u201CFix float box midpoints overflowing to inf (#2787)\u201D; \u201Cfix(detection): prevent integer overflow when moving boxes (#2734)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/utils/boxes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/boxes.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef4c8a0e1ca5b155458f5543c5b7432fa7ec6ea518b82c50c743e6813637ad79"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/dataset/core.py: src/supervision/dataset/core.py changed 15 times in last 90 days and 10 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is DetectionDataset.merge at line 337), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(dataset): keep mask holes open in COCO polygon export (#2879)\u201D; \u201Cfix(dataset): merge annotations without class IDs (#2858)\u201D; \u201Cfix(dataset): raise when an image cannot be written during export (#2772)\u201D; \u201Cfix(dataset): name the malformed YOLO line instead of failing on its shape (#2665)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/core.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/core.py"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"03b1eac6f790ae855b58d6f2b4b438dae342447e8f282a0929784571707291be"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/dataset/formats/pascal_voc.py: src/supervision/dataset/formats/pascal_voc.py changed 13 times in last 90 days and 10 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is pascal_voc.detections_to_pascal_voc at line 108), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(dataset): reject out-of-range class_id in CreateML and Pascal VOC export (#2859)\u201D; \u201Cfix(dataset): round Pascal VOC bndbox corners instead of truncating them (#2748)\u201D; \u201Cfix(dataset): use devkit box extents for Pascal VOC export and import (#2780)\u201D; \u201Cfix: keep mask holes from becoming extra instances in dataset export (#2703)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/formats/pascal_voc.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/pascal_voc.py"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"87d5c1c92a95264bb1c95dc0e20fffa11ed875bc309d4bcd1fcc0ad14d77db07"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/metrics/mean_average_recall.py: src/supervision/metrics/mean_average_recall.py changed 15 times in last 90 days and 9 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is MeanAverageRecall._compute at line 385), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(metrics): select MeanAverageRecall targets before copying (#2953)\u201D; \u201Cfix(metrics): preserve oriented-box precision in recall and classification metrics (#2887)\u201D; \u201Cfix(metrics): count COCO boundary areas in both mAR size buckets (#2848)\u201D; \u201Cfix(metrics): Preserve scalar metadata in recall size buckets (#2791)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/metrics/mean_average_recall.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/mean_average_recall.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9e42dedcbb364bb94088bb90d2e1d69d121d45237f547a9a556978950687693"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/utils/image.py: src/supervision/utils/image.py changed 14 times in last 90 days and 9 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is image._overlay_image at line 459), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(utils): keep exact fitted size in \u0060resize_image\u0060 and \u0060letterbox_image\u0060 (#2952)\u201D; \u201Cfix(utils): keep (H, W, 1) grayscale images intact in image utilities (#2905)\u201D; \u201Cfix(cv2): honor grayscale image read flags (#2841)\u201D; \u201Cfix(utils): prevent \u0060ImageSink\u0060 from replacing existing images (#2800)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/utils/image.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/image.py"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca16ebb8f03bb7b97f0b32fd86110074cb00b2816721d4a08b5fb2542d235296"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/dataset/utils.py: src/supervision/dataset/utils.py changed 12 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is utils._splice_holes_in_order at line 248), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(dataset): bridge holes from traced contours when simplified ones have no seam (#2933)\u201D; \u201Cfix(dataset): keep mask holes open in COCO polygon export (#2879)\u201D; \u201Cfix(dataset): raise when an image cannot be written during export (#2772)\u201D; \u201Cfix: keep mask holes from becoming extra instances in dataset export (#2703)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/dataset/utils.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/utils.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"d92dfb2beba271e1810a30828c0aae6532ff39ff140cefaade8dcac945adb5a6"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/utils/video.py: src/supervision/utils/video.py changed 12 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is video._validate_and_setup_video at line 183), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(video): stop reading at the requested end (#2874)\u201D; \u201Cfix(video): reject nonpositive frame stride (#2819)\u201D; \u201Cfix(video): release captures when frame setup fails (#2782)\u201D; \u201Cfix(video): cancel source reader after processing failure (#2720)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/utils/video.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/video.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"4522956e0d9d10d2091533c70f31169bff7bc66e60f69c16443bb1148bb49e3d"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/tools/smoother.py: src/supervision/detection/tools/smoother.py changed 11 times in last 90 days and 6 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is DetectionsSmoother.get_smoothed_detections at line 291), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(smoother): leave unconfirmed tracks with a negative \u0060tracker_id\u0060 unsmoothed (#2926)\u201D; \u201Cfix(smoother): merge tracks with mixed oriented history (#2923)\u201D; \u201Cfix(smoother): Prevent overflow in oriented corner alignment (#2785)\u201D; \u201Cfix(smoother): Age history on frames without tracker IDs (#2676)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/tools/smoother.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/smoother.py"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"302055c92f0ace68cefd619b4cd1f104dc13953700c2745234f889e501aa2df2"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/utils/converters.py: src/supervision/detection/utils/converters.py changed 9 times in last 90 days and 6 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is converters.xyxy_to_mask at line 350), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(converters): prevent integer overflow in \u0060xyxy_to_xywh\u0060 (#2951)\u201D; \u201Cfix: prevent integer overflow in XYWH box conversion (#2922)\u201D; \u201Cfix(detection): handle empty polygons in \u0060filter_polygons_by_area\u0060 and \u0060polygon_to_xyxy\u0060 (#2761)\u201D; \u201Cfix(detection): keep off-frame fractional boxes out of masks (#2646)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/utils/converters.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/converters.py"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e560ee521b9a6d142728e177e10021ef0b62323ee53a9130296904042d20950"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/utils/conversion.py: src/supervision/utils/conversion.py changed 9 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is conversion._palette_index_patch at line 112), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(annotators): draw rich labels on grayscale scenes (#2916)\u201D; \u201Cfix(utils): draw annotator colors on Pillow palette scenes (#2907)\u201D; \u201Cfix(utils): keep unannotated pixels of Pillow scenes unchanged (#2883)\u201D; \u201Cfix(utils): convert every Pillow mode to 8-bit BGR or grayscale in \u0060pillow_to_cv2\u0060 (#2614)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/utils/conversion.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/conversion.py"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"a58a0c3a3b34020b91f859dc322647b293f7a0ed632089e8a6b3e43394681d5e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/tools/csv_sink.py: src/supervision/detection/tools/csv_sink.py changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is CSVSink.parse_detection_data at line 201), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(csv): reject extra fields that shadow built-in columns (#2934)\u201D; \u201Cfix(csv): preserve block exceptions during sink cleanup (#2869)\u201D; \u201Cfix: write array-valued data to CSV as parseable lists (#2707)\u201D; \u201Cfix: preserve Unicode in CSV detection exports (#2615)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/tools/csv_sink.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/csv_sink.py"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"d24ceb31f932d417e38f08d10606751ad40a7d17c06807a1f892a2ef97587dc9"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/tools/transformers.py: src/supervision/detection/tools/transformers.py changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 5 (its worst body is transformers.process_transformers_v4_segmentation_result at line 61), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(detection): read zero-shot detections from \u0060from_transformers\u0060 (#2913)\u201D; \u201Cfix(detection): read RF-DETR binary instance maps in \u0060from_transformers\u0060 (#2912)\u201D; \u201Cfix(detection): accept Transformers semantic outputs with scores (#2643)\u201D; \u201Cfix(detection): load v5 instance results returned as binary maps (#2576)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/tools/transformers.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/transformers.py"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"00922ff78f262c6ab3944b1a5a6320ba2664046393b0aca1bd74324bc168ca32"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/_cv2/_transform.py: src/supervision/_cv2/_transform.py changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is _transform._perspective_transform at line 240), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(cv2): blur 16-bit images with OpenCV\u0027s exact sums and float32 scaling (#2875)\u201D; \u201Cfix(cv2): name blur, \u0060approxPolyDP\u0060 and \u0060intersectConvexConvex\u0060 fallback parameters (#2856)\u201D; \u201Cfix(cv2): blur 8-bit images with OpenCV\u0027s integer rounding (#2811)\u201D; \u201Cfix(_cv2): add \u0060getPerspectiveTransform\u0060 and \u0060perspectiveTransform\u0060 (#2652)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/_cv2/_transform.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/_cv2/_transform.py"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"8505cb411a6e84f470cfaf576d540e4b2ad58218b376407dbba1af7c636fa637"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/draw/utils.py: src/supervision/draw/utils.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is utils.draw_image at line 485), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(draw): draw images on grayscale and BGRA scenes (#2906)\u201D; \u201Cfix(draw): scale 16-bit images down in \u0060draw_image\u0060 (#2603)\u201D; \u201Cfix(annotators): draw grayscale PNG icons in \u0060IconAnnotator\u0060 (#2591)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/draw/utils.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/draw/utils.py"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"477d5a08cfb7dabe03af07c9bb7f057d18b22e5863bbaf633428fa9f0e2deb5d"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/detection/utils/masks.py: src/supervision/detection/utils/masks.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is masks.filter_segments_by_distance at line 374), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(detection): prevent integer offset overflow when moving masks (#2918)\u201D; \u201Cfix(detection): preserve narrow mask dimensions when resizing (#2762)\u201D; \u201Cfix(annotators): exclude empty compact masks from the mask blend region (#2741)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/detection/utils/masks.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/masks.py"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"52ae33376143465497da3ab6fb5306c0a81876feb79f664c9835c8f53f8426cc"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: src/supervision/metrics/utils/object_size.py: src/supervision/metrics/utils/object_size.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is object_size.get_detection_areas at line 323), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(metrics): preserve oriented-box precision in recall and classification metrics (#2887)\u201D; \u201Cfix(metrics): count COCO boundary areas in both mAR size buckets (#2848)\u201D; \u201Cfix(metrics): prevent integer overflow in object size categories (#2713)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-16..2026-11-14, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-16 00:10:13 \u002B01:00\u0027 --until=\u00272026-11-14 00:10:13 \u002B01:00\u0027 --full-history --no-merges -- src/supervision/metrics/utils/object_size.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/utils/object_size.py"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"c390f75f6c4b791e0288e75bbd33403658ece78d18d8549fe544df15e8bc60a0"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 1 significant file(s) lose their only recent owner: src/supervision/_cv2/_text.py. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"e6940d4f9b40e96ec4ab42c162b1baeb0fb048030aa9bd7478c5a525642d6c60"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 1 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold \u2014 folded into the bus-factor score and metrics (2 single-owned of 72 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 72 of the 94 production source files in this repository met that bar). They are anonymized user #2 (1 file(s)) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: src/supervision/depth/readers.py."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: # TODO: replace isinstance dispatch with a MaskLike Protocol (separate PR) \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060# REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"da556e0674b4cd859e74ad1ad53a4df92e0322c0ef8f8373f48d86230b354607"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: # noqa: S603 # TODO: Validate command input to prevent execution of untrusted input \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060# REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/time_in_zone/scripts/stream_from_file.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f72c5a634f5d3a996a9c0c22a50e1b1e5e03f98e096e075449d6464202bae54"}},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"357b87d9a5344a0acd9d940831bab003ffcd0db0b10480224b1f5adeb4b4b3d9"},"taxa":[{"id":"CWE-611","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"09eef8b6625b25738f8700358b71be29a093fcfe59905926f2178ad3d178132f"},"properties":{"dependency":{"package":"pillow","version":"12.3.0","advisory":"[GHSA redacted]","aliases":["BIT-pillow-2026-112390","BIT-pillow-2026-112391","BIT-pillow-2026-112392","BIT-pillow-2026-112393","BIT-pillow-2026-112394","BIT-pillow-2026-112395","BIT-pillow-2026-112396","BIT-pillow-2026-112397","BIT-pillow-2026-112398","BIT-pillow-2026-112399","BIT-pillow-2026-112400","BIT-pillow-2026-112401","BIT-pillow-2026-112402","BIT-pillow-2026-112403","BIT-pillow-2026-112404","BIT-pillow-2026-112405","BIT-pillow-2026-112406","BIT-pillow-2026-112891","BIT-pillow-2026-112892","BIT-pillow-2026-112893","BIT-pillow-2026-112894","BIT-pillow-2026-112895","BIT-pillow-2026-112896","BIT-pillow-2026-112897","BIT-pillow-2026-112898","BIT-pillow-2026-112900","BIT-pillow-2026-112901","BIT-pillow-2026-114501","BIT-pillow-2026-96636","BIT-pillow-2026-96637","BIT-pillow-2026-96638","BIT-pillow-2026-96639","BIT-pillow-2026-96640","BIT-pillow-2026-96641","BIT-pillow-2026-96642","BIT-pillow-2026-96643","BIT-pillow-2026-96644","BIT-pillow-2026-96778","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","PYSEC-2026-4326","PYSEC-2026-4327","PYSEC-2026-4328","PYSEC-2026-4329","PYSEC-2026-4330","PYSEC-2026-4331","PYSEC-2026-4332","PYSEC-2026-4333","PYSEC-2026-4334","PYSEC-2026-4335","PYSEC-2026-4336","PYSEC-2026-4337","PYSEC-2026-4338","PYSEC-2026-4339","PYSEC-2026-4340","PYSEC-2026-4341","PYSEC-2026-4342","PYSEC-2026-4343","PYSEC-2026-4363"],"reachability":{"kind":"production","file":"examples/depth_showcase/depth_showcase.py","line":24}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"227de30ae7be437f4f715c4155e4f269c3010acfa07e3ba3da805ef58812ad9d"},"properties":{"dependency":{"package":"transformers","version":"4.49.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","PYSEC-2025-211","PYSEC-2025-212","PYSEC-2025-213","PYSEC-2025-214","PYSEC-2025-215","PYSEC-2025-216","PYSEC-2025-217","PYSEC-2025-218","PYSEC-2026-2290","PYSEC-2026-4174"],"reachability":{"kind":"production","file":"examples/depth_showcase/depth_showcase.py","line":25}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1cd5edb55bbbb627ab2f3a485a1a65f2b7d9e94a298b940d9d0c04d4a4bc987f"},"properties":{"dependency":{"package":"filelock","version":"4.1.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"efbf8eae28b98109bf3fd48bb902502fe1acadac21d4d3c631ef3a831a3d504e"},"properties":{"dependency":{"package":"jaraco-context","version":"6.0.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","PYSEC-2026-1469"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"575e71672c9901048ef5423bc0fd582e533de9919d1255fe21985ccc907301c5"},"properties":{"dependency":{"package":"jupyter-server","version":"2.20.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","PYSEC-2026-4054"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c5edc0ec9e0f535342ada95ecc0efcbfe4f1ed6560267b94d06cbf1fa94b95ad"},"properties":{"dependency":{"package":"soupsieve","version":"2.9","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"872f8162dfe13e3ca9045a654de4ba73d52fa5d70a9569c7bfd6e95b722f8813"},"properties":{"dependency":{"package":"tornado","version":"6.5.10","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"eb00976a698a5d68999b7ee6d27206fd374e916853e7ff1ead5eed42386f043f"},"taxa":[{"id":"CICD-SEC-9","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9e238042ec4000c74ea100daa2e1d550d8f67c4e4d6db3cfb6f2c9f84f3f4979"},"taxa":[{"id":"CICD-SEC-5","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"M2","level":"note","message":{"text":"No ADRs: No Architecture Decision Records found \u2014 no conventional ADR directory, no numbered \u0060NNNN-title\u0060 documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"670b3d6e36a756d63097d0dfbf90afd5fc761308800b9354894a07c3f4e4aa14"}},{"ruleId":"M2","level":"note","message":{"text":"No architecture diagram/doc: No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named \u0060architecture\u0060 or \u0060design\u0060 in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape \u2014 no \u0060## Architecture\u0060 heading, no \u0022architecture overview\u0022/\u0022high-level design\u0022 phrasing, no \u0022the architecture is \u2026\u0022 introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document \u2014 not evidence that nobody wrote the shape down."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0c190e7c159d1850ee706c3ac4486e151e8a4fe169de4bf61436b9f399654f06"}},{"ruleId":"P3","level":"note","message":{"text":"No SAST: No static application security testing detected. For this repository\u0027s stack, add bandit, \u0060semgrep --config=p/python\u0060, or CodeQL\u0027s python pack as a CI step. What was searched, so you can tell an absence from a miss: the 14 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge\u0027s web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen \u2014 if that is your case the row is wrong, and saying so is more useful than adding a second scanner."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":".github/workflows/ci-build-docs.yml"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e54424179c892f03ef2fd003130ac4bd43f39bbf3b1ca0a0143e25acb80ec87"}},{"ruleId":"P3","level":"note","message":{"text":"Dependabot does not watch uv: \u0060.github/dependabot.yml\u0060 schedules updates, but no \u0060package-ecosystem\u0060 entry covers \u0060uv\u0060, which this tree depends on \u2014 so those dependencies get no update pull requests and no advisory pressure, however complete the dep-scan credit looks. Add the missing entry to the \u0060updates:\u0060 list."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":".github/dependabot.yml"},"region":{"startLine":2}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ed202f0b8c65987b68a54d94365b30bc5060f82aa41cda10a8502aa9b58ed3c"}},{"ruleId":"S1","level":"note","message":{"text":"Security headers incomplete: Set: Content-Security-Policy, Permissions-Policy, Referrer-Policy, Strict-Transport-Security, X-Content-Type-Options. Missing: X-Frame-Options \u2014 the four headers that carry the points of this card\u0027s security-headers term (Content-Security-Policy, Strict-Transport-Security, X-Content-Type-Options, X-Frame-Options), 0.5 each. (\u22120.5 on this card.)"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/_headers"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"906991fef79b762203289a0b35018c482cbb7153d01544db94bc8aa89b90cc82"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060box.shape != (4,) or not np.isfinite(box).all()\u0060 appears character-identically in 2 files \u2014 src/supervision/depth/core.py, src/supervision/detection/vlm.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/depth/core.py"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b3065010aeb9c682565370377f39e4c73516b5811a9d99c5df85f07164d484e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060class_index \u003C 0 or class_index \u003E= len(classes)\u0060 appears character-identically in 2 files \u2014 src/supervision/dataset/formats/createml.py, src/supervision/dataset/formats/labelme.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/createml.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea3649220f30795ad3f6c34f9d3704ab774dee3a6300ab07308a8b0e62f1e3d5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060detections.is_empty() or size_category == ObjectSizeCategory.ANY\u0060 appears character-identically in 2 files \u2014 src/supervision/metrics/_confusion_matrix_metric.py, src/supervision/metrics/mean_average_recall.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"181884500a73db90037dcf5620ea205d133cac9305d3dfb0a059b9c585339ba8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(class_id, np.ndarray) and class_id.shape == (n,)\u0060 appears character-identically in 2 files \u2014 src/supervision/classification/core.py, src/supervision/validators/__init__.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/classification/core.py"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"88a1e8e134d4f458aa8b07de16135b69d759749f2ae4e9b8e554b9c3e0badb70"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(confidence, np.ndarray) and confidence.shape == (n,)\u0060 appears character-identically in 2 files \u2014 src/supervision/classification/core.py, src/supervision/validators/__init__.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/classification/core.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"b51afec9c746e0cac915bfefd4cf66241082271a28456424ab8901000bb424b0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, (int, np.integer)) and not isinstance(value, bool)\u0060 appears character-identically in 2 files \u2014 src/supervision/dataset/utils.py, src/supervision/detection/compact_mask.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/utils.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf7cb77cb7d5e4802368818e67cf6134735256a2bb035fe134edfc0c3c8e6b53"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, (list, tuple)) and len(value) == n\u0060 appears character-identically in 2 files \u2014 src/supervision/detection/tools/csv_sink.py, src/supervision/detection/tools/json_sink.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/csv_sink.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"77bf85f203c94b7eaad25b8d9b6020a0395a5b38aa8a15adb855e6b4aab9e442"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(boxes_detection) == 0 or len(boxes_true) == 0\u0060 appears character-identically in 2 files \u2014 src/supervision/detection/utils/iou_and_nms.py, src/supervision/metrics/mean_average_precision.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/utils/iou_and_nms.py"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"681b3573c73b9f66c87f7474b6f18169c8ddb8bc72a990ebcf08896907e4cd81"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060math.isfinite(low) and math.isfinite(high)\u0060 appears character-identically in 2 files \u2014 src/supervision/depth/annotators.py, src/supervision/depth/core.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/depth/annotators.py"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fbcbb458747954f568d2b79572a237ec033664f9a918e7112651d44778f5a28"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not polygons and not mask_to_polygons(mask=mask)\u0060 appears character-identically in 2 files \u2014 src/supervision/dataset/formats/pascal_voc.py, src/supervision/dataset/formats/yolo.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/dataset/formats/pascal_voc.py"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"124f3d170bd856ee0f83bd044d5c110ce79291f334ce7c02a759bf2af38ee21c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060parent_directory and not os.path.exists(parent_directory)\u0060 appears character-identically in 2 files \u2014 src/supervision/detection/tools/csv_sink.py, src/supervision/detection/tools/json_sink.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/tools/csv_sink.py"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6454a5b85b885b891796eb039b63afe03cf58824dd166d551470b76bd512f4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060position == Position.CENTER or position == Position.CENTER_OF_MASS\u0060 appears character-identically in 2 files \u2014 src/supervision/annotators/core.py, src/supervision/annotators/utils.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/annotators/core.py"},"region":{"startLine":3153}}}],"partialFingerprints":{"codehealthFindingId/v1":"61cc65b22104c593efc541b42acc71bfbd8a159b168e13900cf51f8d72ce2c6c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060predictions.class_id is None or targets.class_id is None\u0060 appears character-identically in 3 files \u2014 src/supervision/metrics/_confusion_matrix_metric.py, src/supervision/metrics/detection.py, src/supervision/metrics/mean_average_recall.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/metrics/_confusion_matrix_metric.py"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"05e87bc72220a386bdd40ed6969ebbf02773a8e4dccb8d60120ccc5ada0fde1f"}},{"ruleId":"X2","level":"note","message":{"text":"Not all async functions that make a request accept an AbortSignal: Only 0/1 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up \u2014 a page navigated away from, an unmounted component, a timed-out job. Take a \u0060signal\u0060 (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice \u2014 judge against how the function is used."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"bd89d014f84408f7063269aa5892ba3df7c9af3e981ecfb0752c5731bc62d406"}},{"ruleId":"X2","level":"warning","message":{"text":"Async function without AbortSignal: renderCard: \u0060renderCard\u0060 awaits \u0060fetch(\u2026)\u0060 but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept \u0060{ signal }\u0060 and pass it through: \u0060fetch(url, { signal })\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/javascripts/cookbooks-card.js"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"554c4b10be8fca5e0868997770c75a816b2a06802779b538e1f065eefeedcd98"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/utils/image_window.py"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"841dbd058dd56cacda1f0c7bcebe229908aa3e723bd47b38efd672b1c1e507f2"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"src/supervision/detection/vlm.py"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"c36b6473fbc4b5cf57ff2e90bcb3700a4ca0e8e2fb0a1aa2f8eea64535aade9d"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1357","guid":"e4d2e772-757e-0a5c-bd7d-77052949d866","name":"Reliance on Insufficiently Trustworthy Component","shortDescription":{"text":"Reliance on Insufficiently Trustworthy Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1357.html"},{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-494","guid":"b8a65e0d-e459-4a55-a931-fc1136482375","name":"Download of Code Without Integrity Check","shortDescription":{"text":"Download of Code Without Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/494.html"},{"id":"CWE-506","guid":"401d6455-56e3-0552-9a39-f77461673e3f","name":"Embedded Malicious Code","shortDescription":{"text":"Embedded Malicious Code"},"helpUri":"https://cwe.mitre.org/data/definitions/506.html"},{"id":"CWE-611","guid":"1afbae66-ea29-2d59-aaa2-134e3ae2e85a","name":"Improper Restriction of XML External Entity Reference","shortDescription":{"text":"Improper Restriction of XML External Entity Reference"},"helpUri":"https://cwe.mitre.org/data/definitions/611.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)","shortDescription":{"text":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Improper Control of Generation of Code (\u0027Code Injection\u0027)","shortDescription":{"text":"Improper Control of Generation of Code (\u0027Code Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]},{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61","version":"2025","organization":"OWASP Foundation","informationUri":"https://top10.owasp.org/2025/","isComprehensive":false,"shortDescription":{"text":"The OWASP Top 10:2025 web application security risks."},"taxa":[{"id":"A02:2025","guid":"668dee9e-41bc-6354-97d0-fdf8f40c50c1","name":"Security Misconfiguration","shortDescription":{"text":"Security Misconfiguration"},"helpUri":"https://top10.owasp.org/2025/A02_2025-Security_Misconfiguration/"},{"id":"A03:2025","guid":"168e227c-7735-2e57-bc6e-997affe644c5","name":"Software Supply Chain Failures","shortDescription":{"text":"Software Supply Chain Failures"},"helpUri":"https://top10.owasp.org/2025/A03_2025-Software_Supply_Chain_Failures/"},{"id":"A05:2025","guid":"87e86033-3231-8458-8e4a-5cb82743553a","name":"Injection","shortDescription":{"text":"Injection"},"helpUri":"https://top10.owasp.org/2025/A05_2025-Injection/"},{"id":"A07:2025","guid":"334ddd78-539d-d35c-83dd-253647eb7eaf","name":"Authentication Failures","shortDescription":{"text":"Authentication Failures"},"helpUri":"https://top10.owasp.org/2025/A07_2025-Authentication_Failures/"},{"id":"A08:2025","guid":"84b0c297-710e-9a5f-9335-936ecb260c36","name":"Software or Data Integrity Failures","shortDescription":{"text":"Software or Data Integrity Failures"},"helpUri":"https://top10.owasp.org/2025/A08_2025-Software_or_Data_Integrity_Failures/"}]},{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35","organization":"OWASP Foundation","informationUri":"https://owasp.org/www-project-top-10-ci-cd-security-risks/","isComprehensive":false,"shortDescription":{"text":"The OWASP Top 10 CI/CD Security Risks."},"taxa":[{"id":"CICD-SEC-5","guid":"cc7f4610-8859-e654-9029-d5f97d992220","name":"Insufficient PBAC (Pipeline-Based Access Controls)","shortDescription":{"text":"Insufficient PBAC (Pipeline-Based Access Controls)"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-05-Insufficient-PBAC"},{"id":"CICD-SEC-9","guid":"b3d36727-0395-5b51-94c4-5e173d62eab3","name":"Improper Artifact Integrity Validation","shortDescription":{"text":"Improper Artifact Integrity Validation"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-09-Improper-Artifact-Integrity-Validation"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":10,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}