Jekyll2019-12-30T15:04:39-06:00http://eric-tramel.github.io/feed.xmlEric W. Tramel, Ph.D.Site Refresh, 20192019-12-26T00:00:00-06:002019-12-26T00:00:00-06:00http://eric-tramel.github.io/SiteRefresh<p>It has come time, <strong>once again</strong>, to revisit the personal site. Now, with a few
more years of experience, and some more time for the tools to develop, it seems
a nice time to refresh the content, make sure things are up to date, and to
tweak the presentation a bit so that it is more to my liking.</p>
<h2 id="todos">TODOS</h2>
<ul class="task-list">
<li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled="disabled" checked="checked" />Finish converting codeblocks to Nord theme (finish the SASS)</li>
<li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled="disabled" checked="checked" />Fix codeblock border</li>
<li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled="disabled" checked="checked" />Convert site color scheme into Nord.</li>
<li class="task-list-item"><del>[ ] Figure out why SASS won’t accept variables imported from SCSS?</del></li>
<li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled="disabled" checked="checked" />Get code blocks centered</li>
<li class="task-list-item"><del>[ ] Figure out why Jekyll/Kramdown is not converting fence blocks and only relying on Liquid-defined code blocks.</del></li>
<li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled="disabled" checked="checked" />Fix MathJax header script to use the right AMS formatting.</li>
</ul>
<h2 id="building--previewing-site">Building & Previewing Site</h2>
<p>I ran into a big barrier on Day 1 of this expedition: I simply <em>could not</em> get
a working version of Ruby on my local machine to behave and build the site. There
were many version conflicts, and then my Brew-installed Ruby was fighting and
conflicting with the MacOS system Ruby, and Gems were getting installed in
unknown locations, etc.</p>
<p>To overcome this, I went with a docker solution. Specifically, running the
<code class="highlighter-rouge">jekyll/builder</code> image with the right ports exposed.</p>
<figure class="highlight"><pre><code class="language-bash" data-lang="bash"><span class="nv">$ </span><span class="nb">cd </span>path/to/repo
<span class="nv">$ </span>docker run <span class="nt">--rm</span> <span class="se">\</span>
<span class="nt">--publish</span> 35729:35729 <span class="se">\</span>
<span class="nt">--publish</span><span class="o">=</span>4000:4000 <span class="se">\</span>
<span class="nt">--volume</span><span class="o">=</span><span class="s2">"</span><span class="nv">$PWD</span><span class="s2">:/srv/jekyll"</span> <span class="se">\</span>
<span class="nt">-it</span> jekyll/builder:<span class="nv">$JEKYLL_VERSION</span> <span class="se">\</span>
jekyll serve <span class="nt">--config</span> _config.yml,_config-dev.yml</code></pre></figure>
<p>I put this together in the new <code class="highlighter-rouge">serve</code> script.</p>
<h2 id="code-blocks">Code Blocks</h2>
<p>One thing that I find myself more particular about these days is the humble
code block. I want these things to look <em>good</em>, so I’m going to do my best
to make that happen. I’m going to put down an example code block here
just for visualization purposes.</p>
<p>I wanted to introduce a Nord-themed syntax highlighting into the site. For this
I needed to make reference to the <a href="https://github.com/nnooney/jekyll-theme-nn">following repo</a> where
Nicolas Nooney has already done a great work in implementing the theme as CSS for Rogue/Pygments.
However, I wasn’t able to get the SCSS->SASS importing of variables to work
properly, so I migrated this content into <code class="highlighter-rouge">_sass/base/variables.sass</code> in order
to make the color settings global to the entire site (and not just to the
syntax highlighter!)</p>
<p>I make the slight variation on theme theme by going with dark backgrounds,
instead of white, for legibility. To be able to control the styling of the
code block backgrounds, the colors need to be changed within the
global SASS, <code class="highlighter-rouge">_sass/base/general.sass</code>.</p>
<figure class="highlight"><pre><code class="language-python" data-lang="python"><span class="kn">import</span> <span class="nn">os</span>
<span class="kn">import</span> <span class="nn">sys</span>
<span class="k">from</span> <span class="n">torch</span> <span class="n">immport</span> <span class="n">nn</span>
<span class="kn">import</span> <span class="nn">torch.nn.functional</span> <span class="k">as</span> <span class="n">F</span>
<span class="k">class</span> <span class="nc">Net</span><span class="p">(</span><span class="n">nn</span><span class="o">.</span><span class="n">Module</span><span class="p">):</span>
<span class="s">"""A Network
A Neural Network that does something.
"""</span>
<span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
<span class="nb">super</span><span class="p">(</span><span class="n">Net</span><span class="p">,</span> <span class="bp">self</span><span class="p">)</span><span class="o">.</span><span class="n">__init__</span><span class="p">()</span>
<span class="bp">self</span><span class="o">.</span><span class="n">conv1</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Conv2d</span><span class="p">(</span><span class="mi">3</span><span class="p">,</span> <span class="mi">6</span><span class="p">,</span> <span class="mi">5</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">pool</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">MaxPool2d</span><span class="p">(</span><span class="mi">2</span><span class="p">,</span> <span class="mi">2</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">conv2</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Conv2d</span><span class="p">(</span><span class="mi">6</span><span class="p">,</span> <span class="mi">16</span><span class="p">,</span> <span class="mi">5</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">fc1</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Linear</span><span class="p">(</span><span class="mi">16</span> <span class="o">*</span> <span class="mi">5</span> <span class="o">*</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">120</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">fc2</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Linear</span><span class="p">(</span><span class="mi">120</span><span class="p">,</span> <span class="mi">84</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">fc3</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Linear</span><span class="p">(</span><span class="mi">84</span><span class="p">,</span> <span class="mi">10</span><span class="p">)</span>
<span class="k">def</span> <span class="nf">forward</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">x</span><span class="p">):</span>
<span class="c1"># This is a single line comment
</span> <span class="n">x</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">pool</span><span class="p">(</span><span class="n">F</span><span class="o">.</span><span class="n">relu</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">conv1</span><span class="p">(</span><span class="n">x</span><span class="p">)))</span>
<span class="n">x</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">pool</span><span class="p">(</span><span class="n">F</span><span class="o">.</span><span class="n">relu</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">conv2</span><span class="p">(</span><span class="n">x</span><span class="p">)))</span>
<span class="n">x</span> <span class="o">=</span> <span class="n">x</span><span class="o">.</span><span class="n">view</span><span class="p">(</span><span class="o">-</span><span class="mi">1</span><span class="p">,</span> <span class="mi">16</span> <span class="o">*</span> <span class="mi">5</span> <span class="o">*</span> <span class="mi">5</span><span class="p">)</span>
<span class="n">x</span> <span class="o">=</span> <span class="n">F</span><span class="o">.</span><span class="n">relu</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">fc1</span><span class="p">(</span><span class="n">x</span><span class="p">))</span>
<span class="n">x</span> <span class="o">=</span> <span class="n">F</span><span class="o">.</span><span class="n">relu</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">fc2</span><span class="p">(</span><span class="n">x</span><span class="p">))</span>
<span class="n">x</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">fc3</span><span class="p">(</span><span class="n">x</span><span class="p">)</span>
<span class="k">return</span> <span class="n">x</span>
<span class="n">net</span> <span class="o">=</span> <span class="n">Net</span><span class="p">()</span>
<span class="k">if</span> <span class="n">__name__</span> <span class="o">==</span> <span class="s">"__main__"</span><span class="p">:</span>
<span class="k">print</span><span class="p">(</span><span class="n">Net</span><span class="p">())</span></code></pre></figure>
<h3 id="getting-fence-blocks-to-work">Getting Fence Blocks to Work?</h3>
<p>Somewhere along the way, we have lost the ability to be able
to get proper syntax highlighting when using markdown code fence
blocks. This means that one has to use the Liquid notation format
(which is a big bummer)! So, why are Jekyll and Kramdown not
working together to process down these fenced code blocks properly?</p>
<p>Notably, the documentation for Jekyll is pretty bad, as well as
that of Kramdown. So we are left with searching around on the
internet to see if we can find anything at all to help us answer
this question. I found <a href="https://github.com/jekyll/jekyll/issues/4619#issuecomment-191267346">this reference</a> in a closed
issue. Perhaps it will be informative?</p>
<p>After a lot of work, I really couldn’t find the reason why it isn’t playing
nice. This means that I just can’t use fenced code blocks for the time being :(
Is this a problem with the Jekyll version? For some reason when running
bundler, it insists on an older <code class="highlighter-rouge">jekyll==3.8.5</code>. Perhaps there is some version
clash going on and I’m missing some patches?</p>
<p>For now, as I want to move on, I’ll use the liquid settings :(</p>
<h2 id="double-checking-math-again">Double Checking Math Again</h2>
<p>Is my math working? I really hope so. For instance, if <script type="math/tex">a \in \mathbb{R}</script>,
then we can hope for</p>
<script type="math/tex; mode=display">|a| \leq |a+a|.</script>
<p>It seems like MathJax is a little bit broken in its original formulation. Specifically,
it seems like the <code class="highlighter-rouge">\mathbb</code> is not working, but this is probably due to the wrong
script being used for the MathJaX configuration in the header.</p>
<h2 id="revisiting-publications">Revisiting Publications</h2>
<p>In the original implementation of the site, I used the same <code class="highlighter-rouge">post</code> layout
for blog posts <em>as well as</em> publication pages. Since most of the publication
page is boilerplate, this meant a lot of by-hand editing of the individual
pages to make them conform. This is painful and a bad idea! This is exactly
why Jekyll has <strong>layouts</strong>.</p>
<p>Honestly, I don’t know why I didn’t do this in the first place. Probably I was
just too new to the entire process to be able make a good decision about it
in the first place.</p>
<p>Now the majority of the publication pages are auto-generated from some
preamble YAML. It still leaves open the possibility of also including some
custom content on each page, which will be included after the abstract if desired.</p>
<p>To be able to do this, I needed to also start using the <code class="highlighter-rouge">category</code> property
from Jekyll, making sure that these pages are separated out distinctly and
handled distinctly from the general blog posts.</p>
<h3 id="adding-more-content">Adding More Content</h3>
<p>Additionally, I had a number of works to include into the list since the
last time I refreshed the publication list in 2016. Finally, I also have tried
to do my best to dig up all of the slides, presentations, papers, etc. that I
could for these different works. My hope is that this page can serve to finally
tie up all of these loose ends. If not for anyone else, then at least for
<em>myself</em>. Honestly, it is hard to be able to dig up my own content to be
able to refer back to later!</p>
<h2 id="nord-theme--sass">Nord Theme & SASS</h2>
<p>This time around, I have spent <em>a lot</em> of time with the SASS/SCSS of the site.
Previously, I never touched this stuff. Especially back in 2016, when the entire
formatting ran off of CSS, it seemed just a nightmare to be able to dig into.
Especially for me as a front-end neophyte.</p>
<p>However, with the more recent inclusion of SASS support into Jekyll, it has been
a little bit fun, actually, to learn more about CSS and how to format content
properly. I also have grown to appreciate the SASS structure layout that the
Indigo theme authors put together.</p>erictramelIt has come time, once again, to revisit the personal site. Now, with a few more years of experience, and some more time for the tools to develop, it seems a nice time to refresh the content, make sure things are up to date, and to tweak the presentation a bit so that it is more to my liking.Efficient Per-Example Gradient Computations in Convolutional Neural Networks2019-12-12T00:00:00-06:002019-12-12T00:00:00-06:00http://eric-tramel.github.io/rmt2019ToxicBlend: Virtual Screening of Toxic Compounds with Ensemble Predictors2019-05-01T00:00:00-05:002019-05-01T00:00:00-05:00http://eric-tramel.github.io/zjt2019Federated Learning: Rewards & Challenges of Distributed Private ML2019-05-01T00:00:00-05:002019-05-01T00:00:00-05:00http://eric-tramel.github.io/tra2019<h2 id="summary">Summary</h2>
<p>I discuss the basic concepts underlying the federated ML approach, the advantages it brings, as well as the challenges associated with constructing federated solutions.</p>
<h2 id="about-qconai">About Qcon.ai</h2>
<p>QCon.ai is a practical AI and machine learning conference bringing together software teams working on all aspects of AI and machine learning.</p>Summary(Panelist) Federated Learning: ML with Privacy on the Edge2018-11-01T00:00:00-05:002018-11-01T00:00:00-05:00http://eric-tramel.github.io/tra2018<h2 id="invited-panelist">Invited Panelist</h2>
<p>I was an invited panelist for this webinar put on by Cloudera’s Fast Forward Labs,
alongside Virginia Smith (CMU), and Andrew Trask (OpenMined, Deepmind, Oxford).
I talked a bit about the specific challenges involved in the application of
federated learning in the health industry.</p>Invited PanelistDeterministic and Generalized Framework for Unsupervised Learning with Restricted Boltzmann Machines2018-10-01T00:00:00-05:002018-10-01T00:00:00-05:00http://eric-tramel.github.io/tgm2018<h2 id="popular-summary">Popular Summary</h2>
<p>Is it possible to build a machine that teaches itself? How can we grade its proficiency in a learned task? Is it possible to observe what the machine has learned? These are just a few of the open questions in the field of unsupervised machine learning. To help address these questions, we have developed a framework for training, comparing, and analyzing restricted Boltzmann machines (RBMs), an important practical and theoretical building block for deep neural networks.</p>
<p>An RBM “learns” by employing a joint statistical neural model trained to maximize the correlation between data, external observables, and a set of parameters from which it builds internal representations of those observables. Our framework relies on statistical physics methods as a basis for investigating statistical inference over many interacting variables, a common feature of machine learning models. Specifically, we use the Thouless-Anderson-Palmer formalism from spin-glass theory to approximate the macroscopic behavior of the many simple, widely interacting neurons that comprise an RBM.</p>
<p>In our numerical experiments, we demonstrate the effective deterministic training of our proposed models and show interesting features of unsupervised learning that could not be directly observed with sampling. We also show how to use our framework to put RBMs to work on more practical tasks, such as cleaning up noisy signals.</p>
<p>The framework we propose is not only useful for the analysis and inspection of restricted Boltzmann machines, but it also leads to novel practical training techniques and new applications for these unsupervised models.</p>Popular SummaryClassification and Disease Localization in Histopathology Using Only Global Labels: A Weakly-Supervised Approach2018-02-01T00:00:00-06:002018-02-01T00:00:00-06:00http://eric-tramel.github.io/cts2018Robust Detection of Covariate-Treatment Interactions in Clinical Trials2017-12-01T00:00:00-06:002017-12-01T00:00:00-06:00http://eric-tramel.github.io/gtc2017Streaming Bayesian Inference: Theoretical Limits and Mini-batch Approximate Message-Passing2017-10-03T00:00:00-05:002017-10-03T00:00:00-05:00http://eric-tramel.github.io/mkt2017Inferring Sparsity: Compressed Sensing using Generalized Restricted Boltzmann Machines2016-08-01T00:00:00-05:002016-08-01T00:00:00-05:00http://eric-tramel.github.io/tra2016