Skip to content

Instantly share code, notes, and snippets.

View ppaulojr's full-sized avatar

Pedro Paulo Jr ppaulojr

View GitHub Profile
@ppaulojr
ppaulojr / stockfish.sh
Created March 5, 2017 02:12 — forked from notbanker/stockfish.sh
Use stockfish engine to output the position evaluation only
#!/usr/bin/env bash
# Call stockfish engine on mac and return only the evaluation score
# Usage stockfish.sh 'r1b2rk1/4qppp/2pp4/pp6/3Bn3/PB3Q1P/1PP2PP1/3R1RK1' 5 mac 12 1024
# Usage stockfish.sh 'r1b2rk1/4qppp/2pp4/pp6/3Bn3/PB3Q1P/1PP2PP1/3R1RK1' 5 mac 12 1024
# Assumes the stockfish binary is called 'stockfish_'+binary
fen=$1
seconds=${2:-3}
binary=${3:-mac}
threads=${4:-12}