The tlt-train tool does not support training on images of multiple resolutions, or resizing images during training. All of the images must be resized offline to the final training size and the corresponding bounding boxes must be scaled accordingly.
Have you resized all of your training/validation images/labels to 1920x1080?
i sent file from private message.
Tried to make sure training and test images are in same resolutions 1280 x 720.
I have included some training images and test images. peoplenet_H50V50_resnet34.tlt is new trained model and resnet34_peoplenet.tlt is Nvidia’s unpruned pretrained model.
I made sure all resolutions are 1280 x 720 for both training and testing. But still no detection at testing even though training accuracy shows very high. Do you receive data from private message?
Hi,
Your dataset folder does not contain any label files. Thus, I cannot trigger training.
One suggestion for you,
Did you ever label your test images? If yes, you can use them for training. This way will ensure the training data are more closed to test data.
The prunedmodels are intended for efficient deployment on the edge using DeepStream SDK or TensorRT. These models accept960x544x3dimension input tensors and outputs60x34x12bbox coordinate tensor and60x34x3 class confidence tensor.
Do you think I need to resize to 960x544x3 for trained images.
According to this, training is done on 1920x1080 images.
1. All objects that fall under one of the three classes (person, face, bag) in the image and are larger than the smallest bounding-box limit for the corresponding class (height >= 10px OR width >= 10px @1920x1080) are labeled with the appropriate class label.
1. Truncation: For an object other than a person that is at the edge of the frame with visibility of 60% or more visible are marked with the truncation flag for the object.
2. Truncation for person class: If a truncated person’s head and shoulders are visible and the visible height is approximately 20% or more mark the bounding box around the visible part of the person object. If the head and shoulders are not visible please follow the Truncation guidelines in item 5 above.
As long as head and shoulder can be seen, we don’t need truncation flag?
Because I trained with overlapping people images, so do I need truncation flag?
More, in order to monitor the evaluation mAP every 10 epoch during the training, could you change below in the spec? It will evaluate your test dataset directly during training.
“validation_fold : 0”
to
validation_data_source: {
tfrecords_path: " path to your test tfrecords "
image_directory_path: " path to test data source"
}
@edit_or
Actually your trained tlt model(peoplenet_H50V50_resnet34.tlt) can only detect a person inside a rectangular. This matches your training image.
Below is my inference step.
Use Windows-paint-select-rectangular_selection tool to modify your test image as below. Add two guys.
Suggest you to modify your training dataset’s labels, to make sure the label contains the exact coordinate of one person instead of the coordinate of the rectangular.
“exact coordinate of one person” means I need the x,y coordinates of the full body?
What I did was crop full body and place them into another background image with some % of overlapping. That means model recognizes not the person, but the rectangles.
In this case, place the full body cropped image onto a background image and make the rectangle smaller to make sure that model recognizes the person inside rather than the rectangle. Is that make sense?
First, could you tell what is the coordinate in your training label file?
Is it (x1,y1,x2,y2) of the rectangle or (x1,y1,x2,y2) of the cropped person inside this rectangle?
“exact coordinate of one person” means (x1,y1,x2,y2) of the cropped person inside the rectangle.
For “In this case, place the full body cropped image onto a background image and make the rectangle smaller to make sure that model recognizes the person inside rather than the rectangle.”
Please share an example image and its label. Thanks.
i have image labeling issue. Labeling is not right and training doesn’t work.
Please look at the following image. The cropped human bodies were placed on the background image. The bounding box is same as rectangle of cropped image. So model recognize the cropped rectangle rather than the person inside. How should I change the label so that model is retrained to recognize the person inside not the rectangle?
There is truncation flag definition for labeling Truncation for person class: If a truncated person’s head and shoulders are visible and the visible height is approximately 20% or more mark the bounding box around the visible part of the person object. If the head and shoulders are not visible please follow the Truncation guidelines in item 5 above..
So I put truncation flag only when the person’s head and shoulders are hidden. As long as 20% of the body is seen, need bounding box with no truncation flag. Is that true?