
    9i                         S SK JrJrJrJrJr  S SKrSSKJ	r	  SSK
Jr  SSKJr  SSKJr  SS	KJr  S
SKJr  \R(                  \	" S5       " S S\5      5       5       rg)    )AnyDictListOptionalUnionN   )pipeline_requires_extra   )TSClsResult)	benchmark)	HPIConfig)PaddlePredictorOption   )BasePipelinetsc                      ^  \ rS rSrSrSr    SS\S\S\S\	S	\
\\\\4   \4      S
S4U 4S jjjrS\\\\   \R"                  \\R"                     4   S
\4S jrSrU =r$ )TSClsPipeline   zTSClsPipeline Pipelinets_classificationNconfigdevice	pp_optionuse_hpip
hpi_configreturnc                 ^   > [         TU ]  X#XES9  US   S   nU R                  U5      U l        g)a]  Initializes the Time Series classification pipeline.

Args:
    config (Dict): Configuration dictionary containing various settings.
    device (str, optional): Device to run the predictions on. Defaults to None.
    pp_option (PaddlePredictorOption, optional): PaddlePredictor options. Defaults to None.
    use_hpip (bool, optional): Whether to use the high-performance
        inference plugin (HPIP) by default. Defaults to False.
    hpi_config (Optional[Union[Dict[str, Any], HPIConfig]], optional):
        The default high-performance inference configuration dictionary.
        Defaults to None.
)r   r   r   r   
SubModulesTSClassificationN)super__init__create_modelts_classification_model)selfr   r   r   r   r   ts_classification_model_config	__class__s          v/var/www/html/land-doc-ocr/venv/lib/python3.13/site-packages/paddlex/inference/pipelines/ts_classification/pipeline.pyr    TSClsPipeline.__init__"   sC    * 	 	 	
 *0)=>P)Q&'+'8'89W'X$    inputc              +   B   #    U R                  U5       Sh  vN   g N7f)aU  Predicts time series classification results for the given input.

Args:
    input (Union[str, list[str], pd.DataFrame, list[pd.DataFrame]]): The input image(s) or path(s) to the images.
    **kwargs: Additional keyword arguments that can be passed to the function.

Returns:
    TSFcResult: The predicted time series classification results.
Nr"   )r#   r)   kwargss      r&   predictTSClsPipeline.predict>   s      //666s   r+   )NNFN)__name__
__module____qualname____firstlineno____doc__entitiesr   strr   boolr   r   r   r   r    r   pd	DataFramer   r-   __static_attributes____classcell__)r%   s   @r&   r   r      s     !"H
 +/AEYY Y )	Y
 Y U4S>9#<=>Y 
Y Y873S	2<<bll9KKL7	7 7r(   r   )typingr   r   r   r   r   pandasr7   
utils.depsr	   models.ts_classification.resultr   utils.benchmarkr   	utils.hpir   utils.pp_optionr   baser   time_methodsr    r(   r&   <module>rE      sP    4 3  2 : ( " 4  -7L -7  -7r(   