Changed database model for finite cards

Also cleaned up bin/pyp