Merge branch 'master' of git://git.assembla.com/fpdboz

This commit is contained in:
gimick 2010-06-24 21:41:16 +01:00
commit bd440f3008
10 changed files with 5 additions and 1802 deletions

View File

@ -1,75 +0,0 @@
This is partially outdated
File list
=========
.:
docs/ Documentation files
pyfpdb/ The main program (in python)
setup/ Directory with files for setting up this program
regression-test/ Directory with test data, query scripts (in python) and the regression test script (in bash)
utils/ A couple of things that will migrate to the main prog soon
viewer/ Directory with the GUI (in Java)
./docs:
abbreviations.txt A list of abbreviations used and their meaning
agpl-3.0.txt License of the program (everything under /code)
benchmarks.txt Some benchmark results
codingstyle.txt Some notes on formatting. Feel free to ignore.
fdl-1.2.txt License of the documentation (the files in /)
filelist.txt This file
howto-import.txt Instructions on how to run the importer
install-in-gentoo.txt Installation instructions for Gentoo GNU/Linux
install-in-windows.txt Installation instructions for Windows
readme-dev.txt Some notes, pointers and such for developers or anyone else interested in changing fpdb
readme-overview.txt Some general info about this program - read that first
readme-user.txt Instructions on how to use fpdb
status.txt Details of support for poker types and sites
tabledesign.html Table design with comments
./pyfpdb:
fpdb.py The main GUI. This is what the user will start and use to access the other things.
fpdb_import.py Main import program. Calls methods in the other files.
Takes one hand history file as input. This is the file
you execute, do not run the other ones individually.
Except import_gui.py of course.
fpdb_parse_logic.py Parses a holdem/omaha/razz/stud hand.
fpdb_save_to_db.py Just methods to store the parsed data into SQL.
Seperate file because these calls are very unwieldy.
fpdb_simple.py Simple methods called by the other files. Most work is
actually done in this file to make the other ones look
much easier than they are.
import_gui.py GUI interface to the importer (obselete)
./setup:
insert-basedata.sql Fills sites and gametypes tables. Run this once after running the above.
recreate-tables.sql File for mysql to recreate the tables. THIS WILL DELETE EXISTING TABLES!!!
./testdata:
should be self explanatory
./utils:
dump_db_basedata.py Prints the contents of the tables sites and gametypes
fpdb_util_lib.py Helper methods for the utilities.
get_DB_stats.py Prints some counts (like no. of players in the DB)
get_player_stats.py Prints certain stats about players with CLI-passed constraints
mysql-reset-tables.sh Reset tables for MySQL. THIS WILL DELETE EXISTING TABLES!!!
print_hand.py Prints a hand in legible format.
psql-interactive.sh *nix script to connect to a PostgreSQL database in
interactive mode (note that we're currently only supporting MySQL)
regression-test.sh Resets tables and checks manually verified hands for errors
./viewer:
todo
License
=======
Trademarks of third parties have been used under Fair Use or similar laws.
Copyright 2008 Steffen Jobbagy-Felso
Permission is granted to copy, distribute and/or modify this
document under the terms of the GNU Free Documentation License,
Version 1.2 as published by the Free Software Foundation; with
no Invariant Sections, no Front-Cover Texts, and with no Back-Cover
Texts. A copy of the license can be found in fdl-1.2.txt
The program itself is licensed under AGPLv3, see agpl-3.0.txt

View File

@ -1,79 +0,0 @@
README.txt
updated 22 February 2010, REB
fpdb - Free Poker Database
The most accurate and up-to-date information on fpdb will be found in the wiki:
http://fpdb.wiki.sourceforge.net/
Other resources are:
Mailing list: http://sourceforge.net/mailarchive/forum.php?forum_name=fpdb-main
Chat room(irc): #fpdb on freenode.net
fpdb is a free program for use with on line poker. It provides:
Tracking of your results and statistics.
Tracking of opponents' results statistics.
Win/loss graphing
Heads Up Display (HUD) with a variety of statistics
Display of mucked cards in the HUD
fpdb supports:
Sites:
PokerStars
Full Tilt Poker
Everleaf Network
Other sites are under development and are easily added
Games:
Holdem
Omaha (incl Hi/low)
7 Card Stud (incl Hi/low)
Razz
Triple Draw and Badugi
Mixed Games -- HUD under development
Operating Systems:
Linux and other Unix-like, using X
Windows
Mac OS/X -- no support for HUD
Databases:
SQLite configured by default
MySQL
PostgreSQL
Downloads:
Releases: http://sourceforge.net/project/showfiles.php?group_id=226872
Development code via git: http://www.assembla.com/spaces/free_poker_tools/trac_git_tool
Developers:
At least 10 people have contributed code or patches. Others are welcome.
Source Code:
If you received fpdb as the Windows compressed exe, then you did not
receive souce code for fpdb or the included libraries. If you wish, you can
obtain the source code here:
fpdb: see Downloads, above.
python: http://python.org/
gtk: http://www.gtk.org/download.html
pygtk: http://www.pygtk.org/downloads.html
psycopg2: http://initd.org/pub/software/psycopg/
mysqldb: http://sourceforge.net/projects/mysql-python/files/
sqlalchemy: http://www.sqlalchemy.org/download.html
numpy: http://www.scipy.org/Download
matplotlib: http://sourceforge.net/projects/matplotlib/files/
License
=======
Trademarks of third parties have been used under Fair Use or similar laws.
Copyright 2008 Steffen Jobbagy-Felso
Copyright 2009,2010 Ray E. Barker
Permission is granted to copy, distribute and/or modify this
document under the terms of the GNU Free Documentation License,
Version 1.2 as published by the Free Software Foundation; with
no Invariant Sections, no Front-Cover Texts, and with no Back-Cover
Texts. A copy of the license can be found in fdl-1.2.txt
fpdb itself is licensed under AGPLv3, see agpl-3.0.txt.

View File

@ -1,93 +0,0 @@
alpha2
======
Hi everyone,
we are proud to announce the second alpha release of fpdb, the free/libre open source poker tracker. The biggest highlight is the HUD for Linux made by Ray (and perhaps Mac, not sure). But for everyone fpdb now also supports PS tournaments (SnG and MTT) and FTP ring games. There is also a new auto-importer though it currently only runs on one file per instance (but you can open multiple instances of fpdb).
Fpdb also parses alot of new situations into the cache table for the HUD, most of which are already available through the Linux HUD. There have also been a large number of bugfixes for all kinds of things. For full details of the changes see the git commit comments.
You can download fpdb at https://sourceforge.net/project/showfiles.php?group_id=226872
Our website at http://fpdb.sourceforge.net/ will be updated shortly but in the meantime please note that the configuration file now resides in ~/.fpdb/default.conf on Linux/Mac and in C:\Documents and Settings\Application Data\fpdb\default.conf on Windows (on non-English Windows you have to translate the Documents and Settings, but not the Application data bit). Apart from that just follow the instructions on the site. I will be updating/improving the fpdb ebuild for Gentoo next week, please send me a PM or email if you would like a package for another Linux/BSD.
To use the HUD in Linux simply run the auto importer whilst having the table open. You will also have to rename HUD_config.xml.example to HUD_config.xml and edit the database parameters in there in addition to what is written in the install guide.
If you've been using fpdb alpha1 just delete the fpdb folder, follow the installation guide except for installing the dependencies, then run fpdb and run recreate tables. Note that you will have to reimport ALL your history files.
For external devs (in particular Youre Toast): The table design has gone through some changes, though most of it was just renaming to make a consistent naming scheme and to make it more flexible towards stud/razz type games. I do not expect to having to make any future changes to the existing fields but I cannot yet guarantee that. There will be some additional fields in particular in the HudCache table. Please let me know if you need any further fields. I realise my naming breaks the "database designer's convention" but for this project I feel ignoring this convention for the benefit of consistent naming between Python and SQL is ok.
Any questions and comments please post here, send me a PM or email, post a feature request or bug report on sourceforge or use any of the other means of contact listed on our webpage.
Enjoy,
The fpdb team
PS: I personally will be away Sun-Tue so I probably won't be responding to anything but feel free to message me anyways, but if you post here or at SF someone else might be able to help.
PPS: If you wanna know EXACTLY how this project is moving along follow the git tree over at [url]http://www.assembla.com/spaces/fpdb/trac_git_tool[/url]
alpha1
======
Hi everyone,
I am proud to announce the first release of my new poker tracking software fpdb (freepokerdb, very imaginative I know ;) ). You may wonder why I bothered when now with HM and PT3 there are at least two excellent packages to choose from.
Four main reasons:
1. Fpdb is free/libre open source software. In short, this means you don't depend on me if sth. is wrong or you want something more in this program as you can freely change it yourself. You also don't have to pay anything for it. If you like it and think I deserve to be paid just drop me a mail ;)
2. HM and PT3 only support holdem. Fpdb initially supports Holdem and Omaha, with Stud and Razz mostly implemented and coming soon.
3. HM and PT3 run on Windows only, and for me at least did not work in wine even after installing Mono. Fpdb runs on any plattform that has the required software, which will cover roundabout 99.9% of PCs. Currently tested plattforms are Windows XP-x86 and Gentoo GNU/Linux-amd64 as well as -x86.
You still need to run Windows or wine to run the actual poker client though.
4. Fpdb won't irritate you with copy prevention measures.
To install it go to https://sourceforge.net/project/showfiles.php?group_id=226872 and download the zip or tar.bz2, unpack it, and follow the instructions in docs/install-in-* for your operating system (e.g. docs\install-in-windows.txt). Sourceforge lists the release files as source files, not as binary executables - this is correct, python will automagically compile as and when required.
This is alpha1, as the name indicates it is still at a very early stage. The importer and database are nearing completion but the GUI in particular is not very functional yet and the HUD is missing alltogether.
If anyone wishes to help with development that would be very very welcome and I've put a few notes in docs/readme-dev.txt in the download for what you could do. Or just start coding and send me the patches :)
If you're not a programmer and you're not interested in learning it you can still help simply by trying it out and sending bug reports and feature requests. To avoid unrealistic expectations I'd like to state that it'll be a long time until fpdb reaches feature parity to established paid-for closed source software.
Feature List (short now, growing fast ;) ):
You can edit/add whatever you like, it's all python and SQL. The code should be fairly straightforward I think and I put some notes into readme-dev.txt but feel free to ask.
Backend, Distribution
=====================
- Choice of MySQL/InnoDB or PostgreSQL. (not tested on PostgreSQL)
- It is possible to run the database on one PC, the importer on another, and then access the database with the table viewer or HUD from a third PC. (note: do NOT do this unencrypted over an untrusted network like your employer's LAN or the Internet!)
Site/Game Support
=================
- Initially only full support for PS, FTP coming soon
- Supports Holdem, Omaha Hi and Omaha Hi/Lo. Stud and Razz coming soon.
- Supports No Limit, Pot Limit, Fixed Limit NL, Cap NL and Cap PL
Note that currently it does not display extra stats for NL/PL so usefulness is limited for these limit types. Suggestions welcome, I don't play these.
- Supports ring/cash games, SnG/MTT coming soon
Tableviewer (tv)
===========
Tv takes a history filename and loads the appropriate players' stats and displays them in a tabular format. These stats currently are:
- VPIP, PFR and Preflop 3B/4B (3B/4B is not quite correct I think)
- Raise and Fold % on flop, turn and river. Fold only counts hands when someone raised. This can be displayed per street or as one combined value each for aggression and folding.
- Number of hands this is based on.
- SD/F (aka WtSD, proportion of hands where player went to showdown after seeing flop)
- W$wSF (Won $ when seen Flop)
- W$@SD (Won $ at showdown)
For all stats it also displays how many hands this particular is based on
IMPORTANT: The database format WILL undergo more changes and at this point I am not planning to write a converter so please keep your history files so you can re-import when necessary. Independent of this you should always keep the original raw files in a safe place with any tracking software. Should you however end up loosing your files somehow let me know and I'll try to help.
Please send any feedback, feature requests/suggestions, bug reports and animal names to steffen@sycamoretest.info, pick one of the contact methods listed in readme-overview.txt, send me a PM here or reply to this post.
License
=======
Trademarks of third parties have been used under Fair Use or similar laws.
Copyright 2008 Steffen Jobbagy-Felso
Permission is granted to copy, distribute and/or modify this
document under the terms of the GNU Free Documentation License,
Version 1.2 as published by the Free Software Foundation; with
no Invariant Sections, no Front-Cover Texts, and with no Back-Cover
Texts. A copy of the license can be found in fdl-1.2.txt
The program itself is licensed under AGPLv3, see agpl-3.0.txt

File diff suppressed because it is too large Load Diff

View File

@ -345,7 +345,7 @@ For sites (currently only Carbon Poker) which record "all in" as a special actio
self.actions['BLINDSANTES'].append(act)
if blindtype == 'both':
# work with the real ammount. limit games are listed as $1, $2, where
# work with the real amount. limit games are listed as $1, $2, where
# the SB 0.50 and the BB is $1, after the turn the minimum bet amount is $2....
amount = self.bb
self.bets['BLINDSANTES'][player].append(Decimal(self.sb))

View File

@ -896,9 +896,10 @@ class fpdb:
def tab_main_help(self, widget, data=None):
"""Displays a tab with the main fpdb help screen"""
mh_tab=gtk.Label("""Welcome to Fpdb!
For documentation please visit our website at http://fpdb.sourceforge.net/ or check the docs directory in the fpdb folder.
Please note that default.conf is no longer needed nor used, all configuration now happens in HUD_config.xml
This program is licensed under the AGPL3, see docs"""+os.sep+"agpl-3.0.txt")
For documentation please visit our website at http://fpdb.sourceforge.net/.
If you need help click on Contact - Get Help on our website.
Please note that default.conf is no longer needed nor used, all configuration now happens in HUD_config.xml.
This program is licensed under the AGPL3, see agpl-3.0.txt in the fpdb installation directory.""")
self.add_and_display_tab(mh_tab, "Help")
def tab_table_viewer(self, widget, data=None):

View File

@ -1,38 +0,0 @@
#!/usr/bin/python
#Copyright 2008 Steffen Jobbagy-Felso
#This program is free software: you can redistribute it and/or modify
#it under the terms of the GNU Affero General Public License as published by
#the Free Software Foundation, version 3 of the License.
#
#This program is distributed in the hope that it will be useful,
#but WITHOUT ANY WARRANTY; without even the implied warranty of
#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
#GNU General Public License for more details.
#
#You should have received a copy of the GNU Affero General Public License
#along with this program. If not, see <http://www.gnu.org/licenses/>.
#In the "official" distribution you can find the license in
#agpl-3.0.txt in the docs folder of the package.
import sys
import MySQLdb
db = MySQLdb.connect("localhost", "fpdb", sys.argv[1], "fpdb")
cursor = db.cursor()
print "Connected to MySQL on localhost. Printing dev-supplied base data:"
cursor.execute("SELECT * FROM sites")
print "Sites"
print "====="
print cursor.fetchall()
cursor.execute("SELECT * FROM gametypes")
print "Gametypes"
print "========="
result=cursor.fetchall()
for i in range (len(result)):
print result[i]
cursor.close()
db.close()

View File

@ -1,83 +0,0 @@
#!/usr/bin/python
#Copyright 2008 Steffen Jobbagy-Felso
#This program is free software: you can redistribute it and/or modify
#it under the terms of the GNU Affero General Public License as published by
#the Free Software Foundation, version 3 of the License.
#
#This program is distributed in the hope that it will be useful,
#but WITHOUT ANY WARRANTY; without even the implied warranty of
#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
#GNU General Public License for more details.
#
#You should have received a copy of the GNU Affero General Public License
#along with this program. If not, see <http://www.gnu.org/licenses/>.
#In the "official" distribution you can find the license in
#agpl-3.0.txt in the docs folder of the package.
import sys
import MySQLdb
db = MySQLdb.connect("localhost", "fpdb", sys.argv[1], "fpdb")
cursor = db.cursor()
print "Connected to MySQL on localhost. Printing summary stats:"
cursor.execute("SELECT id FROM Players")
print "Players:",cursor.rowcount
cursor.execute("SELECT id FROM Autorates")
print "Autorates:",cursor.rowcount
cursor.execute("SELECT id FROM Sites")
print "Sites:",cursor.rowcount
cursor.execute("SELECT id FROM Gametypes")
print "Gametypes:",cursor.rowcount
cursor.execute("SELECT id FROM Hands")
print "Total Hands:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.type='ring'")
print "Hands, Ring:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.type='stt'")
print "Hands, STT:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.type='mtt'")
print "Hands, MTT:",cursor.rowcount
print ""
print "Hands per category and type"
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.limitType='cn'")
print "Hands, Cap No Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.limitType='cp'")
print "Hands, Cap Pot Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='holdem' AND Gametypes.limitType='nl'")
print "Hands, Holdem No Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='holdem' AND Gametypes.limitType='pl'")
print "Hands, Holdem Pot Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='holdem' AND Gametypes.limitType='fl'")
print "Hands, Holdem Fixed Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahi' AND Gametypes.limitType='nl'")
print "Hands, Omaha Hi No Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahi' AND Gametypes.limitType='pl'")
print "Hands, Omaha Hi Pot Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahi' AND Gametypes.limitType='fl'")
print "Hands, Omaha Hi Fixed Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahilo' AND Gametypes.limitType='nl'")
print "Hands, Omaha Hi/Lo No Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahilo' AND Gametypes.limitType='pl'")
print "Hands, Omaha Hi/Lo Pot Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='omahahilo' AND Gametypes.limitType='fl'")
print "Hands, Omaha Hi/Lo Fixed Limit:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='razz'")
print "Hands, Razz:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='studhi'")
print "Hands, Stud Hi:",cursor.rowcount
cursor.execute("SELECT Hands.id FROM Hands INNER JOIN Gametypes ON Hands.gametypeId = Gametypes.id WHERE Gametypes.category='studhilo'")
print "Hands, Stud Hi/Lo:",cursor.rowcount
print ""
cursor.execute("SELECT id FROM BoardCards")
print "Board_cards:",cursor.rowcount
cursor.execute("SELECT id FROM HandsPlayers")
print "Hands_players:",cursor.rowcount
cursor.execute("SELECT id FROM HandsActions")
print "Hands_actions:",cursor.rowcount
cursor.close()
db.close()