GooeyAI / gooey-server

The core orchestration logic behind Gooey.AI
https://gooey.ai
Other
9 stars 2 forks source link

Latest update deforum ux #471

Open clr-li opened 1 month ago

clr-li commented 1 month ago

Asana: https://app.asana.com/0/1203067047205953/1205632871208949

I made a new pr since the old one was very outdated. I did implement the feedback Dev provided in the previous pr.

Q/A checklist


Executed in 1.15 secs fish external usr time 2.22 secs 86.00 micros 2.22 secs sys time 0.72 secs 613.00 micros 0.72 secs

To reduce import times, import libraries that take a long time inside the functions that use them instead of at the top of the file:
```python
def my_function():
    import pandas as pd
    ...

Legal Boilerplate

Look, I get it. The entity doing business as “Gooey.AI” and/or “Dara.network” was incorporated in the State of Delaware in 2020 as Dara Network Inc. and is gonna need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Dara Network Inc can use, modify, copy, and redistribute my contributions, under its choice of terms.

devxpy commented 2 weeks ago

i get this error when i load the page locally

ValueError: not enough values to unpack (expected 2, got 1)
Traceback (most recent call last):
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/Users/dev/Projects/dara/ddgai/./server.py", line 107, in middleware
    await app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/sessions.py", line 86, in __call__
    await self.app(scope, receive, send_wrapper)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/authentication.py", line 48, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 75, in __call__
    raise exc
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 64, in __call__
    await self.app(scope, receive, sender)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 680, in __call__
    await route.handle(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 275, in handle
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 65, in app
    response = await func(request)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/routing.py", line 231, in app
    raw_response = await run_endpoint_function(
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/routing.py", line 162, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "/Users/dev/Projects/dara/gooey-gui/py/gooey_gui/core/renderer.py", line 70, in wrapper
    return renderer(
  File "/Users/dev/Projects/dara/gooey-gui/py/gooey_gui/core/renderer.py", line 117, in renderer
    ret = render()
  File "/Users/dev/Projects/dara/ddgai/routers/root.py", line 615, in recipe_or_handle_or_static
    return render_recipe_page(request, parts[0], RecipeTabs.run, example_id)
  File "/Users/dev/Projects/dara/ddgai/routers/root.py", line 691, in render_recipe_page
    page.render()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 359, in render
    self.render_selected_tab()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 898, in render_selected_tab
    submitted = self._render_input_col()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 1474, in _render_input_col
    self.render_form_v2()
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 374, in render_form_v2
    animation_prompts_editor()
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 159, in animation_prompts_editor
    zoom_dict = get_zoom_pan_dict(gui.session_state.get("zoom", {0: 1.004}))
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 307, in get_zoom_pan_dict
    frame, zoom = pair.split(":(")
ValueError: not enough values to unpack (expected 2, got 1)
clr-li commented 2 weeks ago

i get this error when i load the page locally

ValueError: not enough values to unpack (expected 2, got 1)
Traceback (most recent call last):
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/Users/dev/Projects/dara/ddgai/./server.py", line 107, in middleware
    await app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/sessions.py", line 86, in __call__
    await self.app(scope, receive, send_wrapper)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/authentication.py", line 48, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 75, in __call__
    raise exc
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 64, in __call__
    await self.app(scope, receive, sender)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 680, in __call__
    await route.handle(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 275, in handle
    await self.app(scope, receive, send)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/routing.py", line 65, in app
    response = await func(request)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/routing.py", line 231, in app
    raw_response = await run_endpoint_function(
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/fastapi/routing.py", line 162, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "/Users/dev/.virtualenvs/ddgai-b0692ca2/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "/Users/dev/Projects/dara/gooey-gui/py/gooey_gui/core/renderer.py", line 70, in wrapper
    return renderer(
  File "/Users/dev/Projects/dara/gooey-gui/py/gooey_gui/core/renderer.py", line 117, in renderer
    ret = render()
  File "/Users/dev/Projects/dara/ddgai/routers/root.py", line 615, in recipe_or_handle_or_static
    return render_recipe_page(request, parts[0], RecipeTabs.run, example_id)
  File "/Users/dev/Projects/dara/ddgai/routers/root.py", line 691, in render_recipe_page
    page.render()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 359, in render
    self.render_selected_tab()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 898, in render_selected_tab
    submitted = self._render_input_col()
  File "/Users/dev/Projects/dara/ddgai/./daras_ai_v2/base.py", line 1474, in _render_input_col
    self.render_form_v2()
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 374, in render_form_v2
    animation_prompts_editor()
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 159, in animation_prompts_editor
    zoom_dict = get_zoom_pan_dict(gui.session_state.get("zoom", {0: 1.004}))
  File "/Users/dev/Projects/dara/ddgai/recipes/DeforumSD.py", line 307, in get_zoom_pan_dict
    frame, zoom = pair.split(":(")
ValueError: not enough values to unpack (expected 2, got 1)

Hmm, not sure why that error is happening. I implemented all of your other feedback, maybe it's fixed? If not I can help take a look tomorrow after standup