Traceback (most recent call last):
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 2116, in _compile
    guarded_code, tracer_output = compile_inner(code, one_graph, hooks)
                                  ~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_utils_internal.py", line 114, in wrapper_function
    return function(*args, **kwargs)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 1701, in compile_inner
    result = _compile_inner(code, one_graph, hooks)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 1761, in _compile_inner
    dynamo_output = compile_frame(
        code,
    ...<11 lines>...
        package=package,
    )
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 1598, in compile_frame
    bytecode, tracer_output = transform_code_object(code, transform)
                              ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/bytecode_transformation.py", line 1843, in transform_code_object
    tracer_output = transformations(instructions, code_options)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 1569, in transform
    tracer_output = trace_frame(
        code,
    ...<14 lines>...
        package=package,
    )
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 369, in _fn
    return fn(*args, **kwargs)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 968, in trace_frame
    run_tracer()
    ~~~~~~~~~~^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/convert_frame.py", line 949, in run_tracer
    tracer.run()
    ~~~~~~~~~~^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/symbolic_convert.py", line 2094, in run
    while self.step():
          ~~~~~~~~~^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/symbolic_convert.py", line 1747, in step
    self.dispatch_table[inst.opcode](self, inst)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/symbolic_convert.py", line 5891, in RETURN_VALUE
    self._return(inst)
    ~~~~~~~~~~~~^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/symbolic_convert.py", line 5864, in _return
    all_stack_locals_metadata = self.output.compile_subgraph(
        self,
    ...<4 lines>...
        stack_pops=1 if inst.opname == "RETURN_VALUE" else 0,
    )
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/output_graph.py", line 2318, in compile_subgraph
    instructions, subgraph_pycode = self.compile_and_call_fx_graph(
                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
        tx, pass2.graph_output_vars(), root
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/output_graph.py", line 2993, in compile_and_call_fx_graph
    compiled_fn = self.call_user_compiler(gm, example_inputs)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/output_graph.py", line 3170, in call_user_compiler
    return self._call_user_compiler(gm, example_inputs)
           ~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/output_graph.py", line 3260, in _call_user_compiler
    raise BackendCompilerFailed(
        self.compiler_fn, e, inspect.currentframe()
    ).with_traceback(e.__traceback__) from None
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/output_graph.py", line 3232, in _call_user_compiler
    compiled_fn = compiler_fn(gm, example_inputs)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/_dynamo/repro/after_dynamo.py", line 163, in __call__
    compiled_gm = compiler_fn(gm, example_inputs)
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.venv/lib/python3.13/site-packages/torch/__init__.py", line 3002, in __call__
    return self.compiler_fn(model_, inputs_, **self.kwargs)
           ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aps/Documents/ChatGPT/Job Apps/dynamo-diff/.cache/pilot-worker/model.py", line 23, in recording_backend
    raise RuntimeError("Backend stopped before returning an executable graph")
torch._dynamo.exc.BackendCompilerFailed: backend='recording_backend' raised:
RuntimeError: Backend stopped before returning an executable graph

Set TORCHDYNAMO_VERBOSE=1 for the internal stack trace (please do this especially if you're reporting a bug to PyTorch). For even more developer context, set TORCH_LOGS="+dynamo"

