Showing posts with label software. Show all posts
Showing posts with label software. Show all posts

Monday, May 12, 2014

Gencon 2014 scheduler update

 I have updated my scheduling script for GenCon 2014. I had originally not expected to have to make any changes to the code, but GenCon this year moved the location of their event catalog files, and decided to only release the event catalogs in xlsx format instead of csv.  While you can still use last year's version of my scheduler by manually downloading and converting the catalog files, I've modified my code to use a converter utility to do the conversion.

The latest version of it can be found here.

In order to use this, you will need to install Python 2.7.  You will also need to install this xlsx to csv converter code. After installing xlsx2csv, you'll have to copy the xlsx2csv.py file from the install directory into the same directory that the schedule solver python file is located.

The GenCon event registration system is also limiting event wish lists to 50 items this year, so the wishlist generator will limit itself to that number of wishlist items.

As before, this is an experimental and somewhat crude schedule optimization utility.  It allows you to search the event catalog with a text-based interface, add events to your wishlist with assigned priorities, and then generates an optimal schedule for you, as well as a wishlist to enter into the GenCon registration system.

Friday, May 3, 2013

Gencon Scheduler Script Update

As it is nearly time for the annual hectic GenCon event scheduling frenzy, I have updated my schedule-planning script.  The latest version of the script is available here.

A stand-alone application version of the program is available here.

This script is a utility I wrote in Python to help in the complex process of searching through the 9000+ individual events in the GenCon event catalog and finding the optimal mix of things to do at the convention.  Like to the Highprogrammer search tool, this script can search through the event catalog and filter events by time, type, organizer, system, age, etc.  Unlike the highprogrammer tool, this script runs completely on your own computer (once it downloads the catalog from the GenCon site) so you don't need to worry about Highprogrammer going down.  But it also does a lot more.

In addition to the event search function, this script also has a schedule optimization mode.  After running a search on the event list and finding an event that interests you, you can add that event to a wish list and assign a priority rank to it.  Once you have gathered a selection of events you might want to attend, the schedule optimization function will run through every possible combination of events to determine the best possible convention schedule for you.  The search tool is also smart enough to recognize that many of the events at GenCon are run at multiple timeslots throughout the weekend.  You simply specify that you'd like to attend an event and the schedule optimizer will pick the best slot for you to attend considering other possible conflicting events.

The script also has a function to guide you through the registration process, filling out your online wishlist with events as determined by your optimal schedule and all the less-optimal schedules yo might fall back on if you don't get tickets to your highest-ranking events.  This function is still somewhat experimental, but does seem to work.

For this year I've vastly improved the code that digests the raw event list files.  It should be a lot more robust to GenCon suddenly deciding to change their catalog format again.  I have also greatly improved the search algorithm, it can now process complex search queries like "Find any pathfinder by paizo on thursday or friday not before noon".  The schedule optimizer also now has a set of user-tweakable rules for things like minimum hours of sleep per night and maximum contiguous hours of gaming without a break.

Now for the downsides.  This is a script, not a stand-alone application.  You will need to download and install Python 2.7 (not 3.x!) for this to run.  The code is not terribly well optimized, some of the functions are quite slow.  Updating the event catalog from the GenCon website in particular takes forever.  The interface is a command-line text interface, there's no GUI or anything friendly like that, but there are some built-in help functions to tell you how to use it.

The first time you run the script, it will automatically connect to the GenCon site and download the event catalog.  At the time of this writing, that catalog does not exist yet, so the script will fail and quit.  I am at the moment assuming that GenCon will be putting this year's event list in the same place as last year's and storing it in a similar format.  If they don't, I'll be updating this script shortly after the catalog becomes available.

Update:  As of the evening of May 8th, the event catalog is live, and my script is successfully downloading and processing it.

Saturday, May 12, 2012

Gencon Schedule Solver

Gencon has an absurd number of events taking place over the course of 5 days.  Many of these events are things I'd like to attend, with varying degrees of liking.  Many of the events are run at different times through the weekend, giving me multiple opportunities to attend them.  Some events - such as the True Dungeon events - have over 100 timeslots, others have only a few.  The number of possible schedule combinations are huge.

I could simply pull out the calendar and go over it manually, working out the optimum schedule on my own, but I'm lazy, and when presented with that kind of challenge I prefer to automate it.  So I created a Python script.

This script was in part an excuse to learn how to use some of the url library functions in Python, as it connects on its own to the Gencon community file directory and downloads the latest event calendar automatically.  On extracting the event file it then processes it and attempts to find all events which are the same event run in multiple slots, and combines them into single entry.

There's a fairly simple command-line interface I wrote to search the event list to find the events I wanted, and then assign a priority to each one.  The script then works through all the possible permutations of events, assigns a rating to each one, and then either presents the best possible schedule, or walks the user through the registration process and adjusts the schedule as required to account for events filling up.

It's still crude and buggy, but works for its intended purpose - optimizing your event schedule.

I made the mistake of mentioning this on the Gencon community forums, and immediately received requests for the script.

I have put the script on a pastebin page here:

http://pastebin.com/Rmuf0iJS

Or you can download it as a file from here:

http://www.2shared.com/file/QSKfjxeY/Gencon_schedule_solver_2012.html

To use this, you will need to first install Python 2.7.  Then, either download and extract the zipped file, or create a new file in the Idle python text editor and copy-and-paste the text from pastebin.

Run the script.  The first time it is run, it will create a directory for event calendars.  It will ask you if you want to download the latest schedule.  Obviously, you need to say yes on the first time or it won't have anything to work with.  You can then search for events, create wishlists, and then have it solve for optimal schedules.  Command help is imbedded in the script, just type 'help' at the command line.