Open prabin333 opened 10 months ago
Hi, @prabin333
you should download ViT-B SAM model to ./checkpoints
,
or change this line to the path of ViT-B SAM model. https://github.com/CircleRadon/Osprey/blob/ce786ba5f612de3166039c4a9c196f77352f702c/demo/inference.py#L8
I'm currently using Google Colab. Could you please guide me on where to put the checkpoints folder and other required folders? I have already downloaded the Vit-B, SAM, and CLIP models, and placed them inside the checkpoints folder.
2024-01-18 05:23:43.070875: E external/local_xla/xla/stream_executor/cuda/cuda_dnn.cc:9261] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
2024-01-18 05:23:43.070933: E external/local_xla/xla/stream_executor/cuda/cuda_fft.cc:607] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered
2024-01-18 05:23:43.073035: E external/local_xla/xla/stream_executor/cuda/cuda_blas.cc:1515] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
2024-01-18 05:23:44.112812: W tensorflow/compiler/tf2tensorrt/utils/pyutils.cc:38] TF-TRT Warning: Could not find TensorRT
Traceback (most recent call last):
File "/content/Osprey/demo/app.py", line 19, in
It appears that the path to the CLIP model is incorrect. Based on the error message and the location of your checkpoints, please update this line in the config.json file of Osprey-7b model to reflect the correct path for the CLIP model, i.e., ./checkpoints/open_clip_pytorch_model.bin
.
After modifying the path for the models as per your instructions, a new error is occurring. Could you provide a solution to solve the specific error message?
Downloading shards: 100% 2/2 [06:42<00:00, 201.50s/it] Loading checkpoint shards: 100% 2/2 [00:12<00:00, 6.06s/it] Some weights of the model checkpoint at sunshine-lwt/Osprey-7b were not used when initializing OspreyLlamaForCausalLM: ['model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.25.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.24.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.14.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.15.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.20.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.5.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.19.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.23.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.26.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.9.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.13.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.4.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.18.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.10.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.22.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.3.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.16.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.11.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.7.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.6.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.8.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.21.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.17.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.12.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.2.weight']
do_sample
is set to False
. However, temperature
is set to 0.9
-- this flag is only used in sample-based generation modes. You should set do_sample=True
or unset temperature
. This was detected when initializing the generation config instance, which means the corresponding file may hold incorrect parameterization and should be fixed.
warnings.warn(
/usr/local/lib/python3.10/dist-packages/transformers/generation/configuration_utils.py:394: UserWarning: do_sample
is set to False
. However, top_p
is set to 0.6
-- this flag is only used in sample-based generation modes. You should set do_sample=True
or unset top_p
. This was detected when initializing the generation config instance, which means the corresponding file may hold incorrect parameterization and should be fixed.
warnings.warn(
ERROR: Exception in ASGI application
Traceback (most recent call last):
File "/content/gradio-osprey-demo/gradio/routes.py", line 271, in main
return templates.TemplateResponse(
File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 223, in TemplateResponse
template = self.get_template(name)
File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 137, in get_template
return self.env.get_template(name)
File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 1010, in get_template
return self._load_template(name, globals)
File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 969, in _load_template
template = self.loader.load(self, name, self.make_globals(globals))
File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 125, in load
source, filename, uptodate = self.get_source(environment, name)
File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 204, in get_source
raise TemplateNotFound(template)
jinja2.exceptions.TemplateNotFound: frontend/index.htmlThe above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi result = await app( # type: ignore[func-returns-value] File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in call await super().call(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in call raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in call await self.app(scope, receive, _send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 83, in call await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in call await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 762, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 782, in app await route.handle(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app await wrap_app_handling_exceptions(app, request)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app response = await func(request) File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 299, in app raise e File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 294, in app raw_response = await run_endpoint_function( File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 193, in run_endpoint_function return await run_in_threadpool(dependant.call, *values) File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 40, in run_in_threadpool return await anyio.to_thread.run_sync(func, args) File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/content/gradio-osprey-demo/gradio/routes.py", line 282, in main raise ValueError( ValueError: Did you install Gradio from source files? You need to build the frontend by running /scripts/build_frontend.sh ERROR: Exception in ASGI application Traceback (most recent call last): File "/content/gradio-osprey-demo/gradio/routes.py", line 271, in main return templates.TemplateResponse( File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 223, in TemplateResponse template = self.get_template(name) File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 137, in get_template return self.env.get_template(name) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 1010, in get_template return self._load_template(name, globals) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 969, in _load_template template = self.loader.load(self, name, self.make_globals(globals)) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 125, in load source, filename, uptodate = self.get_source(environment, name) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 204, in get_source raise TemplateNotFound(template) jinja2.exceptions.TemplateNotFound: frontend/index.html
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi result = await app( # type: ignore[func-returns-value] File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in call await super().call(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in call raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in call await self.app(scope, receive, _send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 83, in call await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in call await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 762, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 782, in app await route.handle(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app await wrap_app_handling_exceptions(app, request)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app response = await func(request) File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 299, in app raise e File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 294, in app raw_response = await run_endpoint_function( File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 193, in run_endpoint_function return await run_in_threadpool(dependant.call, *values) File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 40, in run_in_threadpool return await anyio.to_thread.run_sync(func, args) File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/content/gradio-osprey-demo/gradio/routes.py", line 282, in main raise ValueError( ValueError: Did you install Gradio from source files? You need to build the frontend by running /scripts/build_frontend.sh ERROR: Exception in ASGI application Traceback (most recent call last): File "/content/gradio-osprey-demo/gradio/routes.py", line 271, in main return templates.TemplateResponse( File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 223, in TemplateResponse template = self.get_template(name) File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 137, in get_template return self.env.get_template(name) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 1010, in get_template return self._load_template(name, globals) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 969, in _load_template template = self.loader.load(self, name, self.make_globals(globals)) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 125, in load source, filename, uptodate = self.get_source(environment, name) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 204, in get_source raise TemplateNotFound(template) jinja2.exceptions.TemplateNotFound: frontend/index.html
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi result = await app( # type: ignore[func-returns-value] File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in call await super().call(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in call raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in call await self.app(scope, receive, _send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 83, in call await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in call await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 762, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 782, in app await route.handle(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app await wrap_app_handling_exceptions(app, request)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app response = await func(request) File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 299, in app raise e File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 294, in app raw_response = await run_endpoint_function( File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 193, in run_endpoint_function return await run_in_threadpool(dependant.call, *values) File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 40, in run_in_threadpool return await anyio.to_thread.run_sync(func, args) File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/content/gradio-osprey-demo/gradio/routes.py", line 282, in main raise ValueError( ValueError: Did you install Gradio from source files? You need to build the frontend by running /scripts/build_frontend.sh ERROR: Exception in ASGI application Traceback (most recent call last): File "/content/gradio-osprey-demo/gradio/routes.py", line 271, in main return templates.TemplateResponse( File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 223, in TemplateResponse template = self.get_template(name) File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 137, in get_template return self.env.get_template(name) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 1010, in get_template return self._load_template(name, globals) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 969, in _load_template template = self.loader.load(self, name, self.make_globals(globals)) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 125, in load source, filename, uptodate = self.get_source(environment, name) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 204, in get_source raise TemplateNotFound(template) jinja2.exceptions.TemplateNotFound: frontend/index.html
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi result = await app( # type: ignore[func-returns-value] File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in call await super().call(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in call raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in call await self.app(scope, receive, _send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 83, in call await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in call await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 762, in call await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 782, in app await route.handle(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle await self.app(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app await wrap_app_handling_exceptions(app, request)(scope, receive, send) File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app raise exc File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app await app(scope, receive, sender) File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app response = await func(request) File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 299, in app raise e File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 294, in app raw_response = await run_endpoint_function( File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 193, in run_endpoint_function return await run_in_threadpool(dependant.call, *values) File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 40, in run_in_threadpool return await anyio.to_thread.run_sync(func, args) File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/content/gradio-osprey-demo/gradio/routes.py", line 282, in main raise ValueError( ValueError: Did you install Gradio from source files? You need to build the frontend by running /scripts/build_frontend.sh ERROR: Exception in ASGI application Traceback (most recent call last): File "/content/gradio-osprey-demo/gradio/routes.py", line 271, in main return templates.TemplateResponse( File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 223, in TemplateResponse template = self.get_template(name) File "/usr/local/lib/python3.10/dist-packages/starlette/templating.py", line 137, in get_template return self.env.get_template(name) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 1010, in get_template return self._load_template(name, globals) File "/usr/local/lib/python3.10/dist-packages/jinja2/environment.py", line 969, in _load_template template = self.loader.load(self, name, self.make_globals(globals)) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 125, in load source, filename, uptodate = self.get_source(environment, name) File "/usr/local/lib/python3.10/dist-packages/jinja2/loaders.py", line 204, in get_source raise TemplateNotFound(template) jinja2.exceptions.TemplateNotFound: frontend/index.html
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi
result = await app( # type: ignore[func-returns-value]
File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 84, in call
return await self.app(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in call
await super().call(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in call
await self.middleware_stack(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in call
raise exc
File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in call
await self.app(scope, receive, _send)
File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 83, in call
await self.app(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in call
await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app
raise exc
File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app
await app(scope, receive, sender)
File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 762, in call
await self.middleware_stack(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 782, in app
await route.handle(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle
await self.app(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app
await wrap_app_handling_exceptions(app, request)(scope, receive, send)
File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app
raise exc
File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app
await app(scope, receive, sender)
File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app
response = await func(request)
File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 299, in app
raise e
File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 294, in app
raw_response = await run_endpoint_function(
File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 193, in run_endpoint_function
return await run_in_threadpool(dependant.call, *values)
File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 40, in run_in_threadpool
return await anyio.to_thread.run_sync(func, args)
File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
return await future
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run
result = context.run(func, *args)
File "/content/gradio-osprey-demo/gradio/routes.py", line 282, in main
raise ValueError(
ValueError: Did you install Gradio from source files? You need to build the frontend by running /scripts/build_frontend.sh
Traceback (most recent call last):
File "/content/Osprey/demo/app.py", line 501, in
In colab, localhost is not accessible, you can set os.environ["no_proxy"] = "localhost,127.0.0.1,::1”
in colab. I tried it and it works.
import os os.environ["no_proxy"] = "localhost,127.0.0.1,::1"
Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/httpx/_urlparse.py", line 339, in normalize_port port_as_int = int(port) ValueError: invalid literal for int() with base 10: ':1'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/content/Osprey/demo/app.py", line 5, in
34s !python /content/Osprey/demo/app.py --model sunshine-lwt/Osprey-7b output 2024-01-14 16:21:15.919229: E tensorflow/compiler/xla/stream_executor/cuda/cuda_dnn.cc:9342] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered 2024-01-14 16:21:15.919294: E tensorflow/compiler/xla/stream_executor/cuda/cuda_fft.cc:609] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered 2024-01-14 16:21:15.919351: E tensorflow/compiler/xla/stream_executor/cuda/cuda_blas.cc:1518] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered 2024-01-14 16:21:17.052157: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT Loading checkpoint shards: 100% 2/2 [00:12<00:00, 6.40s/it] Some weights of the model checkpoint at sunshine-lwt/Osprey-7b were not used when initializing OspreyLlamaForCausalLM: ['model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.22.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.13.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.3.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.16.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.23.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.5.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.15.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.4.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.9.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.14.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.21.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.17.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.18.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.20.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.11.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.24.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.10.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.25.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.3.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.19.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.8.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.7.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.0.blocks.0.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.6.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.2.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.26.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.1.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.2.blocks.12.weight', 'model.vision_tower.vision_tower.visual.trunk.stages.1.blocks.2.weight']
do_sample
is set toFalse
. However,temperature
is set to0.9
-- this flag is only used in sample-based generation modes. You should setdo_sample=True
or unsettemperature
. This was detected when initializing the generation config instance, which means the corresponding file may hold incorrect parameterization and should be fixed. warnings.warn( /usr/local/lib/python3.10/dist-packages/transformers/generation/configuration_utils.py:394: UserWarning:do_sample
is set toFalse
. However,top_p
is set to0.6
-- this flag is only used in sample-based generation modes. You should setdo_sample=True
or unsettop_p
. This was detected when initializing the generation config instance, which means the corresponding file may hold incorrect parameterization and should be fixed. warnings.warn( Traceback (most recent call last): File "/content/Osprey/demo/app.py", line 20, in