def METHOD_NAME(self, filename):
    result = subprocess.run(["qemu-img", "info", "--output", "json", filename], capture_output=True)
    if result.returncode != 0:
        sys.exit("Error getting image info for " + filename + ": " + result.stdout)
    doc = json.loads(result.stdout)
    fileSize = doc["actual-size"]
    virtualSize = doc["format-specific"]["data"]["extents"][0]["virtual-size"]
    return (fileSize, virtualSize)