Skip to content

Commit d989527

Browse files
authored
fix: Error when loading Chipper model (#248)
1 parent 870c300 commit d989527

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## 0.7.3-dev1
1+
## 0.7.3-dev2
22

33
* Integration of Chipperv2 and additional Chipper functionality, which includes automatic detection of GPU,
44
bounding box prediction and hierarchical representation.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "0.7.3-dev1" # pragma: no cover
1+
__version__ = "0.7.3-dev2" # pragma: no cover

unstructured_inference/models/chipper.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,14 @@ class UnstructuredChipperModel(UnstructuredElementExtractionModel):
4646
def initialize(
4747
self,
4848
pre_trained_model_repo: str,
49-
swap_head: bool,
50-
swap_head_hidden_layer_size: int,
5149
start_token_prefix: str,
5250
prompt: str,
5351
max_length: int,
5452
heatmap_h: int,
5553
heatmap_w: int,
5654
source: Source,
55+
swap_head: bool = False,
56+
swap_head_hidden_layer_size: int = 0,
5757
no_repeat_ngram_size: int = 10,
5858
auth_token: Optional[str] = os.environ.get("UNSTRUCTURED_HF_TOKEN"),
5959
device: Optional[str] = None,

0 commit comments

Comments
 (0)