Skip to content

Commit

Permalink
Merge pull request #175 from UC-Davis-molecular-computing/dev
Browse files Browse the repository at this point in the history
v0.16.0
  • Loading branch information
UnHumbleBen authored May 23, 2021
2 parents b6cd698 + 08ecf96 commit aa7a624
Show file tree
Hide file tree
Showing 17 changed files with 6,809 additions and 6,116 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/docs-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,17 @@ jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: ammaraskar/sphinx-action@master
- uses: actions/[email protected]
- name: Set up Python
uses: actions/setup-python@v2
with:
docs-folder: "doc/"
pre-build-command: "pip3 install sphinx_rtd_theme"
build-command: "sphinx-build -T -E -W -b html . _build"
python-version: '3.x'
- name: Install Sphinx
run: |
python -m pip install --upgrade pip
pip install sphinx sphinx_rtd_theme
- name: Move to docs folder and build
run: |
cd doc
pwd
sphinx-build -T -E -W -b html . _build
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: "release"
on:
push:
branches:
- "master"
- "main"

jobs:
release:
Expand Down
9 changes: 8 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,14 @@ def extract_version(filename: str):
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = ['sphinx.ext.autodoc']
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.viewcode',
# 'sphinx.ext.napoleon',
]

# next line puts type of each function parameter next to description of parameter
autodoc_typehints = "description"

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
Expand Down
6 changes: 4 additions & 2 deletions examples/1_staple_1_helix_origami_position_nondefault.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@

def create_design() -> sc.Design:
length = 9
pitch90_group = sc.HelixGroup(pitch=90)
helices = [
sc.Helix(max_offset=length, major_ticks=[2, 5], position=sc.Position3D(x=1, y=2, z=3), pitch=90)]
sc.Helix(max_offset=length, major_ticks=[2, 5], position=sc.Position3D(x=1, y=2, z=3), group='pitch90')]
stap_ss = sc.Domain(0, True, 0, length)
scaf_ss = sc.Domain(0, False, 0, length)
stap = sc.Strand([stap_ss])
scaf = sc.Strand([scaf_ss], color=sc.default_scaffold_color)
strands = [stap, scaf]
design = sc.Design(helices=helices, strands=strands, grid=sc.Grid.none)
design = sc.Design(helices=helices, groups={
'pitch90': pitch90_group}, strands=strands)
design.assign_dna(scaf, 'AACT' * (length // 4))

return design
Expand Down
8 changes: 4 additions & 4 deletions examples/4_helix_grid_none.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
def create_design() -> sc.Design:
length = 10
helices = [
sc.Helix(max_offset=length, position=sc.Position3D(x=0, y=0, z=2.5), pitch=0, roll=0, yaw=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=3, y=3, z=0), pitch=0, roll=0, yaw=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=8, y=-3, z=0), pitch=0, roll=0, yaw=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=11, y=1, z=0), pitch=0, roll=0, yaw=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=0, y=0, z=2.5), roll=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=3, y=3, z=0), roll=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=8, y=-3, z=0), roll=0),
sc.Helix(max_offset=length, position=sc.Position3D(x=11, y=1, z=0), roll=0),
]
stap_ss = sc.Domain(0, True, 0, length)
scaf_ss = sc.Domain(0, False, 0, length)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
{
"version": "0.15.0",
"grid": "none",
"version": "0.16.0",
"groups": {
"pitch90": {
"position": {"x": 0, "y": 0, "z": 0},
"pitch": 90,
"grid": "none"
}
},
"helices": [
{
"group": "pitch90",
"position": {"x": 1, "y": 2, "z": 3},
"pitch": 90,
"major_ticks": [2, 5]
}
],
Expand Down
Loading

0 comments on commit aa7a624

Please sign in to comment.