kensmosis/ccsearch
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Repository files navigation
CCSearch README. This project contains the reference implementation, white-paper, and documentation for the CCSearch algorithm.
To compile the library (obj/ccslib.so)
make
To compile the documentation (doc/*)
make docs
The following are some useful files and locations:
doc/SearchAlgo.* White paper on the CCSearch algorithm itself (gen'ed by make)
doc/CCSearch.* General documentation about API and reference implementation (gen'ed by make)
apitest.py Python3 front-end (and sample code)
ccsapi.py A simple API module to be included in any homegrown Python3 file which calls the backend. Put 'exec(open("ccsapi.py").read())' right after all the import statements.
obj/ccslib.so The C++ backend API and library (gen'ed by make)
src/* The C++ Source code for the CCSearch backend and API (i.e. ccslib.so). Also contains the markdown source for documentation.
Makefile The make file for the library and docs
README This file
samplefbdata.txt Some sample obfuscated data from a few FB tournaments
Detailed API documentation can be found in the source code src/OAPI.h, and additional documentation can be found throughout the C++ code. apitest.py also serves as documentation.
The C++ machinery requires nothing beyond a standard setup. The Python machinery requires Python 3 and numpy.
Please note that this is a quick and dirty reference implementation. While we expect it will work fairly well, we make no representation of useability or full functionality. In particular, it has not been rigorously unit-tested and we include no regression or coverage suite.
To run a simple test (after running "make") on some sample fantasy baseball data, try
python3 ./apitest.py -f samplefbdata.txt -H -P 1 -G "2:1:1:1:1:1:3" --ispart 1 --ispart 2 --ispart 3 --ispart 4 -C "mingrp:3:2" -C "maxitem:4:5" --maxcost 50000 --ctol 0.2 --itol 0.5 --ntol 1 --resnumb 10000 --maxres 100000 --smode 2 -o foo
For detailed search info and output (warning --- this will generate a LARGE file):
python3 ./apitest.py -f samplefbdata.txt -H -P 1 -G "2:1:1:1:1:1:3" --ispart 1 --ispart 2 --ispart 3 --ispart 4 -C "mingrp:3:2" -C "maxitem:4:5" --maxcost 50000 --ctol 0.2 --itol 0.5 --ntol 1 --resnumb 10000 --maxres 100000 --smode 2 -V 32 -o foo > bar