# pydbm.dbm.deepboltzmannmachine package¶

## pydbm.dbm.deepboltzmannmachine.shape_boltzmann_machine module¶

class pydbm.dbm.deepboltzmannmachine.shape_boltzmann_machine.ShapeBoltzmannMachine

Shape Boltzmann Machine(Shape-BM).

The concept of Shape Boltzmann Machine (Eslami, S. A., et al. 2014) provided inspiration to this library.

The usecases of Shape-BM are image segmentation, object detection, inpainting and graphics. Shape-BM is the model for the task of modeling binary shape images, in that samples from the model look realistic and it can generalize to generate samples that differ from training examples.

References

• Eslami, S. A., Heess, N., Williams, C. K., & Winn, J. (2014). The shape boltzmann machine: a strong model of object shape. International Journal of Computer Vision, 107(2), 155-176.
get_visible_points_arr

getter

learn

Learning.

Parameters: observed_data_arr – The np.ndarray of observed data points. training_count – Training counts. batch_size – Batch size in learning. r_batch_size – Batch size in inferencing. If this value is 0, the inferencing is a recursive learning. If this value is more than 0, the inferencing is a mini-batch recursive learning. If this value is ‘-1’, the inferencing is not a recursive learning. If you do not want to execute the mini-batch training, the value of batch_size must be -1. And r_batch_size is also parameter to control the mini-batch training but is refered only in inference and reconstruction. If this value is more than 0, the inferencing is a kind of reccursive learning with the mini-batch training.
set_readonly

setter

visible_points_arr

getter

## pydbm.dbm.deepboltzmannmachine.stacked_auto_encoder module¶

class pydbm.dbm.deepboltzmannmachine.stacked_auto_encoder.StackedAutoEncoder

Stacked Auto-Encoder.

DBM is functionally equivalent to a Stacked Auto-Encoder, which is-a neural network that tries to reconstruct its input. To encode the observed data points, the function of DBM is as linear transformation of feature map. On the other hand, to decode this feature points, the function of DBM is as linear transformation of feature map.

The reconstruction error should be calculated in relation to problem setting. This library provides a default method, which can be overridden, for error function that computes Mean Squared Error(MSE).

References

• https://github.com/chimera0/accel-brain-code/blob/master/Deep-Learning-by-means-of-Design-Pattern/demo/demo_stacked_auto_encoder.ipynb
• Ackley, D. H., Hinton, G. E., & Sejnowski, T. J. (1985). A learning algorithm for Boltzmann machines. Cognitive science, 9(1), 147-169.
• Hinton, G. E. (2002). Training products of experts by minimizing contrastive divergence. Neural computation, 14(8), 1771-1800.
• Le Roux, N., & Bengio, Y. (2008). Representational power of restricted Boltzmann machines and deep belief networks. Neural computation, 20(6), 1631-1649.
• Salakhutdinov, R., & Hinton, G. E. (2009). Deep boltzmann machines. InInternational conference on artificial intelligence and statistics (pp. 448-455).
feature_points_arr

getter

get_feature_points_arr

getter

get_visible_points_arr

getter

learn

Learning and auto-saving featrue points with np.ndarray.

Parameters: observed_data_arr – The np.ndarray of observed data points. training_count – Training counts. batch_size – Batch size. r_batch_size – Batch size. If this value is 0, the inferencing is a recursive learning. If this value is more than 0, the inferencing is a mini-batch recursive learning. If this value is ‘-1’, the inferencing is not a recursive learning.
set_readonly

setter

visible_points_arr

getter