Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

with model mistralai/Mixtral-8x7B-Instruct-v0.1- (🌍, 4bit) errors #29

Open
shanghailiwei opened this issue Mar 2, 2024 · 2 comments

Comments

@shanghailiwei
Copy link

Traceback (most recent call last):
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/chat_interface.py", line 490, in _stream_fn
first_response = await async_iteration(generator)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 514, in async_iteration
return await iterator.anext()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 507, in anext
return await anyio.to_thread.run_sync(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/anyio/to_thread.py", line 56, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 2144, in run_sync_in_worker_thread
return await future
^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 851, in run
result = context.run(func, *args)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 493, in run_sync_iterator_async
raise StopAsyncIteration() from None
StopAsyncIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/queueing.py", line 495, in call_prediction
output = await route_utils.call_process_api(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/route_utils.py", line 235, in call_process_api
output = await app.get_blocks().process_api(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/blocks.py", line 1627, in process_api
result = await self.call_function(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/blocks.py", line 1185, in call_function
prediction = await utils.async_iteration(iterator)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 514, in async_iteration
return await iterator.anext()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/liwei/miniconda3/envs/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 640, in asyncgen_wrapper
response = await iterator.anext()
^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: async generator raised StopAsyncIteration

@qnguyen3
Copy link
Owner

qnguyen3 commented Mar 2, 2024

Hello @shanghailiwei , can you give me the spec of your macbook?

@kane-le
Copy link

kane-le commented Mar 25, 2024

I meet the same problem

MacbookPro M3
Memory 24GB
macOS Sonoma 14.4 (23E214)
python 3.11.6

图片
Traceback (most recent call last):
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/chat_interface.py", line 544, in _stream_fn
    first_response = await async_iteration(generator)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 517, in async_iteration
    return await iterator.__anext__()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 510, in __anext__
    return await anyio.to_thread.run_sync(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/anyio/to_thread.py", line 56, in run_sync
    return await get_async_backend().run_sync_in_worker_thread(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 2144, in run_sync_in_worker_thread
    return await future
           ^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 851, in run
    result = context.run(func, *args)
             ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 496, in run_sync_iterator_async
    raise StopAsyncIteration() from None
StopAsyncIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/queueing.py", line 501, in call_prediction
    output = await route_utils.call_process_api(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/route_utils.py", line 258, in call_process_api
    output = await app.get_blocks().process_api(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/blocks.py", line 1710, in process_api
    result = await self.call_function(
             ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/blocks.py", line 1262, in call_function
    prediction = await utils.async_iteration(iterator)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 517, in async_iteration
    return await iterator.__anext__()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/kane/.pyenv/versions/mlx-chat/lib/python3.11/site-packages/gradio/utils.py", line 643, in asyncgen_wrapper
    response = await iterator.__anext__()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: async generator raised StopAsyncIteration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants