fixed some bugs in model comparison