Skip to content

Commit

Permalink
Fix to ensure Factor states are aligned when adding/multiplying/etc.
Browse files Browse the repository at this point in the history
  • Loading branch information
mellesies committed Jul 16, 2020
1 parent 050ab7f commit 3e54010
Show file tree
Hide file tree
Showing 11 changed files with 442 additions and 1,324 deletions.
17 changes: 10 additions & 7 deletions Dockerfile
Expand Up @@ -9,25 +9,28 @@ ENV USER ${NB_USER}
ENV NB_UID ${NB_UID}
ENV HOME /home/${NB_USER}

USER root

RUN adduser --disabled-password \
--gecos "Default user" \
--uid ${NB_UID} \
${NB_USER}

# Copy package
# Install widget first, so the (editable) install of 'core' overwrites
# the PyPI version of thomas-core.
RUN pip install thomas-jupyter-widget
RUN jupyter labextension install --minimize=False thomas-jupyter-widget

# Copy & install package
COPY . /usr/local/python/thomas-core/
WORKDIR /usr/local/python/
RUN pip install ./thomas-core

# Make sure the contents of our repo are also in ${HOME}
# COPY . ${HOME}

USER root
RUN chown -R ${NB_UID} ${HOME}
RUN chown -R ${NB_UID} /usr/local/python/thomas-core/
USER ${NB_USER}

WORKDIR /usr/local/python/
RUN pip install ./thomas-core

# JupyterLab runs on port 8888
EXPOSE 8888

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -5,7 +5,7 @@
# Thomas
Very simple (almost naive ;-) bayesian network implementation.

Example (module `thomas.core.examples`) contains examples from the book "Probabilistic Graphical Models: Principles and Techniques" from Koller and Friedman ([PGM Stanford](http://pgm.stanford.edu)) and from the lecture by [Adnan Darwiche](http://web.cs.ucla.edu/~darwiche/) on YouTube:
Contains examples (`thomas.core.examples`) from the book "Probabilistic Graphical Models: Principles and Techniques" from Koller and Friedman ([PGM Stanford](http://pgm.stanford.edu)) and from the lecture by [Adnan Darwiche](http://web.cs.ucla.edu/~darwiche/) on YouTube:
* [6a. Inference by Variable Elimination I (Chapter 6)](https://www.youtube.com/watch?v=7oRReD_ayWo).
* [6b. Inference by Variable Elimination II (Chapter 6)](https://www.youtube.com/watch?v=QSSmx1ndUvg).

Expand Down

0 comments on commit 3e54010

Please sign in to comment.