Poker-AI.org
https://poker-ai.org/phpbb/

Omaha hand evaluator - speed
https://poker-ai.org/phpbb/viewtopic.php?f=26&t=2705
Page 2 of 2

Author:  mlatinjo [ Fri May 03, 2019 9:48 pm ]
Post subject:  Re: Omaha hand evaluator - speed

Hello JoeSham would you please share your latest version of c# implementation for omaha hand evaluator?

Author:  HontoNiBaka [ Tue Mar 31, 2020 1:24 pm ]
Post subject:  Re: Omaha hand evaluator - speed

pulser wrote:
Attached a standalone version of the code here, with a simple profiler running 10 mill random hands. Seems it only does 17M hands/s for me now, not sure if it's my compiler settings or if I did something wrong last time i tested it.

Didn't go through the comments, but guess they can be ignored for the most part :p

Quote:
Also if you dont mind sharing, how do you create ranges of cards, if you do? I mean for example from a string "AAhh:(23+,35+)", ie. PPT style. That is what I am working on now and it seems tougher than i thought.
Guess I could share code for this too, but don't think I'll do so publicly.

Anyway, I read in hands at a format similar to what you mentioned, creating Range-objects hierarchically, combined with and or or links. After connecting all the rules it feeds hands through the different Rule-filters, eventually storing the final range as Hand-objects in a vector.

In no way rocket science, but it allows for complex combination of rules and a fast final product.


I downloaded the code and the test with random hands looks good so far, however I am not sure what card each integer represents.
Is it like 0 = "2c", 1 = "2d", 2 = "2h", 3 = "2s", 4 = "3c" ...
or is it like
0 = "2c", 1 = "3c", 2 = "4c", 3 = "5c", 4 = "6c" ...

Page 2 of 2 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/