Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to generate the npz files for the custom reference dataset? #148

Open
ChongjianGE opened this issue Jun 17, 2024 · 4 comments
Open

How to generate the npz files for the custom reference dataset? #148

ChongjianGE opened this issue Jun 17, 2024 · 4 comments

Comments

@ChongjianGE
Copy link

I notice that the the npz file for the reference images mainly include some information of
mu
sigma
mu_s
sigma_s
mu_clip
sigma_clip
arr_0

Since I am currently considering on generating new reference npz files on my custom dataset, could anyone explain how to generate the above information on a new set of reference images?

@Fushennn
Copy link

I am thinking about it, too. Has it been solved yet?

@TaylorJocelyn
Copy link

I’m experiencing a similar issue. May I ask if you were able to resolve it?

@ZachL1
Copy link

ZachL1 commented Oct 6, 2024

If the FID statistics haven't been calculated for the provided reference batch, the evaluation script will automatically compute them.

see line 172:

obj = np.load(npz_path)
if "mu" in list(obj.keys()):
return FIDStatistics(obj["mu"], obj["sigma"]), FIDStatistics(
obj["mu_s"], obj["sigma_s"]
)
return tuple(self.compute_statistics(x) for x in activations)

@escorciav
Copy link

when dumping your own data use np.savez or np.savez_compressed

for details, refer to:

NpzArrayReader, BatchIterator, StreamingNpzArrayReader, open_npz_array, _open_npy_file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants