##PET: A Roundup and Speed Comparison of Seven Card Poker Hand Evaluators
##What's This? A open test framework and speed comparison of seven card poker hand evaluators in C and C++. Measuring the state-of-the art in open-source hand evaluators. Inspired by James Devlin's apparently defunct five card roundup at CodingTheWheel.
##What do I do with it?
-
Create more test scenarios.
##How does it work?
The framework provides a C adaptor for each evaluator to give it a uniform interface. Each Evaluator Under Test (EUT) is assigned a unique 3 letter abbreviation, and implements the api defined in PET_evaluator.h
. A set of macros in that header translates the API names to the evaluator's names so that we can use the same test harness for all of them. See Interface.md for more details
It runs each evaluator through two tests, and times the performance for:
- Enumerating every possible 7 card hand.
- This test includes the cost of adding cards to the hand.
- Enumerating lots (50,000,000 by default) of random hands.
- This one creates the hands and calls
addcard
outside the timing loop.
There is a script to collect and plot the results. python plot.py trials
- CactusKev
- TwoPlusTwo
- Paul Senzee's 7-Card
- Steve Brecher's Holdem Showdown
- PokerSource
- Ace Eval
- Moritz Hammer
- PerfectHash for CactusKev
The PET code is open source, available under the terms of the MIT License (see LICENSE). Individual evaluators are licenced under their original terms, see README files in each subidrectory.