DocumentationClassesLocallyLinearEmbedding

Class: LocallyLinearEmbedding

Locally Linear Embedding.

Read more in the User Guide.

Python Reference

Constructors

new LocallyLinearEmbedding()

new LocallyLinearEmbedding(opts?): LocallyLinearEmbedding

Parameters

ParameterTypeDescription
opts?object-
opts.eigen_solver?"auto" | "arpack" | "dense"The solver used to compute the eigenvectors. The available options are:
opts.hessian_tol?numberTolerance for Hessian eigenmapping method. Only used if method \== 'hessian'.
opts.max_iter?numberMaximum number of iterations for the arpack solver. Not used if eigen_solver==’dense’.
opts.method?"standard" | "hessian" | "modified" | "ltsa"standard: use the standard locally linear embedding algorithm. see reference [1]
opts.modified_tol?numberTolerance for modified LLE method. Only used if method \== 'modified'.
opts.n_components?numberNumber of coordinates for the manifold.
opts.n_jobs?numberThe number of parallel jobs to run. undefined means 1 unless in a joblib.parallel_backend context. \-1 means using all processors. See Glossary for more details.
opts.n_neighbors?numberNumber of neighbors to consider for each point.
opts.neighbors_algorithm?"auto" | "ball_tree" | "kd_tree" | "brute"Algorithm to use for nearest neighbors search, passed to NearestNeighbors instance.
opts.random_state?numberDetermines the random number generator when eigen_solver == ‘arpack’. Pass an int for reproducible results across multiple function calls. See Glossary.
opts.reg?numberRegularization constant, multiplies the trace of the local covariance matrix of the distances.
opts.tol?numberTolerance for ‘arpack’ method Not used if eigen_solver==’dense’.

Returns LocallyLinearEmbedding

Defined in generated/manifold/LocallyLinearEmbedding.ts:23

Properties

PropertyTypeDefault valueDefined in
_isDisposedbooleanfalsegenerated/manifold/LocallyLinearEmbedding.ts:21
_isInitializedbooleanfalsegenerated/manifold/LocallyLinearEmbedding.ts:20
_pyPythonBridgeundefinedgenerated/manifold/LocallyLinearEmbedding.ts:19
idstringundefinedgenerated/manifold/LocallyLinearEmbedding.ts:16
optsanyundefinedgenerated/manifold/LocallyLinearEmbedding.ts:17

Accessors

embedding_

Get Signature

get embedding_(): Promise<ArrayLike>

Stores the embedding vectors

Returns Promise<ArrayLike>

Defined in generated/manifold/LocallyLinearEmbedding.ts:411


feature_names_in_

Get Signature

get feature_names_in_(): Promise<ArrayLike>

Names of features seen during fit. Defined only when X has feature names that are all strings.

Returns Promise<ArrayLike>

Defined in generated/manifold/LocallyLinearEmbedding.ts:492


n_features_in_

Get Signature

get n_features_in_(): Promise<number>

Number of features seen during fit.

Returns Promise<number>

Defined in generated/manifold/LocallyLinearEmbedding.ts:465


nbrs_

Get Signature

get nbrs_(): Promise<any>

Stores nearest neighbors instance, including BallTree or KDtree if applicable.

Returns Promise<any>

Defined in generated/manifold/LocallyLinearEmbedding.ts:519


py

Get Signature

get py(): PythonBridge

Returns PythonBridge

Set Signature

set py(pythonBridge): void

Parameters

ParameterType
pythonBridgePythonBridge

Returns void

Defined in generated/manifold/LocallyLinearEmbedding.ts:108


reconstruction_error_

Get Signature

get reconstruction_error_(): Promise<number>

Reconstruction error associated with embedding_

Returns Promise<number>

Defined in generated/manifold/LocallyLinearEmbedding.ts:438

Methods

dispose()

dispose(): Promise<void>

Disposes of the underlying Python resources.

Once dispose() is called, the instance is no longer usable.

Returns Promise<void>

Defined in generated/manifold/LocallyLinearEmbedding.ts:164


fit()

fit(opts): Promise<any>

Compute the embedding vectors for data X.

Parameters

ParameterTypeDescription
optsobject-
opts.X?ArrayLike[]Training set.
opts.y?anyNot used, present here for API consistency by convention.

Returns Promise<any>

Defined in generated/manifold/LocallyLinearEmbedding.ts:181


fit_transform()

fit_transform(opts): Promise<ArrayLike>

Compute the embedding vectors for data X and transform X.

Parameters

ParameterTypeDescription
optsobject-
opts.X?ArrayLike[]Training set.
opts.y?anyNot used, present here for API consistency by convention.

Returns Promise<ArrayLike>

Defined in generated/manifold/LocallyLinearEmbedding.ts:220


get_feature_names_out()

get_feature_names_out(opts): Promise<any>

Get output feature names for transformation.

The feature names out will prefixed by the lowercased class name. For example, if the transformer outputs 3 features, then the feature names out are: \["class_name0", "class_name1", "class_name2"\].

Parameters

ParameterTypeDescription
optsobject-
opts.input_features?anyOnly used to validate feature names with the names seen in fit.

Returns Promise<any>

Defined in generated/manifold/LocallyLinearEmbedding.ts:263


get_metadata_routing()

get_metadata_routing(opts): Promise<any>

Get metadata routing of this object.

Please check User Guide on how the routing mechanism works.

Parameters

ParameterTypeDescription
optsobject-
opts.routing?anyA MetadataRequest encapsulating routing information.

Returns Promise<any>

Defined in generated/manifold/LocallyLinearEmbedding.ts:301


init()

init(py): Promise<void>

Initializes the underlying Python resources.

This instance is not usable until the Promise returned by init() resolves.

Parameters

ParameterType
pyPythonBridge

Returns Promise<void>

Defined in generated/manifold/LocallyLinearEmbedding.ts:121


set_output()

set_output(opts): Promise<any>

Set output container.

See Introducing the set_output API for an example on how to use the API.

Parameters

ParameterTypeDescription
optsobject-
opts.transform?"default" | "pandas" | "polars"Configure output of transform and fit_transform.

Returns Promise<any>

Defined in generated/manifold/LocallyLinearEmbedding.ts:339


transform()

transform(opts): Promise<ArrayLike[]>

Transform new points into embedding space.

Parameters

ParameterTypeDescription
optsobject-
opts.X?ArrayLike[]Training set.

Returns Promise<ArrayLike[]>

Defined in generated/manifold/LocallyLinearEmbedding.ts:375

Last updated on