code: def assertContainsResults(self, geom, x, y):
      from shapely.vectorized import contains
  
      result = contains(geom, x, y)
      x = np.asanyarray(x)
      y = np.asanyarray(y)
  
      self.assertIsInstance(result, np.ndarray)
      self.assertEqual(result.dtype, bool)
  
      result_flat = result.flat
      x_flat, y_flat = x.flat, y.flat
  
      # Do the equivalent operation, only slowly, comparing the result
      # as we go.
      for idx in range(x.size):
          assert result_flat[idx] == geom.contains(
              Point(x_flat[idx], y_flat[idx])
          )
      return result
  
file_path: shapely/shapely/tests/legacy/test_vectorized.py
imports: import unittest
  import numpy
  from shapely.geometry import box, MultiPolygon, Point
label_desc: Use image node_id 1 for calling the VectorizedContainsTestCase obj's underlying member method code with example usage: obj.assertContainsResults(geom, x, y) and returns: result