Definition at line 60 of file burca_tailor.py.
Inherits lalburst.snglcoinc.LnLRDensity.
Public Member Functions | |
| def | __init__ (self, instruments) |
| def | __call__ (self, **params) |
| Evaluate. More... | |
| def | __iadd__ (self, other) |
| Marginalize the two densities. More... | |
| def | increment (self, params, weight=1.0) |
| Increment the counts defining this density at the given parameters. More... | |
| def | copy (self) |
| Return a duplicate copy of this object. More... | |
| def | mkinterps (self) |
| def | finish (self) |
| Ensure all internal densities are normalized, and initialize interpolator objects as needed for smooth evaluation. More... | |
| def | to_xml (self, name) |
| Serialize to an XML fragment and return the root element of the resulting XML tree. More... | |
| def | from_xml (cls, xml, name) |
| In the XML document tree rooted at xml, search for the serialized LnLRDensity object named name, and deserialize it. More... | |
Public Member Functions inherited from lalburst.snglcoinc.LnLRDensity | |
| def | __call__ (self, *args, **kwargs) |
| Evaluate. More... | |
| def | __iadd__ (self, other) |
| Marginalize the two densities. More... | |
| def | increment (self, *args, **kwargs) |
| Increment the counts defining this density at the given parameters. More... | |
| def | copy (self) |
| Return a duplicate copy of this object. More... | |
| def | finish (self) |
| Ensure all internal densities are normalized, and initialize interpolator objects as needed for smooth evaluation. More... | |
| def | samples (self) |
| Generator returning a sequence of parameter values drawn from the distribution density. More... | |
| def | to_xml (self, name) |
| Serialize to an XML fragment and return the root element of the resulting XML tree. More... | |
| def | get_xml_root (cls, xml, name) |
| Sub-classes can use this in their overrides of the .from_xml() method to find the root element of the XML serialization. More... | |
| def | from_xml (cls, xml, name) |
| In the XML document tree rooted at xml, search for the serialized LnLRDensity object named name, and deserialize it. More... | |
Data Fields | |
| densities | |
| interps | |
| def lalburst.burca_tailor.LnLRDensity.__init__ | ( | self, | |
| instruments | |||
| ) |
Definition at line 61 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.__call__ | ( | self, | |
| ** | args | ||
| ) |
Evaluate.
Return the natural logarithm of the density evaluated at the given parameters.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 73 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.__iadd__ | ( | self, | |
| other | |||
| ) |
Marginalize the two densities.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 81 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.increment | ( | self, | |
| args, | |||
kwargs = 1.0 |
|||
| ) |
Increment the counts defining this density at the given parameters.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 89 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.copy | ( | self | ) |
Return a duplicate copy of this object.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 93 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.mkinterps | ( | self | ) |
Definition at line 99 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.finish | ( | self | ) |
Ensure all internal densities are normalized, and initialize interpolator objects as needed for smooth evaluation.
Must be invoked before .__call__() will yield sensible results.
NOTE: for some implementations this operation will irreversibly alter the contents of the counts array, for example often this operation will involve the convolution of the counts with a density estimation kernel. If it is necessary to preserve a pristine copy of the counts data, use the .copy() method to obtain a copy of the data, first, and then .finish() the copy.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 102 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.to_xml | ( | self, | |
| name | |||
| ) |
Serialize to an XML fragment and return the root element of the resulting XML tree.
Subclasses must chain to this method, then customize the return value as needed.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 108 of file burca_tailor.py.
| def lalburst.burca_tailor.LnLRDensity.from_xml | ( | cls, | |
| xml, | |||
| name | |||
| ) |
In the XML document tree rooted at xml, search for the serialized LnLRDensity object named name, and deserialize it.
The return value is the deserialized LnLRDensity object.
Reimplemented from lalburst.snglcoinc.LnLRDensity.
Definition at line 118 of file burca_tailor.py.
| lalburst.burca_tailor.LnLRDensity.densities |
Definition at line 62 of file burca_tailor.py.
| lalburst.burca_tailor.LnLRDensity.interps |
Definition at line 100 of file burca_tailor.py.