changed some methods into functions in make_slices.py