Closed kanghyunyu closed 3 months ago
eICU has hundreds of units for medication dosage, which is why I did not provide the dose_unit_conversion dictionnary nor support for drug dosage in eICU.
However it should not raise an Error, I'm fixing this as soon as I can.
As an instant fix, replacing
exprs = []
if self.dose_unit_conversion_dic is None:
return exprs
by
exprs = []
if self.dose_unit_conversion_dic is None:
return exprs, {}
Should be fine.
Please tell me if this fixes the issue, I can't run the codes at the moment.
I see. This works (although sink_parquet fails for medication and gets diverted to pl.writing. Hope that's normal).
For medications it should not be too problematic to do pl.write_parquet
because tables size remain reasonable.
I was a lot more focused on enabling sinking for larger tables to avoid memory error.
thanks for contributing, I'll push the change asap Matthieu
Great, thanks for all the work!
Unlike other datasets, eICU seems to be missing the variable "dose_unit_conversions" in "eicupreparator.py".
Is this meant to be? It ends up raising "ValueError: not enough values to unpack (expected 2, got 0)" in "newmedicationprocessor.py", as the return value for "self.dose_unit_expressions, self.dose_unit_replacements = self._dose_unit_expressions()" is an empty list.