Texas Holdem Poker
This is a package including a command-line-interacted simulated texas holdem poker game, and a winning-rate calculator
In this game, you will play holdem and compete with AI which is based on Monte Carlo method and Kelly formula
If you are interested in poker game like this, try and enjoy!
德州扑克模拟器
这个包包含了一个命令行交互形式的德州扑克游戏,以及包含一个实时胜率计算器
在该游戏中,你将与其他基于蒙特卡洛算法与凯利公式设计的AI玩家进行对抗
如果你也对德州扑克感兴趣,不妨一起来试一试吧!
1.How to install
pip install texas_holdem_poker
2.How to play
HoldemGame
class HoldemGame is a simulator of texas holdem poker game
to start the game, just import this class and call ‘run’ method
from texas_holdem_poker import HoldemGame HoldemGame().run()
And it will work like this
Texas Holdem Poker Simulator Your money: 1000 Player1 money: 1000 Player2 money: 1000 Player3 money: 1000 Player4 money: 1000 Player5 money: 1000 Round: 0 now your turn, your cards: [♦K, ♠K] remaining money: 5000, already bet: 0 input your bet:
- And then, input your bet(bet should be an integer) to action!
fold if input < 0
check if input == 0 == bottom
call if input <= bottom
raise if input > bottom
Calculator
class Calculator is designed for winning-rate calculation
from texas_holdem_poker import Calculator Calculator(simulate_times=1500).run()
And it will work like this
Input your hand cards, for examples: "SJ S10", S=Spade♠, C=Club♣, H=Heart♥, D=Diamond♦ SJ S10 Input community cards, can be empty Input total players and total remaining players(include yourself), for examples:"6 2" 6 2 Win Rate: 0.6093
through pip and pypi, you can easily use it anywhere and on any devices which can run python
Metadata
Release files for texas-holdem-poker 0.1.8
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| texas_holdem_poker-0.1.8.tar.gz | 12.2 kB | Without provenance | Details for texas_holdem_poker-0.1.8.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| texas_holdem_poker-0.1.8-py3-none-any.whl | Python 3 | none | any | Details for texas_holdem_poker-0.1.8-py3-none-any.whl |
Total release size: 25.3 kB
Release files / texas_holdem_poker-0.1.8.tar.gz
| Download URL | texas_holdem_poker-0.1.8.tar.gz |
|---|---|
| Size | 12.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e4cffeb06efe6fd48bf2260ab92be84a6b733ae2f064d03b6953d6c1d0546c74
|
|
BLAKE2b-256 checksum How to use checksums |
32ff6b467ce15f9dcea73874ccaed542b7f40968b62da69a324ee3cfa5214abe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.9
|
Release files / texas_holdem_poker-0.1.8-py3-none-any.whl
| Download URL | texas_holdem_poker-0.1.8-py3-none-any.whl |
|---|---|
| Size | 13.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c688959ef022291079002ef28137d141eaf2738feb2931d14829e95e64f9d585
|
|
BLAKE2b-256 checksum How to use checksums |
2fa24785b65f578e43d7197c659246cc46ea1359027d385154b3f45063658edb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.9
|
Security for texas-holdem-poker 0.1.8
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.