class_docstr: Bernoulli Restricted Boltzmann Machine (RBM)
  
  Parameters:
  -----------
  n_hidden: int:
      The number of processing nodes (neurons) in the hidden layer. 
  learning_rate: float
      The step length that will be used when updating the weights.
  batch_size: int
      The size of the mini-batch used to calculate each weight update.
  n_iterations: float
      The number of training iterations the algorithm will tune the weights for.
  
  Reference:
      A Practical Guide to Training Restricted Boltzmann Machines 
      URL: https://www.cs.toronto.edu/~hinton/absps/guideTR.pdf
class_docstr_tok: ["Bernoulli","Restricted","Boltzmann","Machine","(","RBM",")","Parameters",":","--","--","--","--","--","-","n_hidden",":","int",":","The","number","of","processing","nodes","(","neurons",")","in","the","hidden","layer",".","learning_rate",":","float","The","step","length","that","will","be","used","when","updating","the","weights",".","batch_size",":","int","The","size","of","the","mini-batch","used","to","calculate","each","weight","update",".","n_iterations",":","float","The","number","of","training","iterations","the","algorithm","will","tune","the","weights","for",".","Reference",":","A","Practical","Guide","to","Training","Restricted","Boltzmann","Machines","URL",":","https",":","\/\/www.cs.toronto.edu\/~hinton\/absps\/guideTR.pdf"]
code: def __init__(
      self,
      n_hidden=128,
      learning_rate=0.1,
      batch_size=10,
      n_iterations=100,
  ):
      self.n_iterations = n_iterations
      self.batch_size = batch_size
      self.lr = learning_rate
      self.n_hidden = n_hidden
      self.progressbar = progressbar.ProgressBar(widgets=bar_widgets)
  
file_path: ML-From-Scratch/mlfromscratch/unsupervised_learning/restricted_boltzmann_machine.py
imports: import logging
  import numpy
  import progressbar
  from mlfromscratch.utils.misc import bar_widgets
  from mlfromscratch.utils import batch_iterator
  from mlfromscratch.deep_learning.activation_functions import Sigmoid
label_desc: Use image node_id 1 to create a new RBM object  with example: obj = RBM(n_hidden, learning_rate, batch_size, n_iterations)