Skip to content

v0.1.1

Choose a tag to compare

@77axel 77axel released this 08 Aug 12:40
· 146 commits to main since this release
0d429ea

πŸ“¦ Release: v0.1.1 – Training Visualization Added

This update enhances PyCNN by adding real-time training visualization for accuracy and loss per epoch using Matplotlib β€” making it easier to monitor model performance while training.


πŸš€ Key Features

  • βœ… Fully functional CNN implementation from scratch
  • 🧠 Manual convolution, max pooling, and ReLU activations
  • πŸ” Forward and backward propagation with mini-batch gradient descent
  • 🏷 Multi-class classification via softmax and cross-entropy loss
  • πŸ’Ύ Model save/load using pickle
  • πŸ–Ό RGB image preprocessing with customizable filters
  • πŸ” Predict function to classify new unseen images
  • πŸ“Š New: Real-time training visualization (accuracy & loss per epoch) in train_model(visualize=True)

πŸ–ΌοΈ Preview


πŸ“Œ Installation

πŸ“¦ Install directly from GitHub:

pip install git+https://github.com/77AXEL/PyCNN.git@v0.1.1

πŸ§ͺ How to Use

🏁 Train the model with visualization:

from cnnfs.model import CNN

model = CNN()
model.init(
    image_size=32,
    batch_size=32,
    h1=128,
    h2=64,
    learning_rate=0.01,
    epochs=10,
    dataset_path="data",
    max_image=200
)
model.load_dataset()
model.train_model(visualize=True)  # <-- visualization enabled (Without this setting, the visualization won’t appear)
model.save_model()

πŸ” Predict an image:

model.load_model("model.bin")
result = model.predict("path/to/image.png")
print("Prediction:", result)

πŸ—‚ Included Filters

PyCNN uses a set of basic filters for feature extraction:

  • Sharpen
  • Vertical edges
  • Laplacian (high-pass)

🧾 Changelog

v0.1.1

  • New: Real-time training visualization (accuracy & loss per epoch) with Matplotlib.
  • Dark theme visualization with clear, color-coded curves.
  • Optional: Enable by calling train_model(visualize=True).

v0.1.0

  • Initial version with full training and prediction pipeline
  • Manual convolution + pooling + ReLU
  • Batch softmax + cross-entropy loss
  • Two hidden layers and output layer
  • Save/load model capability
  • Example dataset folder included
  • Beginner-friendly structure for learning how CNNs work

πŸ’¬ Feedback & Contributions

We welcome issues, suggestions, and contributions!
Join the conversation in the [[Discussions tab](https://github.com/77AXEL/PyCNN/discussions)]\([https://github.com/77AXEL/PyCNN/discussions](https://github.com/77AXEL/PyCNN/discussions)) or check the [[CONTRIBUTING.md](https://github.com/77AXEL/PyCNN/?tab=coc-ov-file)]\(./CONTRIBUTING.md) guide.


πŸ›‘ Security

Found a security issue? Please report it privately to:
πŸ“§ a.x.e.l777444000@gmail.com


πŸ“œ License

Released under the MIT License