LightNet: Efficient Pascal AI Neural Network Library

GitHub Stats Value
Stars 50
Forks 7
Language Pascal
Created 2024-05-04
License MIT License

LightNet is an artificial intelligence neural network library implemented in pure Pascal, drawing inspiration from Darknet and YOLOv7. This library allows for the native and self-dependent execution of most Darknet models, including YOLO, without the need for external libraries. Currently, it supports training and inference on CPU, with inference speeds that often outperform optimized C CPU implementations. Optional integration with libopenblas or Intel’s Math Kernel Library can further optimize CPU performance. While it is currently under development for OpenCL, CUDA, and testing on other platforms like MacOS, Linux, and single-board computers, LightNet is already a promising tool worth exploring for AI enthusiasts and developers.

LightNet is an artificial intelligence neural network library implemented in pure Pascal, inspired by Darknet and YOLOv7. It can run most Darknet models, including YOLO, natively and self-dependently without external libraries. Currently, it supports training and inference on CPU, with inference performance comparable to or even faster than optimized C CPU implementations. Optional use of libopenblas or Intel’s Math Kernel Library can further optimize CPU performance. The project includes tests for both Lazarus and Delphi and supports various .weights models. Future work includes OpenCL and CUDA implementation, testing on other platforms, and single board computers.

LightNet, an artificial intelligence neural network library implemented in pure Pascal, offers several practical uses:

  • Object Detection: Users can leverage LightNet to run YOLOv7 and other Darknet models for object detection tasks, such as identifying objects in images or videos, without the need for external libraries.
  • CPU Optimization: Although currently running on CPU, LightNet’s inference is noted to be faster than optimized C CPU implementations. Users can further optimize performance using libopenblas or Intel’s Math Kernel Library.
  • Cross-Platform Testing: Developers can test the library on various platforms, including Windows, with plans to expand to MacOS, Linux, and single-board computers like NVIDIA Jetson and Raspberry Pi.
  • Model Compatibility: The library supports multiple .weights models; users need to ensure the corresponding configuration files are in the “cfg” folder.

To benefit from the repository:

  • Ensure the necessary weights files (e.g., yolov7.weights) are placed next to the executable.
  • Use the provided tests for both Lazarus and Delphi to get started.
  • Contribute or donate to support the development of additional features like OpenCL and CUDA implementations.

This project is still in its early stages, but it offers a promising self-dependent solution for neural network tasks in Pascal.

LightNet is an AI neural network library implemented in pure Pascal, inspired by Darknet and YOLOv7. It can run most Darknet models, including YOLO, without external libraries. Key points include:

  • Inference runs faster than optimized C CPU implementations.
  • Optional use of OpenBLAS or Intel’s Math Kernel Library for further CPU optimization.
  • Pending work includes OpenCL and CUDA implementation, testing on MacOS, Linux, and single board computers.
  • Currently in an early stage with ongoing development needs.

For further insights and to explore the project further, check out the original hshatti/LightNet repository.

Content derived from the hshatti/LightNet repository on GitHub. Original materials are licensed under their respective terms.