Auto warp sample input and output

Fix #190