OpenBMB / MiniCPM-V

MiniCPM-V 2.6: A GPT-4V Level MLLM for Single Image, Multi Image and Video on Your Phone
Apache License 2.0
12.75k stars 893 forks source link

[BUG] finetune minicpm error #578

Closed jackyjinjing closed 1 month ago

jackyjinjing commented 2 months ago

是否已有关于该错误的issue或讨论? | Is there an existing issue / discussion for this?

该问题是否在FAQ中有解答? | Is there an existing answer for this in FAQ?

当前行为 | Current Behavior

img_v3_02en_d3458080-6779-4388-b180-c4e60e4f757g

I encountered an error while fine-tuning MinicPM. I found that issue #553 is similar to this one, but it was closed without any fixes, resulting in me encountering this problem as well.

期望行为 | Expected Behavior

no error No response

复现方法 | Steps To Reproduce

run fine-tuning sciprt: sh sh finetune_ds.sh No response

运行环境 | Environment

- OS: 
- Python:3.10.14
- Transformers:4.36.0
- PyTorch:2.1.2
- CUDA (`python -c 'import torch; print(torch.version.cuda)'`):12.1

备注 | Anything else?

No response

LDLINGLINGLING commented 2 months ago

hello ,please show me your dataset json。

jackyjinjing commented 2 months ago

hello ,please show me your dataset json。

Here is the dataset json. I have fixed it locally. Can you help me review the PR #579 ? I see that there are new people encountering this issue.

[
    {
        "id": "0",
        "image": "example.jpg",
        "conversations": [
            {
                "role": "user",
                "content": "<image>\nHow many desserts are on the white plate?"
            },
            {
                "role": "assistant",
                "content": "There are three desserts on the white plate."
            },
            {
                "role": "user",
                "content": "What type of desserts are they?"
            },
            {
                "role": "assistant",
                "content": "The desserts are cakes with bananas and pecans on top. They share similarities with donuts, but the presence of bananas and pecans differentiates them."
            },
            {
                "role": "user",
                "content": "What is the setting of the image?"
            },
            {
                "role": "assistant",
                "content": "The image is set on a table top with a plate containing the three desserts."
            }
        ]
    }
]
qyc-98 commented 1 month ago

We fix the code, please try again. Thanks

natsoe7 commented 1 month ago

@.***

On Wed, Oct 9, 2024, 9:37 AM qianyu chen @.***> wrote:

We fix the code, please try again. Thanks

— Reply to this email directly, view it on GitHub https://github.com/OpenBMB/MiniCPM-V/issues/578#issuecomment-2401177946, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMIIOEAFXQAY22S2BB5H46LZ2SMVNAVCNFSM6AAAAABOG3PLQ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBRGE3TOOJUGY . You are receiving this because you are subscribed to this thread.Message ID: @.***>