trainwave-cli 0.1.1__tar.gz → 0.1.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: trainwave-cli
3
- Version: 0.1.1
3
+ Version: 0.1.3
4
4
  Summary:
5
5
  Author: Johan Backman
6
6
  Author-email: johan@trainwave.ai
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "trainwave-cli"
3
- version = "0.1.1"
3
+ version = "0.1.3"
4
4
  description = ""
5
5
  authors = ["Johan Backman <johan@trainwave.ai>"]
6
6
  readme = "README.md"
@@ -35,6 +35,7 @@ class Job:
35
35
  project: str
36
36
  upload_url: str
37
37
  cloud_offer: CloudOffer
38
+ cost_per_hour: float
38
39
 
39
40
 
40
41
  @dataclass(frozen=True)
@@ -45,6 +45,7 @@ async def launch( # noqa
45
45
  cpus: Annotated[int, typer.Option()] = 0,
46
46
  gpus: Annotated[int, typer.Option()] = 0,
47
47
  gpu_type: Annotated[str, typer.Option()] = "",
48
+ compliance_soc2: Annotated[bool, typer.Option()] = None,
48
49
  ) -> None:
49
50
  api_client = Api(config.api_key, config.endpoint, project)
50
51
  # Interpolate environe variables
@@ -69,6 +70,8 @@ async def launch( # noqa
69
70
  "gpu_type": gpu_type,
70
71
  "env_vars": env_vars,
71
72
  }
73
+ if compliance_soc2 is not None:
74
+ conf["compliance_soc2"] = compliance_soc2
72
75
 
73
76
  if expires != "":
74
77
  expires_time = pytimeparse.parse(expires)
@@ -109,6 +112,7 @@ async def launch( # noqa
109
112
  "value": [truncate_string(str(co[k]), 50) for k in tab_keys],
110
113
  }
111
114
  logger.info("\nMatched machine\n" + tabulate(tab_values, headers="keys") + "\n")
115
+ logger.info(f"Cost per hour for this job: ${job.cost_per_hour/100:.2f}")
112
116
  logger.info(f"Job created: {job.rid} ({job.id})")
113
117
  except Exception as e:
114
118
  traceback.print_exc()
File without changes