Skip to content

Commit

Permalink
Merge branch 'develop' into beta
Browse files Browse the repository at this point in the history
  • Loading branch information
Braden Dubois committed Mar 26, 2021
2 parents 43f1c0a + 3b99fed commit 32ddc69
Show file tree
Hide file tree
Showing 78 changed files with 1,659 additions and 440 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: "CodeQL Analysis"
on:
push:
branches: [ main, beta, develop ]
pull_request:
branches: [ main ]

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: python

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1

31 changes: 28 additions & 3 deletions .github/workflows/update_wiki.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ on:
push:
# Trigger only when wiki directory changes
paths:
- 'wiki/**'
- 'wiki/pages/**'

# Trigger only on main/beta
# Trigger only on main
branches: [ main ]

jobs:
Expand All @@ -16,10 +16,35 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install tools to build whl package
run: |
pip install sdist
- name: Build whl package
run: |
python setup.py sdist bdist_wheel
env:
SEMANTIC_VERSION: 1.0.0 # not actually 1.0.0, but has no impact on wiki-building

- name: Install do-calculus package
run: |
pip install -e .
env:
SEMANTIC_VERSION: 1.0.0 # not actually 1.0.0, but has no impact on wiki-building

- name: Build Pages (replace stubs)
run: |
python ./wiki/build_wiki.py
- name: Push Wiki Changes
uses: Andrew-Chen-Wang/github-wiki-action@v2
env:
WIKI_DIR: docs/
WIKI_DIR: wiki/pages/
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_MAIL: ${{ secrets.EMAIL }}
GH_NAME: ${{ github.repository_owner }}
2 changes: 1 addition & 1 deletion do/probability/shpitser/Shpitser.py → debug/Shpitser.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
# #
#########################################################

from src.probability.shpitser.identification.IDAlgorithm import ID
from identification.IDAlgorithm import ID
from src.probability.shpitser.identification.IDProcessing import parse_shpitser
from src.probability.shpitser.latent.LatentProjection import latent_projection
from src.probability.shpitser.structures.Distribution import Distribution
Expand Down
26 changes: 26 additions & 0 deletions debug/scrap.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
from pathlib import Path
from do.structures.Graph import Graph
from yaml import safe_dump

from gen_distribution import generate_distribution

V = {"U1", "U2", "U3", "A", "B", "X", "Z", "W", "Y"}
E = {
("U1", "A"), ("U1", "X"),
("U2", "A"), ("U2", "Y"),
("U3", "X"), ("U3", "W"),
("A", "B"), ("B", "X"), ("X", "Z"), ("X", "W"), ("Z", "Y"), ("W", "Y")
}

G = Graph(V, E)

distribution = generate_distribution(G)

P = Path(".", "shpitser2a.yml")

with P.open("w") as f:
safe_dump({
"name": "Shpitser Figure 2a",
"model": distribution

}, f)
Loading

0 comments on commit 32ddc69

Please sign in to comment.