pzivich / Delicatessen

Delicatessen: the Python one-stop sandwich (variance) shop 🥪
https://deli.readthedocs.io/en/latest/index.html
MIT License
22 stars 2 forks source link

v0.5 #12

Closed pzivich closed 2 years ago

pzivich commented 2 years ago

v0.5 branch

This branch proposes a new functionality, subset.

The subset argument allows a user to only run the root-finding procedure on a subset of the provided parameters. This feature is intended for the use of layered estimating equations, where pieces can be optimized outside (or pre-washed) of the stacked estimating equations. An example would be the propensity score for the IPW mean.

pzivich commented 2 years ago

I thought the subset process would be faster to run, but it is actually slower (possibly due to the extra logic). This is different from what I was hoping (I was hoping it would be faster). However, I still think there are use-cases for this feature.

Goal would be to try to sharpen the internal function logic to speed up this version

pzivich commented 2 years ago

Items to fix in RTD

pzivich commented 2 years ago

After a bit more exploring, I figured out one trick to reduce the runtime (convert to np.array instead of a list). However, a benefit doesn't become apparent until there are lots of additional parameters. Before that point, subset is slower (which I think is fine for the actual use-cases of subset)