Comments (4)
What Python version are you using?
I get the following error:
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/Documents/GitHub/LWM/lwm/vision_generation.py", line 11, in <module>
from tux import (
File "/Documents/GitHub/LWM/venv/lib/python3.11/site-packages/tux/__init__.py", line 6, in <module>
from .distributed import (FlaxTemperatureLogitsWarper, JaxDistributedConfig,
File "/Documents/GitHub/LWM/venv/lib/python3.11/site-packages/tux/distributed.py", line 15, in <module>
from jax.experimental.pjit import \
ImportError: cannot import name 'with_sharding_constraint' from 'jax.experimental.pjit' (/Documents/GitHub/LWM/venv/lib/python3.11/site-packages/jax/experimental/pjit.py)
from lwm.
Was able to make it work as soon as I posted this SMH
Here is what I did.
- Remove the
decord
line fromrequirements.txt
file. Instead installeva-decord
from https://github.com/georgia-tech-db/eva-decord - Update
jax
,chex
,tux
, andflax
to latest version.
pip install jax -U
pip install chex -U
pip install flax -U
pip install tux -U
- Remove the
--mesh_dim='!-1,1,8,1' \
line from therun_sample_video.sh
file.
This was able to make it run on CPU. However, to make it run on the M1 processor was a whole another level of dependencies issues. So I just stopped at that. For someone trying to open and clean the can of worms, start by installing jax-metal
. This will make the script run on apple m1 processor by default and the show begins.
Since the original problem with this issue was resolved, I will let the repo owners decide if they should close this issue or keep it open as it technically doesn't run on the metal architecture.
from lwm.
@Pkoiralap thanks for your info, im using jax-metal, i installed eva-decord and update all libs, remove the mes-dim line, but still i got data type unsuppored error:
jaxlib.xla_extension.XlaRuntimeError: UNKNOWN: <unknown>:0: error: 'func.func' op One or more function input/output data types are not supported.
<unknown>:0: note: see current operation:
"func.func"() <{arg_attrs = [{mhlo.sharding = "{replicated}"}], function_type = (tensor<4096x32000xbf16>) -> tensor<4096x32000xf32>, res_attrs = [{jax.result_info = "", mhlo.sharding = "{replicated}"}], sym_name = "main", sym_visibility = "public"}> ({
^bb0(%arg0: tensor<4096x32000xbf16>):
%0 = "mhlo.convert"(%arg0) : (tensor<4096x32000xbf16>) -> tensor<4096x32000xf32>
"func.return"(%0) : (tensor<4096x32000xf32>) -> ()
}) : () -> ()
<unknown>:0: error: failed to legalize operation 'func.func'
<unknown>:0: note: see current operation:
"func.func"() <{arg_attrs = [{mhlo.sharding = "{replicated}"}], function_type = (tensor<4096x32000xbf16>) -> tensor<4096x32000xf32>, res_attrs = [{jax.result_info = "", mhlo.sharding = "{replicated}"}], sym_name = "main", sym_visibility = "public"}> ({
^bb0(%arg0: tensor<4096x32000xbf16>):
%0 = "mhlo.convert"(%arg0) : (tensor<4096x32000xbf16>) -> tensor<4096x32000xf32>
"func.return"(%0) : (tensor<4096x32000xf32>) -> ()
}) : () -> ()
any ideas? thanks
from lwm.
The code is tested on ubuntu, we are not sure about how well Jax would work on mac.
from lwm.
Related Issues (20)
- error when run run_sample_img.sh HOT 1
- NCCL Error when running the Jax LWM-Chat-32K-Jax HOT 1
- We need API
- How to set the input length parameter to support long context window e.g. 256k inputs? HOT 1
- Example Data for vision language training (What is the format?) HOT 1
- ValueError: bytes is too large when running scripts/run_train_text.sh HOT 1
- LlamaForCausalLM requires the PyTorch library but it was not found in your environment HOT 1
- `model_max_length` why is it 2048? HOT 1
- When will you support text to video in pytorch?
- Getting memory error while running run_vision.sh
- run run_samle_image.sh error
- run run_sample_video.sh config
- pytorch model & ring attention HOT 4
- How to setup conversation with vision chat? HOT 1
- Does support text to image and video geneation training ?
- Request for publicizing the LWM-1K/8K JAX or PyTorch model
- AttributeError: module 'jax.numpy' has no attribute 'DeviceArray' when run sample_video.sh
- RESOURCE_EXHAUSTED: XLA:TPU compile permanent
- DP FSDP & SP
- ValueError: Incompatible shapes for broadcasting: (2, 1, 1, 526464) and requested shape (2, 1, 32768, 32768) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lwm.