Interface IRFDetrDetectionPreprocessor
- Namespace
- NT2I.ONNX.Abstractions.Interfaces.RFDetr
- Assembly
- NT2I.ONNX.Abstractions.dll
Définit le contrat pour un pré-processeur spécifique aux modèles de détection RF-DETR.
Le pipeline de pré-traitement RF-DETR utilise :
- Normalisation ImageNet — mean=[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225] (ordre RGB).
- Resize direct (StretchResize) — pas de letterbox, ratio d'aspect non conservé.
- Layout NCHW — [batch, 3, H, W] en float32.
CudaSharedImageContext : cache hit sur Requirements identiques).
public interface IRFDetrDetectionPreprocessor : IPreprocessor, IDisposable
- Inherited Members
Methods
BatchProcessBGR(byte[][], int[], int[], int, int, int)
Prétraite un batch d'images au format BGR.
IDataHandlingResult BatchProcessBGR(byte[][] PackedBGRBatchBuffer, int[] widthsPerImage, int[] heightsPerImage, int batchSize, int targetWidth, int targetHeight)
Parameters
PackedBGRBatchBufferbyte[][]Tableau de buffers BGR, un par image.
widthsPerImageint[]Largeurs des images sources.
heightsPerImageint[]Hauteurs des images sources.
batchSizeintNombre d'images dans le batch.
targetWidthintLargeur cible après redimensionnement.
targetHeightintHauteur cible après redimensionnement.
Returns
- IDataHandlingResult
Un résultat de traitement contenant les données du batch prêtes pour l'inférence.
BatchProcessPlanar(byte[][], byte[][], byte[][], int[], int[], int, int, int)
Prétraite un batch d'images au format planaire.
IDataHandlingResult BatchProcessPlanar(byte[][] PlanarBatchBuffer_R, byte[][] PlanarBatchBuffer_G, byte[][] PlanarBatchBuffer_B, int[] widthsPerImage, int[] heightsPerImage, int batchSize, int targetWidth, int targetHeight)
Parameters
PlanarBatchBuffer_Rbyte[][]Canaux rouges, un par image.
PlanarBatchBuffer_Gbyte[][]Canaux verts, un par image.
PlanarBatchBuffer_Bbyte[][]Canaux bleus, un par image.
widthsPerImageint[]Largeurs des images sources.
heightsPerImageint[]Hauteurs des images sources.
batchSizeintNombre d'images dans le batch.
targetWidthintLargeur cible après redimensionnement.
targetHeightintHauteur cible après redimensionnement.
Returns
- IDataHandlingResult
Un résultat de traitement contenant les données du batch prêtes pour l'inférence.
ProcessBGR(byte[], int, int, int, int)
Prétraite une seule image au format BGR.
IDataHandlingResult ProcessBGR(byte[] PackedBGRBuffer, int imageWidth, int imageHeight, int targetWidth, int targetHeight)
Parameters
PackedBGRBufferbyte[]Buffer contenant l'image au format BGR entrelacé (B₀G₀R₀…).
imageWidthintLargeur de l'image source en pixels.
imageHeightintHauteur de l'image source en pixels.
targetWidthintLargeur cible après redimensionnement.
targetHeightintHauteur cible après redimensionnement.
Returns
- IDataHandlingResult
Un résultat de traitement contenant les données prêtes pour l'inférence.
ProcessPlanar(byte[], byte[], byte[], int, int, int, int)
Prétraite une seule image au format planaire (R, G, B séparés).
IDataHandlingResult ProcessPlanar(byte[] PlanarBuffer_R, byte[] PlanarBuffer_G, byte[] PlanarBuffer_B, int imageWidth, int imageHeight, int targetWidth, int targetHeight)
Parameters
PlanarBuffer_Rbyte[]Canal rouge de l'image source.
PlanarBuffer_Gbyte[]Canal vert de l'image source.
PlanarBuffer_Bbyte[]Canal bleu de l'image source.
imageWidthintLargeur de l'image source en pixels.
imageHeightintHauteur de l'image source en pixels.
targetWidthintLargeur cible après redimensionnement.
targetHeightintHauteur cible après redimensionnement.
Returns
- IDataHandlingResult
Un résultat de traitement contenant les données prêtes pour l'inférence.