Skip to content

Commit

Permalink
Adds --pad_max flag and relevant docs.
Browse files Browse the repository at this point in the history
It is not plugged into anything yet.

Working on issue CUNY-CL#50.
  • Loading branch information
kylebgorman committed May 29, 2023
1 parent 6023dbc commit 4543c5b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ A non-exhaustive list includes:

- Batch size:
- `--batch_size` (default: `32`)
- `--pad_max` (default: not enabled): gives a consistent batch size
- Regularization:
- `--dropout` (default: `.2`)
- `--label_smoothing` (default: not enabled)
Expand Down
6 changes: 6 additions & 0 deletions yoyodyne/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,12 @@ def main() -> None:
default=defaults.BATCH_SIZE,
help="Batch size. Default: %(default)s.",
)
parser.add_argument(
"--pad_max",
action="store_true",
help="Pads all batches to the same length. Default: False.",
)
parser.add_argument("--no_pad_max", action="store_false", dest="pad_max")
parser.add_argument(
"--patience", type=int, help="Patience for early stopping"
)
Expand Down

0 comments on commit 4543c5b

Please sign in to comment.