AS Q Neural Net Pure MQ L5 Neural Network Library

AS Q Neural Net Pure MQ L5 Neural Network Library
DOWNLOAD all MT5 librarys (393)
YouTube Video Thumbnail

Similar MetaTrader Tools

AS Q Neural Net Pure MQ L5 Neural Network Library

Info

The AS Q Neural Net Pure MQ L5 Neural Network Library is a Library for MetaTrader 5 that asq neuralnet is a complete neural network library written 100% in native mql5 — no dlls, no python bridge, no external dependencies. Build, train, and run inference with multi-layer neural networks directly inside MetaTrader 5.

Usage

This tool is typically used for enhancing chart analysis and decision making.

Platform

This Library works exclusively on MetaTrader 5 (both build 600+ and newer versions).

Setup

Place the downloaded file in MQL5/Libraries folder via File ? Open Data Folder in MetaTrader 5.


How to Install and Use AS Q Neural Net Pure MQ L5 Neural Network Library

1. Storage: Place library files in the MQL/Libraries directory to ensure they are accessible to your projects.

2. Implementation: Include the library in your code using the #import directive, ensuring you match the exact function names and parameters.

3. Compilation: Ensure the library is present in the directory before you compile your main EA or script, as the compiler links them during this phase.

4. Management: Keep libraries organized in sub-folders if you manage many custom functions to maintain a clean project structure.

Frequently Asked Questions

Q: What is a library file used for? A: Libraries store reusable code modules, allowing you to centralize common logic used by multiple EAs or indicators.

Q: Is a library executable? A: No, libraries are non-executable files containing functions; they must be imported into an EA, indicator, or script to function.

Q: Can I update a library while the platform is running? A: You should compile your EA or script after updating a library to ensure the latest code changes are integrated.

What this tool does

ASQ NeuralNet is a complete neural network library written 100% in native MQL5 — no DLLs, no Python bridge, no external dependencies.

Typical Use Case

This Library excels in automated trading and technical analysis on MetaTrader 5.

Compatible Platform & Setup

This Library works on MetaTrader 5. Place the file in the MQL5/Libraries folder and restart the terminal.

Description & Settings

Related: ML P Neural Network Class - another powerful library for MetaTrader 5 traders.


ASQ NeuralNet is a complete neural network library written 100% in native MQL5 — no DLLs, no Python bridge, no external dependencies. Build, train, and run inference with multi-layer neural networks directly inside MetaTrader 5.

Also recommended: RB F Neural Network Class - similar library with strong performance on MetaTrader 5.

WHAT YOU GET
A fully functional deep learning framework for MQL5 developers, including:
— Dense matrix algebra engine with 40+ operations (multiply, transpose, Hadamard, He/Xavier initialization, NaN detection) — 13 activation functions with analytical derivatives: ReLU, LeakyReLU, ELU, SELU, Sigmoid, Tanh, Softmax, Swish, Mish, GELU, Softplus, HardSigmoid, Linear — Dense layers with forward and backward propagation, dropout, and gradient clipping — 3 optimizers: SGD (with momentum), Adam, AdamW (decoupled weight decay) — 7 learning rate schedulers: Constant, Step Decay, Exponential, Cosine Annealing, Linear, ReduceOnPlateau, Warmup, Cyclic LR — 5 loss functions: MSE, MAE, Huber, Cross-Entropy, Binary Cross-Entropy — Full training pipeline with mini-batch SGD, Fisher-Yates shuffle, and epoch logging
QUICK START
Building a network takes 6 lines of code:
CNeuralNetwork net; net.Init(32); // 32 input features net.AddLayer(64, ACT_RELU); // Hidden layer 1 net.AddLayer(32, ACT_RELU, 0.2); // Hidden layer 2 + dropout net.AddLayer(3, ACT_SOFTMAX); // Output: BUY/SELL/HOLD net.Build();
Train with one call:
net.SetOptimizer(OPT_ADAM, 0.001); net.SetLoss(LOSS_CROSS_ENTROPY); net.Fit(trainX, trainY, 100, 32);
Predict with one call:
int action = net.PredictClass(features); // 0=BUY, 1=SELL, 2=HOLD
USE CASES
— Train classification models for trading signals (BUY/SELL/HOLD) — Price direction regression with MSE or Huber loss — Pattern recognition on candlestick formations — Market regime detection (trending / ranging / volatile) — Feature importance analysis — Q-value function approximation for reinforcement learning agents
PERFORMANCE
— Inference latency: < 0.1ms for typical architectures (under 1000 parameters) — Memory: proportional to total parameters (5KB for a 32→64→32→3 network) — No dynamic allocation during inference — Numerically stable: NaN detection, gradient clipping, safe Softmax with max-subtraction
INSTALLATION
Place the 5 library files in MQL5/Include/AlgoSphere/NeuralNet/ and include the main header:
#include <AlgoSphere/NeuralNet/NN_Network.mqh>
The demo script demonstrates matrix operations, activation functions, XOR classification, and synthetic market direction prediction.
LIBRARY FILES
— NN_Matrix.mqh (908 lines) — Dense matrix algebra engine — NN_Activations.mqh (300 lines) — 13 activations + derivatives — NN_Layer.mqh (374 lines) — Dense layer with forward/backward/dropout — NN_Optimizer.mqh (454 lines) — SGD/Adam/AdamW + 7 LR schedulers — NN_Network.mqh (734 lines) — Complete feedforward network with training — ASQ_NeuralNet_Demo.mq5 (283 lines) — 4 runnable demonstrations
Total: 3,053 lines of pure MQL5.
TECHNICAL NOTES
— Weight initialization: He Init for ReLU-family, Xavier for Sigmoid/Tanh — Box-Muller transform for normal distribution (MQL5 native MathRand) — Softmax + Cross-Entropy gradient shortcut (ŷ - y, avoids full Jacobian) — Inverted dropout (scaled during training, identity during inference) — Fisher-Yates shuffle for mini-batch training — Gradient norm clipping per layer (default max norm = 1.0)
Built by AlgoSphere Quant.
Tags / Keywords
neural network, deep learning, machine learning, AI, MQL5, library, matrix, backpropagation, Adam optimizer, classification, regression, trading signals, pure MQL5, no DLL, feedforward, activation functions, softmax, cross-entropy, dropout

You may also like: PN N Neural Network Class - excellent alternative for library users on MetaTrader 5.

Limitations & Risk Warning

  • This tool is provided for educational and testing purposes only.
  • Past performance does not guarantee future results.
  • Trading involves substantial risk of loss. Use on a demo account first.
  • Results may vary depending on market conditions, broker, and settings.
  • We recommend thorough backtesting and forward testing before using with real funds.
RobotFX does not own any of the code provided on this platform. All tools are freely available on the internet; we simply index and re-offer them for download. We are not responsible for any financial losses that may occur. Trading responsibilities rely solely on the traders downloading and using the displayed Expert Advisors, indicators, and scripts. These tools are provided for educational purposes only and may require modification or optimization to align with a trader's specific strategy or needs.
© ROBOTFX - Best MetaTrader Expert Advisors & Indicators