code: def test_parse_with_anonymous_axes(self):
      for shape, pattern, expected in [
          ([1, 2, 3, 4], "1 2 3 a", dict(a=4)),
          ([10, 1, 2], "a 1 2", dict(a=10)),
          ([10, 1, 2], "a () 2", dict(a=10)),
      ]:
          x = numpy.ones(shape)
          parsed1 = parse_shape(x, pattern)
          parsed2 = parse_shape(self.backend.from_numpy(x), pattern)
          assert parsed1 == parsed2 == expected
  
imports: import sys
  import unittest
  from doctest import testmod
  from typing import Dict, List, Optional
  import numpy
  import pytest
  from parameterized import parameterized, parameterized_class
  import einops
  import einops.layers
  import einops.parsing
  from einops._backends import AbstractBackend
  from einops.einops import rearrange, parse_shape, _optimize_transformation
  from .None import collect_test_backends, is_backend_tested
label_desc: Use image node_id 8 for calling the TestParseShapeImperative obj's underlying member method code with example usage: obj.test_parse_with_anonymous_axes() without return types