Sample
Schnappinger/aoi/artofillusion.animation.distortion.CustomDistortion
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 31.1Δ 7.7 |
| Scalabrino | 0.385 | 0–1; higher is more readable | 3.8Δ 19.7 |
| Dorn | 0.19 | 0–1; higher is more readable | 40.3Δ 16.8 |
| Mi | 0.401 | 0–1; higher is more readable | 24.8Δ 1.3 |
| LLOC | 68 | Logical lines; fewer is more readable | 30.7Δ 7.3 |
| DeepSeek V4 Pro | 14.33 | 0–20; mean of three runs | 32.3Δ 8.9 |
| GPT-6.1 Sol | 16 | 0–20; mean of three runs | 38.9Δ 15.5 |
| BTTF | 0.355 | 0–1; higher is more readable | 28.4Δ 5.0 |
| Human | 2.99 | 1–4; original rating | 23.4 |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 4664.347 | −153.923 |
| Source linesThe number of non-empty source lines. | 114 | +45.6 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 4.743 | −7.115 |
Intercept 8.87 + feature contributions = -106.568 (log-odds).
Score = sigmoid(-106.568) = 0.
| Score | 0.385 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 114 | −3 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 106 | +2.929 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 106 | −2.012 |
| Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names. | 128.982 | −1.798 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 128.991 | +1.277 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 112.754 | +1.166 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.106 | −0.086 |
Intercept 0.07 + feature contributions = -1.453 (log-odds).
Score = sigmoid(-1.453) = 0.19.
| Score | 0.401 |
|---|
| Score | 68 |
|---|
Run 1
The code has clear structure with logical method separation and a readable copyright header. The constructor and duplicate() method are straightforward. However, isIdenticalTo() contains deep nesting and duplicated null-checking logic that could be simplified, reducing readability. The transform() method is mostly clear but mixes multiple actions per line in several assignments, lowering action granularity. Variable names like 'w2' and 'proc' are terse but acceptable. Overall, the code is understandable but has moderate complexity in comparisons and some dense lines.
Run 2
The code is generally readable with clear naming, logical class structure, and straightforward methods. However, several issues reduce readability. The `isIdenticalTo` method is long and deeply nested, with null-checking logic that interrupts flow. The `transform` method mixes multiple operations per line (e.g., weighted value calculations) and has a dense loop body. The use of `output[0]`, `output[1]`, `output[2]` lacks descriptive indexing. Some magic numbers (e.g., `0.0`, `1.0`) and repeated null-check patterns could be extracted. While the overall intent is clear, the code would benefit from refactoring to reduce nesting and improve action granularity.
Run 3
The code has a clear class structure with organized methods for comparison, duplication, and transformation. However, readability is reduced by the deeply nested and verbose isIdenticalTo method, which contains multiple if-else blocks and a loop inside a nested branch. The transform method is relatively flat but contains several similar operations that could be extracted into a helper. Variable names like 'w2' and 's' are unclear, and null-check branching adds cognitive load. Action granularity is mostly one action per line, and intent is generally understandable, but the overall flow could be improved by simplifying conditional logic and reducing repetition.
Run 1
Code Structure: Clearly separated constructor, comparison, duplication, and transformation methods provide logical organization. Nesting: Mostly shallow, with early returns reducing complexity; parameter comparison adds moderate nesting. Clarity of intent: Method comments and descriptive fields explain the purpose, but abbreviated locals such as s, d, vert, and w2, plus unexplained output indices, require interpretation. Code length: Reasonably concise, although coordinate updates repeat similar logic and equality checking is somewhat verbose. Action granularity: Statements generally perform one action per line, making state changes easy to follow. Reading flow: Transformation proceeds naturally from duplication through per-vertex processing to returning the mesh. Unusual brace indentation, inconsistent array declaration styles, omitted conditional braces, and tightly spaced arithmetic slightly disrupt readability.
Run 2
Code Structure: The class is logically organized into initialization, equality checking, duplication, and mesh transformation. Nesting: Early returns keep comparisons relatively flat; parameter checks and the vertex loop introduce only moderate nesting. Clarity of intent: Method names and brief documentation explain the purpose, but abbreviated variables such as s, d, vert, and w2, implicit output-index meanings, and shared mutable point state require interpretation. Code length: Generally concise, although repetitive coordinate updates and manual parameter comparisons add some verbosity. Action granularity: Statements mostly perform one action per line, making execution easy to follow. Reading flow: Transformation steps progress naturally from duplication through pre-transformation, procedural evaluation, blending, and post-transformation. Unconventional brace indentation, inconsistent array declaration styles, omitted conditional braces, and tightly spaced arithmetic slightly reduce readability.
Run 3
Code Structure: The class is logically divided into construction, equality checking, duplication, and transformation, with helpful method comments. Nesting: Mostly shallow; early returns keep equality checks manageable, though parameter comparison adds some nesting. Clarity of intent: Method names and the transformation sequence communicate purpose well, but abbreviated variables such as s, d, vert, and w2, plus unexplained output indices, require interpretation. Code length: Reasonably concise, although repeated coordinate calculations and detailed equality checks could benefit from small helper methods. Action granularity: Statements generally perform one action per line; compound conditions remain understandable. Reading flow: Execution proceeds naturally from prior distortion through mesh duplication, vertex processing, and result assignment. Inconsistent array declaration styles, unusual brace indentation, omitted braces around conditional bodies, and tight operator spacing slightly reduce scanability.