Sample
Dorn/cuda/58
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.005 | 0–1; higher is more readable | 65.7Δ 59.1 |
| Scalabrino | 0.166 | 0–1; higher is more readable | 11.6Δ 4.9 |
| Dorn | 0.007 | 0–1; higher is more readable | 1.1Δ 5.6 |
| Mi | 0.502 | 0–1; higher is more readable | 51.8Δ 45.1 |
| LLOC | 3 | Logical lines; fewer is more readable | 88.6Δ 81.9 |
| DeepSeek V4 Pro | 7 | 0–20; mean of three runs | 22.7Δ 16.0 |
| GPT-6.1 Sol | 11.33 | 0–20; mean of three runs | 15.5Δ 8.8 |
| BTTF | 0.032 | 0–1; higher is more readable | 0.8Δ 5.8 |
| Human | 2.23 | 1–5; original rating | 6.7 |
Views
Select the downloaded ZIP or its extracted folder. Files stay in your browser.
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. | 323.855 | −10.687 |
| 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.98 | −7.47 |
| Source linesThe number of non-empty source lines. | 10 | +4 |
Intercept 8.87 + feature contributions = -5.287 (log-odds).
Score = sigmoid(-5.287) = 0.005.
| Score | 0.166 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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. | 193 | −4.51 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 11 | +0.647 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 10 | −0.391 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 9.933 | −0.271 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.104 | −0.067 |
Intercept 0.07 + feature contributions = -4.928 (log-odds).
Score = sigmoid(-4.928) = 0.007.
| Score | 0.502 |
|---|
| Score | 3 |
|---|
Run 1
The code snippet is incomplete and lacks sufficient context for a thorough evaluation. The function signature is clear with descriptive parameter names (e.g., output, Sample, dCenters, dWeights), but the overall structure is minimal. Thread index calculations use standard CUDA patterns, making the code somewhat readable. The nesting is shallow (one line of index computation), and the code length is concise. However, without the full kernel body, it is difficult to assess action granularity and reading flow. The use of generic type `cudafloat` is slightly ambiguous. Overall, it is understandable but incomplete.
Run 2
The code is nearly unreadable due to a complete lack of structure and clarity. It consists of a single function signature with poorly named parameters (e.g., dCenters, dWidths, idnx) and no comments or documentation explaining purpose. The kernel launches thread indices but provides no logic or context, making intent ambiguous. Nesting is absent, but only because there is no implementation to evaluate. Code length is minimal but meaningless. Action granularity and reading flow are poor due to abrupt parameter capitalization and no formatting. This appears to be an incomplete or obfuscated snippet, scoring very low on readability.
Run 3
The code defines a CUDA kernel with clear mathematical purpose (likely RBF network activation), and the single calculation of thread indices is straightforward. However, readability is poor: variable names are cryptic and inconsistently abbreviated (e.g., 'dCenters', 'NumCenters'), the function signature is extremely long and dense, and there is no whitespace or comments to explain parameters. The logic stops after computing indices, so the core action is absent, making intent hard to assess. The function has minimal nesting but suffers from low clarity and poor naming conventions. While the structure is not tangled, the lack of documentation and unclear parameter roles reduce the score significantly. Overall, the code is hard to follow without external context.
Run 1
Code Structure: The thread-index calculations are logically grouped, but the snippet is incomplete and the long kernel signature is poorly organized. Nesting: The visible body is flat and easy to follow. Clarity of intent: The kernel name suggests network activation, but only index initialization is shown; abbreviations such as idnx and idny and inconsistent parameter naming reduce clarity. Code length: The body is concise, though excessive leading blank lines add clutter and the signature would benefit from wrapping. Action granularity: Each statement performs one clear calculation on its own line. Reading flow: The two parallel index calculations read naturally, but inconsistent spacing and the missing closing brace interrupt the overall flow.
Run 2
Code Structure: A straightforward kernel declaration followed by thread-index calculations, but the snippet is incomplete and has excessive leading blank lines. Nesting: Flat, with no nested control flow shown. Clarity of intent: The function name suggests network activation, and the index calculations are recognizable CUDA patterns, but abbreviated names and undocumented parameters reduce clarity. Code length: The body is concise, while the long, unformatted parameter list is harder to scan. Action granularity: Each shown statement performs one clear calculation on its own line. Reading flow: The two index calculations follow a natural parallel structure, but inconsistent spacing, capitalization, and the missing remainder of the function interrupt readability.
Run 3
Code Structure: The kernel declaration followed by thread-index calculations is logically organized, but the snippet is incomplete. Nesting: The visible body is flat and easy to follow. Clarity of intent: The function name suggests network activation, and the index calculations are recognizable CUDA patterns, but abbreviated names and undocumented parameters obscure details. Code length: The body is concise, while the long single-line parameter list and excessive leading blank lines reduce readability. Action granularity: Each index calculation occupies its own line. Reading flow: The calculations flow naturally, but inconsistent spacing, a crowded signature, and the missing closing brace interrupt reading.