Esempio n. 1
0
def main():
    print("Create Whoosh index from a directory with JSONs")

    start_time = datetime.datetime.now()

    indexCreator = IndexCreator("data/jsons/")
    indexCreator.create()
    indexCreator.process_files()
    indexCreator.save_index()

    print(
        "Time used to create the index: {0} ".format(datetime.datetime.now() -
                                                     start_time))