Robotics · Software · Cloud
What Matters More: The Model or The Data?
My First Lessons From Training AI Models for a Real Robot
By Sebastian Rychlik · Published
- TerraScanAI
- YOLOv8
- Computer Vision
- Machine Learning
- Vertex AI
- Dataset Training
- Object Detection
- NVIDIA T4
- NVIDIA L4

When I started building the AI training pipeline for TerraScanAI, I assumed that improving the model would be the biggest factor affecting detection quality.
I was wrong.
The biggest improvement came from improving the data. Over the last few weeks I completed the first end-to-end training loop inside TerraScanAI:
Collection → Annotation → Dataset → Version → Training → Registry → Deployment
The goal was deliberately simple:
Teach a robot to recognize a decorative garden vase.
Simple goals often produce the most interesting engineering lessons.
The Flower Pot That Used To Be A Cat
Readers of my previous post may remember the now-famous flower pot that was confidently classified as a cat by the factory model running on my OAK-D Pro camera.

The original system used the factory YOLOv4 Tiny COCO model supplied with the camera ecosystem. While surprisingly capable, it occasionally produced entertaining results.
- The flower pot became a cat.
- Actual cats occasionally became dogs.
- Sometimes neither was recognized correctly.
It was clear that if TerraScanAI was going to identify objects specific to my environment, a custom training pipeline would eventually be required.
Replacing YOLOv4 With YOLOv8
The first step was migrating from YOLOv4 to YOLOv8. The newer architecture offered:
- Better training tooling
- Better deployment support
- Easier future customization
- Stronger ecosystem support
The migration itself immediately improved detection quality. However, another problem quickly appeared. The flower pot was no longer classified as a cat. But it still wasn’t recognized as a vase.
The reason was simple:
The model had never seen my vase before.
Building The First Dataset
To solve that problem, I built the first custom dataset inside TerraScanAI.

The initial dataset contained only 17 manually annotated photographs collected in the garden. At the time, that seemed sufficient. After all, the object was large, highly visible and easy to annotate.
I was about to learn my first lesson.
Why 17 Images Were Not Enough
The first training job completed successfully. The model recognized the vase. Technically.
The problem was confidence. Even when the vase occupied a large portion of the image, confidence remained around 36%.

The model had learned something. Just not enough to be trusted by a robotic platform operating in the real world.
More Data Changes Everything
Instead of changing the architecture, I decided to change the dataset. I added another 25 photographs collected indoors.
Different:
- Lighting
- Backgrounds
- Viewing angles
- Distances
The dataset grew from:
17 images → 42 images

The model architecture remained the same. The training pipeline remained the same. Only the data changed.
The Result
Confidence increased dramatically:


That was the moment when the biggest lesson became obvious.
The largest improvement did not come from changing the model. It came from improving the dataset.
YOLOv8 certainly helped.
But the difference between 17 and 42 carefully selected images was dramatically larger than I expected.
Benchmarking Vertex AI
While building the training workflow, TerraScanAI also gained support for:
- Training job management
- Machine selection
- GPU selection
- Vertex AI integration
- Model registry workflows
- Deployment automation
That allowed me to benchmark exactly the same training workload across multiple environments.

Training configuration:
- Dataset: 42 images
- Model: YOLOv8
- Epochs: 50
- Batch size: 16
Results

At first glance, the NVIDIA Tesla T4 appeared to outperform the newer NVIDIA L4. However, these numbers represent end-to-end execution time, not pure training performance. For very small datasets like mine, infrastructure provisioning, scheduling and startup overhead become a significant part of the total runtime. For larger datasets, I expect cloud GPUs—especially newer accelerators like the L4—to become increasingly advantageous.
What Surprised Me Most
Before this experiment, I expected model architecture to be the dominant factor. Instead, the data itself turned out to be far more important than I anticipated.
The migration from YOLOv4 to YOLOv8 was valuable. But the jump from 17 images to 42 images produced a much larger improvement than I expected.
For anyone building custom AI systems, that may be the most valuable lesson from this entire experiment:
Better data often beats a better model.
What Comes Next?
Recognizing a vase was never the final goal. The real goal is recognizing individual cats.
If identifying a decorative vase required 42 carefully selected training images, how many examples will be needed before a robot can reliably distinguish:
- Bonifacy
- Lolek
- Bianca
- Frusia
from one another?
A flower pot was the easy part. Teaching a robot to recognize individual cats by name will be far more challenging. I already have a few ideas involving multi-stage AI pipelines and model chaining. That will be the subject of the next TerraScanAI article.

