Image

The documentation of the image module.

The pyts.image module includes imaging algorithms.

class pyts.image.GASF(image_size=32, overlapping=False, scale=-1)[source]

Gramian Angular Summation Field.

Parameters:
image_size : int (default = 32)

Determine the shape of the output images: (image_size, image_size)

overlapping : bool (default = False)

If True, reduce the size of each time series using PAA with possible overlapping windows.

scale : {-1, 0} (default = -1)

The lower bound of the scaled time series.

Methods

fit([X, y]) Pass.
fit_transform(X[, y]) Fit to data, then transform it.
get_params([deep]) Get parameters for this estimator.
set_params(**params) Set the parameters of this estimator.
transform(X) Transform each time series into a GASF image.
fit(X=None, y=None)[source]

Pass.

Parameters:
X

Ignored

y

Ignored

transform(X)[source]

Transform each time series into a GASF image.

Parameters:
X : array-like, shape = [n_samples, n_features]
Returns:
X_new : array-like, shape = [n_samples, image_size, image_size]

Transformed data.

class pyts.image.GADF(image_size=32, overlapping=False, scale=-1)[source]

Gramian Angular Difference Field.

Parameters:
image_size : int (default = 32)

Determine the shape of the output images: (image_size, image_size)

overlapping : bool (default = False)

If True, reducing the size of the time series with PAA is done with possible overlapping windows.

scale : {-1, 0} (default = -1)

The lower bound of the scaled time series.

Methods

fit([X, y]) Pass.
fit_transform(X[, y]) Fit to data, then transform it.
get_params([deep]) Get parameters for this estimator.
set_params(**params) Set the parameters of this estimator.
transform(X) Transform each time series into a GADF image.
fit(X=None, y=None)[source]

Pass.

Parameters:
X

Ignored

y

Ignored

transform(X)[source]

Transform each time series into a GADF image.

Parameters:
X : array-like, shape = [n_samples, n_features]
Returns:
X_new : array-like, shape = [n_samples, image_size, image_size]

Transformed data.

class pyts.image.MTF(image_size=32, n_bins=4, quantiles=u'empirical', overlapping=False)[source]

Markov Transition Field.

Parameters:
image_size : int (default = 32)

Determine the shape of the output images: (image_size, image_size)

n_bins : int (default = 4)

Number of bins (also known as the size of the alphabet)

quantiles : {‘gaussian’, ‘empirical’} (default = ‘gaussian’)

The way to compute quantiles. If ‘gaussian’, quantiles from a gaussian distribution N(0,1) are used. If ‘empirical’, empirical quantiles are used.

overlapping : bool (default = False)

If False, reducing the image with the blurring kernel will be applied on non-overlapping rectangles. If True, it will be applied on eventually overlapping squares.

Methods

fit([X, y]) Pass.
fit_transform(X[, y]) Fit to data, then transform it.
get_params([deep]) Get parameters for this estimator.
set_params(**params) Set the parameters of this estimator.
transform(X) Transform each time series into a MTF image.
fit(X=None, y=None)[source]

Pass.

Parameters:
X

Ignored

y

Ignored

transform(X)[source]

Transform each time series into a MTF image.

Parameters:
X : array-like, shape = [n_samples, n_features]
Returns:
X_new : array-like, shape = [n_samples, image_size, image_size]

Transformed data.

class pyts.image.RecurrencePlots(dimension=1, epsilon=None, percentage=10)[source]

Recurrence Plots.

Parameters:
dimension : int (default = 1)

Dimension of the trajectory.

epsilon : float, ‘percentage_points’, ‘percentage_distance’ or None
(default = None)

Threshold for the minimum distance.

percentage : float (default = 10)

Percentage of black points if epsilon='percentage_points' or percentage of maximum distance for threshold if epsilon='percentage_distance'.

Methods

fit([X, y]) Pass.
fit_transform(X[, y]) Fit to data, then transform it.
get_params([deep]) Get parameters for this estimator.
set_params(**params) Set the parameters of this estimator.
transform(X) Transform each time series into a recurrence plot.
fit(X=None, y=None)[source]

Pass.

Parameters:
X

Ignored

y

Ignored

transform(X)[source]

Transform each time series into a recurrence plot.

Parameters:
X : array-like, shape = [n_samples, n_features]
Returns:
X_new : array-like, shape = [n_samples, n_features-dimension+1,

n_features-dimension+1]

Transformed data.