Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing --softmax-temperature T #1109

Open
AmitMY opened this issue May 17, 2024 · 1 comment
Open

Missing --softmax-temperature T #1109

AmitMY opened this issue May 17, 2024 · 1 comment

Comments

@AmitMY
Copy link

AmitMY commented May 17, 2024

I would like to sample from my decoder.

The docs say I can:
image

But I get an error:

usage: translate.py [-h] [--config CONFIG] [--input INPUT] [--input-factors INPUT_FACTORS [INPUT_FACTORS ...]] [--json-input] [--output OUTPUT] --models MODELS [MODELS ...]
                    [--checkpoints CHECKPOINTS [CHECKPOINTS ...]] [--nbest-size NBEST_SIZE] [--beam-size BEAM_SIZE] [--greedy] [--beam-search-stop {all,first}]
                    [--batch-size BATCH_SIZE] [--chunk-size CHUNK_SIZE] [--sample [SAMPLE]] [--seed SEED] [--ensemble-mode {linear,log_linear}] [--bucket-width BUCKET_WIDTH]
                    [--max-input-length MAX_INPUT_LENGTH] [--max-output-length-num-stds MAX_OUTPUT_LENGTH_NUM_STDS] [--max-output-length MAX_OUTPUT_LENGTH]
                    [--restrict-lexicon RESTRICT_LEXICON [RESTRICT_LEXICON ...]] [--restrict-lexicon-topk RESTRICT_LEXICON_TOPK] [--skip-nvs] [--nvs-thresh NVS_THRESH]
                    [--strip-unknown-words] [--prevent-unk] [--output-type {translation,score,translation_with_score,translation_with_factors,benchmark,json}]
                    [--length-penalty-alpha LENGTH_PENALTY_ALPHA] [--length-penalty-beta LENGTH_PENALTY_BETA] [--brevity-penalty-type {none,learned,constant}]
                    [--brevity-penalty-weight BREVITY_PENALTY_WEIGHT] [--brevity-penalty-constant-length-ratio BREVITY_PENALTY_CONSTANT_LENGTH_RATIO]
                    [--dtype {None,float32,float16,bfloat16,int8}] [--clamp-to-dtype] [--device-id DEVICE_ID] [--use-cpu] [--env ENV] [--tf32 TF32] [--quiet]
                    [--quiet-secondary-workers] [--no-logfile] [--loglevel {INFO,DEBUG,ERROR}] [--loglevel-secondary-workers {INFO,DEBUG,ERROR}] [--knn-index KNN_INDEX]
                    [--knn-lambda KNN_LAMBDA]
translate.py: error: unrecognized arguments: --softmax-temperature 2.0

Is this supported otherwise?

@mjdenkowski
Copy link
Contributor

Hi Amit,

This was implemented in the old MXNet version of Sockeye. When we updated Sockeye to PyTorch (3.1.0), --softmax-temperature was one of the features we chose not to migrate. If you're interested in taking a look at the MXNet code for this feature, the pull request for that implementation is #869.

Best,
Michael

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants