o
    …ôjr  ã                   @   sÈ  d dl mZ d dlmZmZ ddlmZ erïddlmZm	Z	m
Z
 ddlmZ ddlmZmZ ddlmZmZ dd	lmZmZ dd
lmZmZ ddlmZmZmZmZmZmZm Z m!Z!m"Z"m#Z#m$Z$m%Z%m&Z&m'Z'm(Z(m)Z)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3 ddl4m5Z5m6Z6 ddl7m8Z8 ddl9m:Z:m;Z; ddl<m=Z= ddl>m?Z?m@Z@mAZAmBZBmCZC ddlDmEZE eƒ rÔddlFmGZGmHZHmIZImJZJ ddlFmKZKmLZLmMZMmNZNmOZOmPZPmQZQmRZRmSZS neTdƒ ddlUmVZVmWZW ddlXmYZY ddlZm[Z[m\Z\ nji dddg“dg d¢“dg d¢“ddg“d d!d"g“d#d$d%g“d&d'd(g“d)d*d+g“d,g d-¢“d.d/d0g“d1d2g“d3d4d5g“d6d7d8g“d9d:g“d;d<g“d=d>g“Z]eƒ �rFg d?¢e]d@< d dAl^Z^ee_e`ƒ dB e]eai dC�e^jbe_< eƒ �rbeƒ  dAS dAS )Dé    )ÚTYPE_CHECKING)ÚLazyImportModuleÚis_transformers_availableé   )Úfix_transformers_upgrade)ÚExporterÚTfModelExporterÚTorchModelExporter)ÚHubApi)Úcheck_local_model_is_latestÚcheck_model_is_id)Úpush_to_hubÚpush_to_hub_async)Úsnapshot_downloadÚdataset_snapshot_download)Úmodel_file_downloadÚdataset_file_download)ÚAccuracyMetricÚAudioNoiseMetricÚ
BleuMetricÚImageColorEnhanceMetricÚImageColorizationMetricÚImageDenoiseMetricÚImageInpaintingMetricÚ#ImageInstanceSegmentationCOCOMetricÚImagePortraitEnhancementMetricÚ'ImageQualityAssessmentDegradationMetricÚImageQualityAssessmentMosMetricÚ
LossMetricÚMetricÚMovieSceneSegmentationMetricÚOCRRecognitionMetricÚ	PplMetricÚ&ReferringVideoObjectSegmentationMetricÚSequenceClassificationMetricÚTextGenerationMetricÚTextRankingMetricÚTokenClassificationMetricÚVideoFrameInterpolationMetricÚVideoStabilizationMetricÚVideoSummarizationMetricÚVideoSuperResolutionMetricÚtask_default_metrics)ÚModelÚ
TorchModel)Ú	MsDataset)ÚPipelineÚpipeline)ÚPreprocessor)ÚEpochBasedTrainerÚHookÚPriorityÚTrainingArgsÚbuild_dataset_from_file)ÚTasks)Ú
AutoConfigÚ
GPTQConfigÚ	AwqConfigÚBitsAndBytesConfig)	Ú	AutoModelÚAutoModelForCausalLMÚAutoModelForSeq2SeqLMÚ"AutoModelForSequenceClassificationÚAutoModelForTokenClassificationÚAutoTokenizerÚGenerationConfigÚAutoImageProcessorÚBatchFeaturezRtransformer is not installed, please install it if you want to use related modules)Úcreate_model_if_not_existÚread_config)Ú
get_logger)Ú__release_datetime__Ú__version__ÚversionrI   rJ   Útrainers)r3   r6   r4   r5   r7   Ú	exporterszhub.apir
   zhub.snapshot_downloadr   r   zhub.file_downloadr   r   zhub.push_to_hubr   r   zhub.check_modelr   r   Úmetrics)r   r   r,   r   r   r   r   r$   r%   r'   r*   r    r   r   r   r#   r(   r)   r+   r"   r   r   r&   r   r   r!   Úmodelsr-   r.   Úpreprocessorsr2   Ú	pipelinesr0   r1   z	utils.hubrG   rF   zutils.loggerrH   zutils.constantr8   Ú
msdatasetsr/   )r9   rC   r=   r:   r;   r<   r>   r?   rB   r@   rA   rD   rE   zutils.hf_utilNÚ__file__)Zmodule_specZextra_objects)cÚtypingr   Zmodelscope.utils.import_utilsr   r   Zutils.automodel_utilsr   rM   r   r   r	   Zhub.apir
   Zhub.check_modelr   r   Zhub.push_to_hubr   r   Zhub.snapshot_downloadr   r   Zhub.file_downloadr   r   rN   r   r   r   r   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   r+   r,   rO   r-   r.   rR   r/   rQ   r0   r1   rP   r2   rL   r3   r4   r5   r6   r7   Zutils.constantr8   Zutils.hf_utilr9   r:   r;   r<   r=   r>   r?   r@   rA   rB   rC   rD   rE   ÚprintZ	utils.hubrF   rG   Zutils.loggerrH   rK   rI   rJ   Z_import_structureÚsysÚ__name__ÚglobalsÚ__spec__Úmodules© r[   r[   úf/var/www/html/academy/tools/voices/clone/cosy-venv/lib/python3.10/site-packages/modelscope/__init__.pyÚ<module>   s”   p.ÿÿþúõóòñïî!ß"Þ#Ý$Ü%Û&Ú'Ù*	û
ÿ