Skip to content

Error while finding module specification for 'flexrag.entypoints.prepare_index' (ModuleNotFoundError: No module named 'flexrag.entypoints') #8

@successhaha

Description

@successhaha

你好,在运行flexrag的代码时,报错。
运行代码如下

#!/bin/bash

set -euo pipefail

DEVICE_ID='[0,1,2,3]'
ENCODER_PATH='intfloat/e5-base-v2'

wget https://dl.fbaipublicfiles.com/dpr/wikipedia_split/psgs_w100.tsv.gz
gunzip psgs_w100.tsv.gz

python -m flexrag.entypoints.prepare_index
retriever_type=dense
corpus_path=[psgs_w100.tsv]
saving_fields=[id,title,text]
text_process_pipeline.processor_type=[length_filter]
text_process_pipeline.length_filter_config.max_chars=4096
text_process_pipeline.length_filter_config.min_chars=10
text_process_fields=[text]
dense_config.database_path=wiki
dense_config.encode_fields=[text]
dense_config.passage_encoder_config.encoder_type=hf
dense_config.passage_encoder_config.hf_config.model_path=$ENCODER_PATH
dense_config.passage_encoder_config.hf_config.prompt='query: '
dense_config.passage_encoder_config.hf_config.normalize=True
dense_config.passage_encoder_config.hf_config.device_id=$DEVICE_ID
dense_config.index_type=faiss
dense_config.faiss_config.batch_size=12288
dense_config.faiss_config.log_interval=100000
dense_config.batch_size=5376
dense_config.log_interval=100000
报错内容
Error while finding module specification for 'flexrag.entypoints.prepare_index' (ModuleNotFoundError: No module named 'flexrag.entypoints')

希望能提供一些解决思考,感谢!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions