code: def test_ngrams(sequence, n, expected_keys, expected_values):
      ngrams_counter = ngrams(sequence=sequence, n=n)
      assert list(ngrams_counter.values()) == expected_values
      assert list(ngrams_counter.keys()) == expected_keys
  
imports: import pytest
  from ignite.metrics.nlp.utils import lcs, modified_precision, ngrams
label_desc: Use image node_id 1 for calling a global function with example usage: test_ngrams(sequence, n, expected_keys, expected_values) without return types