/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rocal/checkouts/docs-6.2.0/rocAL/include/api/rocal_api_data_loaders.h Source File

/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rocal/checkouts/docs-6.2.0/rocAL/include/api/rocal_api_data_loaders.h Source File#

rocAL: /home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rocal/checkouts/docs-6.2.0/rocAL/include/api/rocal_api_data_loaders.h Source File
rocal_api_data_loaders.h
Go to the documentation of this file.
1 /*
2 Copyright (c) 2019 - 2023 Advanced Micro Devices, Inc. All rights reserved.
3 
4 Permission is hereby granted, free of charge, to any person obtaining a copy
5 of this software and associated documentation files (the "Software"), to deal
6 in the Software without restriction, including without limitation the rights
7 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8 copies of the Software, and to permit persons to whom the Software is
9 furnished to do so, subject to the following conditions:
10 
11 The above copyright notice and this permission notice shall be included in
12 all copies or substantial portions of the Software.
13 
14 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
20 THE SOFTWARE.
21 */
22 
23 #ifndef MIVISIONX_ROCAL_API_DATA_LOADERS_H
24 #define MIVISIONX_ROCAL_API_DATA_LOADERS_H
25 #include "rocal_api_types.h"
26 #include <vector>
27 
54  const char *source_path,
55  RocalImageColor rocal_color_format,
56  unsigned internal_shard_count,
57  bool is_output,
58  bool shuffle = false,
59  bool loop = false,
61  unsigned max_width = 0, unsigned max_height = 0, RocalDecoderType rocal_decoder_type = RocalDecoderType::ROCAL_DECODER_TJPEG);
62 
81  const char *source_path,
82  RocalImageColor rocal_color_format,
83  unsigned shard_id,
84  unsigned shard_count,
85  bool is_output,
86  bool shuffle = false,
87  bool loop = false,
89  unsigned max_width = 0, unsigned max_height = 0, RocalDecoderType rocal_decoder_type = RocalDecoderType::ROCAL_DECODER_TJPEG);
90 
107  const char *source_path,
108  RocalImageColor rocal_color_format,
109  unsigned internal_shard_count,
110  unsigned sequence_length,
111  bool is_output,
112  bool shuffle = false,
113  bool loop = false,
114  unsigned step = 0,
115  unsigned stride = 0);
116 
134  const char *source_path,
135  RocalImageColor rocal_color_format,
136  unsigned shard_id,
137  unsigned shard_count,
138  unsigned sequence_length,
139  bool is_output,
140  bool shuffle = false,
141  bool loop = false,
142  unsigned step = 0,
143  unsigned stride = 0);
144 
162  const char *source_path,
163  const char *json_path,
164  RocalImageColor color_format,
165  unsigned internal_shard_count,
166  bool is_output,
167  bool shuffle = false,
168  bool loop = false,
170  unsigned max_width = 0, unsigned max_height = 0,
172 
192  const char *source_path,
193  const char *json_path,
194  RocalImageColor rocal_color_format,
195  unsigned internal_shard_count,
196  bool is_output,
197  std::vector<float> &area_factor,
198  std::vector<float> &aspect_ratio,
199  unsigned num_attempts,
200  bool shuffle = false,
201  bool loop = false,
203  unsigned max_width = 0, unsigned max_height = 0);
204 
224  const char *source_path,
225  const char *json_path,
226  RocalImageColor rocal_color_format,
227  unsigned shard_id,
228  unsigned shard_count,
229  bool is_output,
230  std::vector<float> &area_factor,
231  std::vector<float> &aspect_ratio,
232  unsigned num_attempts,
233  bool shuffle = false,
234  bool loop = false,
236  unsigned max_width = 0, unsigned max_height = 0);
253  const char *source_path,
254  const char *json_path,
255  RocalImageColor color_format,
256  unsigned shard_id,
257  unsigned shard_count,
258  bool is_output,
259  bool shuffle = false,
260  bool loop = false,
262  unsigned max_width = 0, unsigned max_height = 0,
264 
282  const char *source_path,
283  RocalImageColor rocal_color_format,
284  unsigned internal_shard_count,
285  bool is_output,
286  bool shuffle = false,
287  bool loop = false,
289  unsigned max_width = 0, unsigned max_height = 0,
291 
310  const char *source_path,
311  RocalImageColor rocal_color_format,
312  unsigned shard_id,
313  unsigned shard_count,
314  bool is_output,
315  bool shuffle = false,
316  bool loop = false,
318  unsigned max_width = 0, unsigned max_height = 0,
320 
339  const char *source_path,
340  RocalImageColor rocal_color_format,
341  unsigned internal_shard_count,
342  bool is_output,
343  bool shuffle = false,
344  bool loop = false,
346  unsigned max_width = 0, unsigned max_height = 0,
348 
367  const char *source_path,
368  RocalImageColor rocal_color_format,
369  unsigned shard_id,
370  unsigned shard_count,
371  bool is_output,
372  bool shuffle = false,
373  bool loop = false,
375  unsigned max_width = 0, unsigned max_height = 0,
377 
396  const char *source_path,
397  RocalImageColor rocal_color_format,
398  unsigned internal_shard_count,
399  bool is_output,
400  bool shuffle = false,
401  bool loop = false,
403  unsigned max_width = 0, unsigned max_height = 0,
405 
424  const char *source_path,
425  RocalImageColor rocal_color_format,
426  unsigned shard_id,
427  unsigned shard_count,
428  bool is_output,
429  bool shuffle = false,
430  bool loop = false,
432  unsigned max_width = 0, unsigned max_height = 0,
434 
455  const char *source_path,
456  RocalImageColor rocal_color_format,
457  unsigned num_threads,
458  bool is_output,
459  std::vector<float> &area_factor,
460  std::vector<float> &aspect_ratio,
461  unsigned num_attempts,
462  bool shuffle = false,
463  bool loop = false,
465  unsigned max_width = 0, unsigned max_height = 0);
466 
485  const char *source_path,
486  RocalImageColor color_format,
487  unsigned shard_id,
488  unsigned shard_count,
489  bool is_output,
490  std::vector<float> &area_factor,
491  std::vector<float> &aspect_ratio,
492  unsigned num_attempts,
493  bool shuffle = false,
494  bool loop = false,
496  unsigned max_width = 0, unsigned max_height = 0);
497 
516  const char *source_path,
517  RocalImageColor rocal_color_format,
518  unsigned internal_shard_count,
519  bool is_output,
520  const char *user_key_for_encoded,
521  const char *user_key_for_filename,
522  bool shuffle = false,
523  bool loop = false,
525  unsigned max_width = 0, unsigned max_height = 0,
527 
546  const char *source_path,
547  RocalImageColor rocal_color_format,
548  unsigned shard_id,
549  unsigned shard_count,
550  bool is_output,
551  bool shuffle = false,
552  bool loop = false,
554  unsigned max_width = 0, unsigned max_height = 0,
556 
571  const char *source_path,
572  const char *user_key_for_raw,
573  const char *user_key_for_filename,
574  RocalImageColor rocal_color_format,
575  bool is_output,
576  bool shuffle = false,
577  bool loop = false,
578  unsigned out_width = 0, unsigned out_height = 0,
579  const char *record_name_prefix = "");
580 
597  const char *source_path,
598  RocalImageColor rocal_color_format,
599  unsigned shard_id,
600  unsigned shard_count,
601  bool is_output,
602  bool shuffle = false,
603  bool loop = false,
604  unsigned out_width = 0, unsigned out_height = 0,
605  const char *record_name_prefix = "");
606 
627  const char *source_path,
628  RocalImageColor color_format,
629  RocalDecodeDevice rocal_decode_device,
630  unsigned internal_shard_count,
631  unsigned sequence_length,
632  const std::vector<std::string>& file_names_list,
633  bool is_output = false,
634  bool shuffle = false,
635  bool loop = false,
636  unsigned step = 0,
637  unsigned stride = 0,
638  bool file_list_frame_num = true);
639 
661  const char *source_path,
662  RocalImageColor color_format,
663  RocalDecodeDevice rocal_decode_device,
664  unsigned shard_id,
665  unsigned shard_count,
666  unsigned sequence_length,
667  const std::vector<std::string>& file_names_list,
668  bool shuffle = false,
669  bool is_output = false,
670  bool loop = false,
671  unsigned step = 0,
672  unsigned stride = 0,
673  bool file_list_frame_num = true);
674 
697  const char *source_path,
698  RocalImageColor color_format,
699  RocalDecodeDevice rocal_decode_device,
700  unsigned internal_shard_count,
701  unsigned sequence_length,
702  unsigned dest_width,
703  unsigned dest_height,
704  const std::vector<std::string>& file_names_list,
705  bool shuffle = false,
706  bool is_output = false,
707  bool loop = false,
708  unsigned step = 0,
709  unsigned stride = 0,
710  bool file_list_frame_num = true,
712  std::vector<unsigned> max_size = {},
713  unsigned resize_shorter = 0,
714  unsigned resize_longer = 0,
716 
740  const char *source_path,
741  RocalImageColor color_format,
742  RocalDecodeDevice rocal_decode_device,
743  unsigned shard_id,
744  unsigned shard_count,
745  unsigned sequence_length,
746  unsigned dest_width,
747  unsigned dest_height,
748  const std::vector<std::string>& file_names_list,
749  bool shuffle = false,
750  bool is_output = false,
751  bool loop = false,
752  unsigned step = 0,
753  unsigned stride = 0,
754  bool file_list_frame_num = true,
756  std::vector<unsigned> max_size = {},
757  unsigned resize_shorter = 0,
758  unsigned resize_longer = 0,
760 
774  const char *source_path,
775  RocalImageColor color_format,
776  bool is_output,
777  unsigned out_width, unsigned out_height, const char *filename_prefix = "",
778  bool loop = false);
779 
787 
808  const char *source_path,
809  RocalImageColor rocal_color_format,
810  unsigned shard_id,
811  unsigned shard_count,
812  bool is_output,
813  std::vector<float> &area_factor,
814  std::vector<float> &aspect_ratio,
815  unsigned num_attempts,
816  bool shuffle = false,
817  bool loop = false,
819  unsigned max_width = 0, unsigned max_height = 0);
820 
838  const char *source_path,
839  RocalImageColor rocal_color_format,
840  unsigned shard_id,
841  unsigned shard_count,
842  bool is_output,
843  std::vector<float> &area_factor,
844  std::vector<float> &aspect_ratio,
845  unsigned num_attempts,
846  bool shuffle = false,
847  bool loop = false,
849  unsigned max_width = 0, unsigned max_height = 0);
850 
851 #endif // MIVISIONX_ROCAL_API_DATA_LOADERS_H
RocalImage ROCAL_API_CALL rocalJpegCOCOFileSourcePartialSingleShard(RocalContext p_context, const char *source_path, const char *json_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder. It allocates the resources and objects required to rea...
RocalImage ROCAL_API_CALL rocalJpegCOCOFileSourceSingleShard(RocalContext context, const char *source_path, const char *json_path, RocalImageColor color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
RocalImage ROCAL_API_CALL rocalFusedJpegCropSingleShard(RocalContext context, const char *source_path, RocalImageColor color_format, unsigned shard_id, unsigned shard_count, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder. It allocates the resources and objects required to rea...
RocalImage ROCAL_API_CALL rocalJpegCaffe2LMDBRecordSourcePartialSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder for Caffe2 LMDB records. It allocates the resources and...
RocalImage ROCAL_API_CALL rocalJpegFileSourceSingleShard(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder. It allocates the resources and objects required to read and de...
RocalImage ROCAL_API_CALL rocalJpegTFRecordSourceSingleShard(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates TensorFlow records JPEG image reader and decoder. It allocates the resources and objects requ...
RocalImage ROCAL_API_CALL rocalRawTFRecordSourceSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, unsigned out_width=0, unsigned out_height=0, const char *record_name_prefix="")
Creates Raw image loader. It allocates the resources and objects required to load images stored on th...
RocalImage ROCAL_API_CALL rocalRawTFRecordSource(RocalContext p_context, const char *source_path, const char *user_key_for_raw, const char *user_key_for_filename, RocalImageColor rocal_color_format, bool is_output, bool shuffle=false, bool loop=false, unsigned out_width=0, unsigned out_height=0, const char *record_name_prefix="")
Creates Raw image loader. It allocates the resources and objects required to load images stored on th...
RocalImage ROCAL_API_CALL rocalJpegCaffe2LMDBRecordSourceSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for Caffe2 LMDB records. It allocates the resources and objects...
RocalImage ROCAL_API_CALL rocalVideoFileSource(RocalContext context, const char *source_path, RocalImageColor color_format, RocalDecodeDevice rocal_decode_device, unsigned internal_shard_count, unsigned sequence_length, const std::vector< std::string > &file_names_list, bool is_output=false, bool shuffle=false, bool loop=false, unsigned step=0, unsigned stride=0, bool file_list_frame_num=true)
Creates a video reader and decoder as a source. It allocates the resources and objects required to re...
RocalImage ROCAL_API_CALL rocalVideoFileSourceSingleShard(RocalContext context, const char *source_path, RocalImageColor color_format, RocalDecodeDevice rocal_decode_device, unsigned shard_id, unsigned shard_count, unsigned sequence_length, const std::vector< std::string > &file_names_list, bool shuffle=false, bool is_output=false, bool loop=false, unsigned step=0, unsigned stride=0, bool file_list_frame_num=true)
Creates a video reader and decoder as a source. It allocates the resources and objects required to re...
RocalImage ROCAL_API_CALL rocalRawCIFAR10Source(RocalContext context, const char *source_path, RocalImageColor color_format, bool is_output, unsigned out_width, unsigned out_height, const char *filename_prefix="", bool loop=false)
Creates CIFAR10 raw data reader and loader. It allocates the resources and objects required to read r...
RocalImage ROCAL_API_CALL rocalJpegCaffeLMDBRecordSourceSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for Caffe LMDB records. It allocates the resources and objects ...
RocalImage ROCAL_API_CALL rocalJpegCaffeLMDBRecordSourcePartialSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder for Caffe LMDB records. It allocates the resources and ...
RocalImage ROCAL_API_CALL rocalJpegFileSource(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder. It allocates the resources and objects required to read and de...
RocalImage ROCAL_API_CALL rocalVideoFileResize(RocalContext context, const char *source_path, RocalImageColor color_format, RocalDecodeDevice rocal_decode_device, unsigned internal_shard_count, unsigned sequence_length, unsigned dest_width, unsigned dest_height, const std::vector< std::string > &file_names_list, bool shuffle=false, bool is_output=false, bool loop=false, unsigned step=0, unsigned stride=0, bool file_list_frame_num=true, RocalResizeScalingMode scaling_mode=ROCAL_SCALING_MODE_DEFAULT, std::vector< unsigned > max_size={}, unsigned resize_shorter=0, unsigned resize_longer=0, RocalResizeInterpolationType interpolation_type=ROCAL_LINEAR_INTERPOLATION)
Creates a video reader and decoder as a source. It allocates the resources and objects required to re...
RocalImage ROCAL_API_CALL rocalJpegCaffeLMDBRecordSource(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for Caffe LMDB records. It allocates the resources and objects ...
RocalImage ROCAL_API_CALL rocalVideoFileResizeSingleShard(RocalContext context, const char *source_path, RocalImageColor color_format, RocalDecodeDevice rocal_decode_device, unsigned shard_id, unsigned shard_count, unsigned sequence_length, unsigned dest_width, unsigned dest_height, const std::vector< std::string > &file_names_list, bool shuffle=false, bool is_output=false, bool loop=false, unsigned step=0, unsigned stride=0, bool file_list_frame_num=true, RocalResizeScalingMode scaling_mode=ROCAL_SCALING_MODE_DEFAULT, std::vector< unsigned > max_size={}, unsigned resize_shorter=0, unsigned resize_longer=0, RocalResizeInterpolationType interpolation_type=ROCAL_LINEAR_INTERPOLATION)
Creates a video reader and decoder as a source. It allocates the resources and objects required to re...
RocalImage ROCAL_API_CALL rocalJpegCOCOFileSourcePartial(RocalContext p_context, const char *source_path, const char *json_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder. It allocates the resources and objects required to rea...
RocalImage ROCAL_API_CALL rocalJpegTFRecordSource(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, const char *user_key_for_encoded, const char *user_key_for_filename, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates TensorFlow records JPEG image reader and decoder. It allocates the resources and objects requ...
RocalImage ROCAL_API_CALL rocalFusedJpegCrop(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned num_threads, bool is_output, std::vector< float > &area_factor, std::vector< float > &aspect_ratio, unsigned num_attempts, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0)
Creates JPEG image reader and partial decoder. It allocates the resources and objects required to rea...
RocalImage ROCAL_API_CALL rocalSequenceReader(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, unsigned sequence_length, bool is_output, bool shuffle=false, bool loop=false, unsigned step=0, unsigned stride=0)
Creates JPEG image reader and decoder. Reads [Frames] sequences from a directory representing a colle...
RocalStatus ROCAL_API_CALL rocalResetLoaders(RocalContext context)
RocalImage ROCAL_API_CALL rocalJpegCaffe2LMDBRecordSource(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for Caffe2 LMDB records. It allocates the resources and objects...
RocalImage ROCAL_API_CALL rocalJpegCOCOFileSource(RocalContext context, const char *source_path, const char *json_path, RocalImageColor color_format, unsigned internal_shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder. It allocates the resources and objects required to read and de...
RocalImage ROCAL_API_CALL rocalMXNetRecordSource(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned internal_shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for MXNet records. It allocates the resources and objects requi...
RocalImage ROCAL_API_CALL rocalMXNetRecordSourceSingleShard(RocalContext p_context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, bool is_output, bool shuffle=false, bool loop=false, RocalImageSizeEvaluationPolicy decode_size_policy=ROCAL_USE_MOST_FREQUENT_SIZE, unsigned max_width=0, unsigned max_height=0, RocalDecoderType rocal_decoder_type=RocalDecoderType::ROCAL_DECODER_TJPEG)
Creates JPEG image reader and decoder for MXNet records. It allocates the resources and objects requi...
RocalImage ROCAL_API_CALL rocalSequenceReaderSingleShard(RocalContext context, const char *source_path, RocalImageColor rocal_color_format, unsigned shard_id, unsigned shard_count, unsigned sequence_length, bool is_output, bool shuffle=false, bool loop=false, unsigned step=0, unsigned stride=0)
Creates JPEG image reader and decoder. Reads [Frames] sequences from a directory representing a colle...
RocalDecoderType
rocAL Decoder Type enum
Definition: rocal_api_types.h:244
RocalResizeScalingMode
rocAL Resize Scaling Mode enum
Definition: rocal_api_types.h:295
RocalStatus
rocAL Status enum
Definition: rocal_api_types.h:113
RocalImageSizeEvaluationPolicy
rocAL Image Size Evaluation Policy enum
Definition: rocal_api_types.h:180
RocalDecodeDevice
rocAL Decode Device enum
Definition: rocal_api_types.h:202
void * RocalContext
typedef void* rocAL Context
Definition: rocal_api_types.h:61
RocalResizeInterpolationType
rocAL Resize Interpolation Type enum
Definition: rocal_api_types.h:314
RocalImageColor
rocAL Image Color enum
Definition: rocal_api_types.h:135
void * RocalImage
typedef void* rocAL Image
Definition: rocal_api_types.h:65
@ ROCAL_DECODER_TJPEG
AMD ROCAL_DECODER_TJPEG.
Definition: rocal_api_types.h:247
@ ROCAL_SCALING_MODE_DEFAULT
scales wrt specified size, if only resize width/height is provided the other dimension is scaled acco...
Definition: rocal_api_types.h:298
@ ROCAL_USE_MOST_FREQUENT_SIZE
AMD ROCAL_USE_MOST_FREQUENT_SIZE.
Definition: rocal_api_types.h:189
@ ROCAL_LINEAR_INTERPOLATION
AMD ROCAL_LINEAR_INTERPOLATION.
Definition: rocal_api_types.h:320
The AMD rocAL Library - Types.
#define ROCAL_API_CALL
Definition: rocal_api_types.h:35