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
!23
Implement format command
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Implement format command
implement-format-command
into
main
Overview
16
Commits
32
Pipelines
0
Changes
19
Merged
Yoann Schneider
requested to merge
implement-format-command
into
main
2 years ago
Overview
12
Commits
32
Pipelines
0
Changes
19
Expand
Closes
#4 (closed)
0
0
Merge request reports
Compare
main
main (base)
and
latest version
latest version
b1119380
32 commits,
2 years ago
19 files
+
242
−
518
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
19
Search (e.g. *.vue) (Ctrl+P)
dan/datasets/format/__init__.py
+
35
−
0
Options
# -*- coding: utf-8 -*-
"""
Format datasets for training.
"""
from
pathlib
import
Path
from
dan.datasets.format.atr
import
run
def
add_format_parser
(
subcommands
)
->
None
:
parser
=
subcommands
.
add_parser
(
"
format
"
,
description
=
__doc__
,
help
=
__doc__
,
)
parser
.
add_argument
(
"
--dataset
"
,
type
=
Path
,
help
=
"
Path to the exported dataset.
"
,
required
=
True
,
)
parser
.
add_argument
(
"
--image-format
"
,
type
=
str
,
help
=
"
Format under which the images were saved.
"
,
required
=
True
,
)
parser
.
add_argument
(
"
--keep-spaces
"
,
action
=
"
store_true
"
,
help
=
"
Do not remove spaces in transcriptions.
"
,
)
parser
.
set_defaults
(
func
=
run
)
Loading