Skip to content

Commit

Permalink
update docs with mdi_plus index
Browse files Browse the repository at this point in the history
  • Loading branch information
csinva committed May 25, 2024
1 parent 245f019 commit 3ca2544
Show file tree
Hide file tree
Showing 65 changed files with 6,548 additions and 1,097 deletions.
916 changes: 640 additions & 276 deletions docs/algebraic/gam_multitask.html

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions docs/algebraic/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ <h2 class="section-title" id="header-submodules">Sub-modules</h2>
<dd>
<div class="desc"></div>
</dd>
<dt><code class="name"><a title="imodels.algebraic.tree_gam_minimal" href="tree_gam_minimal.html">imodels.algebraic.tree_gam_minimal</a></code></dt>
<dd>
<div class="desc"></div>
</dd>
</dl>
</section>
<section>
Expand All @@ -69,6 +73,7 @@ <h1>Index 🔍</h1>
<ul>
<li><a href="https://csinva.io/imodels/shrinkage.html">Hierarchical shrinkage: post-hoc regularization for tree-based methods</a></li>
<li><a href="https://csinva.io/imodels/figs.html">FIGS: Fast interpretable greedy-tree sums</a></li>
<li><a href="https://csinva.io/imodels/mdi_plus.html">MDI+: Flexible tree-based feature importance</a></li>
</ul>
</li>
<li><h3><a href="#header-submodules">Sub-modules</a></h3>
Expand All @@ -77,6 +82,7 @@ <h1>Index 🔍</h1>
<li><code><a title="imodels.algebraic.marginal_shrinkage_linear_model" href="marginal_shrinkage_linear_model.html">imodels.algebraic.marginal_shrinkage_linear_model</a></code></li>
<li><code><a title="imodels.algebraic.slim" href="slim.html">imodels.algebraic.slim</a></code></li>
<li><code><a title="imodels.algebraic.tree_gam" href="tree_gam.html">imodels.algebraic.tree_gam</a></code></li>
<li><code><a title="imodels.algebraic.tree_gam_minimal" href="tree_gam_minimal.html">imodels.algebraic.tree_gam_minimal</a></code></li>
</ul>
</li>
</ul>
Expand Down
145 changes: 115 additions & 30 deletions docs/algebraic/marginal_shrinkage_linear_model.html
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ <h2 id="returns">Returns</h2>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def func(**kw):
<pre><code class="python">def func(*args, **kw):
&#34;&#34;&#34;Updates the request for provided parameters

This docstring is overwritten below.
Expand All @@ -481,19 +481,36 @@ <h2 id="returns">Returns</h2>

if self.validate_keys and (set(kw) - set(self.keys)):
raise TypeError(
f&#34;Unexpected args: {set(kw) - set(self.keys)}. Accepted arguments&#34;
f&#34; are: {set(self.keys)}&#34;
f&#34;Unexpected args: {set(kw) - set(self.keys)} in {self.name}. &#34;
f&#34;Accepted arguments are: {set(self.keys)}&#34;
)

requests = instance._get_metadata_request()
# This makes it possible to use the decorated method as an unbound method,
# for instance when monkeypatching.
# https://github.com/scikit-learn/scikit-learn/issues/28632
if instance is None:
_instance = args[0]
args = args[1:]
else:
_instance = instance

# Replicating python&#39;s behavior when positional args are given other than
# `self`, and `self` is only allowed if this method is unbound.
if args:
raise TypeError(
f&#34;set_{self.name}_request() takes 0 positional argument but&#34;
f&#34; {len(args)} were given&#34;
)

requests = _instance._get_metadata_request()
method_metadata_request = getattr(requests, self.name)

for prop, alias in kw.items():
if alias is not UNCHANGED:
method_metadata_request.add_request(param=prop, alias=alias)
instance._metadata_request = requests
_instance._metadata_request = requests

return instance</code></pre>
return _instance</code></pre>
</details>
</dd>
</dl>
Expand Down Expand Up @@ -691,7 +708,7 @@ <h2 id="returns">Returns</h2>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def func(**kw):
<pre><code class="python">def func(*args, **kw):
&#34;&#34;&#34;Updates the request for provided parameters

This docstring is overwritten below.
Expand All @@ -706,19 +723,36 @@ <h2 id="returns">Returns</h2>

if self.validate_keys and (set(kw) - set(self.keys)):
raise TypeError(
f&#34;Unexpected args: {set(kw) - set(self.keys)}. Accepted arguments&#34;
f&#34; are: {set(self.keys)}&#34;
f&#34;Unexpected args: {set(kw) - set(self.keys)} in {self.name}. &#34;
f&#34;Accepted arguments are: {set(self.keys)}&#34;
)

requests = instance._get_metadata_request()
# This makes it possible to use the decorated method as an unbound method,
# for instance when monkeypatching.
# https://github.com/scikit-learn/scikit-learn/issues/28632
if instance is None:
_instance = args[0]
args = args[1:]
else:
_instance = instance

# Replicating python&#39;s behavior when positional args are given other than
# `self`, and `self` is only allowed if this method is unbound.
if args:
raise TypeError(
f&#34;set_{self.name}_request() takes 0 positional argument but&#34;
f&#34; {len(args)} were given&#34;
)

requests = _instance._get_metadata_request()
method_metadata_request = getattr(requests, self.name)

for prop, alias in kw.items():
if alias is not UNCHANGED:
method_metadata_request.add_request(param=prop, alias=alias)
instance._metadata_request = requests
_instance._metadata_request = requests

return instance</code></pre>
return _instance</code></pre>
</details>
</dd>
</dl>
Expand Down Expand Up @@ -798,7 +832,7 @@ <h2 id="returns">Returns</h2>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def func(**kw):
<pre><code class="python">def func(*args, **kw):
&#34;&#34;&#34;Updates the request for provided parameters

This docstring is overwritten below.
Expand All @@ -813,19 +847,36 @@ <h2 id="returns">Returns</h2>

if self.validate_keys and (set(kw) - set(self.keys)):
raise TypeError(
f&#34;Unexpected args: {set(kw) - set(self.keys)}. Accepted arguments&#34;
f&#34; are: {set(self.keys)}&#34;
f&#34;Unexpected args: {set(kw) - set(self.keys)} in {self.name}. &#34;
f&#34;Accepted arguments are: {set(self.keys)}&#34;
)

requests = instance._get_metadata_request()
# This makes it possible to use the decorated method as an unbound method,
# for instance when monkeypatching.
# https://github.com/scikit-learn/scikit-learn/issues/28632
if instance is None:
_instance = args[0]
args = args[1:]
else:
_instance = instance

# Replicating python&#39;s behavior when positional args are given other than
# `self`, and `self` is only allowed if this method is unbound.
if args:
raise TypeError(
f&#34;set_{self.name}_request() takes 0 positional argument but&#34;
f&#34; {len(args)} were given&#34;
)

requests = _instance._get_metadata_request()
method_metadata_request = getattr(requests, self.name)

for prop, alias in kw.items():
if alias is not UNCHANGED:
method_metadata_request.add_request(param=prop, alias=alias)
instance._metadata_request = requests
_instance._metadata_request = requests

return instance</code></pre>
return _instance</code></pre>
</details>
</dd>
</dl>
Expand Down Expand Up @@ -1165,7 +1216,7 @@ <h2 id="returns">Returns</h2>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def func(**kw):
<pre><code class="python">def func(*args, **kw):
&#34;&#34;&#34;Updates the request for provided parameters

This docstring is overwritten below.
Expand All @@ -1180,19 +1231,36 @@ <h2 id="returns">Returns</h2>

if self.validate_keys and (set(kw) - set(self.keys)):
raise TypeError(
f&#34;Unexpected args: {set(kw) - set(self.keys)}. Accepted arguments&#34;
f&#34; are: {set(self.keys)}&#34;
f&#34;Unexpected args: {set(kw) - set(self.keys)} in {self.name}. &#34;
f&#34;Accepted arguments are: {set(self.keys)}&#34;
)

# This makes it possible to use the decorated method as an unbound method,
# for instance when monkeypatching.
# https://github.com/scikit-learn/scikit-learn/issues/28632
if instance is None:
_instance = args[0]
args = args[1:]
else:
_instance = instance

# Replicating python&#39;s behavior when positional args are given other than
# `self`, and `self` is only allowed if this method is unbound.
if args:
raise TypeError(
f&#34;set_{self.name}_request() takes 0 positional argument but&#34;
f&#34; {len(args)} were given&#34;
)

requests = instance._get_metadata_request()
requests = _instance._get_metadata_request()
method_metadata_request = getattr(requests, self.name)

for prop, alias in kw.items():
if alias is not UNCHANGED:
method_metadata_request.add_request(param=prop, alias=alias)
instance._metadata_request = requests
_instance._metadata_request = requests

return instance</code></pre>
return _instance</code></pre>
</details>
</dd>
</dl>
Expand Down Expand Up @@ -1291,7 +1359,7 @@ <h2 id="returns">Returns</h2>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def func(**kw):
<pre><code class="python">def func(*args, **kw):
&#34;&#34;&#34;Updates the request for provided parameters

This docstring is overwritten below.
Expand All @@ -1306,19 +1374,36 @@ <h2 id="returns">Returns</h2>

if self.validate_keys and (set(kw) - set(self.keys)):
raise TypeError(
f&#34;Unexpected args: {set(kw) - set(self.keys)}. Accepted arguments&#34;
f&#34; are: {set(self.keys)}&#34;
f&#34;Unexpected args: {set(kw) - set(self.keys)} in {self.name}. &#34;
f&#34;Accepted arguments are: {set(self.keys)}&#34;
)

# This makes it possible to use the decorated method as an unbound method,
# for instance when monkeypatching.
# https://github.com/scikit-learn/scikit-learn/issues/28632
if instance is None:
_instance = args[0]
args = args[1:]
else:
_instance = instance

# Replicating python&#39;s behavior when positional args are given other than
# `self`, and `self` is only allowed if this method is unbound.
if args:
raise TypeError(
f&#34;set_{self.name}_request() takes 0 positional argument but&#34;
f&#34; {len(args)} were given&#34;
)

requests = instance._get_metadata_request()
requests = _instance._get_metadata_request()
method_metadata_request = getattr(requests, self.name)

for prop, alias in kw.items():
if alias is not UNCHANGED:
method_metadata_request.add_request(param=prop, alias=alias)
instance._metadata_request = requests
_instance._metadata_request = requests

return instance</code></pre>
return _instance</code></pre>
</details>
</dd>
</dl>
Expand Down

0 comments on commit 3ca2544

Please sign in to comment.