ID = the pull request ID number (eg: 3544) BRANCHNAME = the name of the pull request branch (eg: 'image-registration')
git fetch upstream pull/ID/head:BRANCHNAME
git checkout BRANCHNAME
See: https://help.github.com/articles/checking-out-pull-requests-locally/