nemo-evaluator-launcher 0.1.0rc9__tar.gz → 0.1.1__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.
Files changed (63) hide show
  1. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/PKG-INFO +1 -1
  2. nemo_evaluator_launcher-0.1.1/src/nemo_evaluator_launcher/cli/ls_tasks.py +134 -0
  3. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/main.py +6 -5
  4. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/package_info.py +2 -2
  5. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/PKG-INFO +1 -1
  6. nemo_evaluator_launcher-0.1.0rc9/src/nemo_evaluator_launcher/cli/ls_tasks.py +0 -34
  7. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/LICENSE +0 -0
  8. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/README.md +0 -0
  9. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/pyproject.toml +0 -0
  10. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/setup.cfg +0 -0
  11. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/__init__.py +0 -0
  12. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/api/__init__.py +0 -0
  13. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/api/functional.py +0 -0
  14. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/api/types.py +0 -0
  15. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/api/utils.py +0 -0
  16. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/__init__.py +0 -0
  17. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/export.py +0 -0
  18. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/info.py +0 -0
  19. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/kill.py +0 -0
  20. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/ls_runs.py +0 -0
  21. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/run.py +0 -0
  22. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/status.py +0 -0
  23. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/cli/version.py +0 -0
  24. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/common/__init__.py +0 -0
  25. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/common/execdb.py +0 -0
  26. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/common/helpers.py +0 -0
  27. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/common/logging_utils.py +0 -0
  28. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/common/mapping.py +0 -0
  29. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/__init__.py +0 -0
  30. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/default.yaml +0 -0
  31. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/deployment/nim.yaml +0 -0
  32. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/deployment/none.yaml +0 -0
  33. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/deployment/sglang.yaml +0 -0
  34. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/deployment/vllm.yaml +0 -0
  35. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/execution/lepton/default.yaml +0 -0
  36. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/execution/local.yaml +0 -0
  37. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/configs/execution/slurm/default.yaml +0 -0
  38. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/__init__.py +0 -0
  39. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/base.py +0 -0
  40. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/lepton/__init__.py +0 -0
  41. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/lepton/deployment_helpers.py +0 -0
  42. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/lepton/executor.py +0 -0
  43. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/lepton/job_helpers.py +0 -0
  44. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/local/__init__.py +0 -0
  45. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/local/executor.py +0 -0
  46. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/local/run.template.sh +0 -0
  47. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/registry.py +0 -0
  48. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/slurm/__init__.py +0 -0
  49. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/executors/slurm/executor.py +0 -0
  50. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/__init__.py +0 -0
  51. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/base.py +0 -0
  52. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/gsheets.py +0 -0
  53. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/local.py +0 -0
  54. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/mlflow.py +0 -0
  55. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/registry.py +0 -0
  56. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/utils.py +0 -0
  57. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/exporters/wandb.py +0 -0
  58. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher/resources/mapping.toml +0 -0
  59. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/SOURCES.txt +0 -0
  60. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/dependency_links.txt +0 -0
  61. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/entry_points.txt +0 -0
  62. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/requires.txt +0 -0
  63. {nemo_evaluator_launcher-0.1.0rc9 → nemo_evaluator_launcher-0.1.1}/src/nemo_evaluator_launcher.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nemo-evaluator-launcher
3
- Version: 0.1.0rc9
3
+ Version: 0.1.1
4
4
  Summary: Launcher for the evaluations provided by NeMo Evaluator containers with different runtime backends
5
5
  Author: NVIDIA
6
6
  Author-email: nemo-toolkit@nvidia.com
@@ -0,0 +1,134 @@
1
+ # SPDX-FileCopyrightText: Copyright (c) 2025, NVIDIA CORPORATION. All rights reserved.
2
+ # SPDX-License-Identifier: Apache-2.0
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+ #
16
+ import json
17
+ from collections import defaultdict
18
+ from dataclasses import dataclass
19
+
20
+ from simple_parsing import field
21
+
22
+ from nemo_evaluator_launcher.api.functional import get_tasks_list
23
+
24
+
25
+ @dataclass
26
+ class Cmd:
27
+ """List command configuration."""
28
+
29
+ json: bool = field(
30
+ default=False,
31
+ action="store_true",
32
+ help="Print output as JSON instead of table format",
33
+ )
34
+
35
+ def execute(self) -> None:
36
+ # TODO(dfridman): modify `get_tasks_list` to return a list of dicts in the first place
37
+ data = get_tasks_list()
38
+ headers = ["task", "endpoint_type", "harness", "container"]
39
+ supported_benchmarks = []
40
+ for task_data in data:
41
+ assert len(task_data) == len(headers)
42
+ supported_benchmarks.append(dict(zip(headers, task_data)))
43
+
44
+ if self.json:
45
+ print(json.dumps({"tasks": supported_benchmarks}, indent=2))
46
+ else:
47
+ self._print_table(supported_benchmarks)
48
+
49
+ def _print_table(self, tasks: list[dict]) -> None:
50
+ """Print tasks grouped by harness and container in table format."""
51
+ if not tasks:
52
+ print("No tasks found.")
53
+ return
54
+
55
+ # Group tasks by harness and container
56
+ grouped = defaultdict(lambda: defaultdict(list))
57
+ for task in tasks:
58
+ harness = task["harness"]
59
+ container = task["container"]
60
+ grouped[harness][container].append(task)
61
+
62
+ # Print grouped tables
63
+ for i, (harness, containers) in enumerate(grouped.items()):
64
+ if i > 0:
65
+ print() # Extra spacing between harnesses
66
+
67
+ for j, (container, container_tasks) in enumerate(containers.items()):
68
+ if j > 0:
69
+ print() # Spacing between containers
70
+
71
+ # Prepare task table first to get column widths
72
+ task_headers = ["task", "endpoint_type"]
73
+ rows = []
74
+ for task in container_tasks:
75
+ rows.append([task["task"], task["endpoint_type"]])
76
+
77
+ # Sort tasks alphabetically for better readability
78
+ rows.sort(key=lambda x: x[0])
79
+
80
+ # Calculate column widths with some padding
81
+ widths = [
82
+ max(len(task_headers[i]), max(len(str(row[i])) for row in rows)) + 2
83
+ for i in range(len(task_headers))
84
+ ]
85
+
86
+ # Calculate minimum table width based on task columns
87
+ min_table_width = sum(widths) + len(widths) + 1
88
+
89
+ # Calculate required width for header content
90
+ harness_line = f"harness: {harness}"
91
+ container_line = f"container: {container}"
92
+ header_content_width = (
93
+ max(len(harness_line), len(container_line)) + 4
94
+ ) # +4 for "| " and " |"
95
+
96
+ # Use the larger of the two widths
97
+ table_width = max(min_table_width, header_content_width)
98
+
99
+ # Print combined header with harness and container info
100
+ print("=" * table_width)
101
+ print(f"{harness_line}")
102
+ print(f"{container_line}")
103
+
104
+ # Adjust column widths to fill the full table width
105
+ available_width = table_width
106
+ # Give more space to the first column (task names can be long)
107
+ adjusted_widths = [
108
+ max(
109
+ widths[0], available_width * 2 // 3
110
+ ), # 2/3 of available width for task
111
+ 0, # Will be calculated as remainder
112
+ ]
113
+ adjusted_widths[1] = (
114
+ available_width - adjusted_widths[0]
115
+ ) # Remainder for endpoint_type
116
+
117
+ # Print task table header separator
118
+ print(" " * table_width)
119
+ header_row = f"{task_headers[0]:<{adjusted_widths[0]}}{task_headers[1]:<{adjusted_widths[1]}}"
120
+ print(header_row)
121
+ print("-" * table_width)
122
+
123
+ # Print task rows
124
+ for row in rows:
125
+ data_row = f"{str(row[0]):<{adjusted_widths[0]}}{str(row[1]):<{adjusted_widths[1]}}"
126
+ print(data_row)
127
+
128
+ print("-" * table_width)
129
+ # Show task count
130
+ task_count = len(rows)
131
+ print(f" {task_count} task{'s' if task_count != 1 else ''} available")
132
+ print("=" * table_width)
133
+
134
+ print()
@@ -70,6 +70,9 @@ def create_parser() -> ArgumentParser:
70
70
  ls_parser = subparsers.add_parser(
71
71
  "ls", help="List resources", description="List tasks or runs"
72
72
  )
73
+ # Add arguments from `ls tasks` so that they work with `ls` as default alias
74
+ ls_parser.add_arguments(ls_tasks.Cmd, dest="tasks_alias")
75
+
73
76
  ls_sub = ls_parser.add_subparsers(dest="ls_command", required=False)
74
77
 
75
78
  # ls tasks (default)
@@ -126,12 +129,10 @@ def main() -> None:
126
129
  # Dispatch nested ls subcommands
127
130
  if args.ls_command is None or args.ls_command == "tasks":
128
131
  # Default to tasks when no subcommand specified
129
- if hasattr(args, "tasks"):
130
- args.tasks.execute()
132
+ if hasattr(args, "tasks_alias"):
133
+ args.tasks_alias.execute()
131
134
  else:
132
- # Create default tasks command if not specified
133
- tasks_cmd = ls_tasks.Cmd()
134
- tasks_cmd.execute()
135
+ args.tasks.execute()
135
136
  elif args.ls_command == "runs":
136
137
  args.runs.execute()
137
138
  elif args.command == "export":
@@ -16,8 +16,8 @@
16
16
  # Below is the _next_ version that will be published, not the currently published one.
17
17
  MAJOR = 0
18
18
  MINOR = 1
19
- PATCH = 0
20
- PRE_RELEASE = "rc9"
19
+ PATCH = 1
20
+ PRE_RELEASE = ""
21
21
 
22
22
  # Use the following formatting: (major, minor, patch, pre-release)
23
23
  VERSION = (MAJOR, MINOR, PATCH, PRE_RELEASE)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nemo-evaluator-launcher
3
- Version: 0.1.0rc9
3
+ Version: 0.1.1
4
4
  Summary: Launcher for the evaluations provided by NeMo Evaluator containers with different runtime backends
5
5
  Author: NVIDIA
6
6
  Author-email: nemo-toolkit@nvidia.com
@@ -1,34 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025, NVIDIA CORPORATION. All rights reserved.
2
- # SPDX-License-Identifier: Apache-2.0
3
- #
4
- # Licensed under the Apache License, Version 2.0 (the "License");
5
- # you may not use this file except in compliance with the License.
6
- # You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS,
12
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- # See the License for the specific language governing permissions and
14
- # limitations under the License.
15
- #
16
- import json
17
- from dataclasses import dataclass
18
-
19
- from nemo_evaluator_launcher.api.functional import get_tasks_list
20
-
21
-
22
- @dataclass
23
- class Cmd:
24
- """List command configuration."""
25
-
26
- def execute(self) -> None:
27
- # TODO(dfridman): modify `get_tasks_list` to return a list of dicts in the first place
28
- data = get_tasks_list()
29
- headers = ["task", "endpoint_type", "harness", "container"]
30
- supported_benchmarks = []
31
- for task_data in data:
32
- assert len(task_data) == len(headers)
33
- supported_benchmarks.append(dict(zip(headers, task_data)))
34
- print(json.dumps(supported_benchmarks, indent=2))