code: def _check_shapes(
      shapes,
      n_components=None,
      atlas_shape=None,
      ignore_nsubjects=False,
  ):
      """Check that number of voxels is the same for each subjects. Number of
      timeframes can vary between sessions but must be consistent across
      subjects
  
      Parameters
      ----------
      shapes : array of shape (n_subjects, n_sessions, 2)
          Array of shapes of input images
      """
      n_subjects, n_sessions, _ = shapes.shape
  
      if n_subjects <= 1 and not ignore_nsubjects:
          raise ValueError(
              "The number of subjects should be greater than 1"
          )
  
      n_timeframes_list = [None] * n_sessions
      n_voxels = None
      for n in range(n_subjects):
          for m in range(n_sessions):
              if n_timeframes_list[m] is None:
                  n_timeframes_list[m] = shapes[n, m, 1]
  
              if n_voxels is None:
                  n_voxels = shapes[m, n, 0]
  
              if n_timeframes_list[m] != shapes[n, m, 1]:
                  raise ValueError(
                      "Subject %i Session %i does not have the "
                      "same number of timeframes "
                      "as Subject %i Session %i" % (n, m, 0, m)
                  )
  
              if n_voxels != shapes[n, m, 0]:
                  raise ValueError(
                      "Subject %i Session %i"
                      " does not have the same number of voxels as "
                      "Subject %i Session %i." % (n, m, 0, 0)
                  )
  
      _check_shapes_atlas_compatibility(
          n_voxels, np.sum(n_timeframes_list), n_components, atlas_shape
      )
  
imports: import hashlib
  import logging
  import os
  import numpy
  import scipy
  from joblib import Parallel, delayed
  from brainiak.funcalign.srm import DetSRM
  from sklearn.base import BaseEstimator, TransformerMixin
  from sklearn.exceptions import NotFittedError
  import uuid
label_desc: Use image node_id 13 for calling a global function with example usage: _check_shapes(shapes, n_components, atlas_shape, ignore_nsubjects) without return types