ObjectVision / GeoDMS

Source code for the GeoDMS software
https://www.geodms.nl/
Other
7 stars 1 forks source link

recollect_by_cond(condition, subsetAttr, optional default value) #177

Closed MaartenHilferink closed 1 year ago

MaartenHilferink commented 1 year ago

recollect_by_cond(condition, subsetAttr, fillerValue) should become the inverse of collect_by_cond(condition, orgAttr)

now, a lookup(invert(org_rel), subsetAttr) is required, which requires the calculation and storage of invert(org_rel) whereas org_rel isn't even available when the subset resulted from select_with_attr_by_cond()

Similar to: #164

MaartenHilferink commented 1 year ago

Desired for speeding up Hestia

MaartenHilferink commented 1 year ago

8.8.1 now contains recollect_by_cond(cond: D->Bool, subsetValues: S-.V, fillerValue: ->V) -> (D->V); recollect_with_attr_by_cond, recollect_by_org_rel, and recollect_with_attr_by_org_rel will follow in later versions

MaartenHilferink commented 1 year ago

Alternative form for v8.9:

recollect_by_cond(cond: D->Bool, subsetValues: S->V, backupValue: D->V) -> (D->V);

which is equivalent to MakeDefined(subsetvalues[invert(org_rel)], backupValue) and org_rel equivalent to collect_by_cond(S, cond, ID(D))