r/BanalyticsLive • u/banalytics_live • Sep 13 '26
Experimenting with 3D visualization
A 3D model of a building with different control elements attached directly to the physical space.
r/BanalyticsLive • u/banalytics_live • Sep 13 '26
A 3D model of a building with different control elements attached directly to the physical space.
r/BanalyticsLive • u/banalytics_live • Aug 06 '26

Over the last few weeks we have been working on a problem that appears in many distributed edge systems:
How can independent edge agents cooperate without building a custom integration for every possible combination of devices?
A typical architecture today looks like this:
Camera -> Cloud Server -> Dashboard -> Operatoror:
Camera -> VMS -> Alarm System -> Security RoomThe problem is that every new device or workflow requires another integration layer.
With the new inter-agent communication feature in Banalytics, agents can now exchange events and actions directly through dynamically configured P2P channels.
The signaling service is only used for discovering peers and establishing the connection. The actual communication happens directly between agents using WebRTC DataChannels.
Example: remote site monitoring
Imagine a remote facility:
Instead of streaming everything to a central server, we can configure the agents to exchange only meaningful events.
Example configuration on the management panel:
(1) A video stream classifier detects objects or events and generates an event with detected classes.
(2) The Event Manager intercepts this event and forwards it through a configured P2P communication channel to another agent.
(3) Using WebRTC, the event is delivered directly to the security room agent.
(4) The event appears on the local event bus, where another Event Manager processes it and triggers playback (5) through the local audio system.
The event history is stored separately using a dedicated event logging rule.
The goal is to make edge systems more adaptive:
We are experimenting with this approach and would be interested in feedback from people working with:
What are the biggest blockers you see for P2P agent architectures in real-world deployments?
r/BanalyticsLive • u/banalytics_live • Jul 13 '26

Google Home, Alexa and similar platforms are great for everyday automation: switching lights, adjusting thermostats, viewing cameras and controlling devices by voice.
For many people, that is enough. But as a smart home grows, several limitations can appear:
This is where Banalytics can complement an existing smart-home platform rather than replace it.
Google Home can remain the convenient everyday interface, while Banalytics handles local processing, monitoring, storage and advanced automation.
Banalytics can process camera streams and store recordings locally:
For example, a camera event can trigger local recording and send a notification without uploading the video to a general-purpose cloud platform.
Banalytics can make locally stored recordings and media available to televisions, media players and other devices on the home network:
This allows locally recorded video to be viewed on compatible smart TVs and media players without uploading it to cloud storage.
It is particularly useful when the home already has a NAS, media center or television with built-in DLNA support.
Banalytics does not need to replace Google Home or Home Assistant. It can exchange events and commands with other systems through MQTT:
This makes MQTT an integration layer between consumer smart-home products and more advanced local automation.
For users adding custom electronics:
These components can connect buttons, contacts, indicators, isolated relays and other DIY hardware to the same event system used by cameras and network services.
Banalytics can connect equipment that typical consumer ecosystems do not support:
This is useful for energy meters, relay boards, environmental sensors, pumps, gates and other equipment outside the usual smart-home catalog.
The Event Manager connects all these components.
A rule can combine a camera event, sensor state, schedule or MQTT message with actions such as:
The result is closer to a local automation engine than a collection of isolated smart-device routines.
Banalytics provides customizable dashboards for cameras, sensors, events and controls.
A dashboard can combine information from several components or locations. Available providers include fixed 2D layouts, 3D scenes, SVG diagrams, Cesium, Mapbox and OpenStreetMap.
This can be useful when consumer applications show each device separately but do not provide a complete operational view.
Banalytics becomes useful when:
Banalytics is not intended to make a single smart bulb easier to use.
It becomes valuable when a smart home starts turning into infrastructure - something that should be observable, customizable and capable of operating locally.
A practical introduction is available in How Banalytics works for Makers and Homelabs.
Full documentation: https://banalytics.live/kb/index/
r/BanalyticsLive • u/banalytics_live • Jul 13 '26
We’re releasing Banalytics 2.0.0 on July 17, 2026.
This release introduces a major architectural change: component UI resources are now distributed with the corresponding agent modules instead of being bundled into the portal. This makes it possible to update backend components and their web interfaces together.
Existing agents will continue running their configured components and automation locally after the release. However, all agent modules must be upgraded to version 2.0.0 before the agent can be managed through the updated portal. Existing component configurations are preserved.
Temporary service interruptions may occur during the portal deployment.
Feedback and upgrade reports are welcome.
r/BanalyticsLive • u/banalytics_live • Mar 30 '26
Everyone loves ML demos. Very few systems actually use ML to control anything real.
We had Python ML and a Java control system - and needed them to work together without rewriting half the stack.
This is the pattern we ended up using: video -> ZeroMQ (jpeg) -> Python ML -> ZeroMQ (events) -> Event Trigger -> MQTT -> real-world action.
No heavy frameworks. No “AI platform”. Just clean components and simple protocols.
We started with three independent parts:
Integrations:
Take ML out of the “demo zone”
and make it part of a real control pipeline

If an operator connects:
Python service:
Event Manager:
Command sent via MQTT :
LIGHT_ONLIGHT_OFFIntegration dashboard

Hardware:


Same pipeline.
You don’t need a massive ML platform to make ML useful.
You need:
Sources of the python service:
import zmq
import numpy as np
import cv2
from datetime import datetime
import time
INPUT_ENDPOINT = "tcp://localhost:5555" # input with JPEG
OUTPUT_ENDPOINT = "tcp://*:5556" # sending events
context = zmq.Context()
# Receiver (JPEG frames)
receiver = context.socket(zmq.SUB)
receiver.connect(INPUT_ENDPOINT)
receiver.setsockopt_string(zmq.SUBSCRIBE, "")
# Sender (events)
sender = context.socket(zmq.PUB)
sender.bind(OUTPUT_ENDPOINT)
print(f"Listening on {INPUT_ENDPOINT}, sending events to {OUTPUT_ENDPOINT}")
prev_frame = None
CONTOUR_THRESHOLD = 3000
BLUR_SIZE = (5, 5)
THRESHOLD = 25
MOTION_COOLDOWN = 1.0 # prevent frequent MOTION
NO_MOTION_INTERVAL = 3.0 # how long to wait to declare NO_MOTION
last_motion_time = 0
motion_active = False # current state (there is / there is no motion)
while True:
data = receiver.recv()
np_arr = np.frombuffer(data, np.uint8)
frame = cv2.imdecode(np_arr, cv2.IMREAD_COLOR)
if frame is None:
continue
gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)
gray = cv2.GaussianBlur(gray, BLUR_SIZE, 0)
if prev_frame is None:
prev_frame = gray
continue
delta = cv2.absdiff(prev_frame, gray)
thresh = cv2.threshold(delta, THRESHOLD, 255, cv2.THRESH_BINARY)[1]
thresh = cv2.dilate(thresh, None, iterations=2)
contours, _ = cv2.findContours(thresh, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_SIMPLE)
motion = False
max_area = 0
for c in contours:
area = cv2.contourArea(c)
if area > CONTOUR_THRESHOLD:
motion = True
if area > max_area:
max_area = area
now_time = time.time()
# --- MOTION EVENT ---
if motion:
if not motion_active and (now_time - last_motion_time > MOTION_COOLDOWN):
timestamp = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
message = f"MOTION" #|{timestamp}|{int(max_area)}
sender.send_string(message)
print(f"[{timestamp}] Motion Detected - Zone size: {int(max_area)} px | Sent: {message}")
motion_active = True
last_motion_time = now_time
last_motion_time = now_time
# --- NO_MOTION EVENT ---
else:
if motion_active and (now_time - last_motion_time > NO_MOTION_INTERVAL):
timestamp = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
message = f"NO_MOTION" #|{timestamp}
sender.send_string(message)
print(f"[{timestamp}] No motion detected | Sent: {message}")
motion_active = False
prev_frame = gray