anchor.diff:                                  (* 20 (length *training-images*))))))
               :decay 0.001
               :visible-sampling t)
  -           (save-weights (merge-pathnames "mnist-2.dbn" *mnist-dir*)
  -                         *dbn/2*))
  +           (save-weights *mnist-2-dbn-filename* *dbn/2*))
            (train-dbm ()
              (train-mnist-dbm *dbm/2*)
  -           (save-weights (merge-pathnames "mnist-2.dbm" *mnist-dir*)
  -                         *dbm/2*)))
  +           (save-weights *mnist-2-dbm-filename* *dbm/2*)))
       (cond (load-dbm-p
              (setq *dbm/2* (make-mnist-dbm))
  -           (load-weights (merge-pathnames "mnist-2.dbm" *mnist-dir*) *dbm/2*))
  +           (load-weights *mnist-2-dbm-filename* *dbm/2*))
             (load-dbn-p
              (setq *dbm/2* (make-mnist-dbm))
              (setq *dbn/2* (make-mnist-dbn/2 *dbm/2*))
  -           (load-weights (merge-pathnames "mnist-2.dbn" *mnist-dir*) *dbn/2*)
  +           (load-weights *mnist-2-dbn-filename* *dbn/2*)
              (log-msg "Loaded DBN~%")
              (train-dbm))
             (t
  
positive.code: (defvar *dbn/1*)
  (defvar *bpn/1*)
  
  (defun train-mnist/1 (&key load-dbn-p)
    (unless (boundp '*training-images*)
      (setq *training-images* (load-training)))
  
negative.code:          (init-mnist-dbn *dbn/1* :stddev 0.1)
           (train-mnist-dbn *dbn/1* :n-epochs 50 :learning-rate 0.1
                            :decay 0.0002 :visible-sampling nil)
           (save-weights *mnist-1-dbn-filename* *dbn/1*)))
    (setq *bpn/1* (unroll-mnist-dbn/1 *dbn/1*))
    (train-mnist-bpn *bpn/1*)
    (save-weights *mnist-1-bpn-filename* *bpn/1*))
  
  
  