- Storage Directory Change:
paddlex/configs
has been updated topaddlex/configs/modules
. - Module Name Changes, and related configuration file paths have also been updated:
anomaly_detection
updated toimage_anomaly_detection
face_recognition
updated toface_feature
general_recognition
updated toimage_feature
multilabel_classification
updated toimage_multilabel_classification
pedestrian_attribute
updated topedestrian_attribute_recognition
structure_analysis
updated tolayout_detection
table_recognition
updated totable_structure_recognition
text_detection_seal
updated toseal_text_detection
vehicle_attribute
updated tovehicle_attribute_recognition
-
Parameter Change:
model_name
: Only accepts model name.- New Parameters:
model_dir
: Specifies the local directory for inference model files, defaults toNone
, which means automatically downloading and using the official model.batch_size
: Specifies the batch size during inference, defaults to1
.- Supports specifying common model inference hyperparameters, with specific parameters related to the module, as detailed in the module tutorial documentation. For example, image classification module support
topk
. use_hpip
andhpi_params
: For supporting high-performance inference, not enabled by default.
-
Function Updates:
- Supports using PDF files as input samples for CV modules.
- Prediction results remain of
dict
type, but the format has changed: from{'key1': val}
to{"res": {'key': val}}
, using"res"
as the key with the original result data as the value. - When using the
save_to_xxx()
method to save prediction results, ifsave_path
is a directory, the name for stored files has changed. For example, saving in JSON format is{input_file_prefix}_res.json
; saving in image format is{input_file_prefix}_res_img.{input_file_extension}
.
- Configuration File Storage Directory Change:
paddlex/pipelines
updated topaddlex/configs/pipelines
. - Pipeline Name Changes:
ts_fc
updated tots_forecast
ts_ad
updated tots_anomaly_detection
ts_cls
updated tots_classification
- New Support:
- Inference hyperparameters, specific parameters related to the pipeline, detailed in the pipeline tutorial documentation. For example, image classification pipeline supports the
--topk
parameter to specify thetopk
results to return.
- Inference hyperparameters, specific parameters related to the pipeline, detailed in the pipeline tutorial documentation. For example, image classification pipeline supports the
- Removed:
--serial_number
, high-performance inference no longer requires the serial number.
- Removed:
- The
serial_number
parameter in high-performance inferencehpi_params
, high-performance inference no longer requires the serial number.
- The
- No Longer Supported:
- Setting pipeline inference hyperparameters, all related parameters must be set through the pipeline configuration file, such as
batch_size
, thresholds, etc.
- Setting pipeline inference hyperparameters, all related parameters must be set through the pipeline configuration file, such as
- Function Updates:
- When using the
save_to_xxx()
method to save prediction results, ifsave_path
is a directory, the name for stored files has updated. - CV model prediction results have a new
page_index
field, which indicates the page number of the current prediction result only when the input sample is a PDF file. - Model pipeline prediction results have new pipeline inference parameter fields, such as the
text_det_params
field in the OCR pipeline, with values for the post-processing settings of the text detection model.
- When using the
- Configuration File Format Update:
-
After updating the content of the pipeline configuration file, it is divided into three parts: pipeline name, pipeline-related parameter settings, and sub-pipelines and sub-modules composition. For example:
pipeline_name: pipeline # Pipeline Name threshold: 0.5 # Pipeline Inference Related Parameters SubPipelines: # Sub-pipelines DocPreprocessor: pipeline_name: doc_preprocessor use_doc_unwarping: True # Settings related to the sub-pipeline DocPreprocessor SubModules: # Sub-modules TextDetection: module_name: text_detection model_name: PP-OCRv4_mobile_det model_dir: null limit_side_len: 960 # Settings related to the sub-module TextDetection limit_type: max thresh: 0.3 box_thresh: 0.6 unclip_ratio: 2.0
-
- New Features:
- Document Preprocessing: Supports whole image direction classification and correction, controlled by relevant parameters in the
OCR.yaml
configuration file. - Text Line Direction Classification: Controlled by relevant parameters in the configuration file.
- Support for modifying model inference hyperparameters, such as post-processing parameters of the text detection model, controlled by relevant parameters in the configuration file.
- Document Preprocessing: Supports whole image direction classification and correction, controlled by relevant parameters in the
- New Features:
- Document Preprocessing: Supports whole image direction classification and correction, controlled by relevant parameters in the configuration file.
- Option to use the layout detection model: Controlled by relevant parameters in the configuration file.
- New Features:
- Document Preprocessing: Supports whole image direction classification and correction, controlled by relevant parameters in the configuration file.
- Option to use the OCR pipeline for text detection and recognition: Controlled by relevant parameters in the configuration file.
- Updated Features:
- Supports more inference hyperparameter settings, such as document preprocessing, text recognition, and model post-processing parameter settings, all of which can be configured in the pipeline configuration file.
-
New Features:
- Supports standard OpenAI API calls, which can be controlled through relevant parameters in the configuration file.
- Allows switching large language models during Chat API calls by passing the relevant configuration through the API call parameters.
-
Updated Features:
- Inference Module Initialization: Supports initialization of the inference module upon its first invocation, eliminating the need for full initialization at production line startup.
- Vector Library: Enables setting block size for long text and removes the control of interval duration between vector library calls.