File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -162,7 +162,7 @@ def _get_reference_outputs(
162
162
163
163
def _get_representative_inputs (
164
164
bundled_program : BundledProgram ,
165
- ) -> List [ProgramInput ]:
165
+ ) -> Optional [ List [ProgramInput ] ]:
166
166
"""
167
167
Extracts out the inputs from the bundled program, keyed by the method names.
168
168
"""
@@ -175,7 +175,9 @@ def _get_representative_inputs(
175
175
# Get first example input from the forward method
176
176
test_case = method_test_suite .test_cases [0 ]
177
177
return test_case .inputs
178
- raise ValueError ("No 'forward' method found in the bundled program." )
178
+
179
+ # If the forward method is not defined, return None to indicate that there are no representative inputs for the model.
180
+ return None
179
181
180
182
181
183
def generate_etrecord (
You can’t perform that action at this time.
0 commit comments