io-chess
UCI chess engine
Loading...
Searching...
No Matches
feature_api.cpp File Reference

WebAssembly API for feature extraction. More...

#include "FactorizedFeatureExtractor.hpp"
#include "FeatureExtractor.hpp"
#include "chess.hpp"
#include <cstddef>
#include <cstdint>
#include "ExpertRouter.hpp"
Include dependency graph for feature_api.cpp:

Functions

int extract_features (const char *fen)
std::uintptr_t get_feature_layers_ptr ()
std::uintptr_t get_feature_globals_ptr ()
int get_feature_layers_len ()
int get_feature_globals_len ()
std::uintptr_t get_factorized_branches_ptr ()
std::uintptr_t get_factorized_bypass_ptr ()
std::uintptr_t get_factorized_globals_ptr ()
int get_factorized_branches_len ()
int get_factorized_bypass_len ()
int get_factorized_globals_len ()
void get_expert_weights (float *output)

Variables

static ChessInput g_features
static FactorizedInput g_factorized

Detailed Description

WebAssembly API for feature extraction.

Exposes C-linkage functions for extracting chess features into flat buffers for the JavaScript frontend to consume without running the full UCI engine.

Function Documentation

◆ extract_features()

int extract_features ( const char * fen)
Here is the call graph for this function:

◆ get_expert_weights()

void get_expert_weights ( float * output)
Here is the call graph for this function:

◆ get_factorized_branches_len()

int get_factorized_branches_len ( )

◆ get_factorized_branches_ptr()

std::uintptr_t get_factorized_branches_ptr ( )

◆ get_factorized_bypass_len()

int get_factorized_bypass_len ( )

◆ get_factorized_bypass_ptr()

std::uintptr_t get_factorized_bypass_ptr ( )

◆ get_factorized_globals_len()

int get_factorized_globals_len ( )

◆ get_factorized_globals_ptr()

std::uintptr_t get_factorized_globals_ptr ( )

◆ get_feature_globals_len()

int get_feature_globals_len ( )

◆ get_feature_globals_ptr()

std::uintptr_t get_feature_globals_ptr ( )

◆ get_feature_layers_len()

int get_feature_layers_len ( )

◆ get_feature_layers_ptr()

std::uintptr_t get_feature_layers_ptr ( )

Variable Documentation

◆ g_factorized

FactorizedInput g_factorized
static

◆ g_features

ChessInput g_features
static