Skip to content
This repository has been archived by the owner on Oct 31, 2023. It is now read-only.

extract features Infersent error #154

Open
elidabiri628 opened this issue Aug 7, 2023 · 1 comment
Open

extract features Infersent error #154

elidabiri628 opened this issue Aug 7, 2023 · 1 comment

Comments

@elidabiri628
Copy link

why that code doesn't work?
I receive this message:
all of arguments are required after this step in the last line

I was busy with it for 2 months and now I don't know how to fix it
I will be very appreciate if you answer me
thanks a lot

parser.add_argument('-g', '--w2v_path', type=str, required=True,
                    help='Path to word vector file')
parser.add_argument('-v', '--version', type=int, required=True,
                    help='Version of InferSent (GloVe-V1 or fastText-V2)')
parser.add_argument('-f', '--model_path', type=str, required=True,
                    help='Path to pretrained .pkl model file')
parser.add_argument('-t', '--tokenize', action='store_true',
                    help='Passes tokenize=True to build_vocab()')
parser.add_argument('-o', '--out-dir', type=str, required=True,
                    help='Output folder to save feature files')
parser.add_argument('-c', '--cpu', action='store_true',
                    help='Use CPU instead of GPU.')
parser.add_argument('-b', '--batch-size', type=int, default=64,
                    help='Batch size (default: 64)')
parser.add_argument('files', nargs='+',
                    help='List of files to extract sentence embeddings')

args = parser.parse_args()
@elidabiri628
Copy link
Author

usage: extract-features [-h] -g W2V_PATH -v VERSION -f MODEL_PATH [-t] -o
OUT_DIR [-c] [-b BATCH_SIZE]
files [files ...]
extract-features: error: the following arguments are required: -g/--w2v_path, -v/--version, -o/--out-dir, files
An exception has occurred, use %tb to see the full traceback.

this is the error message

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

No branches or pull requests

1 participant