Start code for refine value