Methods setting in segment.py