qikify Package

qikify Package

helpers Module

qikify.helpers.bool2symmetric(data)[source]

Changes True/False data to +1/-1 symmetric.

qikify.helpers.computeR2(yhat, y)[source]

Computes R-squared coefficient of determination.

R2 = 1 - sum((y_hat - y_test)**2) / sum((y_test - np.mean(y_test))**2)
Parameters :

yhat : 1d array or list of floats – estimated values of y

y : 1d array or list of floats – true values

Examples

r2 = computeR2(yhat, y)

qikify.helpers.create_logger(logmodule)[source]
qikify.helpers.getParetoFront(data)[source]

Extracts the 2D Pareto-optimal front from a 2D numpy array.

Parameters :

data : numpy ndarray, or pandas.DataFrame

Data for which we want pareto-optimal front.

Examples

p = getParetoFront(data)

qikify.helpers.is1D(data)[source]

Determine if data is 1-dimensional.

qikify.helpers.nmse(yhat, y, min_y=None, max_y=None)[source]

Calculates the normalized mean-squared error.

Parameters :

yhat : 1d array or list of floats

estimated values of y

y : 1d array or list of floats

true values

min_y, max_y : float, float

roughly the min and max; they do not have to be the perfect values of min and max, because they’re just here to scale the output into a roughly [0,1] range

Examples

nmse = nmse(yhat, y)

qikify.helpers.partition(data, threshold=0.5, verbose=False)[source]

Partitions data into training and test sets. Assumes the last column of data is y.

Parameters :

data : numpy ndarray, or pandas.DataFrame

Data to partition into training and test sets.

threshold : float

Determines ratio of training : test.

Examples

TODO

qikify.helpers.standardize(X, scaleDict=None, reverse=False)[source]

Facilitates standardizing data by subtracting the mean and dividing by the standard deviation. Set reverse to True to perform the inverse operation.

Parameters :

X : numpy ndarray, or pandas.DataFrame

Data for which we want pareto-optimal front.

scaleDict: dict, default None :

Dictionary with elements mean/std to control standardization.

reverse: boolean, default False :

If this flag is set, the standardization will be reversed; e.g., we take a dataset with zero mean and unit variance and change to dataset with mean=scaleDict.mean and std=scaleDict.std.

Examples

TODO

qikify.helpers.zeroMatrixDiagonal(X)[source]

Set the diagonal of a matrix to all zeros.

Parameters :

X : numpy ndarray

Matrix on which to zero out the diagonal.

Examples

Xp = zeroMatrixDiagonal(X)

term_helpers Module

class qikify.term_helpers.colors[source]

Bases: object

Methods

disable()
disable()[source]
qikify.term_helpers.outputPassFail(gnd)[source]

Table Of Contents

Previous topic

Welcome to qikify’s documentation!

This Page