Open https://app.roboflow.com/ in your browser, and navigate to the Workflows tab to click
the Create Workflows button. Select Custom Workflow to start the creation process.
We need to add a block with an object detection model to the existing workflow. We will use the yolov8n-640 model.
Step 3: Crop each detected object to run breed classification¶
Next, we are going to add a block to our Workflow that crops the objects that our first model detects.
Step 4: Classify dog breeds with second stage model¶
We are then going to add a classification model that runs on each crop to classify its content. We will use
Roboflow Universe model dog-breed-xpaq6/1. Please make sure that in the block configuration, the Image property
points to the crops output of the Dynamic Crop block.
Step 5: Replace Bounding Box classes with classification model predictions¶
When each crop is classified, we would like to assign the class predicted for each crop (dog breed) as a class
of the dog bounding boxes from the object detection model . To do this we use Detections Classes Replacement block,
which accepts a reference to predictions of a object detection model, as well as a reference to the classification
results on the crops.
As a final step of the workflow, we would like to visualize our predictions. We will use two
visualization blocks: Bounding Box Visualization and Label Visualization chained together.
At first, add Bounding Box Visualization referring to $inputs.image for the Image property (that's the
image sent as your input to workflow), the second step (Label Visualization) however, should point to
the output of Bounding Box Visualization step. Both visualization steps should refer to predictions
from the Detections Classes Replacement step.
You have everything ready to construct your workflow output. You can use any intermediate step output that you
need, but in this example we will only select bounding boxes with replaced classes (output from Detections
Classes Replacement step) and visualisation (output from Label Visualization step).