moving drawing to RBM class