Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jph00 committed Dec 16, 2018
1 parent f47b03c commit 6ff4799
Show file tree
Hide file tree
Showing 34 changed files with 377 additions and 319 deletions.
4 changes: 2 additions & 2 deletions docs/applications.html
Expand Up @@ -27,8 +27,8 @@ <h2 id="text"><a href="/text.html#text"><code>text</code></a><a class="anchor-li
<h2 id="vision"><a href="/vision.html#vision"><code>vision</code></a><a class="anchor-link" href="#vision">&#182;</a></h2><p>This sub-package contains the classes that deal with Computer Vision.</p>
<h2 id="Module-structure">Module structure<a class="anchor-link" href="#Module-structure">&#182;</a></h2><p>In each case (except for <a href="/collab.html#collab"><code>collab</code></a>), the module is organized this way:</p>
<h3 id="transform"><a href="/tabular.transform.html#tabular.transform"><code>transform</code></a><a class="anchor-link" href="#transform">&#182;</a></h3><p>This sub-module deals with the pre-processing (data augmentation for images, cleaning for tabular data, tokenizing and numericalizing for text).</p>
<h3 id="data"><a href="/tabular.data.html#tabular.data"><code>data</code></a><a class="anchor-link" href="#data">&#182;</a></h3><p>This sub-module defines the dataset class(es) to deal with this kind of data.</p>
<h3 id="models"><a href="/tabular.models.html#tabular.models"><code>models</code></a><a class="anchor-link" href="#models">&#182;</a></h3><p>This sub-module defines the specific models used for this kind of data.</p>
<h3 id="data"><a href="/data.html#data"><code>data</code></a><a class="anchor-link" href="#data">&#182;</a></h3><p>This sub-module defines the dataset class(es) to deal with this kind of data.</p>
<h3 id="models"><a href="/models.html#models"><code>models</code></a><a class="anchor-link" href="#models">&#182;</a></h3><p>This sub-module defines the specific models used for this kind of data.</p>
<h3 id="learner"><a href="/text.learner.html#text.learner"><code>learner</code></a><a class="anchor-link" href="#learner">&#182;</a></h3><p>When it exists, this sub-module contains functions will directly bind this data with a suitable model and add the necessary callbacks.</p>

</div>
Expand Down
20 changes: 10 additions & 10 deletions docs/basic_data.html
Expand Up @@ -69,7 +69,7 @@ <h3 id="Factory-method">Factory method<a class="anchor-link" href="#Factory-meth


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L109" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>train_ds</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>valid_ds</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>test_ds</code>:<code>Optional</code>[<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>]=<code>None</code>, <code>path</code>:<code>PathOrStr</code>=<code>'.'</code>, <code>bs</code>:<code>int</code>=<code>64</code>, <code>num_workers</code>:<code>int</code>=<code>4</code>, <code>tfms</code>:<code>Optional</code>[<code>Collection</code>[<code>Callable</code>]]=<code>None</code>, <code>device</code>:<a href="https://pytorch.org/docs/stable/tensor_attributes.html#torch-device"><code>device</code></a>=<code>None</code>, <code>collate_fn</code>:<code>Callable</code>=<code>'data_collate'</code>, <code>no_check</code>:<code>bool</code>=<code>False</code>) → <code>DataBunch</code></p>
<h4 id="DataBunch.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L109" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>train_ds</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>valid_ds</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>test_ds</code>:<code>Optional</code>[<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>]=<code>None</code>, <code>path</code>:<code>PathOrStr</code>=<code>'.'</code>, <code>bs</code>:<code>int</code>=<code>64</code>, <code>num_workers</code>:<code>int</code>=<code>16</code>, <code>tfms</code>:<code>Optional</code>[<code>Collection</code>[<code>Callable</code>]]=<code>None</code>, <code>device</code>:<a href="https://pytorch.org/docs/stable/tensor_attributes.html#torch-device"><code>device</code></a>=<code>None</code>, <code>collate_fn</code>:<code>Callable</code>=<code>'data_collate'</code>, <code>no_check</code>:<code>bool</code>=<code>False</code>) → <code>DataBunch</code></p>
</blockquote>
<p>Create a <a href="/basic_data.html#DataBunch"><code>DataBunch</code></a> from <code>train_ds</code>, <code>valid_ds</code> and maybe <code>test_ds</code> with a batch size of <code>bs</code>.</p>

Expand Down Expand Up @@ -103,7 +103,7 @@ <h3 id="Visualization">Visualization<a class="anchor-link" href="#Visualization"


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.show_batch"><code>show_batch</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L157" class="source_link">[source]</a></h4><blockquote><p><code>show_batch</code>(<code>rows</code>:<code>int</code>=<code>5</code>, <code>ds_type</code>:<a href="/basic_data.html#DatasetType"><code>DatasetType</code></a>=<code>&lt;DatasetType.Train: 1&gt;</code>, <code>kwargs</code>)</p>
<h4 id="DataBunch.show_batch"><code>show_batch</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L159" class="source_link">[source]</a></h4><blockquote><p><code>show_batch</code>(<code>rows</code>:<code>int</code>=<code>5</code>, <code>ds_type</code>:<a href="/basic_data.html#DatasetType"><code>DatasetType</code></a>=<code>&lt;DatasetType.Train: 1&gt;</code>, <code>kwargs</code>)</p>
</blockquote>
<p>Show a batch of data in <code>ds_type</code> on a few <code>rows</code>.</p>

Expand Down Expand Up @@ -151,7 +151,7 @@ <h4 id="DataBunch.dl"><code>dl</code><a href="https://github.com/fastai/fastai/b


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.one_batch"><code>one_batch</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L137" class="source_link">[source]</a></h4><blockquote><p><code>one_batch</code>(<code>ds_type</code>:<a href="/basic_data.html#DatasetType"><code>DatasetType</code></a>=<code>&lt;DatasetType.Train: 1&gt;</code>, <code>detach</code>:<code>bool</code>=<code>True</code>, <code>denorm</code>:<code>bool</code>=<code>True</code>, <code>cpu</code>:<code>bool</code>=<code>True</code>) → <code>Collection</code>[<code>Tensor</code>]</p>
<h4 id="DataBunch.one_batch"><code>one_batch</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L139" class="source_link">[source]</a></h4><blockquote><p><code>one_batch</code>(<code>ds_type</code>:<a href="/basic_data.html#DatasetType"><code>DatasetType</code></a>=<code>&lt;DatasetType.Train: 1&gt;</code>, <code>detach</code>:<code>bool</code>=<code>True</code>, <code>denorm</code>:<code>bool</code>=<code>True</code>, <code>cpu</code>:<code>bool</code>=<code>True</code>) → <code>Collection</code>[<code>Tensor</code>]</p>
</blockquote>
<p>Get one batch from the data loader of <code>ds_type</code>. Optionally <code>detach</code> and <code>denorm</code>.</p>

Expand All @@ -172,7 +172,7 @@ <h4 id="DataBunch.one_batch"><code>one_batch</code><a href="https://github.com/f


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.one_item"><code>one_item</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L151" class="source_link">[source]</a></h4><blockquote><p><code>one_item</code>(<code>item</code>, <code>detach</code>:<code>bool</code>=<code>False</code>, <code>denorm</code>:<code>bool</code>=<code>False</code>)</p>
<h4 id="DataBunch.one_item"><code>one_item</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L153" class="source_link">[source]</a></h4><blockquote><p><code>one_item</code>(<code>item</code>, <code>detach</code>:<code>bool</code>=<code>False</code>, <code>denorm</code>:<code>bool</code>=<code>False</code>)</p>
</blockquote>
<p>Get <code>item</code> into a batch. Optionally <code>detach</code> and <code>denorm</code>.</p>

Expand All @@ -193,7 +193,7 @@ <h4 id="DataBunch.one_item"><code>one_item</code><a href="https://github.com/fas


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.sanity_check"><code>sanity_check</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L193" class="source_link">[source]</a></h4><blockquote><p><code>sanity_check</code>()</p>
<h4 id="DataBunch.sanity_check"><code>sanity_check</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L195" class="source_link">[source]</a></h4><blockquote><p><code>sanity_check</code>()</p>
</blockquote>
<p>Check the underlying data in the training set can be properly loaded.</p>

Expand All @@ -220,7 +220,7 @@ <h3 id="Empty-DataBunch-for-inference">Empty <a href="/basic_data.html#DataBunch


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.export"><code>export</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L168" class="source_link">[source]</a></h4><blockquote><p><code>export</code>(<code>fname</code>:<code>str</code>=<code>'export.pkl'</code>)</p>
<h4 id="DataBunch.export"><code>export</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L170" class="source_link">[source]</a></h4><blockquote><p><code>export</code>(<code>fname</code>:<code>str</code>=<code>'export.pkl'</code>)</p>
</blockquote>
<p>Export the minimal state of <code>self</code> for inference in <code>self.path/fname</code>.</p>

Expand All @@ -241,7 +241,7 @@ <h4 id="DataBunch.export"><code>export</code><a href="https://github.com/fastai/


<div class="output_markdown rendered_html output_subarea ">
<h4 id="load_empty"><code>load_empty</code><a href="https://github.com/fastai/fastai/blob/master/fastai/data_block.py#L584" class="source_link">[source]</a></h4><blockquote><p><code>load_empty</code>(<code>path</code>, <code>fname</code>:<code>str</code>=<code>'export.pkl'</code>)</p>
<h4 id="load_empty"><code>load_empty</code><a href="https://github.com/fastai/fastai/blob/master/fastai/data_block.py#L586" class="source_link">[source]</a></h4><blockquote><p><code>load_empty</code>(<code>path</code>, <code>fname</code>:<code>str</code>=<code>'export.pkl'</code>)</p>
</blockquote>
<p>Load an empty <a href="/basic_data.html#DataBunch"><code>DataBunch</code></a> from the exported file in <code>path/fname</code> with optional <code>tfms</code>.</p>

Expand Down Expand Up @@ -275,7 +275,7 @@ <h3 id="Dataloader-transforms">Dataloader transforms<a class="anchor-link" href=


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DataBunch.add_tfm"><code>add_tfm</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L134" class="source_link">[source]</a></h4><blockquote><p><code>add_tfm</code>(<code>tfm</code>:<code>Callable</code>)</p>
<h4 id="DataBunch.add_tfm"><code>add_tfm</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L136" class="source_link">[source]</a></h4><blockquote><p><code>add_tfm</code>(<code>tfm</code>:<code>Callable</code>)</p>
</blockquote>

</div>
Expand Down Expand Up @@ -336,7 +336,7 @@ <h3 id="Factory-method">Factory method<a class="anchor-link" href="#Factory-meth


<div class="output_markdown rendered_html output_subarea ">
<h4 id="DeviceDataLoader.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L74" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>dataset</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>bs</code>:<code>int</code>=<code>64</code>, <code>shuffle</code>:<code>bool</code>=<code>False</code>, <code>device</code>:<a href="https://pytorch.org/docs/stable/tensor_attributes.html#torch-device"><code>device</code></a>=<code>device(type='cuda')</code>, <code>tfms</code>:<code>Collection</code>[<code>Callable</code>]=<code>None</code>, <code>num_workers</code>:<code>int</code>=<code>4</code>, <code>collate_fn</code>:<code>Callable</code>=<code>'data_collate'</code>, <code>kwargs</code>:<code>Any</code>)</p>
<h4 id="DeviceDataLoader.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_data.py#L74" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>dataset</code>:<a href="https://pytorch.org/docs/stable/data.html#torch.utils.data.Dataset"><code>Dataset</code></a>, <code>bs</code>:<code>int</code>=<code>64</code>, <code>shuffle</code>:<code>bool</code>=<code>False</code>, <code>device</code>:<a href="https://pytorch.org/docs/stable/tensor_attributes.html#torch-device"><code>device</code></a>=<code>device(type='cuda')</code>, <code>tfms</code>:<code>Collection</code>[<code>Callable</code>]=<code>None</code>, <code>num_workers</code>:<code>int</code>=<code>16</code>, <code>collate_fn</code>:<code>Callable</code>=<code>'data_collate'</code>, <code>kwargs</code>:<code>Any</code>)</p>
</blockquote>
<p>Create DeviceDataLoader from <code>dataset</code> with <code>bs</code> and <code>shuffle</code>: processs using <code>num_workers</code>.</p>

Expand Down Expand Up @@ -454,7 +454,7 @@ <h4 id="DeviceDataLoader.proc_batch"><code>proc_batch</code><a href="https://git


<div class="output_markdown rendered_html output_subarea ">
<h2 id="DatasetType">`DatasetType`</h2><blockquote><p><code>Enum</code> = [Train, Valid, Test, Single]</p>
<h2 id="DatasetType">`DatasetType`</h2><blockquote><p><code>Enum</code> = [Train, Valid, Test, Single, Fix]</p>
</blockquote>

</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/basic_train.html
Expand Up @@ -1343,7 +1343,7 @@ <h4 id="Recorder.on_batch_begin"><code>on_batch_begin</code><a href="https://git


<div class="output_markdown rendered_html output_subarea ">
<h4 id="Recorder.on_epoch_end"><code>on_epoch_end</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_train.py#L355" class="source_link">[source]</a></h4><blockquote><p><code>on_epoch_end</code>(<code>epoch</code>:<code>int</code>, <code>num_batch</code>:<code>int</code>, <code>smooth_loss</code>:<code>Tensor</code>, <code>last_metrics</code>=<code>typing.Collection[typing.Union[torch.Tensor, numbers.Number]]</code>, <code>kwargs</code>:<code>Any</code>) → <code>bool</code></p>
<h4 id="Recorder.on_epoch_end"><code>on_epoch_end</code><a href="https://github.com/fastai/fastai/blob/master/fastai/basic_train.py#L355" class="source_link">[source]</a></h4><blockquote><p><code>on_epoch_end</code>(<code>epoch</code>:<code>int</code>, <code>num_batch</code>:<code>int</code>, <code>smooth_loss</code>:<code>Tensor</code>, <code>last_metrics</code>=<code>'Collection'</code>, <code>kwargs</code>:<code>Any</code>) → <code>bool</code></p>
</blockquote>
<p>Save epoch info: num_batch, smooth_loss, metrics.</p>

Expand Down
2 changes: 1 addition & 1 deletion docs/callback.html
Expand Up @@ -852,7 +852,7 @@ <h4 id="OptimWrapper.clear"><code>clear</code><a href="https://github.com/fastai


<div class="output_markdown rendered_html output_subarea ">
<h4 id="OptimWrapper.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/callback.py#L17" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>opt_func</code>:<code>Union</code>[<code>type</code>, <code>Callable</code>], <code>lr</code>:<code>Union</code>[<code>float</code>, <code>Tuple</code>, <code>List</code>[<code>T</code>]], <code>layer_groups</code>:<code>ModuleList</code>, <code>kwargs</code>:<code>Any</code>) → <a href="https://pytorch.org/docs/stable/optim.html#torch.optim.Optimizer"><code>Optimizer</code></a></p>
<h4 id="OptimWrapper.create"><code>create</code><a href="https://github.com/fastai/fastai/blob/master/fastai/callback.py#L17" class="source_link">[source]</a></h4><blockquote><p><code>create</code>(<code>opt_func</code>:<code>Callable</code>, <code>lr</code>:<code>Union</code>[<code>float</code>, <code>Tuple</code>, <code>List</code>], <code>layer_groups</code>:<code>ModuleList</code>, <code>kwargs</code>:<code>Any</code>) → <a href="https://pytorch.org/docs/stable/optim.html#torch.optim.Optimizer"><code>Optimizer</code></a></p>
</blockquote>
<p>Create an <a href="https://pytorch.org/docs/stable/optim.html#torch.optim.Optimizer"><code>optim.Optimizer</code></a> from <code>opt_func</code> with <code>lr</code>. Set lr on <code>layer_groups</code>.</p>

Expand Down

0 comments on commit 6ff4799

Please sign in to comment.