Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
DAN
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Container Registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Automatic Text Recognition
DAN
Merge requests
!287
Something went wrong on our end
Support subword and word language models
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Support subword and word language models
subword-and-word-lm
into
main
Overview
34
Commits
47
Pipelines
0
Changes
1
Merged
Solene Tarride
requested to merge
subword-and-word-lm
into
main
1 year ago
Overview
14
Commits
47
Pipelines
0
Changes
1
Expand
Closes
#199 (closed)
Ref
https://redmine.teklia.com/issues/4941
0
0
Merge request reports
Viewing commit
f0e15553
Show latest version
1 file
+
1
−
1
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
f0e15553
Replace linebreaks with spaces for LM
· f0e15553
Solene Tarride
authored
1 year ago
dan/datasets/extract/extract.py
+
1
−
1
Options
@@ -370,7 +370,7 @@ class ArkindexExtractor:
),
"
Tokens should be single characters.
"
# Build LM corpus
train_corpus
=
[
text
for
text
in
self
.
data
[
"
train
"
].
values
()]
train_corpus
=
[
text
.
replace
(
"
\n
"
,
"
"
)
for
text
in
self
.
data
[
"
train
"
].
values
()]
tokenizer
=
Tokenizer
(
train_corpus
,
outdir
=
self
.
output
/
"
language_model
"
,
Loading