fix an errors that for single slice mode, the number of slices should be 1
Merge pull request #1262 from ruil2/fix_errors

fix an errors that for single slice mode, the number of slices should be 1