xizaoqu commited on
Commit
d3d004a
·
1 Parent(s): ae8fd03
Files changed (1) hide show
  1. app.py +6 -14
app.py CHANGED
@@ -184,6 +184,7 @@ memory_frames.append(load_image_as_tensor(DEFAULT_IMAGE))
184
 
185
  @spaces.GPU()
186
  def run_interactive(first_frame, action, first_pose, curr_frame, device):
 
187
  new_frame = worldmem.interactive(first_frame,
188
  action,
189
  first_pose,
@@ -253,20 +254,11 @@ def reset():
253
  return input_history, DEFAULT_IMAGE
254
 
255
  def on_image_click(SELECTED_IMAGE):
256
- global DEFAULT_IMAGE
257
- DEFAULT_IMAGE = SELECTED_IMAGE
258
- reset()
259
- return SELECTED_IMAGE
260
-
261
- # new_frame = runner.run(
262
- # memory_frames[0],
263
- # actions[0],
264
- # poses[0],
265
- # memory_curr_frame,
266
- # device
267
- # )
268
-
269
- # print("first algo frame:", len(algo.frames))
270
 
271
  css = """
272
  h1 {
 
184
 
185
  @spaces.GPU()
186
  def run_interactive(first_frame, action, first_pose, curr_frame, device):
187
+ global worldmem
188
  new_frame = worldmem.interactive(first_frame,
189
  action,
190
  first_pose,
 
254
  return input_history, DEFAULT_IMAGE
255
 
256
  def on_image_click(SELECTED_IMAGE):
257
+ global DEFAULT_IMAGE
258
+ DEFAULT_IMAGE = SELECTED_IMAGE
259
+ reset()
260
+ return SELECTED_IMAGE
261
+
 
 
 
 
 
 
 
 
 
262
 
263
  css = """
264
  h1 {