Find people faster when every minute counts.

SwarmSAR turns a fleet of drones into a self-organising search team — coordinating over a real-time graph mesh, fusing what they see into one shared survivor map, and handing confirmed locations to rescuers.

Python 3.10+Zero core dependencies MIT licensedSearch & rescue only

Built to help

A framework with one job

In a disaster the bottleneck is coverage: too much ground, too few responders, too little time. SwarmSAR blankets an area in minutes and turns many noisy sightings into a few locations a team can trust.

Scope & safety. SwarmSAR locates people in order to help them. It contains no targeting or weapons functionality, and its license and responsible-use policy prohibit adapting it to harm the people it detects.

How it works

One decentralised loop, six steps

Every tick, each drone senses and decides on its own — there is no central controller, so the swarm keeps working even when it splits into disconnected islands.

01 · mesh

Form the graph

Drones build a proximity graph and gossip telemetry over it in real time, with bounded hops.

02 · sense

Detect presence

Each drone runs a pluggable human-presence detector (thermal, RGB, acoustic) over its field of view.

03 · fuse

Build the map

Sightings are clustered into confidence-weighted survivor estimates in one shared map.

04 · decide

Re-task the swarm

A pluggable AI layer ranks estimates and sends a second drone to corroborate lone sightings.

05 · confirm

Require corroboration

An estimate is confirmed only when enough distinct drones agree — a single false positive can't escalate.

06 · alert

Notify rescuers

Confirmed survivors are dispatched to responders as de-duplicated alerts with WGS-84 coordinates.

What's inside

Engineered to be extended

Clean interfaces at every seam, so you can swap the AI, the sensor, or the flight backend without touching the rest.

Real-time graph mesh

Range-based topology with telemetry gossip and connected-component awareness.

Sensor fusion

Online clustering with corroboration-gated confirmation and time decay of stale estimates.

Pluggable AI

A runtime registry with ensemble voting — diverse models plug in and can't unilaterally escalate.

Geo coordinates

Local ENU ↔ WGS-84 conversion so alerts carry real latitude/longitude for the field.

MAVLink bridge

The same swarm logic flies PX4/ArduPilot via a velocity-setpoint actuator (optional).

Deterministic sim

The whole pipeline runs offline and reproducibly — 38 tests, plus a live replay dashboard.

Plug in your own model

Implement one method

Providers are interchangeable at runtime; several can be fused so no single model forces an escalation on its own.

from swarmsar.ai.provider import AIProvider, Decision, SituationContext

class MyVisionProvider(AIProvider):
    name = "my-vision"

    def decide(self, ctx: SituationContext) -> Decision:
        ranked = sorted(ctx.estimates, key=lambda e: e.confidence, reverse=True)
        return Decision(
            priorities=[e.id for e in ranked],
            escalate=[e.id for e in ranked if e.confirmed],
            rationale="prioritised by my model",
        )

ai.register(MyVisionProvider(), activate=True)   # diverse models, one bus

See it run

Live mission replay

A recorded search over a 400×300 m field with eight drones and six survivors. Watch the mesh form, estimates appear, and rescue alerts fire as survivors are confirmed.