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

SDXL: index 21 is out of bounds for dimension 0 with size 21 #1917

Open
zixianwang2022 opened this issue Nov 12, 2024 · 3 comments
Open

SDXL: index 21 is out of bounds for dimension 0 with size 21 #1917

zixianwang2022 opened this issue Nov 12, 2024 · 3 comments

Comments

@zixianwang2022
Copy link

Hi,

Run command:

python3 main.py --dataset "coco-1024" --dataset-path coco2014 --profile stable-diffusion-xl-pytorch --model-path /work1/zixian/ziw081/CM/models/SDXL/official_pytorch/fp16/stable_diffusion_fp16/ --dtype fp16 --device cuda --time 30 --scenario Offline --threads 2

When I am running with --threads>1, we are seeing

ERROR:main:thread: failed on contentid=['/work1/zixian/ziw081/inference/text_to_image/coco2014/validation/data/COCO_val2014_000000386589.jpg'], index 21 is out of bounds for dimension 0 with size 21

I saw similar event here: #1519 (comment) , but there's no actual solutions posted regarding this error.

We believed that it was a direct cause of threading.Thread of the source code.

@arjunsuresh
Copy link
Contributor

Hi @zixianwang2022, yes improving the code for multi-threading can be a useful change but that's unlikely to improve the performance.

@zixianwang2022
Copy link
Author

Hi @zixianwang2022, yes improving the code for multi-threading can be a useful change but that's unlikely to improve the performance.

Hello @arjunsuresh ,

When we have --threads>1, we are seeing a significant improvement in terms of performance. However, the run isn't valid as it is not passing the accuracy test for the above error. Are you aware of any changes that can avoid getting the error?

@arjunsuresh
Copy link
Contributor

@zixianwang2022 unfortunately no. Since the performance was expected using 1 thread we haven't checked the reference implementation since.

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

2 participants