updated counting to api changes, added cplex and gurobi modules