class_docstr: Class for a product of manifolds M_1 x ... x M_n.
  
  In contrast to the classes NFoldManifold, Landmarks, or DiscretizedCurves,
  the manifolds M_1, ..., M_n need not be the same, nor of
  same dimension, but the list of manifolds needs to be provided.
  
  Parameters
  ----------
  factors : list
      List of manifolds in the product.
  default_point_type : {'auto', 'vector', 'matrix', 'other'}
      Optional. Default value is 'auto', which will implement as 'vector' unless all
      factors have the same shape. Vector representation gives the point as a 1-d
      array. Matrix representation allows for a point to be represented by an array of
      shape (n, dim), if each manifold has default_point_type 'vector' with shape
      (dim,). 'other' will behave as `matrix` but for higher dimensions.
class_docstr_tok: ["Class","for","a","product","of","manifolds","M_1","x","...","x","M_n",".","In","contrast","to","the","classes","NFoldManifold",",","Landmarks",",","or","DiscretizedCurves",",","the","manifolds","M_1",",","...",",","M_n","need","not","be","the","same",",","nor","of","same","dimension",",","but","the","list","of","manifolds","needs","to","be","provided",".","Parameters","--","--","--","--","--","factors",":","list","List","of","manifolds","in","the","product",".","default_point_type",":","{","'auto","'",",","'vector","'",",","'matrix","'",",","'other","'","}","Optional",".","Default","value","is","'auto","'",",","which","will","implement","as","'vector","'","unless","all","factors","have","the","same","shape",".","Vector","representation","gives","the","point","as","a","1-d","array",".","Matrix","representation","allows","for","a","point","to","be","represented","by","an","array","of","shape","(","n",",","dim",")",",","if","each","manifold","has","default_point_type","'vector","'","with","shape","(","dim",",",")",".","'other","'","will","behave","as","`","matrix","`","but","for","higher","dimensions","."]
code: def __init__(self, factors, default_point_type="auto", equip=True):
      geomstats.errors.check_parameter_accepted_values(
          default_point_type,
          "default_point_type",
          ["auto", "vector", "matrix", "other"],
      )
  
      factors = tuple(factors)
  
      factor_dims = [factor.dim for factor in factors]
      factor_default_coords_types = [
          factor.default_coords_type for factor in factors
      ]
  
      dim = sum(factor_dims)
  
      shape = _find_product_shape(factors, default_point_type)
  
      if "extrinsic" in factor_default_coords_types:
          default_coords_type = "extrinsic"
      else:
          default_coords_type = "intrinsic"
  
      if default_coords_type == "extrinsic":
          factor_embedding_spaces = [
              manifold.embedding_space
              if hasattr(manifold, "embedding_space")
              else manifold
              for manifold in factors
          ]
          # TODO: need to revisit due to removal of scales
          self.embedding_space = ProductManifold(
              factor_embedding_spaces, default_point_type, equip=False
          )
  
      cum_index = (
          gs.cumsum(factor_dims)[:-1]
          if default_coords_type == "intrinsic"
          else self.embedding_space._cum_index
      )
  
      super().__init__(
          factors=factors,
          cum_index=cum_index,
          pool_outputs=True,
          has_mixed_fields=_has_mixed_fields(factors),
          dim=dim,
          shape=shape,
          default_coords_type=default_coords_type,
          equip=equip,
      )
  
imports: import math
  import geomstats.backend
  import geomstats.errors
  from geomstats.geometry.complex_manifold import ComplexManifold
  from geomstats.geometry.complex_riemannian_metric import ComplexRiemannianMetric
  from geomstats.geometry.manifold import Manifold
  from geomstats.geometry.riemannian_metric import RiemannianMetric
  from geomstats.vectorization import get_batch_shape
label_desc: Use image node_id 1 to create a new ProductManifold object from inherited base classes: _IterateOverFactorsMixins, Manifold with example: obj = ProductManifold(factors, default_point_type, equip)