split / correctly on non-ubuntu

This commit is contained in:
Georg Kucsko
2023-05-02 10:57:58 -04:00
parent 49b31b2031
commit 29e68a2e1b
+2
View File
@@ -353,6 +353,8 @@ def _load_history_prompt(history_prompt_input):
if isinstance(history_prompt_input, str) and history_prompt_input.endswith(".npz"):
history_prompt = np.load(history_prompt_input)
elif isinstance(history_prompt_input, str):
# make sure this works on non-ubuntu
history_prompt_input = os.path.join(*history_prompt_input.split("/"))
if history_prompt_input not in ALLOWED_PROMPTS:
raise ValueError("history prompt not found")
history_prompt = np.load(