



'''simple docstring'''





import doctest
from collections import deque

import numpy as np






class __A    :



 '''simple docstring'''







 def __init__(self )					->  Optional[int]:


      """simple docstring"""



      _a											=						[2, 1, 2, -1]
      _a											=						[1, 2, 3, 4]



 def       a__						(self )					->  List[str]:


      """simple docstring"""



      _a											=						len(self.first_signal )
      _a											=						len(self.second_signal )

      _a											=						max(UpperCamelCase__				,     UpperCamelCase__ )

      # create a zero matrix of max_length x max_length
      _a											=						[[0] * max_length for i in range(UpperCamelCase__ )]

      # fills the smaller signal with zeros to make both signals of same length
      if length_first_signal < length_second_signal:
           self.first_signal += [0] * (max_length - length_first_signal)
      elif length_first_signal > length_second_signal:
           self.second_signal += [0] * (max_length - length_second_signal)
      for i in range(UpperCamelCase__ ):
           _a											=						deque(self.second_signal )
           rotated_signal.rotate(UpperCamelCase__ )
           for j, item in enumerate(UpperCamelCase__ ):
                matrix[i][j] += item

        # multiply the matrix with the first signal
      _a											=						np.matmul(np.transpose(UpperCamelCase__ )				,     np.transpose(self.first_signal ) )

      # rounding-off to two decimal places
      return [round(UpperCamelCase__				,     2 ) for i in final_signal]


if __name__ == "__main__":
  doctest.testmod()








'''simple docstring'''





import pytest

import datasets


# Import fixture modules as plugins
lowercase_	 =						["tests.fixtures.files", "tests.fixtures.hub", "tests.fixtures.fsspec"]




def lowerCAmelCase						(__A						,			__A):



     """simple docstring"""



     for item in items:
          if any(marker in item.keywords for marker in ['''integration''', '''unit''']):
               continue
          item.add_marker(pytest.mark.unit)




def lowerCAmelCase						(__A):



     """simple docstring"""



     config.addinivalue_line('''markers'''						,			'''torchaudio_latest: mark test to run with torchaudio>=0.12''')




@pytest.fixture(autouse=__A)
def lowerCAmelCase						(__A						,			__A):



     """simple docstring"""



     _a											=						tmp_path_factory.getbasetemp() / '''cache'''
     _a											=						test_hf_cache_home / '''datasets'''
     _a											=						test_hf_cache_home / '''metrics'''
     _a											=						test_hf_cache_home / '''modules'''
     monkeypatch.setattr('''datasets.config.HF_DATASETS_CACHE'''						,			str(__A))
     monkeypatch.setattr('''datasets.config.HF_METRICS_CACHE'''						,			str(__A))
     monkeypatch.setattr('''datasets.config.HF_MODULES_CACHE'''						,			str(__A))
     _a											=						test_hf_datasets_cache / '''downloads'''
     monkeypatch.setattr('''datasets.config.DOWNLOADED_DATASETS_PATH'''						,			str(__A))
     _a											=						test_hf_datasets_cache / '''downloads''' / '''extracted'''
     monkeypatch.setattr('''datasets.config.EXTRACTED_DATASETS_PATH'''						,			str(__A))




@pytest.fixture(autouse=__A						,			scope='''session''')
def lowerCAmelCase						():



     """simple docstring"""



     datasets.disable_progress_bar()




@pytest.fixture(autouse=__A)
def lowerCAmelCase						(__A):



     """simple docstring"""



     monkeypatch.setattr('''datasets.config.HF_UPDATE_DOWNLOAD_COUNTS'''						,			__A)




@pytest.fixture
def lowerCAmelCase						(__A):



     """simple docstring"""



     monkeypatch.setattr('''sqlalchemy.util.deprecations.SILENCE_UBER_WARNING'''						,			__A)



