'''simple docstring'''




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

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

@dataclass(frozen=snake_case__    )
class 	lowerCamelCase_	(snake_case__    ):
      '''simple docstring'''

      __UpperCamelCase:  str						=						field(default="audio-classification"							, metadata={"include_in_asdict_even_if_is_default": True}    )
      __UpperCamelCase:  ClassVar[Features]						=						Features({"audio": Audio()}    )
      __UpperCamelCase:  ClassVar[Features]						=						Features({"labels": ClassLabel}    )
      __UpperCamelCase:  str						=						"audio"
      __UpperCamelCase:  str						=						"labels"




      def      _A	(       self						:				int						,					A						:				List[Any]       ):
             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]						,					A       ):
                    raise ValueError(F"""Column {self.label_column} is not a ClassLabel."""       )
             _UpperCAmelCase     :  Optional[int]							      =    copy.deepcopy(self       )
             _UpperCAmelCase     :  List[str]							      =    self.label_schema.copy()
             _UpperCAmelCase     :  List[str]							      =    features[self.label_column]
             _UpperCAmelCase     :  str							      =    label_schema
             return task_template





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








from timeit import timeit

def   a_    ( lowerCAmelCase_      :			int	):
   if number < 0:
      raise ValueError('the value of input must not be negative'	)
   __lowerCAmelCase								=	0
   while number:
      number &= number - 1
      result += 1
   return result

def   a_    ( lowerCAmelCase_      :			int	):
   if number < 0:
      raise ValueError('the value of input must not be negative'	)
   __lowerCAmelCase								=	0
   while number:
      if number % 2 == 1:
         result += 1
      number >>= 1
   return result

def   a_    ( ):

   def do_benchmark(lowerCAmelCase_      :			int	) -> None:
      __lowerCAmelCase								=	'import __main__ as z'
      print(F"""Benchmark when {number = }:"""	)
      print(F"""{get_set_bits_count_using_modulo_operator(lowerCAmelCase_	) = }"""	)
      __lowerCAmelCase								=	timeit('z.get_set_bits_count_using_modulo_operator(25)',	setup=lowerCAmelCase_	)
      print(F"""timeit() runs in {timing} seconds"""	)
      print(F"""{get_set_bits_count_using_brian_kernighans_algorithm(lowerCAmelCase_	) = }"""	)
      __lowerCAmelCase								=	timeit(
          'z.get_set_bits_count_using_brian_kernighans_algorithm(25)',	setup=lowerCAmelCase_,	)
      print(F"""timeit() runs in {timing} seconds"""	)

   for number in (25, 37, 58, 0):
      do_benchmark(lowerCAmelCase_	)
      print()


if __name__ == "__main__":
     import doctest

     doctest.testmod()
     benchmark()

