Conversation
ale/base/data_naif.py
Outdated
| else: | ||
| self._kernels = self._props['kernels'] |
There was a problem hiding this comment.
might be worth checking if it's a dict formatted like a spiceQL kernel set.
There was a problem hiding this comment.
Are you envisioning something that checks the kernel keys against valid kernel type names (like [ck, pck, spk, etc.])?
There was a problem hiding this comment.
Yeah, basically. The easiest thing is probably to try to load it as a kernel set? Might need a function in SpiceQL to check.
ale/drivers/__init__.py
Outdated
| res.instrument_id | ||
| with res as driver: | ||
| isd = formatter(driver) | ||
| if 'remove_kernels' in props and props['remove_kernels'] is True and 'kernels' in isd: |
There was a problem hiding this comment.
might be better for it to be "attach_kernels", having a flag being a often a bit odd.
There was a problem hiding this comment.
Just want to confirm, we want kernels added to ISD as default? We can have attach_kernels be default True and users can explicitly set it to False is they want kernels removed.
There was a problem hiding this comment.
yeah, change to attach_kernels and default to true.
| kernels_dict = {} | ||
| for k in driver.kernels: | ||
| k_split = k.split('/') | ||
| k_type = k_split[2] | ||
| if k_type in kernels_dict and isinstance(kernels_dict[k_type], list): | ||
| kernels_dict[k_type].append(k) | ||
| else: | ||
| kernels_dict.update({k_type: [k]}) |
There was a problem hiding this comment.
I am guessing this is to try to identify the kernel types? Might be best to make that a function in SpiceQL, since SpiceQL can use the Config to identify them more effectively. Short term I think it's fine to leave this here.
Couple things
kernelskey to ISDremove_kernelskey option to for thepropsdict in ale.loads()misckey if user enters their own kernelsLicensing
This project is mostly composed of free and unencumbered software released into the public domain, and we are unlikely to accept contributions that are not also released into the public domain. Somewhere near the top of each file should have these words: