Sign In

Solution to the "Missing generation data" error when loading images in Civitai

Solution to the "Missing generation data" error when loading images in Civitai

A problem related to image loading and the occurrence of a "missing generation data" error in a specific context has been identified. This problem appears to be caused by an extension called Neutral Prompt, which adds metadata to the images. Users have observed that when attempting to load images with this extension active, the mentioned error occurs.

In summary, the issue of "missing generation data" when loading images seems to be related to the Neutral Prompt extension and the presence of the Phi character in the image metadata. It has been observed that removing this character does not always fully resolve the problem, indicating the possibility of other underlying factors that could contribute to the occurrence of the error.

To fix the error, the extension should be removed. If you are using Colab and don't want to modify the code where you obtain the files too much, you only need to add the following code in the second half of the code (after all the files have been downloaded, but before you are given the link to access Automatic1111).

Replace this path with the path where the neutral-prompt is saved, which is this (you just need to verify that the stable-diffusion folder is the one being created in Colab) ---> Look at the image tutorial

Verify how your folder is specifically named and replace "stable-diffusion" with its name.

#The program deletes the folder with the extension causing the problem.

import shutil

# Path of the folder you want to delete
folder_to_delete = '/content/stable-diffucion/extensions/neutral-prompt'

# Use the "shutil.rmtree" function to delete the folder and its contents
shutil.rmtree(folder_to_delete)

# Confirm that the folder has been deleted
print(f"The folder {folder_to_delete} has been deleted.")
7

Comments