r/deeplearning • u/felixr314 • 17m ago
Asymmetric multi-head AlphaZero in C++: two kamikaze drones learn a pincer attack via self-play (new in Metis-Core v0.4.0-alpha)
Enable HLS to view with audio, or disable this notification
r/deeplearning • u/felixr314 • 17m ago
Enable HLS to view with audio, or disable this notification
r/deeplearning • u/PanelReader • 4h ago
hey everyone!
recently built a 2 → 3 → 1 XOR neural network using NumPy, without PyTorch or TensorFlow.
wanted to understand backpropagation properly, so I implemented the mathematics and gradient descent manually.
trained it for 5,000 epochs and achieved 4/4 correct classifications.
the repo includes mathematical derivations, training visualizations and 12 editable diagrams.
also wrote a detailed Medium article explaining the process.
GitHub: https://github.com/Vaibh37/Neural-Network
would appreciate feedback on the implementation. if you find it useful, consider starring the repo 🍀
r/deeplearning • u/Radiant_Tax3312 • 21h ago
We had 480 model outputs reviewed by 3 people, which gave us 1440 total reviews. With prior scores and comments visible on the 2nd and 3rd passes, the report counted 1022 matching judgments across those 1440 reviews. We treated that as solid inter rater agreement and decided the rubric was stable. The scores matched and our human scoring looked calibrated. The agreement chart looked very pleased with itself.
So we reran the same set as a blind review. Matches dropped to 749 and 96 rows showed different readings of the rubric. Watching agreement fall as soon as the prior comments disappeared was a rough meeting. Removing score visibility made reviewer anchoring hard to ignore. Our rubric calibration had trained people to align with an existing judgment and hidden where the criteria were ambiguous. The adjudication queue now holds cases where 1 reviewer marks partial compliance as pass while another marks it as fail. I’m trying to decide whether those 96 rows need rewritten criteria, more calibration examples or fresh reviewers before we trust the next agreement number.
How are you separating a stable rubric from reviews that only converge after someone sees the 1st score
r/deeplearning • u/lukiamagi • 6h ago
r/deeplearning • u/kbhaskar306 • 8h ago
Stop typing boilerplate code and start designing with AI! 🚀
Learn how to optimize your coding workflow with ChatGPT and GitHub Copilot today.
Check out the full guide on my profile!
#AI #Coding #Tech #DataScience
r/deeplearning • u/CivilSnow5625 • 18h ago
I made [Sigularty](https://github.com/DewanshShah/Sigularty), an algorithm that combines multiple compression techniques, takes in any model and chooses which techniques to use, and also finds hyperparameters for a few of the techniques. This is one of my first proper projects, and I would love feedback. It is completely free and open source, and these are a few results the algorithm achieved by itself, without any human fine-tuning
|Model|Acc Drop|Compression Ratio|CQI|Speedup|Size (MB)|Accuracy (%)|Latency (ms)|
|:-|:-|:-|:-|:-|:-|:-|:-|
|`Resnet50`|**2.20%**|**8.00x**|**9.897**|**1.28x**|90.66 -> 11.34|66.60 -> 64.40|6.977 -> 5.451|
|`vit_b_16`|**0.00%**|**4.51×**|**4.526**|**1.00x**|327.59 -> 72.67|77.00 -> 77.00|14.96 -> 14.90|
|`efficientnet_b0`|**2.80%**|**2.61x**|**2.284**|**0.90x**|15.95 -> 6.11|91.80 -> 89.00|8.238 -> 9.124|
|`bert_base`|**4.20%**|**6.61x**|**6.449**|**1.02x**|417.66 -> 67.17|86.20 -> 82.00|10.393 -> 10.209|
|`distilbert`|**5.60%**|**9.55x**|**7.049**|**0.78x**|255.42 -> 26.75|82.40 -> 76.80|5.441 -> 6.957|
|`distilgpt2`|**0.00%**|**2.00x**|**2.903**|**1.45x**|312.48 -> 156.24|87.20 -> 87.20|8.559 -> 5.896|
r/deeplearning • u/Glad_Builder_4555 • 15h ago
I wrote a short technical report and then animated it, hoping it's useful to people learning about autoencoders, OOD detection, or mixture-of-experts.
The idea in three steps:
That fingerprint can act as a router between expert models, with no extra gating network to train.
Video: https://www.youtube.com/watch?v=4UhvpIWnOvg Paper: https://arxiv.org/abs/2512.16963
r/deeplearning • u/Yossarian_1234 • 1d ago
r/deeplearning • u/Intrepid_Discount_67 • 1d ago
Enable HLS to view with audio, or disable this notification
r/deeplearning • u/Classic-Fee-8468 • 1d ago
Hey all. I've been working on table extraction from PDFs without any deep learning, and finally open-sourced it. Thought this sub might find the approach interesting (or tear it apart, which is also useful).
The pipeline, roughly:
- Bordered tables: morphological opening with long horizontal/vertical kernels to isolate ruling lines, then contour analysis on the line mask to find table regions.
- Borderless tables: detected from text alignment instead. Words are grouped into phrases and checked for left/centre/right alignment across consecutive lines. When enough rows and columns line up, I draw "pseudo-boundaries" onto the image so the rest of the pipeline treats it like a bordered table.
- Structure: text is masked out first, then LSD (Line Segment Detector) finds segments, which are clustered and merged into a grid. A spanning cell is recovered from missing line segments: if a separator is absent across part of the grid, those cells merge (union-find over the cells).
- Text: for digital PDFs, characters come straight from the PDF text layer and are mapped onto the cell grid, so there are no OCR errors on part numbers. OCR (Tesseract or a plugin engine) only runs on scanned pages.
- Post-processing: nested header detection, key-value vs normal table classification, and merging tables that continue across pages (by matching column widths and headers).
Everything runs on CPU, roughly 0.3–1.5 s/page on a laptop, and every decision traces back to a threshold you can inspect. All pixel thresholds are defined at 300 DPI and scale with resolution.
Where it struggles:
- skewed scans (no de-skewing yet; the line detector only tolerates ~2 px of drift)
- small borderless blocks where a header row can be mistaken for key-value pairs
- wrapped text in borderless cells sometimes splits into extra rows
Contributions very welcome. MIT licensed, no need to ask first, just fork and PR. Some things I'd love help with:
- de-skew estimation (Hough/projection-based) before detection
- evaluating on ICDAR 2013 / PubTables-1M / FinTabNet with GriTS or TEDS; I don't have a proper benchmark yet, and that's the biggest gap
- better row reconstruction for borderless tables with wrapped cells
- plugging in other OCR engines (there's a plugin interface + EasyOCR example)
Repo: https://github.com/shlok-n/spartan · pip install spartan-tables
r/deeplearning • u/ThoughtfulVoyager8 • 22h ago
r/deeplearning • u/No-Conclusion3720 • 20h ago
Over 1,500 npm packages were compromised in a supply-chain attack last week, according to Help Net Security. One infected dependency is enough to execute arbitrary code. AI coding agents and automated pipelines pull these packages as trusted dependencies during normal operation. When an agent installs or executes a tampered package, the payload runs with full session permissions. The agent does not know the package is malicious. The tool call that fetches the dependency is the attack surface.
This is no longer just a developer workstation problem. Autonomous agents run these installs without a human in the loop, at scale, across environments.
How are teams actually handling package execution trust in their agent pipelines right now? Allowlists, sandboxing, something else?
r/deeplearning • u/Rafaelvariavel • 1d ago
Treinei dois modelos de machine learning:
Um classificador de sentimentos (positivo, negativo e neutro)
Um classificador de idiomas com suporte para 59 línguas
O detalhe? Não lembro a acurácia de nenhum dos dois e ainda perdi o dataset que usei. 🤡
👉 Acesse os modelos aqui:
🔗 Classificador de Sentimentos: https://huggingface.co/Rafaelvieira432/LANG-10M
🔗 Classificador de Idiomas (59 línguas): https://huggingface.co/Rafaelvieira432/SENTIMENT-21M
r/deeplearning • u/AsyncVibes • 1d ago
Enable HLS to view with audio, or disable this notification
r/deeplearning • u/atronos_kronios • 1d ago
I implemented GPT-2 small and KV caching in PyTorch to connect the maths with actual inference measurements. I have written up the experiment as the first post on my new blog.
Setup: NVIDIA A40, fp32 with TF32 disabled, batch size 1, greedy decoding, CUDA synchronization around timings, median of five runs per context length. Pretrained weights were loaded and logits checked against Hugging Face; cached and uncached greedy output matched over 200 tokens.
At context length 1,000, my FLOP estimate falls by 1,000x, while per-token latency goes from 29.69 ms to 4.95 ms. Generating 1,016 tokens takes 14.66 s versus 5.03 s. The cached latency is roughly flat, so I want to profile the remaining overhead rather than assume the cause.
The post also covers why a wrong cache order can pass single-token tests, and how a cuBLAS workspace contaminated my memory baseline. After warmup, requested KV bytes match 72 KiB/token; allocator block sizes still produce a separate hump.
Post: https://angry-kratos.github.io/posts/2026-10-kv-cache/
Code: https://github.com/angry-kratos/angry-kratos.github.io/tree/main/code/kv-cache
I am the author and would welcome methodological criticism. What profiling experiment would you prioritize to separate CPU/kernel-launch overhead from GPU memory traffic here? AI assistance was used for editing and tooling; this is an educational experiment, not a claim of a new caching algorithm.
r/deeplearning • u/Mind_the_math • 2d ago
Hi all! I'm AI engineer. This is the first video on my channel. I tried to build Adam from scratch, motivating each step by a concrete problem of the previous one: plain GD, Nesterov, AdaGrad, RMSProp ...
All animations are made with Manim. I'd really appreciate feedback, especially on anything that's mathematically imprecise or unclear.
r/deeplearning • u/MeasurementDull7350 • 1d ago
r/deeplearning • u/No-Conclusion3720 • 1d ago
Traditional security math assumes you can stack independent controls and multiply down the risk. Frontier AI broke that assumption.
When a large model processes a request, it pulls context from whatever retrieval layer is in scope — documents, records, API responses — including fields that were never supposed to leave their origin system. The model has no concept of data classification. A social security number and a product SKU look identical to it. Output can contain that field verbatim, paraphrased, or reconstructed from inference. None of those surface reliably in DLP rules built for exact-match or structured-transit detection.
Security Boulevard covered the underlying shift this week: AI systems do not fit the attacker-defender math that security teams have built their models on. A single node that is simultaneously a data aggregator, a reasoning engine, and an unstructured output channel breaks the independence assumption that makes multiplicative risk reduction work. Teams running AI in production with real customer data are discovering control blind spots they did not know existed.
For those actually operating AI pipelines with sensitive customer data: where in the stack are you catching PII that enters model context through retrieval? Pre-inference, post-inference, somewhere else entirely — and are your current tools even visible to the model's output stream?
r/deeplearning • u/Defiant_Pickle616 • 2d ago
The idea in one paragraph: over 2x2 real matrices, i² = −1 has two orthogonal solutions, rotation by +90 and −90 degrees:
i₊ = [[0, −1], [1, 0]], i₋ = [[0, 1], [−1, 0]]
Square either one and you get [[−1, 0], [0, −1]] = −I, so both are genuine square roots of minus one. Their combination is
S(θ) = cosθ · i₊ + sinθ · i₋ = [[0, −(cosθ − sinθ)], [cosθ − sinθ, 0]]
whose off-diagonal entry is
±(cosθ − sinθ)
That ± in front is a binary object sitting inside a smooth formula. SANATAN promotes it into an explicit soft variable:
r = tanh( γ ( cos(θ+ω) − sin(θ+ω) ) ) ≈ ±1
Each token projection u becomes an angle θ = π·u / (1 + |u|), every feature dimension softly picks a root, and the six-channel feature map
Φ(x) = [ 1, cosθ, sinθ, r, r·cosθ, r·sinθ ]
makes the attention score factorize exactly:
⟨Φ(q), Φ(k)⟩ = (1 + r_q r_k)(1 + cos Δθ)
a per-dimension parity gate (0 or 2 for hard roots) times an angular similarity. The GIF above walks through it step by step.
Because the score is an inner product, the p=1 case runs as an exact recurrence with a constant-size state, no KV cache and no decay:
S_t = S_{t−1} + Φ(k_t) v_tᵀ, z_t = z_{t−1} + Φ(k_t), out = ⟨Φ(q), S⟩ / ⟨Φ(q), z⟩
What I measured (184M params, single seeded held-out protocol):
- The recurrence is exact in practice, not just on paper: parallel and recurrent computation of the trained model agree within 1e-4 nats (float32). There is a demo notebook that reproduces this on CPU in about two minutes on a small model (agreement ~4e-6 per logit).
- Quality survives the constant state: 3.951 held-out loss recurrent vs 3.966 for its full parallel parent, via a two-stage recipe (sharpened pretraining, brief p=1 adaptation). Deploying p>1-trained models through the recurrence costs ~5 nats, so that path is dead and the paper says so.
- Decode: fixed 14.4 MB state vs a KV cache that hits 2.4 GB at 32K context; 0.153 ms/token flat vs 0.49 to 7.3 ms/token for softmax decoding (3.2x to 48x from 1K to 32K).
- Ablation: the root-parity gate is worth +0.53 nats over the same angular kernel without it.
Paper (PDF): https://github.com/bhargavpatel431997/sanatan-attention/blob/main/paper/sanatan_v2.pdf
Code + runnable demo notebook: https://github.com/bhargavpatel431997/sanatan-attention
Visual explainer of the idea: https://github.com/bhargavpatel431997/sanatan-attention/blob/main/docs/MOTIVATION.md
Independent researcher, single GPU/TPU budget, so critiques and pointers are genuinely welcome, especially from anyone who has tried interaction-level gating inside linear attention before.
Thanks for reading,
Bhargav Patel
r/deeplearning • u/Endless4AI • 2d ago