Python3 compatibility fixes.
Python3 compatibility fixes.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=261983733

GoogleCloudPlatform/PerfKitBenchmarker,GoogleCloudPlatform/PerfKitBenchmarker,GoogleCloudPlatform/PerfKitBenchmarker,GoogleCloudPlatform/PerfKitBenchmarker