<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Divyakush Punjabi</title>
    <description>The latest articles on DEV Community by Divyakush Punjabi (@dev-into-space).</description>
    <link>https://dev.to/dev-into-space</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4076031%2F6c15fac4-217a-46b7-a390-d13b22811267.jpg</url>
      <title>DEV Community: Divyakush Punjabi</title>
      <link>https://dev.to/dev-into-space</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/dev-into-space"/>
    <language>en</language>
    <item>
      <title>A warning one minute early beats a perfect post-mortem</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 15:27:55 +0000</pubDate>
      <link>https://dev.to/dev-into-space/a-warning-one-minute-early-beats-a-perfect-post-mortem-1d7a</link>
      <guid>https://dev.to/dev-into-space/a-warning-one-minute-early-beats-a-perfect-post-mortem-1d7a</guid>
      <description>&lt;p&gt;&lt;strong&gt;After a rockfall, you can reconstruct exactly what happened. That analysis is worth almost nothing to the people who were standing there.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The entire value in hazard detection is on the &lt;em&gt;front&lt;/em&gt; of the event, not the back. A crude warning a minute early can clear a slope; a flawless explanation an hour late is a report. So the problem isn't understanding a rockfall — it's seeing it coming.&lt;/p&gt;

&lt;p&gt;The trouble is that no single sensor is trustworthy on its own. Displacement, vibration, moisture — each is noisy, each throws false alarms. But if you &lt;em&gt;fused&lt;/em&gt; those streams into one model that weighs them together, the noise starts to cancel and a real pattern rises out of it: this combination, trending this way, means move.&lt;/p&gt;

&lt;p&gt;That's what I engineered into an &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;AI and IoT rockfall prediction system&lt;/a&gt; — a multi-sensor fusion pipeline feeding a real-time hazard model, built to raise the alarm before the slope moves rather than to explain it afterward. It was shortlisted at Smart India Hackathon 2025.&lt;/p&gt;

&lt;p&gt;Prevention systems are judged by their lead time, not their hindsight. Design for the warning, not the write-up.&lt;/p&gt;




&lt;p&gt;More ML and IoT projects → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>machinelearning</category>
      <category>iot</category>
      <category>edgecomputing</category>
      <category>sensors</category>
    </item>
    <item>
      <title>Multi-tenancy is a promise you keep in the database</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 15:22:24 +0000</pubDate>
      <link>https://dev.to/dev-into-space/multi-tenancy-is-a-promise-you-keep-in-the-database-274b</link>
      <guid>https://dev.to/dev-into-space/multi-tenancy-is-a-promise-you-keep-in-the-database-274b</guid>
      <description>&lt;p&gt;&lt;strong&gt;In a multi-tenant app, "don't show tenant A's data to tenant B" isn't a feature you build. It's a promise you can never break, even once.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The danger is that tenancy usually lives as a filter you remember to add — a WHERE clause on every query. Which means it also lives as the &lt;em&gt;one&lt;/em&gt; query where a tired engineer forgets it, and that single omission is a data breach, not a bug ticket.&lt;/p&gt;

&lt;p&gt;If tenant scoping were enforced server-side by default — part of how data access works, not something each endpoint opts into — then forgetting wouldn't be catastrophic, because there'd be nothing to forget. Isolation becomes a property of the system instead of a discipline you hope everyone maintains.&lt;/p&gt;

&lt;p&gt;That's the spine of &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;DineGuru&lt;/a&gt;, a multi-tenant restaurant operations platform — a FastAPI modular monolith over PostgreSQL with nine domain modules, where tenancy is scoped on the server rather than trusted to each query. The boring, centralized version is the safe version.&lt;/p&gt;

&lt;p&gt;Any guarantee you enforce by convention will eventually be violated by convention. Push it down into the layer where it can't be skipped.&lt;/p&gt;




&lt;p&gt;More backend and SaaS work → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>fastapi</category>
      <category>postgres</category>
      <category>backend</category>
      <category>saas</category>
    </item>
    <item>
      <title>A dumb protocol is a feature, not a compromise</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 15:16:52 +0000</pubDate>
      <link>https://dev.to/dev-into-space/a-dumb-protocol-is-a-feature-not-a-compromise-2elh</link>
      <guid>https://dev.to/dev-into-space/a-dumb-protocol-is-a-feature-not-a-compromise-2elh</guid>
      <description>&lt;p&gt;&lt;strong&gt;When your software has to talk to hardware, the clever protocol is the one you'll regret at 2am.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It's tempting to design a rich, structured message format between your host and your device — length headers, framing, the works. Then something misbehaves on the wire, and now you're decoding your own cleverness with an oscilloscope instead of fixing the actual bug.&lt;/p&gt;

&lt;p&gt;If the two sides spoke in something almost insultingly simple — a flat map where one byte means one action — you could watch the entire conversation in a serial monitor and understand it at a glance. Adding a new device becomes: pick the next number. Debugging becomes: read the byte.&lt;/p&gt;

&lt;p&gt;That's the choice I made in &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;HomeSense&lt;/a&gt;, where the host classifies a spoken command and sends a single-byte opcode down the serial line to an Arduino, which reads it and flips the right pin. Trivial to trace, trivial to extend, and boring in the best possible way.&lt;/p&gt;

&lt;p&gt;"Boring and debuggable" beats "elegant and opaque" almost every time a wire is involved. Save your cleverness for the problem that actually needs it.&lt;/p&gt;




&lt;p&gt;More embedded and IoT builds → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>embedded</category>
      <category>iot</category>
      <category>arduino</category>
      <category>python</category>
    </item>
    <item>
      <title>Your ML accuracy might be quietly cheating</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 15:11:21 +0000</pubDate>
      <link>https://dev.to/dev-into-space/your-ml-accuracy-might-be-quietly-cheating-1jf3</link>
      <guid>https://dev.to/dev-into-space/your-ml-accuracy-might-be-quietly-cheating-1jf3</guid>
      <description>&lt;p&gt;&lt;strong&gt;If your model predicts sequences and you evaluated it on a random split, your accuracy number is probably lying to you.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Here's the leak. You shuffle your data and carve out a random test set. But if behavior unfolds over time, a random split drops &lt;em&gt;future&lt;/em&gt; events into the training set and &lt;em&gt;past&lt;/em&gt; events into the test set. Your model gets to peek at what comes later, then gets graded on what came before. The score looks fantastic and means very little.&lt;/p&gt;

&lt;p&gt;If instead you split on &lt;em&gt;time&lt;/em&gt; — train on the past, test strictly on the future, the way the model will actually be used — the number drops. And that lower number is the honest one. It's the only one that tells you whether the thing will work in production.&lt;/p&gt;

&lt;p&gt;I held that line building a &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;sequential recommender&lt;/a&gt;: evaluated on a temporal, leave-last-out split so nothing from the future ever leaked backward, with a simpler baseline kept alongside so every claim was measured against something real.&lt;/p&gt;

&lt;p&gt;An unflattering metric you trust beats a beautiful one you can't. When a result looks too good, suspect your split before you celebrate.&lt;/p&gt;




&lt;p&gt;More ML notes and projects → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>machinelearning</category>
      <category>datascience</category>
      <category>mlops</category>
      <category>python</category>
    </item>
    <item>
      <title>Hardware doesn't get a second frame</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 15:10:22 +0000</pubDate>
      <link>https://dev.to/dev-into-space/hardware-doesnt-get-a-second-frame-33b5</link>
      <guid>https://dev.to/dev-into-space/hardware-doesnt-get-a-second-frame-33b5</guid>
      <description>&lt;p&gt;&lt;strong&gt;Software gets to retry. A traffic signal at rush hour does not.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Most of us build in a world with a safety net — a request fails, you try again, nobody notices. Move down to hardware controlling something physical and that net disappears. The signal has to make the right decision this cycle, in real time, every time, because there is no "please refresh."&lt;/p&gt;

&lt;p&gt;So imagine signal timing that adapts to actual traffic on the silicon itself — reading demand and adjusting green time cycle by cycle, with no processor, no operating system, and no network call in the loop. Determinism stops being a nice-to-have and becomes the whole point: the logic does exactly one thing, exactly on time.&lt;/p&gt;

&lt;p&gt;That's what I implemented as an &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;FPGA-based adaptive traffic controller&lt;/a&gt; in Verilog — real-time signal timing that adjusts to demand to improve throughput, running entirely in hardware. Writing for an FPGA rewires how you think: you're not writing instructions that execute in sequence, you're describing circuits that all exist at once.&lt;/p&gt;

&lt;p&gt;It's a useful discipline to borrow even in software. When you can't retry, you're forced to actually get it right — and that constraint makes better engineers.&lt;/p&gt;




&lt;p&gt;More hardware and systems work → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>fpga</category>
      <category>verilog</category>
      <category>hardware</category>
      <category>embedded</category>
    </item>
    <item>
      <title>The commerce bug that charges you twice — and how to kill it</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:42:50 +0000</pubDate>
      <link>https://dev.to/dev-into-space/the-commerce-bug-that-charges-you-twice-and-how-to-kill-it-432m</link>
      <guid>https://dev.to/dev-into-space/the-commerce-bug-that-charges-you-twice-and-how-to-kill-it-432m</guid>
      <description>&lt;p&gt;&lt;strong&gt;The most frightening bug in commerce isn't a payment that fails. It's a payment that succeeds twice.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Networks are unreliable, so clients retry. A customer taps "Pay," the response gets lost on the way back, the app tries again — and now you've charged them twice for one order. The naive fix is to hope it doesn't happen. It happens.&lt;/p&gt;

&lt;p&gt;Imagine instead that every payment attempt carried a unique &lt;strong&gt;idempotency key&lt;/strong&gt;, and the server promised: the first time I see this key I do the work; every time after, I return the same result without doing it again. Suddenly a retry is safe. The client can fire the same request ten times over a flaky connection and the customer is charged exactly once.&lt;/p&gt;

&lt;p&gt;That guarantee sat at the center of the checkout I built for &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;Saturdays&lt;/a&gt;, a marketplace taking real orders through two payment gateways. The same idempotency key rides along the whole path, so a retried tap can never become a double charge — the reliability of the ordering-to-payment flow was the entire engineering priority.&lt;/p&gt;

&lt;p&gt;Idempotency isn't a payments trick; it's how you make &lt;em&gt;any&lt;/em&gt; operation safe to repeat. The moment retries exist in your system — and they always do — it stops being optional.&lt;/p&gt;




&lt;p&gt;More backend and systems write-ups → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>payments</category>
      <category>backend</category>
      <category>api</category>
      <category>reliability</category>
    </item>
    <item>
      <title>Two payment gateways, one button the customer never questions</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:37:19 +0000</pubDate>
      <link>https://dev.to/dev-into-space/two-payment-gateways-one-button-the-customer-never-questions-37cb</link>
      <guid>https://dev.to/dev-into-space/two-payment-gateways-one-button-the-customer-never-questions-37cb</guid>
      <description>&lt;p&gt;&lt;strong&gt;A customer should never be able to tell how many payment providers sit behind your checkout button.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Cards and India-native UPI are completely different animals — different flows, different states, different ways to fail. The lazy version exposes that mess to the user: pick your provider, learn our plumbing, good luck. The result is hesitation, and hesitation at the payment step is a lost order.&lt;/p&gt;

&lt;p&gt;If both rails felt like &lt;em&gt;one&lt;/em&gt; button — same interface, same confidence, the differences handled quietly underneath — you'd lose nobody to confusion. The complexity doesn't disappear; it just moves to where it belongs, out of the customer's way.&lt;/p&gt;

&lt;p&gt;That's what I did shipping &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;Saturdays&lt;/a&gt;, a food-ordering marketplace running live payments through both Stripe and PhonePe. They're integrated behind a single, unified checkout, with each provider's states handled deliberately rather than optimistically — because the payment step is the one part of the product a customer cannot forgive getting wrong.&lt;/p&gt;

&lt;p&gt;The principle is older than payments: absorb complexity on behalf of your user. Every messy branch you handle internally is a decision they don't have to make.&lt;/p&gt;




&lt;p&gt;More of what I ship → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>react</category>
      <category>payments</category>
      <category>stripe</category>
      <category>frontend</category>
    </item>
    <item>
      <title>For a servo, a cloud round-trip is a lifetime</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:31:48 +0000</pubDate>
      <link>https://dev.to/dev-into-space/for-a-servo-a-cloud-round-trip-is-a-lifetime-i3d</link>
      <guid>https://dev.to/dev-into-space/for-a-servo-a-cloud-round-trip-is-a-lifetime-i3d</guid>
      <description>&lt;p&gt;&lt;strong&gt;Send a camera frame to the cloud, run detection, send a command back — and by the time your servo moves, the person has already walked out of frame.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We treat latency like a number to optimize later. For anything that touches the physical world, it's a design constraint you decide up front. A few hundred milliseconds is invisible in a web request and an eternity for a motor trying to track a moving target.&lt;/p&gt;

&lt;p&gt;If the intelligence lived &lt;em&gt;next to&lt;/em&gt; the sensor instead of in a datacenter, the loop would close in real time. Detect, decide, actuate — all local, no network in the critical path. The cloud is still useful, just not for the part that has to happen now.&lt;/p&gt;

&lt;p&gt;That's the architecture behind &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;Netra&lt;/a&gt;: an ESP32-CAM streams frames into a local YOLOv8 pipeline that drives pan-tilt servos over MQTT, so tracking reacts immediately instead of waiting on a round-trip. The dashboard and heavier analytics can live elsewhere — the reflex can't.&lt;/p&gt;

&lt;p&gt;Draw the boundary first: what has a physical consequence stays at the edge; what's inherently remote can be remote. Get that line right and everything downstream gets simpler.&lt;/p&gt;




&lt;p&gt;More edge and systems work → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>edgeai</category>
      <category>iot</category>
      <category>computervision</category>
      <category>embedded</category>
    </item>
    <item>
      <title>You can't build intuition for something you can't see</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:26:16 +0000</pubDate>
      <link>https://dev.to/dev-into-space/you-cant-build-intuition-for-something-you-cant-see-1g0m</link>
      <guid>https://dev.to/dev-into-space/you-cant-build-intuition-for-something-you-cant-see-1g0m</guid>
      <description>&lt;p&gt;&lt;strong&gt;You can memorize that quicksort is O(n log n) and still have no feel for why it falls apart on an already-sorted array.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A textbook flattens an algorithm into pseudocode and a Big-O label. But an algorithm is a sequence of decisions unfolding over &lt;em&gt;time&lt;/em&gt;, and that's precisely the dimension the page throws away. The label tells you the cost; it doesn't let you feel it.&lt;/p&gt;

&lt;p&gt;Now imagine you could watch it. Two sorts racing on the same data, comparison and swap counters ticking live. An AVL tree rebalancing itself mid-insertion. A complexity curve bending upward as you drag the input size higher. The moment a concept &lt;em&gt;clicks&lt;/em&gt; is almost always the moment you see it move.&lt;/p&gt;

&lt;p&gt;That's why I built &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;AlgoVerse&lt;/a&gt;, a browser-based platform that renders data structures and algorithms as animated, step-through scenes at 60fps. The hard part wasn't the algorithms — those are well understood. It was decoupling the computation from the rendering so big inputs never freeze the UI and you can scrub the speed from a crawl to a blur.&lt;/p&gt;

&lt;p&gt;Good learning tools don't dumb the idea down. They remove the friction between you and the moment it becomes obvious.&lt;/p&gt;




&lt;p&gt;See what else I've built → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>algorithms</category>
      <category>react</category>
      <category>webdev</category>
      <category>learning</category>
    </item>
    <item>
      <title>The stop-word that quietly breaks every voice smart-home</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:20:45 +0000</pubDate>
      <link>https://dev.to/dev-into-space/the-stop-word-that-quietly-breaks-every-voice-smart-home-3k0f</link>
      <guid>https://dev.to/dev-into-space/the-stop-word-that-quietly-breaks-every-voice-smart-home-3k0f</guid>
      <description>&lt;p&gt;&lt;strong&gt;Every NLP tutorial tells you to strip stop-words. Do that in a voice-controlled home and you just deleted the command.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Standard English stop-word lists throw away tiny, "meaningless" words — including &lt;em&gt;on&lt;/em&gt;, &lt;em&gt;off&lt;/em&gt;, and &lt;em&gt;all&lt;/em&gt;. In ordinary text they're noise. In "turn &lt;strong&gt;on&lt;/strong&gt; light two" they are the entire instruction. Filter them out and "turn on" and "turn off" collapse to the same tokens, so every light command becomes a coin flip.&lt;/p&gt;

&lt;p&gt;Picture the fix from the outside: nobody would ever guess it. You'd stare at a system that transcribes speech perfectly and still toggles the wrong switch, because the bug isn't in the microphone or the model — it's in a default someone imported without reading.&lt;/p&gt;

&lt;p&gt;The whole repair is one line: remove &lt;em&gt;on&lt;/em&gt;, &lt;em&gt;off&lt;/em&gt;, and &lt;em&gt;all&lt;/em&gt; from the stop-word set before you filter. That's it. I leaned on this in &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;HomeSense&lt;/a&gt;, a voice assistant that turns speech into physical actions — NLTK classifies the intent locally, then sends a single byte down a serial line to an Arduino.&lt;/p&gt;

&lt;p&gt;The broader point: your libraries encode someone else's assumptions. When you know your domain better than the default does, override it — and the smallest override can be the thing the whole system depends on.&lt;/p&gt;




&lt;p&gt;More of my projects and write-ups → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>python</category>
      <category>nlp</category>
      <category>iot</category>
      <category>arduino</category>
    </item>
    <item>
      <title>Recommenders throw away your single most useful signal: order</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:15:14 +0000</pubDate>
      <link>https://dev.to/dev-into-space/recommenders-throw-away-your-single-most-useful-signal-order-66i</link>
      <guid>https://dev.to/dev-into-space/recommenders-throw-away-your-single-most-useful-signal-order-66i</guid>
      <description>&lt;p&gt;&lt;strong&gt;Most recommendation engines look at everything you've ever liked and quietly ignore the one thing that matters most: the order you liked it in.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Think about what your &lt;em&gt;last&lt;/em&gt; action says versus a random one from a year ago. If you just finished part two of a trilogy, the next thing you want is obvious to a human and invisible to a system that treats your history as an unordered bag of items.&lt;/p&gt;

&lt;p&gt;So imagine a model that reads your history as a &lt;em&gt;sequence&lt;/em&gt; — that learns which past actions predict the next one, the way a language model learns which words predict the next word. Cold-start gets easier. "You watched these in this order, last night" becomes a real signal instead of noise.&lt;/p&gt;

&lt;p&gt;That's what I built with a &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;self-attention sequential recommender&lt;/a&gt; — a SASRec transformer in PyTorch, trained across movies and music. It attends over your interaction history and predicts what comes next, and on a proper held-out split it lands well above the matrix-factorization baseline I kept next to it for honesty.&lt;/p&gt;

&lt;p&gt;If your domain has any time structure at all — and almost all of them do — switching from a set-based model to a sequence-based one is the biggest single lever you're probably not pulling.&lt;/p&gt;




&lt;p&gt;I write up the things I build → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>machinelearning</category>
      <category>pytorch</category>
      <category>recsys</category>
      <category>datascience</category>
    </item>
    <item>
      <title>The 'do nothing' zone that made my camera track smoothly</title>
      <dc:creator>Divyakush Punjabi</dc:creator>
      <pubDate>Thu, 13 Aug 2026 14:09:43 +0000</pubDate>
      <link>https://dev.to/dev-into-space/the-do-nothing-zone-that-made-my-camera-track-smoothly-1751</link>
      <guid>https://dev.to/dev-into-space/the-do-nothing-zone-that-made-my-camera-track-smoothly-1751</guid>
      <description>&lt;p&gt;&lt;strong&gt;The first version of my auto-tracking camera shook like it was nervous.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Here's the trap. You tell a camera to keep a person centered, so the obvious rule is: if they're not dead-center, move toward them. But "dead-center" is never exactly true — there's always a pixel or two of error — so the servos chase noise forever and the whole rig vibrates.&lt;/p&gt;

&lt;p&gt;If you could teach the camera the difference between &lt;em&gt;off&lt;/em&gt; and &lt;em&gt;close enough&lt;/em&gt;, it would stop fighting itself. And if the correction scaled with how far off the target actually was — a gentle nudge when they're nearly centered, a fast sweep when they're at the edge — motion would look smooth instead of snapping and overshooting.&lt;/p&gt;

&lt;p&gt;That's the whole fix, and it's exactly how I built &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;Netra&lt;/a&gt;, an edge-AI camera that follows a person on its own: proportional control for the speed, and a 12% &lt;strong&gt;dead zone&lt;/strong&gt; in the middle where the servos simply do nothing. Two rules from control theory did more for tracking quality than any amount of model tuning.&lt;/p&gt;

&lt;p&gt;The lesson generalizes past cameras: a system that reacts to every tiny error is a system that never settles. Sometimes the smartest thing your code can do is ignore small differences on purpose.&lt;/p&gt;




&lt;p&gt;More things I've built and written about → &lt;a href="https://www.divyakush.com" rel="noopener noreferrer"&gt;www.divyakush.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>computervision</category>
      <category>iot</category>
      <category>embedded</category>
      <category>robotics</category>
    </item>
  </channel>
</rss>
