style-based-gan-pytorch icon indicating copy to clipboard operation
style-based-gan-pytorch copied to clipboard

What does the map_size mean in lmdb.open in prepare_data.py? If I want to change the max resolution to 128, should I change map_size = 1024 ** 4 to map_size = 128 ** 4?

Open code-roamer opened this issue 4 years ago • 3 comments

code-roamer avatar Dec 23 '20 01:12 code-roamer

It is memory map sizes for LMDB. Generally you don't need to change it.

rosinality avatar Dec 23 '20 04:12 rosinality

Hello,

Thank you very much for the code. I have a question regarding database prep. I don't have enough memory (I get allocation error for map_size = 1024 ** 4 but works for map_size = 256 ** 4) and I have to reduce img size to 256. What should be changed in this case?

Thanks

gabrieloks avatar Oct 25 '22 12:10 gabrieloks

It is hard to know actual image sizes as images are saved as a jpeg. But bounds will be 256 * 256 * 3 * number of images bytes.

rosinality avatar Nov 02 '22 06:11 rosinality