Add get_locatin method to validate input
Optimize rotation method
Add test for invalid location
Add comments in e2e test