Install
One line.
pip install fotonetPython 3.10 to 3.12, on Windows, macOS and Linux.
Just Ultra.
Free and open source under Apache‑2.0.pip install fotonet
UltraFast. No NMS step. Boxes come straight out of the network.
1.22 ms
fotonetn forward pass with TensorRT FP16, batch 1, on an RTX 40601
UltraEfficient. 2.85 million parameters. 6.95 GFLOPs.2 Three more sizes to come, same API.
Ship it anywhere. ONNX and TensorRT export, built in.3
model.export(format="")
Codename UltraDense
fotonet is a new family of object detectors, built from scratch. It starts with fotonetn, at 2.85 million parameters, now retrained with our new trainer in v1.2, and grows to four sizes up to fotonetl. Every one is NMS-free, so what the network outputs is the final answer. One API across all of them, free and open source under Apache-2.0.
fotonetn at a glance
from fotonet import Fotonet model = Fotonet("fotonetn")results = model.predict("surf.jpg", conf=0.5) for det in results[0].boxes: print(det.cls, det.conf, det.xyxy) # corners, 0 to 1
7 objects found
Real fotonetn output, not a mockup.4
Live demo
It runs in your browser on ONNX Runtime Web. Your images and video never leave your device.
Uses the camera on this device. Nothing is recorded or sent anywhere.
WebGPU runs on your graphics card. WASM runs on the CPU and works everywhere.
Runs the released fotonetn model (32.1 mAP on COCO) exported to FP16 ONNX for the browser. The first run downloads the 5.8 MB model and ONNX Runtime Web.
Speed
fotonet has no NMS step at all. The network is trained to give one box per object, so all that's left after it is a sort and a confidence cut. No IoU threshold to set.
Traditional detectors predict thousands of overlapping boxes, then run Non-Maximum Suppression to delete duplicates. fotonet learns one-to-one box assignment during training, skipping the suppression pass entirely.
One threshold. Set a confidence and go. There is no IoU threshold, because there is no NMS.
conf=0.25
Video ready. Pass OpenCV frames as they are, or track a video. Every object keeps its ID.
model.predict_bgr(frame)
Plain results. Class, confidence and box for every object. Nothing to decode.
det.cls, det.conf, det.xyxy
Train your own. Point it at a YAML dataset and pick a size. Resume whenever you like.
fotonet train model=fotonetn data=data.yaml
Efficiency
fotonetn fits in 2.85 million parameters and 6.95 GFLOPs at 640 × 640: small enough for a laptop, a modest GPU or an edge box. When you need more accuracy, move up to a larger size without changing your code.
fotonetn. Maximum speed. The smallest UltraDense model, for laptops, small GPUs and edge boxes.
Built as a TensorRT FP16 engine, fotonetn holds 20 MB of GPU memory at batch 1, weights included, and 96 MB at batch 8. It can share a card with the rest of your application.1
20 MBGPU memory with TensorRT, batch 1
Compare
Every number in this section comes from one harness on one machine, with both models measured in the same runs. YOLO26n ran through its official package.
Measured on 3 November 2026 on an RTX 4060 with an i3-13100F, Windows 11, CUDA 12.8 and PyTorch 2.11. Image to boxes is a photo in, boxes out, through each package's own predict path running an FP16 TensorRT engine at batch 1: resize, inference, picking the boxes and mapping them back to the photo. It is the median of 500 runs on one COCO photo. Accuracy is mAP on all 5,000 images of COCO val2017, scored with pycocotools at confidence 0.01. Each model returns up to 300 boxes per image, as Ultralytics does, and pycocotools keeps up to 100 per class. Ultralytics lists 40.9 for YOLO26n from its own validator; this harness measures it lower, and it scores both models the same way. TensorRT times are the median GPU compute time from trtexec for an FP16 engine built by each package's own export, TensorRT 10.16. YOLO26n's engine also picks its final boxes; fotonetn reads its boxes after the engine. TensorRT memory is what TensorRT reports holding for the engine, weights and working memory. TensorRT cold start runs from the engine file to the first result back on the CPU, in a fresh process with CUDA already started. Parameters and GFLOPs are measured at 640 × 640 on each model's fused deployed graph with PyTorch's ATen FLOP counter (2 × MACs, including attention matmuls).
The engine
UltraDense is the engine inside every fotonet model since v1.1. It scores every part of the image in one pass, and it is trained to keep one box per object. There is no NMS step to clean up afterwards. And everything it knows, it learned from scratch.
While training, a helper head shows the model more examples of where objects are. It is removed before export, so it costs nothing when you run it.
Confidence follows how well a box fits, not only what is inside it. A high score means a tight box.
No pretrained ImageNet backbone and no distilled teacher weights. Every fotonet model since v1.1 learns COCO directly from random initialization.
Zeroborrowed weights
The toolkit
Predict, train, validate and export from one pip install, in Python or from the command line. And fotonet Studio, our desktop app for labeling and training, is on the way.
Predict. Images, folders or video frames. Class, confidence and box for every object.
Train. Your own classes from a YAML dataset. Stop and resume whenever you like.
Validate. Measure mAP50-95, mAP50 and precision-recall on your validation split with built-in COCO evaluation.
Export. ONNX and TensorRT in one call. ONNX output is checked against PyTorch.3
fotonet Studio. Label, train and test on your desktop. Windows, macOS and Linux. Coming soon.
Box tools. Every box carries its own transform. Move, scale, expand or crop it, and measure overlap or distance, in pixels or from 0 to 1.
Install
pip install fotonetPython 3.10 to 3.12, on Windows, macOS and Linux.
Predict
from fotonet import Fotonet
model = Fotonet("fotonetn")
results = model.predict("image.jpg")
Train
fotonet train \
model=fotonetn \
data=data.yaml