Compare commits

...

12 Commits

Author SHA1 Message Date
Xiaomeng Zhao
b231f4493c Merge pull request #3186 from myhloli/dev
fix: update past_key_values handling to support custom sequence lengths
2025-07-27 18:32:39 +08:00
myhloli
4aef8fd168 fix: transformers 4.54.0 adaptation 2025-07-27 18:30:31 +08:00
myhloli
3ff7fee8a6 Merge remote-tracking branch 'origin/dev' into dev 2025-07-27 18:09:33 +08:00
myhloli
0490af1cd7 fix: transformers 4.54.0 adaptation 2025-07-27 18:03:43 +08:00
myhloli
1db99bb403 Merge remote-tracking branch 'origin/dev' into dev 2025-07-27 13:32:17 +08:00
myhloli
4267cfa2c3 chore: update changelog for version 2.1.7 release with transformers 4.54.0 adaptation 2025-07-27 13:31:58 +08:00
myhloli
f6f60b971a fix: update Dockerfile and documentation to use sglang:v0.4.9.post4 base image 2025-07-27 12:57:45 +08:00
myhloli
0f4dbbd0de Merge remote-tracking branch 'origin/dev' into dev 2025-07-26 23:50:40 +08:00
myhloli
e7ed7660e3 fix: update past_key_values handling to support custom sequence lengths 2025-07-26 23:50:29 +08:00
Xiaomeng Zhao
ab02c5943e Merge pull request #3184 from opendatalab/master
master->dev
2025-07-26 05:05:06 +08:00
myhloli
a8d3f789bb Update version.py with new version 2025-07-25 20:59:14 +00:00
Xiaomeng Zhao
9356552a04 Merge pull request #3183 from opendatalab/release-2.1.6
Release 2.1.6
2025-07-26 04:57:28 +08:00
8 changed files with 24 additions and 11 deletions

View File

@@ -43,6 +43,8 @@
</div>
# Changelog
- 2025/07/27 version 2.1.7 Released
- `transformers` 4.54.0 version adaptation
- 2025/07/26 2.1.6 Released
- Fixed table parsing issues in handwritten documents when using `vlm` backend
- Fixed visualization box position drift issue when document is rotated #3175

View File

@@ -43,6 +43,8 @@
</div>
# 更新记录
- 2025/07/27 2.1.7发布
- `transformers` 4.54.0 版本适配
- 2025/07/26 2.1.6发布
- 修复`vlm`后端解析部分手写文档时的表格异常问题
- 修复文档旋转时可视化框位置漂移问题 #3175

View File

@@ -1,7 +1,7 @@
# Use the official sglang image
FROM lmsysorg/sglang:v0.4.9.post3-cu126
FROM lmsysorg/sglang:v0.4.9.post4-cu126
# For blackwell GPU, use the following line instead:
# FROM lmsysorg/sglang:v0.4.9.post3-cu128-b200
# FROM lmsysorg/sglang:v0.4.9.post4-cu128-b200
# Install libgl for opencv support & Noto fonts for Chinese characters
RUN apt-get update && \

View File

@@ -1,7 +1,7 @@
# Use the official sglang image
FROM lmsysorg/sglang:v0.4.9.post3-cu126
FROM lmsysorg/sglang:v0.4.9.post4-cu126
# For blackwell GPU, use the following line instead:
# FROM lmsysorg/sglang:v0.4.9.post3-cu128-b200
# FROM lmsysorg/sglang:v0.4.9.post4-cu128-b200
# Install libgl for opencv support & Noto fonts for Chinese characters
RUN apt-get update && \

View File

@@ -10,8 +10,8 @@ docker build -t mineru-sglang:latest -f Dockerfile .
```
> [!TIP]
> The [Dockerfile](https://github.com/opendatalab/MinerU/blob/master/docker/global/Dockerfile) uses `lmsysorg/sglang:v0.4.9.post3-cu126` as the base image by default, supporting Turing/Ampere/Ada Lovelace/Hopper platforms.
> If you are using the newer `Blackwell` platform, please modify the base image to `lmsysorg/sglang:v0.4.9.post3-cu128-b200` before executing the build operation.
> The [Dockerfile](https://github.com/opendatalab/MinerU/blob/master/docker/global/Dockerfile) uses `lmsysorg/sglang:v0.4.9.post4-cu126` as the base image by default, supporting Turing/Ampere/Ada Lovelace/Hopper platforms.
> If you are using the newer `Blackwell` platform, please modify the base image to `lmsysorg/sglang:v0.4.9.post4-cu128-b200` before executing the build operation.
## Docker Description

View File

@@ -10,8 +10,8 @@ docker build -t mineru-sglang:latest -f Dockerfile .
```
> [!TIP]
> [Dockerfile](https://github.com/opendatalab/MinerU/blob/master/docker/china/Dockerfile)默认使用`lmsysorg/sglang:v0.4.9.post3-cu126`作为基础镜像支持Turing/Ampere/Ada Lovelace/Hopper平台
> 如您使用较新的`Blackwell`平台,请将基础镜像修改为`lmsysorg/sglang:v0.4.9.post3-cu128-b200` 再执行build操作。
> [Dockerfile](https://github.com/opendatalab/MinerU/blob/master/docker/china/Dockerfile)默认使用`lmsysorg/sglang:v0.4.9.post4-cu126`作为基础镜像支持Turing/Ampere/Ada Lovelace/Hopper平台
> 如您使用较新的`Blackwell`平台,请将基础镜像修改为`lmsysorg/sglang:v0.4.9.post4-cu128-b200` 再执行build操作。
## Docker说明

View File

@@ -1416,7 +1416,11 @@ class UnimerMBartDecoder(UnimerMBartPreTrainedModel):
raise ValueError("You have to specify either decoder_input_ids or decoder_inputs_embeds")
# past_key_values_length
past_key_values_length = past_key_values[0][0].shape[2] if past_key_values is not None else 0
# past_key_values_length = past_key_values[0][0].shape[2] if past_key_values is not None else 0
past_key_values_length = 0
if past_key_values is not None:
if isinstance(past_key_values, (list, tuple)) and past_key_values:
past_key_values_length = past_key_values[0][0].shape[2]
if inputs_embeds is None:
inputs_embeds = self.embed_tokens(input_ids)
@@ -1501,7 +1505,12 @@ class UnimerMBartDecoder(UnimerMBartPreTrainedModel):
if dropout_probability < self.layerdrop:
continue
past_key_value = past_key_values[idx] if past_key_values is not None else None
# past_key_value = past_key_values[idx] if past_key_values is not None else None
past_key_value = past_key_values[idx] if (
past_key_values is not None and
isinstance(past_key_values, (list, tuple)) and
idx < len(past_key_values)
) else None
if self.gradient_checkpointing and self.training:
layer_outputs = self._gradient_checkpointing_func(

View File

@@ -1 +1 @@
__version__ = "2.1.5"
__version__ = "2.1.6"