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

failed on script, am I use the right version? #6

Open
SeekPoint opened this issue Aug 25, 2020 · 1 comment
Open

failed on script, am I use the right version? #6

SeekPoint opened this issue Aug 25, 2020 · 1 comment

Comments

@SeekPoint
Copy link

(.venvpy36) transformers-ner/scripts % bash run_softmax_ner.sh
usage: run_softmax_ner.py [-h] --data_dir DATA_DIR --model_type MODEL_TYPE
--model_name_or_path MODEL_NAME_OR_PATH --output_dir
OUTPUT_DIR [--labels LABELS]
[--config_name CONFIG_NAME]
[--tokenizer_name TOKENIZER_NAME]
[--cache_dir CACHE_DIR]
[--max_seq_length MAX_SEQ_LENGTH] [--do_train]
[--do_eval] [--do_predict]
[--evaluate_during_training] [--do_lower_case]
[--keep_accents] [--strip_accents] [--use_fast]
[--per_gpu_train_batch_size PER_GPU_TRAIN_BATCH_SIZE]
[--per_gpu_eval_batch_size PER_GPU_EVAL_BATCH_SIZE]
[--gradient_accumulation_steps GRADIENT_ACCUMULATION_STEPS]
[--loss_type LOSS_TYPE]
[--learning_rate LEARNING_RATE] [--bert_lr BERT_LR]
[--classifier_lr CLASSIFIER_LR]
[--adv_training {fgm,pgd}]
[--weight_decay WEIGHT_DECAY]
[--adam_epsilon ADAM_EPSILON]
[--max_grad_norm MAX_GRAD_NORM]
[--num_train_epochs NUM_TRAIN_EPOCHS]
[--max_steps MAX_STEPS]
[--warmup_steps WARMUP_STEPS]
[--logging_steps LOGGING_STEPS]
[--eval_all_checkpoints] [--no_cuda]
[--overwrite_output_dir] [--overwrite_cache]
[--seed SEED] [--fp16]
[--fp16_opt_level FP16_OPT_LEVEL]
[--local_rank LOCAL_RANK] [--server_ip SERVER_IP]
[--server_port SERVER_PORT]
run_softmax_ner.py: error: argument --data_dir: expected one argument

@liuyukid
Copy link
Owner

You need to specify the values of the following variables:
DATA_DIR=''
MODEL_TYPE=''
MODEL_NAME_OR_PATH=''
OUTPUT_DIR=''
LABEL=''

For example
DATA_DIR='../datasets/conll2003'
MODEL_TYPE='bert'
MODEL_NAME_OR_PATH='../pretrained_models/bert_base_cased'
OUTPUT_DIR='../output/conll2003/bert'
LABEL='../datasets/conll2003/labels.txt'

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