Commit Graph
9 Commits
Author SHA1 Message Date
jensandClaude Sonnet 4.6 37c6e33948 [CheckpointStatus] - add checkpoint status handler; Model.train() accepts status param
status.py: add CheckpointStatus(save_fn, update_interval) — prints progress
and calls save_fn at every report interval to persist model state mid-training.
model.py: Model.train() now accepts an optional Status instance; defaults to
plain Status() if none provided.
test_faces_sub_image.py: use CheckpointStatus(model.save) during training.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 22:42:01 +02:00
jensandClaude Sonnet 4.6 2f9fe1b66b [bugfix] - support large CPU-side datasets; fix numpy/CuPy interop
train.py: add _to_gpu() helper; convert mini-batches from CPU numpy to GPU
CuPy on the fly so large datasets can stay in RAM. Use numpy permutation for
numpy batches during shuffle. Limit status err_rms to first 5000 samples to
avoid GPU OOM on status checks.

model.py: replace np.copy() with np.array() — cupy.copy() does not convert
numpy arrays to CuPy; cupy.array() does. Fixes entity.forward() crash after
training when batch was passed as numpy.

test_faces_sub_image.py: load_patches normalizes on CPU and returns numpy,
avoiding multi-copy GPU OOM for large datasets (500 images ≈ 1.4 GB).
show_reconstructions converts numpy patches to CuPy before inference.
Add --n_images CLI arg.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 22:26:06 +02:00
jens ec5d259ff7 Entity: added property enable training 2026-01-06 09:44:29 +01:00
jens 2e714685d1 model: forward() is not abstract method 2026-01-02 19:42:22 +01:00
jens 10691894d1 - training params are (again) attrubute of Entity
- ditched layout concept
2026-01-02 14:51:19 +01:00
jens dc998d30a2 - initroduced types: BB-RBM GB-RBM, GG-RBM as property of entity
- training simplification and for clarity: added specialized cd_funcs for each entity type
2026-01-01 12:05:39 +01:00
jens 38b834c640 - added training params as list for model.train()
- added gaussian sample
- introduced layout concept
- updated README
2025-12-31 16:13:59 +01:00
jens 4bd5cffd6b - state load/save revised
- num gibbs samples is also part of entity
- working 3-layer deep test model
2025-12-21 17:34:11 +01:00
jens 22d189cf2f added model 2025-12-21 16:39:53 +01:00