Skip to content
Projects

yui0/catseye has 33 GitHub stars and 3 forks. Star changes are not measured yet. Last checked 2026-11-14 05:14 UTC. Last push 2026-11-13.

How these counts are measured

What you can do

  • Just include catseye.h and write your model in c. There is nothing to install.
  • Small dependency & simple implementation
  • OpenCL support (GPGPU)
  • OpenGL support (GPGPU)

Measured star growth

in 24h
Collecting history
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

About

Neural network library written in C and Javascript

Machine Learning

README.md

Original

Cat's Eye

Neural network library and applications in C.

日本語

Location Contents
catseye.h Shared neural-network library
catseye_llm.h Shared GGUF/LLM inference runtime
transcript/ Speech transcription CLI, speech/ONNX headers, model tools, Colab notebooks, fixtures and tests
plamo/ PLaMo 3 Translate translation CLI (0.8B, Q4/Q8 quantization)
llm/ Original LLM examples and GPU implementation
example/, super_resolution/, word2vec/ Neural-network examples
tools/ General library tools

Run make help for project commands. make test runs the library tests (test/: finite-difference gradient check of every layer type, batch-norm / augmentation / safetensors / quantization / GEMM checks, small end-to-end training runs). Build transcription with make -C transcript and run it from that directory so its default models/ path resolves there. Use make legacy for the original root training examples.

Features

  • Lightweight and minimalistic:
    • Header only
    • Just include catseye.h and write your model in c. There is nothing to install.
    • Small dependency & simple implementation
  • Fast: [under construction]
    • OpenCL support (GPGPU)
    • OpenGL support (GPGPU)
    • SSE, AVX support (But gcc and clang support SIMD...)
    • OpenMP support
    • Support half precision floats (16bit)
  • Supported networks:
    • Activation functions
      • sigmoid
      • softmax
      • tanh, scaled tanh (1.7519 * tanh(2/3x))
      • ReLU, Leaky ReLU, ELU, RReLU
      • abs
      • identity
    • Loss functions
      • cross-entropy, mean-squared-error
    • Optimization algorithms
      • SGD (stochastic gradient descent) with/without L2 normalization
      • Momentum SGD
      • AdaGrad
      • RMSProp
      • Adam
    • Layer types
      • linear (mlp)
      • convolution
      • convolution 1d
      • deconvolution
      • Sub-Pixel Convolution (Pixel Shuffler)
      • max pooling
      • average pooling
      • global average pooling (GAP)
      • batch normalization (per-channel statistics over the batch; running mean/variance, gamma and beta are stored in the weights and used by CatsEye_forward() / CatsEye_predict())
      • concat
      • shortcut
  • Loader formats:

Learning rate and batch size

Every layer (dense, convolution, deconvolution, batch normalization) accumulates the mean gradient over the batch, and the bias is updated by the optimizer together with the weights. The learning rate eta therefore means the same thing in every layer. (Earlier versions averaged only in convolution layers; to keep an old setup, multiply eta of its dense/deconvolution layers by the batch size.)

Usage

Just include header files in your project.

for more information, see example/

$ dnf install ghostscript ocl-icd-devel
$ cd example
$ make
$ ./sin

Demo

Open In Colab

Question

  • Neural Network Always Produces Same/Similar Outputs for Any Input
    • Scale down the problem to manageable size.
    • Make sure you have enough hidden units.
    • Change the activation function and its parameters.
    • Change learning algorithm parameters.

Refrences

Explore related projects