data_baseIOLoaderDumperreduced_lda_model

reduced_lda_model

Read and write a ReducedLdaModel.

During saving, the data undergoes the following changes:

  • Spike times and lda values are kept with an accuracy of \(.01\).

  • The index of the spike times is reset, i.e. the sim_trial_index is not kept.

  • The ReducedLdaModel attribute db_list, which normally contains DataBase instances, is replaced by a list of strings that only contain the unique_id of each database. This prevents unpickling errors in case the DataBase has been removed.

  • Older versions of reduced models do not have the attribute st. They are stored with an empty dataframe (Rm.st = pd.DataFrame()) to be compliant with the new version.

The output is a database with the following keys:

Database keys

Key

Description

st

Spike times with a precision of \(.01\).

lda_value_dicts_<index>

Dictionaries of LDA values with a precision of \(.01\).

Rm

The reduced model.

Classes

Loader

Loader for ReducedLdaModel objects

Functions

check(obj)

Check whether the object can be saved with this dumper

dump(obj, savedir)

Save the reduced model in the specified directory as a DataBase.