prompt_search_engine / core /initialization.py
krstakis's picture
fixed imports and back to multistaging
63a3ec4
raw
history blame
457 Bytes
import dill
from .search_engine import PromptSearchEngine
from .data.dataset import PromptDataset
def run():
"""
TODO
"""
prompt_dataset = PromptDataset("Gustavosta/Stable-Diffusion-Prompts")
prompt_dataset.load()
prompts = prompt_dataset.get_prompts()
engine = PromptSearchEngine(prompts)
serialized_engine = dill.dumps(engine)
with open("engine.pickle", "wb") as file:
file.write(serialized_engine)
run()