Fixing weight count + optim with free cell count