Move GetImageForPartition to ota_tools

Cuttlefish instances will use GetImageForPartition. This commit
refactors the code without changing the functionality.

Test: acloud-dev create --avd-type goldfish \
      --local-instance --local-image \
      --local-system-image out/target/product/generic_x86
Bug: 176270532
Change-Id: Ie6ca7da0c84904796d6accbddab93368c997c9c6
3 files changed