ddl.utils.make_interior

ddl.utils.make_interior(X, bounds, eps=None)[source]

Scale/shift data to fit in the open interval given by bounds.

Parameters:
X : array-like, shape (n_samples, n_features)

Data matrix.

bounds : array-like, shape (2,)

Minimum and maximum of bounds.

eps : float, optional

Epsilon for clipping, defaults to np.info(X.dtype).eps

Returns:
X : array, shape (n_samples, n_features)

Data matrix after possible modification.