




import copy
from dataclasses import dataclass, field
from typing import ClassVar, Dict

from ..features import Audio, ClassLabel, Features
from .base import TaskTemplate






@dataclass(frozen=_lowercase	)
class  _lowerCAmelCase     (  _lowercase	):
      A__		     =		field(default='audio-classification'    ,			metadata={'include_in_asdict_even_if_is_default': True}	)
      A__		     =		Features({'audio': Audio()}	)
      A__		     =		Features({'labels': ClassLabel}	)
      A__		     =		"audio"
      A__		     =		"labels"

      def 	__magic_name__(   self      ,				__UpperCAmelCase		):
        if self.label_column not in features:
          raise ValueError(f"""Column {self.label_column} is not present in features."""		)
        if not isinstance(features[self.label_column]      ,				__UpperCAmelCase		):
          raise ValueError(f"""Column {self.label_column} is not a ClassLabel."""		)
        lowerCAmelCase__				:  Optional[Any]		       =     copy.deepcopy(self		)
        lowerCAmelCase__				:  Optional[int]		       =     self.label_schema.copy()
        lowerCAmelCase__				:  int		       =     features[self.label_column]
        lowerCAmelCase__				:  Any		       =     label_schema
        return task_template







      @property
      def 	__magic_name__(   self		):
        return {
            self.audio_column: "audio",
            self.label_column: "labels",
        }







lowerCAmelCase_					    = 6_55_21



def      __lowerCAmelCase			(					UpperCamelCase      )     ->	int:
  lowerCAmelCase__				:  List[str]		       =     1
  lowerCAmelCase__				:  List[Any]		       =     0
  for plain_chr in plain_text:
    lowerCAmelCase__				:  Union[str, Any]		       =     (a + ord(UpperCamelCase      )) % MOD_ADLER
    lowerCAmelCase__				:  Optional[Any]		       =     (b + a) % MOD_ADLER
  return (b << 16) | a

