Details
-
Type:
Bug
-
Status: Won't Fix
-
Resolution: Done
-
Fix Version/s: None
-
Component/s: afw
-
Labels:None
-
Team:Data Release Production
Description
I was running out of memory when using fits files persisted with lsst.afw.table.BaseCatalog with millions of records and relatively narrow rows (a few doubles and ints). The total file sizes were 200Mb - 5Gb, but after reading in with lsst.afw.table.BaseCatalog.readFits() the tables were using 10Gb - 40Gb. This problem makes it impossible to run fgcmcal on any dataset larger than HSC PDR1.
A possible workaround is to copy out the table to numpy arrays, but it is not clear if setting the lsst.afw.table.BaseCatalog to None actually clears the memory. I have attached a test file to the ticket which demonstrates the problem. In this case, it creates a 24Mb fits table that nevertheless takes up ~200Mb of RAM as an lsst.afw.table.BaseCatalog.
I'm calling this Won't Fix. It's a real problem, but if my guess at the cause is right, it's pretty inherent in the afw.table design, and the right solution is to find ways to not use afw.table for very tall, very narrow tables (as I suspect Eli Rykoff has already done).