def __init__(self, num_dims=None, k=None, embedding_type='weighted',
               preprocessor=None):
    '''
    Initialize LFDA.

    Parameters
    ----------
    num_dims : int, optional
        Dimensionality of reduced space (defaults to dimension of X)

    k : int, optional
        Number of nearest neighbors used in local scaling method.
        Defaults to min(7, num_dims - 1).

    embedding_type : str, optional
        Type of metric in the embedding space (default: 'weighted')
          'weighted'        - weighted eigenvectors
          'orthonormalized' - orthonormalized
          'plain'           - raw eigenvectors

    preprocessor : array-like, shape=(n_samples, n_features) or callable
        The preprocessor to call to get tuples from indices. If array-like,
        tuples will be formed like this: X[indices].
    '''
    if embedding_type not in ('weighted', 'orthonormalized', 'plain'):
      raise ValueError('Invalid embedding_type: %r' % embedding_type)
    self.num_dims = num_dims
    self.embedding_type = embedding_type
    self.k = k
    super(LFDA, self).__init__(preprocessor)
def __init__ ( self , num_dims = None , k = None , embedding_type = 'weighted' , preprocessor = None ) : if embedding_type not in ( 'weighted' , 'orthonormalized' , 'plain' ) : raise ValueError ( 'Invalid embedding_type: %r' % embedding_type ) self . num_dims = num_dims self . embedding_type = embedding_type self . k = k super ( LFDA , self ) . __init__ ( preprocessor )
Initialize LFDA.

    Parameters
    ----------
    num_dims : int, optional
        Dimensionality of reduced space (defaults to dimension of X)

    k : int, optional
        Number of nearest neighbors used in local scaling method.
        Defaults to min(7, num_dims - 1).

    embedding_type : str, optional
        Type of metric in the embedding space (default: 'weighted')
          'weighted'        - weighted eigenvectors
          'orthonormalized' - orthonormalized
          'plain'           - raw eigenvectors

    preprocessor : array-like, shape=(n_samples, n_features) or callable
        The preprocessor to call to get tuples from indices. If array-like,
        tuples will be formed like this: X[indices].