box-embeddings icon indicating copy to clipboard operation
box-embeddings copied to clipboard

Consolidate all volume and intersection functions

Open mboratko opened this issue 5 years ago • 5 comments

I think it would make sense to consolidate all volume (and intersection) functions into a single one, where if the variance is zero we revert to the "hard" versions of these functions.

mboratko avatar Nov 16 '20 03:11 mboratko

Do we want to unify all intersections and Volumes under single function? Or do we have 'if conditions' inside each one to revert to hard version based on beta value?

dhruvdcoder avatar Nov 16 '20 03:11 dhruvdcoder

I meant the latter.

Note that this is a situation where the functional interface and class-based interface can (and should) actually be different. For example, the functional interface will include an "if" statement based on the variance (for example), but a class will assign the correct branch during initialization.

(Maybe this is a premature optimization though.)

mboratko avatar Nov 18 '20 21:11 mboratko

We can leave this open and come back to it when we have a better idea about whether the optimization is needed or not.

dhruvdcoder avatar Nov 18 '20 21:11 dhruvdcoder

Add an example in the usage example notebooks.

dhruvdcoder avatar Jul 08 '21 14:07 dhruvdcoder

Trang will address this in the upcoming PR

trangtran72 avatar Jul 22 '21 14:07 trangtran72