Improve samples parcing