deep_bottleneck.callbacks package

Submodules

deep_bottleneck.callbacks.activityprojector module

class deep_bottleneck.callbacks.activityprojector.ActivityProjector(train, test, log_dir='./logs', embeddings_freq=10)[source]

Bases: sphinx.ext.autodoc.importer._MockObject

Read activity from layers of a Keras model and log is for TensorBoard

This callback reads activity from the hidden layers of a Keras model and logs it as Model Checkpoint files. The network activity patterns can then be explored in TensorBoard with its Embeddings Projector

on_epoch_end(epoch, logs=None)[source]

Write layer activations to file :param epoch: Number of the current epoch :param logs: Quantities such as acc, loss which are passed by Sequential.fit()

Returns:None
on_train_end(logs=None)[source]

Close files :param logs: Quantities such as acc, loss which are passed by Sequential.fit()

Returns:None
set_model(model)[source]

Prepare for logging the activities of the layers and set up the TensorBoard projector :param model: The Keras model

Returns:None

deep_bottleneck.callbacks.earlystopping_manual module

class deep_bottleneck.callbacks.earlystopping_manual.EarlyStoppingAtSpecificAccuracy(monitor, value)[source]

Bases: sphinx.ext.autodoc.importer._MockObject

classmethod load(monitor='val_acc', value=0.94)[source]
on_epoch_end(epoch, logs)[source]
deep_bottleneck.callbacks.earlystopping_manual.load(monitor='val_acc', value=0.94)[source]

deep_bottleneck.callbacks.loggingreporter module

class deep_bottleneck.callbacks.loggingreporter.LoggingReporter(trn, tst, calculate_mi_for, batch_size, activation_fn, file_all_activations, do_save_func=None, *args, **kwargs)[source]

Bases: sphinx.ext.autodoc.importer._MockObject

on_batch_begin(batch, logs={})[source]
on_epoch_begin(epoch, logs={})[source]
on_epoch_end(epoch, logs={})[source]
on_train_begin(logs={})[source]

deep_bottleneck.callbacks.metrics_logger module

class deep_bottleneck.callbacks.metrics_logger.MetricsLogger(run)[source]

Bases: sphinx.ext.autodoc.importer._MockObject

Callback to log loss and accuracy to sacred database.

on_epoch_end(epoch, logs=None)[source]

Module contents