From 83ecaef590d9bcfedb6d0c7fb361e6ee5bcaa5b0 Mon Sep 17 00:00:00 2001 From: Branden Moore Date: Tue, 19 Jan 2021 14:09:06 -0600 Subject: [PATCH] Add cluster_group identification to AWS and GCP instance type info --- citc/aws.py | 1 + citc/google.py | 1 + 2 files changed, 2 insertions(+) diff --git a/citc/aws.py b/citc/aws.py index 0b70259..748d5e8 100644 --- a/citc/aws.py +++ b/citc/aws.py @@ -102,6 +102,7 @@ def get_types_info(client: EC2Client) -> Dict[str, NodeTypeInfo]: ), "threads_per_core": d["VCpuInfo"].get("DefaultThreadsPerCore", 1), "arch": d["ProcessorInfo"]["SupportedArchitectures"][0], + "cluster_group": 'cluster' in d["PlacementGroupInfo"]["SupportedStrategies"] } for s, d in instances.items() } diff --git a/citc/google.py b/citc/google.py index c5a3597..f4d6748 100644 --- a/citc/google.py +++ b/citc/google.py @@ -106,6 +106,7 @@ def get_types_info(client, nodespace): "memory": int(math.pow(mt["memoryMb"], 0.7) * 0.9 + 500), "cores_per_socket": mt["guestCpus"], "threads_per_core": "1", + "cluster_group": mt["name"].startswith("c2-") # only C2 currently support compact placement groups } for mt in machine_types }