diff --git a/dist/scadnano-0.8.0.tar.gz b/dist/scadnano-0.8.0.tar.gz new file mode 100644 index 00000000..1652fcbb Binary files /dev/null and b/dist/scadnano-0.8.0.tar.gz differ diff --git a/examples/1_staple_1_helix_origami_position_nondefault.py b/examples/1_staple_1_helix_origami_position_nondefault.py index adb55cb3..721cc572 100644 --- a/examples/1_staple_1_helix_origami_position_nondefault.py +++ b/examples/1_staple_1_helix_origami_position_nondefault.py @@ -1,9 +1,10 @@ import scadnano as sc + def main(): length = 9 helices = [ - sc.Helix(max_offset=length, major_ticks=[2, 5], position3d=sc.Position3D(x=3, y=2, z=1, pitch=90))] + sc.Helix(max_offset=length, major_ticks=[2, 5], position3d=sc.Position3D(x=3, y=2, z=1), pitch=90)] stap_ss = sc.Domain(0, sc.forward, 0, length) scaf_ss = sc.Domain(0, sc.reverse, 0, length) stap = sc.Strand([stap_ss]) @@ -14,6 +15,7 @@ def main(): return design + if not sc.in_browser() and __name__ == '__main__': design = main() design.write_scadnano_file(directory='output_designs') diff --git a/examples/1_staple_1_helix_origami_rotation.py b/examples/1_staple_1_helix_origami_roll.py similarity index 84% rename from examples/1_staple_1_helix_origami_rotation.py rename to examples/1_staple_1_helix_origami_roll.py index f233c4db..f4ee9f9b 100644 --- a/examples/1_staple_1_helix_origami_rotation.py +++ b/examples/1_staple_1_helix_origami_roll.py @@ -1,20 +1,20 @@ -import math - -import scadnano as sc - -def main(): - length = 9 - helices = [sc.Helix(max_offset=length, rotation=math.pi/2, rotation_anchor=2)] - stap_ss = sc.Domain(0, sc.forward, 0, length) - scaf_ss = sc.Domain(0, sc.reverse, 0, length) - stap = sc.Strand([stap_ss]) - scaf = sc.Strand([scaf_ss], color=sc.default_scaffold_color) - strands = [stap, scaf] - design = sc.DNADesign(helices=helices, strands=strands, grid=sc.square) - design.assign_dna(scaf, 'AACT' * (length // 4)) - - return design - -if not sc.in_browser() and __name__ == '__main__': - design = main() - design.write_scadnano_file(directory='output_designs') +import math + +import scadnano as sc + +def main(): + length = 9 + helices = [sc.Helix(max_offset=length, roll=90)] + stap_ss = sc.Domain(0, sc.forward, 0, length) + scaf_ss = sc.Domain(0, sc.reverse, 0, length) + stap = sc.Strand([stap_ss]) + scaf = sc.Strand([scaf_ss], color=sc.default_scaffold_color) + strands = [stap, scaf] + design = sc.DNADesign(helices=helices, strands=strands, grid=sc.square) + design.assign_dna(scaf, 'AACT' * (length // 4)) + + return design + +if not sc.in_browser() and __name__ == '__main__': + design = main() + design.write_scadnano_file(directory='output_designs') diff --git a/examples/24_helix_rectangle.dna b/examples/24_helix_rectangle.dna index 7eb88a55..12d2acc3 100644 --- a/examples/24_helix_rectangle.dna +++ b/examples/24_helix_rectangle.dna @@ -1,5 +1,6 @@ { - "version": "0.1.0", + "version": "0.7.0", + "grid": "square", "helices": [ {"grid_position": [0, -3], "max_offset": 304}, {"grid_position": [0, -2], "max_offset": 304}, diff --git a/examples/4_helix_grid_none.py b/examples/4_helix_grid_none.py index d22e0d39..e348e6c6 100644 --- a/examples/4_helix_grid_none.py +++ b/examples/4_helix_grid_none.py @@ -4,10 +4,10 @@ def main(): length = 10 helices = [ - sc.Helix(max_offset=length, position3d=(sc.Position3D(x=0, y=0, z=0, pitch=0, roll=0, yaw=0))), - sc.Helix(max_offset=length, position3d=(sc.Position3D(x=3, y=3, z=0, pitch=0, roll=0, yaw=0))), - sc.Helix(max_offset=length, position3d=(sc.Position3D(x=8, y=-3, z=0, pitch=0, roll=0, yaw=0))), - sc.Helix(max_offset=length, position3d=(sc.Position3D(x=11, y=1, z=0, pitch=0, roll=0, yaw=0))), + sc.Helix(max_offset=length, position3d=sc.Position3D(x=0, y=0, z=0), pitch=0, roll=0, yaw=0), + sc.Helix(max_offset=length, position3d=sc.Position3D(x=3, y=3, z=0), pitch=0, roll=0, yaw=0), + sc.Helix(max_offset=length, position3d=sc.Position3D(x=8, y=-3, z=0), pitch=0, roll=0, yaw=0), + sc.Helix(max_offset=length, position3d=sc.Position3D(x=11, y=1, z=0), pitch=0, roll=0, yaw=0), ] stap_ss = sc.Domain(0, sc.forward, 0, length) scaf_ss = sc.Domain(0, sc.reverse, 0, length) diff --git a/examples/output_designs/16_helix_origami_barrel_from_algoSST_paper.dna b/examples/output_designs/16_helix_origami_barrel_from_algoSST_paper.dna index a1274777..49e44ab6 100644 --- a/examples/output_designs/16_helix_origami_barrel_from_algoSST_paper.dna +++ b/examples/output_designs/16_helix_origami_barrel_from_algoSST_paper.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 512, "grid_position": [0, 0], "major_ticks": [11, 22, 32, 40, 48, 56, 64, 72, 80, 88, 96, 104, 112, 120, 128, 136, 144, 152, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248, 256, 264, 272, 280, 288, 296, 304, 312, 320, 328, 336, 344, 352, 360, 368, 376, 384, 392, 400, 408, 416, 424, 432, 440, 448, 456, 464, 472, 480, 490, 501]}, diff --git a/examples/output_designs/16_helix_origami_rectangle.dna b/examples/output_designs/16_helix_origami_rectangle.dna index 688fd457..40a9101d 100644 --- a/examples/output_designs/16_helix_origami_rectangle.dna +++ b/examples/output_designs/16_helix_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_idt.dna b/examples/output_designs/16_helix_origami_rectangle_idt.dna index 260dc6f1..5ac9b55d 100644 --- a/examples/output_designs/16_helix_origami_rectangle_idt.dna +++ b/examples/output_designs/16_helix_origami_rectangle_idt.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_no_seq.dna b/examples/output_designs/16_helix_origami_rectangle_no_seq.dna index 825dd3cb..09d6571c 100644 --- a/examples/output_designs/16_helix_origami_rectangle_no_seq.dna +++ b/examples/output_designs/16_helix_origami_rectangle_no_seq.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_no_seq_no_twist.dna b/examples/output_designs/16_helix_origami_rectangle_no_seq_no_twist.dna index f62796d0..14560e10 100644 --- a/examples/output_designs/16_helix_origami_rectangle_no_seq_no_twist.dna +++ b/examples/output_designs/16_helix_origami_rectangle_no_seq_no_twist.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_no_twist.dna b/examples/output_designs/16_helix_origami_rectangle_no_twist.dna index 64c61946..c5a1ee9f 100644 --- a/examples/output_designs/16_helix_origami_rectangle_no_twist.dna +++ b/examples/output_designs/16_helix_origami_rectangle_no_twist.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_seed_tiles_grow_from_top.dna b/examples/output_designs/16_helix_origami_rectangle_seed_tiles_grow_from_top.dna index 9834c9b2..37920857 100644 --- a/examples/output_designs/16_helix_origami_rectangle_seed_tiles_grow_from_top.dna +++ b/examples/output_designs/16_helix_origami_rectangle_seed_tiles_grow_from_top.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 512, "grid_position": [0, 0], "major_ticks": [11, 22, 32, 40, 48, 58, 69, 79, 90, 100, 111, 121, 132, 142, 153, 163, 174, 184, 195, 205, 216, 226, 237, 247, 258, 268, 279, 289, 300, 310, 321, 331, 342, 352, 363, 373, 384, 394, 405, 415, 426, 436, 447, 457, 468, 478]}, diff --git a/examples/output_designs/16_helix_origami_rectangle_shifted_seam_no_seq.dna b/examples/output_designs/16_helix_origami_rectangle_shifted_seam_no_seq.dna index 8b0cac0c..42b33ddb 100644 --- a/examples/output_designs/16_helix_origami_rectangle_shifted_seam_no_seq.dna +++ b/examples/output_designs/16_helix_origami_rectangle_shifted_seam_no_seq.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/examples/output_designs/1_staple_1_helix_origami.dna b/examples/output_designs/1_staple_1_helix_origami.dna index 5c4b1449..a54241fd 100644 --- a/examples/output_designs/1_staple_1_helix_origami.dna +++ b/examples/output_designs/1_staple_1_helix_origami.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0], "major_ticks": [2, 5]} diff --git a/examples/output_designs/1_staple_1_helix_origami_mismatches.dna b/examples/output_designs/1_staple_1_helix_origami_mismatches.dna index 3bba6e03..a4861c17 100644 --- a/examples/output_designs/1_staple_1_helix_origami_mismatches.dna +++ b/examples/output_designs/1_staple_1_helix_origami_mismatches.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]} diff --git a/examples/output_designs/1_staple_1_helix_origami_position_nondefault.dna b/examples/output_designs/1_staple_1_helix_origami_position_nondefault.dna index 98045b16..ab72ab4c 100644 --- a/examples/output_designs/1_staple_1_helix_origami_position_nondefault.dna +++ b/examples/output_designs/1_staple_1_helix_origami_position_nondefault.dna @@ -1,8 +1,8 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ - {"position": {"x": 3, "y": 2, "z": 1, "pitch": 90, "roll": 0, "yaw": 0}, "major_ticks": [2, 5]} + {"position": {"x": 3, "y": 2, "z": 1}, "pitch": 90, "major_ticks": [2, 5]} ], "strands": [ { diff --git a/examples/output_designs/1_staple_1_helix_origami_roll.dna b/examples/output_designs/1_staple_1_helix_origami_roll.dna new file mode 100644 index 00000000..11493beb --- /dev/null +++ b/examples/output_designs/1_staple_1_helix_origami_roll.dna @@ -0,0 +1,23 @@ +{ + "version": "0.8.0", + "grid": "square", + "helices": [ + {"grid_position": [0, 0], "roll": 90} + ], + "strands": [ + { + "color": "#007200", + "sequence": "?AGTTAGTT", + "domains": [ + {"helix": 0, "forward": true, "start": 0, "end": 9} + ] + }, + { + "color": "#0066cc", + "sequence": "AACTAACT?", + "domains": [ + {"helix": 0, "forward": false, "start": 0, "end": 9} + ] + } + ] +} \ No newline at end of file diff --git a/examples/output_designs/1_staple_1_helix_origami_rotation.dna b/examples/output_designs/1_staple_1_helix_origami_rotation.dna index 0442ca48..4a76319d 100644 --- a/examples/output_designs/1_staple_1_helix_origami_rotation.dna +++ b/examples/output_designs/1_staple_1_helix_origami_rotation.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.7.4", "grid": "square", "helices": [ {"grid_position": [0, 0], "rotation": 1.5707963267948966, "rotation_anchor": 2} diff --git a/examples/output_designs/24_helix_origami_rectangle_twist_corrected.dna b/examples/output_designs/24_helix_origami_rectangle_twist_corrected.dna index 13d17128..6f45b71f 100644 --- a/examples/output_designs/24_helix_origami_rectangle_twist_corrected.dna +++ b/examples/output_designs/24_helix_origami_rectangle_twist_corrected.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 304, "grid_position": [0, 0]}, diff --git a/examples/output_designs/2_helix_2_strands_multiple_substrands_no_seq.dna b/examples/output_designs/2_helix_2_strands_multiple_substrands_no_seq.dna index 863264fe..269cb967 100644 --- a/examples/output_designs/2_helix_2_strands_multiple_substrands_no_seq.dna +++ b/examples/output_designs/2_helix_2_strands_multiple_substrands_no_seq.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/2_staple_2_helix_modifications.dna b/examples/output_designs/2_staple_2_helix_modifications.dna index d157613e..ee4a8b14 100644 --- a/examples/output_designs/2_staple_2_helix_modifications.dna +++ b/examples/output_designs/2_staple_2_helix_modifications.dna @@ -1,47 +1,47 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, {"grid_position": [0, 1]} ], "modifications_in_design": { - "/5Biosg/": { - "display_text": "B", - "idt_text": "/5Biosg/", - "display_connector": false, - "location": "5'" - }, "/5Cy5/": { "display_text": "Cy5", "idt_text": "/5Cy5/", "display_connector": false, "location": "5'" }, + "/3Bio/": { + "display_text": "B", + "idt_text": "/3Bio/", + "display_connector": false, + "location": "3'" + }, "/iCy3/": { "display_text": "Cy3", "idt_text": "/iCy3/", "display_connector": false, "location": "internal" }, - "/iBiodT/": { - "display_text": "B", - "idt_text": "/iBiodT/", - "display_connector": false, - "location": "internal", - "allowed_bases": ["T"] - }, "/iCy5/": { "display_text": "Cy5", "idt_text": "/iCy5/", "display_connector": false, "location": "internal" }, - "/3Bio/": { + "/5Biosg/": { "display_text": "B", - "idt_text": "/3Bio/", + "idt_text": "/5Biosg/", "display_connector": false, - "location": "3'" + "location": "5'" + }, + "/iBiodT/": { + "display_text": "B", + "idt_text": "/iBiodT/", + "display_connector": false, + "location": "internal", + "allowed_bases": ["T"] }, "/3Cy3Sp/": { "display_text": "Cy3", diff --git a/examples/output_designs/2_staple_2_helix_origami_6bases_wide.dna b/examples/output_designs/2_staple_2_helix_origami_6bases_wide.dna index 9b09d229..cf463181 100644 --- a/examples/output_designs/2_staple_2_helix_origami_6bases_wide.dna +++ b/examples/output_designs/2_staple_2_helix_origami_6bases_wide.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/2_staple_2_helix_origami_deletions.dna b/examples/output_designs/2_staple_2_helix_origami_deletions.dna index 68698d6e..b8ec2f7d 100644 --- a/examples/output_designs/2_staple_2_helix_origami_deletions.dna +++ b/examples/output_designs/2_staple_2_helix_origami_deletions.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions.dna b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions.dna index 9a7a39ec..f58c4b2f 100644 --- a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions.dna +++ b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 48, "grid_position": [0, 0]}, diff --git a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_mods.dna b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_mods.dna index 55459600..7f2aa608 100644 --- a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_mods.dna +++ b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_mods.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 48, "grid_position": [0, 0]}, diff --git a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_no_seq.dna b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_no_seq.dna index 90e82b84..3950e0b9 100644 --- a/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_no_seq.dna +++ b/examples/output_designs/2_staple_2_helix_origami_deletions_insertions_no_seq.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/3_helix_deletions_insertions.dna b/examples/output_designs/3_helix_deletions_insertions.dna index 03f94d4d..bc5e1db8 100644 --- a/examples/output_designs/3_helix_deletions_insertions.dna +++ b/examples/output_designs/3_helix_deletions_insertions.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 64, "grid_position": [0, 0]}, diff --git a/examples/output_designs/4_helix_grid_none.dna b/examples/output_designs/4_helix_grid_none.dna index dc3525e1..554a60e7 100644 --- a/examples/output_designs/4_helix_grid_none.dna +++ b/examples/output_designs/4_helix_grid_none.dna @@ -1,10 +1,11 @@ { - "version": "0.7.0", + "version": "0.8.0", + "grid": "none", "helices": [ - {"position": {"x": 0, "y": 0, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 10, "position": {"x": 3, "y": 3, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 10, "position": {"x": 8, "y": -3, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 10, "position": {"x": 11, "y": 1, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}} + {"position": {"x": 0, "y": 0, "z": 0}}, + {"max_offset": 10, "position": {"x": 3, "y": 3, "z": 0}}, + {"max_offset": 10, "position": {"x": 8, "y": -3, "z": 0}}, + {"max_offset": 10, "position": {"x": 11, "y": 1, "z": 0}} ], "strands": [ { diff --git a/examples/output_designs/56_helix_origami_rectangle.dna b/examples/output_designs/56_helix_origami_rectangle.dna index 2f39bc84..ddbdb9b8 100644 --- a/examples/output_designs/56_helix_origami_rectangle.dna +++ b/examples/output_designs/56_helix_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 160, "grid_position": [0, 0]}, diff --git a/examples/output_designs/64_helix_origami_rectangle.dna b/examples/output_designs/64_helix_origami_rectangle.dna index d26c8848..5d12dadc 100644 --- a/examples/output_designs/64_helix_origami_rectangle.dna +++ b/examples/output_designs/64_helix_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 128, "grid_position": [0, 0]}, diff --git a/examples/output_designs/6_helix_6_col_origami_rectangle.dna b/examples/output_designs/6_helix_6_col_origami_rectangle.dna index 81d39cc3..d962cfde 100644 --- a/examples/output_designs/6_helix_6_col_origami_rectangle.dna +++ b/examples/output_designs/6_helix_6_col_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/6_helix_bundle_honeycomb.dna b/examples/output_designs/6_helix_bundle_honeycomb.dna index ca015909..bb1ed652 100644 --- a/examples/output_designs/6_helix_bundle_honeycomb.dna +++ b/examples/output_designs/6_helix_bundle_honeycomb.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "honeycomb", "helices": [ {"max_offset": 1295, "grid_position": [1, 1]}, diff --git a/examples/output_designs/6_helix_origami_rectangle.dna b/examples/output_designs/6_helix_origami_rectangle.dna index 53586717..6dedaa53 100644 --- a/examples/output_designs/6_helix_origami_rectangle.dna +++ b/examples/output_designs/6_helix_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 192, "grid_position": [0, 0]}, diff --git a/examples/output_designs/6_helix_origami_rectangle_helices_out_of_order.dna b/examples/output_designs/6_helix_origami_rectangle_helices_out_of_order.dna index 60ef920f..1d30f6cd 100644 --- a/examples/output_designs/6_helix_origami_rectangle_helices_out_of_order.dna +++ b/examples/output_designs/6_helix_origami_rectangle_helices_out_of_order.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 192, "grid_position": [0, 0]}, diff --git a/examples/output_designs/add_deletions_to_24_helix_rectangle.dna b/examples/output_designs/add_deletions_to_24_helix_rectangle.dna index 5cfc97d9..2e4a20bd 100644 --- a/examples/output_designs/add_deletions_to_24_helix_rectangle.dna +++ b/examples/output_designs/add_deletions_to_24_helix_rectangle.dna @@ -1,6 +1,6 @@ { - "version": "0.7.0", - "grid": "square", + "version": "0.8.0", + "grid": "e", "helices": [ {"max_offset": 304, "grid_position": [0, -3]}, {"max_offset": 304, "grid_position": [0, -2]}, diff --git a/examples/output_designs/empty.dna b/examples/output_designs/empty.dna index 7b0696e2..5bb9a7ea 100644 --- a/examples/output_designs/empty.dna +++ b/examples/output_designs/empty.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [], "strands": [] diff --git a/examples/output_designs/hairpin.dna b/examples/output_designs/hairpin.dna index f37738af..9ee7a4b4 100644 --- a/examples/output_designs/hairpin.dna +++ b/examples/output_designs/hairpin.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]} diff --git a/examples/output_designs/helices_out_of_order_nonconsecutive.dna b/examples/output_designs/helices_out_of_order_nonconsecutive.dna index 2d936bbb..775bd82d 100644 --- a/examples/output_designs/helices_out_of_order_nonconsecutive.dna +++ b/examples/output_designs/helices_out_of_order_nonconsecutive.dna @@ -1,5 +1,6 @@ { - "version": "0.7.0", + "version": "0.8.0", + "grid": "none", "helices": [ {"max_offset": 20, "grid_position": [0, 2], "idx": 2}, {"max_offset": 20, "grid_position": [0, 3], "idx": 3}, diff --git a/examples/output_designs/hex_lattice_10x10.dna b/examples/output_designs/hex_lattice_10x10.dna index 1fc7f3f2..c29e6257 100644 --- a/examples/output_designs/hex_lattice_10x10.dna +++ b/examples/output_designs/hex_lattice_10x10.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "hex", "helices": [ {"max_offset": 16, "grid_position": [0, 0]}, diff --git a/examples/output_designs/hex_lattice_10x10_with_negative.dna b/examples/output_designs/hex_lattice_10x10_with_negative.dna index addbf47d..a657894f 100644 --- a/examples/output_designs/hex_lattice_10x10_with_negative.dna +++ b/examples/output_designs/hex_lattice_10x10_with_negative.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "hex", "helices": [ {"max_offset": 16, "grid_position": [-4, -4]}, diff --git a/examples/output_designs/honeycomb_lattice_10x10.dna b/examples/output_designs/honeycomb_lattice_10x10.dna index 52d24476..4f62f9cd 100644 --- a/examples/output_designs/honeycomb_lattice_10x10.dna +++ b/examples/output_designs/honeycomb_lattice_10x10.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "honeycomb", "helices": [ {"max_offset": 16, "grid_position": [0, 0]}, diff --git a/examples/output_designs/honeycomb_lattice_10x10_with_negative.dna b/examples/output_designs/honeycomb_lattice_10x10_with_negative.dna index f4a94f02..5a070a51 100644 --- a/examples/output_designs/honeycomb_lattice_10x10_with_negative.dna +++ b/examples/output_designs/honeycomb_lattice_10x10_with_negative.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "honeycomb", "helices": [ {"max_offset": 16, "grid_position": [-4, -4]}, diff --git a/examples/output_designs/idt-plates-explicit.dna b/examples/output_designs/idt-plates-explicit.dna index cd9d69c8..71dc0411 100644 --- a/examples/output_designs/idt-plates-explicit.dna +++ b/examples/output_designs/idt-plates-explicit.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/long_range_crossovers.dna b/examples/output_designs/long_range_crossovers.dna index 5a757810..ba307d42 100644 --- a/examples/output_designs/long_range_crossovers.dna +++ b/examples/output_designs/long_range_crossovers.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/loopouts_all_types.dna b/examples/output_designs/loopouts_all_types.dna index cbce5fd9..1c987e34 100644 --- a/examples/output_designs/loopouts_all_types.dna +++ b/examples/output_designs/loopouts_all_types.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/examples/output_designs/many_big_helices.dna b/examples/output_designs/many_big_helices.dna index c4edfafa..36ae050f 100644 --- a/examples/output_designs/many_big_helices.dna +++ b/examples/output_designs/many_big_helices.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 2000, "grid_position": [0, 0]}, diff --git a/examples/output_designs/many_helices_modifications.dna b/examples/output_designs/many_helices_modifications.dna index 074374b3..1a30e2f1 100644 --- a/examples/output_designs/many_helices_modifications.dna +++ b/examples/output_designs/many_helices_modifications.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, @@ -12,30 +12,30 @@ {"grid_position": [0, 7]} ], "modifications_in_design": { - "/5Biosg/": { - "display_text": "B", - "idt_text": "/5Biosg/", - "display_connector": false, - "location": "5'" - }, - "/3Cy3Sp/": { - "display_text": "Cy3", - "idt_text": "/3Cy3Sp/", - "display_connector": false, - "location": "3'" - }, "/iCy3/": { "display_text": "Cy3", "idt_text": "/iCy3/", "display_connector": false, "location": "internal" }, + "/5Biosg/": { + "display_text": "B", + "idt_text": "/5Biosg/", + "display_connector": false, + "location": "5'" + }, "/iBiodT/": { "display_text": "B", "idt_text": "/iBiodT/", "display_connector": false, "location": "internal", "allowed_bases": ["T"] + }, + "/3Cy3Sp/": { + "display_text": "Cy3", + "idt_text": "/3Cy3Sp/", + "display_connector": false, + "location": "3'" } }, "strands": [ diff --git a/examples/output_designs/proposal.dna b/examples/output_designs/proposal.dna index f314e3e5..59406779 100644 --- a/examples/output_designs/proposal.dna +++ b/examples/output_designs/proposal.dna @@ -1,22 +1,23 @@ { - "version": "0.7.0", + "version": "0.8.0", + "grid": "none", "helices": [ - {"max_offset": 512, "position": {"x": 0, "y": 0, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 2.5, "y": 0.0, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 4.809698831278217, "y": 0.9567085809127245, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 6.577465784244586, "y": 2.7244755338790934, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 7.534174365157311, "y": 5.034174365157311, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 7.534174365157311, "y": 7.534174365157311, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 6.577465784244587, "y": 9.843873196435528, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 4.809698831278218, "y": 11.611640149401897, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 2.500000000000001, "y": 12.568348730314622, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": 8.881784197001252e-16, "y": 12.568348730314622, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -2.309698831278216, "y": 11.611640149401897, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -4.077465784244586, "y": 9.843873196435528, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -5.034174365157312, "y": 7.534174365157312, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -5.0341743651573125, "y": 5.034174365157312, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -4.077465784244588, "y": 2.724475533879095, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}}, - {"max_offset": 512, "position": {"x": -2.309698831278218, "y": 0.9567085809127276, "z": 0, "pitch": 0, "roll": 0, "yaw": 0}} + {"max_offset": 512, "position": {"x": 0, "y": 0, "z": 0}}, + {"max_offset": 512, "position": {"x": 2.5, "y": 0.0, "z": 0}}, + {"max_offset": 512, "position": {"x": 4.809698831278217, "y": 0.9567085809127245, "z": 0}}, + {"max_offset": 512, "position": {"x": 6.577465784244586, "y": 2.7244755338790934, "z": 0}}, + {"max_offset": 512, "position": {"x": 7.534174365157311, "y": 5.034174365157311, "z": 0}}, + {"max_offset": 512, "position": {"x": 7.534174365157311, "y": 7.534174365157311, "z": 0}}, + {"max_offset": 512, "position": {"x": 6.577465784244587, "y": 9.843873196435528, "z": 0}}, + {"max_offset": 512, "position": {"x": 4.809698831278218, "y": 11.611640149401897, "z": 0}}, + {"max_offset": 512, "position": {"x": 2.500000000000001, "y": 12.568348730314622, "z": 0}}, + {"max_offset": 512, "position": {"x": 8.881784197001252e-16, "y": 12.568348730314622, "z": 0}}, + {"max_offset": 512, "position": {"x": -2.309698831278216, "y": 11.611640149401897, "z": 0}}, + {"max_offset": 512, "position": {"x": -4.077465784244586, "y": 9.843873196435528, "z": 0}}, + {"max_offset": 512, "position": {"x": -5.034174365157312, "y": 7.534174365157312, "z": 0}}, + {"max_offset": 512, "position": {"x": -5.0341743651573125, "y": 5.034174365157312, "z": 0}}, + {"max_offset": 512, "position": {"x": -4.077465784244588, "y": 2.724475533879095, "z": 0}}, + {"max_offset": 512, "position": {"x": -2.309698831278218, "y": 0.9567085809127276, "z": 0}} ], "helices_view_order": [15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0], "strands": [ diff --git a/examples/output_designs/sst-motif-3_2.dna b/examples/output_designs/sst-motif-3_2.dna index 41c91b9d..7422ff7e 100644 --- a/examples/output_designs/sst-motif-3_2.dna +++ b/examples/output_designs/sst-motif-3_2.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "major_tick_distance": 10, "helices": [ diff --git a/examples/output_designs/sst-motif-4_1.dna b/examples/output_designs/sst-motif-4_1.dna index 56e46c36..d3fb21e3 100644 --- a/examples/output_designs/sst-motif-4_1.dna +++ b/examples/output_designs/sst-motif-4_1.dna @@ -1,5 +1,5 @@ { - "version": "0.7.0", + "version": "0.8.0", "grid": "square", "major_tick_distance": 10, "helices": [ diff --git a/scadnano/scadnano.py b/scadnano/scadnano.py index 074873ba..9691d848 100644 --- a/scadnano/scadnano.py +++ b/scadnano/scadnano.py @@ -298,7 +298,7 @@ class Grid(str, enum.Enum): # import scadnano_version # current_version: str = scadnano_version.current_version # initial_version: str = scadnano_version.initial_version -current_version: str = "0.7.4" +current_version: str = "0.8.0" initial_version: str = "0.0.1" default_idt_scale = "25nm" @@ -309,8 +309,9 @@ def default_major_tick_distance(grid: Grid) -> int: return 7 if grid in (Grid.hex, Grid.honeycomb) else 8 -default_helix_rotation: float = 0.0 -default_helix_rotation_anchor: int = 0 +default_pitch: float = 0.0 +default_roll: float = 0.0 +default_yaw: float = 0.0 base_width_svg: float = 10.0 """Width of a single base in the SVG main view of scadnano.""" @@ -318,7 +319,14 @@ def default_major_tick_distance(grid: Grid) -> int: base_height_svg: float = 10.0 """Height of a single base in the SVG main view of scadnano.""" -distance_between_helices_svg: float = (base_width_svg * 2.5 / 0.34) +distance_between_helices_nm: float = 2.5 +"""Distance between centers of helices in nanometers. +See :py:data:`distance_between_helices_svg` for explanation of this value.""" + +base_width_nm: float = 0.34 +"""Width of a single DNA base in nanometers.""" + +distance_between_helices_svg: float = base_width_svg * distance_between_helices_nm / base_width_nm """Distance between tops of two consecutive helices (using default positioning rules). This is set to (:const:`base_width_svg` * 2.5/0.34) based on the following calculation, @@ -644,8 +652,6 @@ def m13(rotation: int = 5587, variant: M13Variant = M13Variant.p7249): grid_key = 'grid' major_tick_distance_key = 'major_tick_distance' major_ticks_key = 'major_ticks' -rotation_key = 'rotation' -rotation_anchor_key = 'rotation_anchor' helices_key = 'helices' strands_key = 'strands' scaffold_key = 'scaffold' @@ -660,14 +666,15 @@ def m13(rotation: int = 5587, variant: M13Variant = M13Variant.p7249): grid_position_key = 'grid_position' svg_position_key = 'svg_position' position3d_key = 'position' +legacy_position3d_keys = ['origin'] # Position3D keys position_x_key = 'x' position_y_key = 'y' position_z_key = 'z' -position_pitch_key = 'pitch' -position_roll_key = 'roll' -position_yaw_key = 'yaw' +pitch_key = 'pitch' +roll_key = 'roll' +yaw_key = 'yaw' position_origin_key = 'origin' # Strand keys @@ -840,15 +847,6 @@ class Position3D(_JSONSerializable): z: float = 0 """z-coordinate of position""" - pitch: float = 0 - """pitch angle in degrees""" - - roll: float = 0 - """roll angle in degrees""" - - yaw: float = 0 - """yaw angle in degrees""" - def to_json_serializable(self, suppress_indent: bool = True): dct = self.__dict__ # return NoIndent(dct) if suppress_indent else dct @@ -865,10 +863,7 @@ def from_json(json_map: dict) -> Position3D: x = json_map[position_x_key] y = json_map[position_y_key] z = json_map[position_z_key] - pitch = json_map[position_pitch_key] - roll = json_map[position_roll_key] - yaw = json_map[position_yaw_key] - return Position3D(x=x, y=y, z=z, pitch=pitch, roll=roll, yaw=yaw) + return Position3D(x=x, y=y, z=z) def in_browser() -> bool: @@ -954,42 +949,26 @@ class Helix(_JSONSerializable): If `grid_position = (h,v,b)` is specified but `position` is omitted, then the default is `x` = b * BASE_WIDTH_SVG, `y` = [index of :any:`Helix`] * :any:`scadnano.distance_between_helices_svg`.""" - rotation: float = 0 - """Rotation angle (in degrees) of backbone of the :any:`Domain` on this :any:`Helix` with - :py:data:`Domain.forward` = ``True``. - - The angle is relative to the offset :py:data:`Helix.rotation_anchor`, and 0 degrees is defined to - be pointing *up* in both the side view and main view. - - A positive rotation angle rotates *clockwise* in the side view. - This violates standard Cartesian coordinate conventions: - https://en.wikipedia.org/wiki/Rotation_matrix, - but it is consistent with SVG rotation conventions: - https://www.w3.org/TR/SVG11/coords.html#ExampleRotateScale. - - For example, a rotation of 90 degrees points right in the side view - and out of the screen in the main view. - - Default is 0 degrees.""" - - rotation_anchor: int = 0 - """Offset on this :any:`Helix` that is the reference point for 0 degrees. - The rotation at offset ``o`` is 360 degrees times the remainder of ``o - rotation_anchor`` - when divided by 10.5. - - For example, if :py:data:`Helix.rotation` = 0 and :py:data:`Helix.rotation_anchor` = 42, then - at offsets of the form :math:`42 + 21k` for integer :math:`k` - (i.e., 42 itself, as well as 21, 0, -21, -42, ..., 63, 84, 105, ...), - the rotation angle is also 0 at those offsets since - they are integer multiples of 21 (hence also multiples of 10.5) from 42. - - Default is 0.""" - position3d: Position3D = None - """Position (x,y,z) and orientation (pitch,roll,yaw) of this :any:`Helix` in 3D space. + """Position (x,y,z) of this :any:`Helix` in 3D space. Optional if :py:data:`Helix.grid_position` is specified. - Default is pitch, roll, yaw are 0, and x,y,z are determined by grid position h, v, b.""" + Default is x,y,z are determined by grid position h, v, b.""" + + pitch: float = 0 + """Angle in the main view plane; 0 means pointing to the right (min_offset on left, max_offset on right). + Rotation is clockwise in the main view. + Units are degrees.""" + + roll: float = 0 + """Angle around the center of the helix; 0 means pointing straight up in the side view. + Rotation is clockwise in the side view. + Units are degrees.""" + + yaw: float = 0 + """Third angle for orientation besides :py:data:`Helix.pitch` and :py:data:`Helix.roll`. + Not visually displayed in scadnano, but here to support more general 3D applications. + Units are degrees.""" idx: int = None """Index of this :any:`Helix`. @@ -1026,12 +1005,12 @@ def to_json_serializable(self, suppress_indent: bool = True): else: dct[position3d_key] = self.position3d.to_json_serializable(suppress_indent) - # print(f'self.svg_position() = {self.svg_position}') - # print(f'default_svg_position() = {self.default_svg_position()}') - default_x, default_y = self.default_svg_position() - if not (_is_close(self.svg_position[0], default_x) and _is_close(self.svg_position[1], - default_y)): - dct[svg_position_key] = (self.svg_position[0], self.svg_position[1]) + if not _is_close(self.pitch, default_pitch): + dct[pitch_key] = self.pitch + if not _is_close(self.roll, default_roll): + dct[roll_key] = self.roll + if not _is_close(self.yaw, default_yaw): + dct[yaw_key] = self.yaw if self.major_tick_distance is not None and self.major_tick_distance > 0: dct[major_tick_distance_key] = self.major_tick_distance @@ -1039,19 +1018,10 @@ def to_json_serializable(self, suppress_indent: bool = True): if self.major_ticks is not None: dct[major_ticks_key] = self.major_ticks - if self.rotation != 0: - dct[rotation_key] = self.rotation - - if self.rotation_anchor != 0: - dct[rotation_anchor_key] = self.rotation_anchor - dct[idx_on_helix_key] = self.idx return _NoIndent(dct) if suppress_indent else dct - def default_svg_position(self): - return 0, self.idx * distance_between_helices_svg - def default_grid_position(self): return (0, self.idx, 0) @@ -1080,35 +1050,29 @@ def from_json(json_map: dict) -> Helix: gp_list.append(0) grid_position = tuple(gp_list) - svg_position = None - if svg_position_key in json_map: - sp_list = json_map[grid_position_key] - if len(sp_list) != 2: - raise IllegalDNADesignError("svg_position must have exactly two integers, " - f"but instead it has {len(sp_list)}: {sp_list}") - svg_position = tuple(sp_list) - major_tick_distance = json_map.get(major_tick_distance_key) major_ticks = json_map.get(major_ticks_key) min_offset = json_map.get(min_offset_key) max_offset = json_map.get(max_offset_key) - rotation = json_map.get(rotation_key, default_helix_rotation) - rotation_anchor = json_map.get(rotation_anchor_key, default_helix_rotation_anchor) idx = json_map.get(idx_on_helix_key) - position3d_map = json_map.get(position3d_key) + position3d_map = optional_field(None, json_map, position3d_key, *legacy_position3d_keys) position3d = Position3D.from_json(position3d_map) if position3d_map is not None else None + pitch = json_map.get(pitch_key, default_pitch) + roll = json_map.get(roll_key, default_roll) + yaw = json_map.get(yaw_key, default_yaw) + return Helix( major_tick_distance=major_tick_distance, major_ticks=major_ticks, grid_position=grid_position, - svg_position=svg_position, min_offset=min_offset, max_offset=max_offset, - rotation=rotation, - rotation_anchor=rotation_anchor, position3d=position3d, + pitch=pitch, + roll=roll, + yaw=yaw, idx=idx, ) @@ -2439,7 +2403,7 @@ def idx_of(helix: Helix, order: int): def __post_init__(self): # XXX: exact order of these calls is important self._set_helices_idxs() - self._set_helices_grid_and_svg_positions() + self._set_helices_grid_positions() self._build_domains_on_helix_lists() self._set_helices_min_max_offsets(update=False) self._check_legal_design() @@ -3025,12 +2989,10 @@ def _set_helices_idxs(self): if helix.idx is None: helix.idx = idx - def _set_helices_grid_and_svg_positions(self): + def _set_helices_grid_positions(self): for idx, helix in self.helices.items(): if helix.grid_position is None: helix.grid_position = helix.default_grid_position() - if helix.svg_position is None: - helix.svg_position = helix.default_svg_position() def _set_helices_min_max_offsets(self, update: bool): """update = whether to overwrite existing Helix.max_offset and Helix.min_offset. diff --git a/scadnano/scadnano_version.py b/scadnano/scadnano_version.py index 1562adb6..b3ddc3d8 100644 --- a/scadnano/scadnano_version.py +++ b/scadnano/scadnano_version.py @@ -1,2 +1,2 @@ -current_version = "0.7.4" +current_version = "0.8.0" initial_version = "0.0.1" \ No newline at end of file diff --git a/setup.py b/setup.py index a1b22bca..2a90a8b5 100644 --- a/setup.py +++ b/setup.py @@ -24,7 +24,7 @@ setup(name='scadnano', packages=['scadnano'], # version=sv.current_version, - version='0.7.4', + version='0.8.0', # download_url=f'https://github.com/UC-Davis-molecular-computing/scadnano-python-package/archive/v{sv.current_version}.zip', download_url=f'https://github.com/UC-Davis-molecular-computing/scadnano-python-package/archive/v0.7.0.zip', license='MIT', diff --git a/tests/scadnano_tests.py b/tests/scadnano_tests.py index 927ddc66..0338d309 100644 --- a/tests/scadnano_tests.py +++ b/tests/scadnano_tests.py @@ -2092,11 +2092,11 @@ def test_position_specified_with_origin_keyword(self): json_str = """ { "grid": "none", - "helices": [{"position": { - "origin": { "x": 1, "y": 2, "z": 3}, - "pitch": 4, - "roll": 5, - "yaw": 6} + "helices": [{ + "origin": {"x": 1, "y": 2, "z": 3}, + "pitch": 4, + "roll": 5, + "yaw": 6 }], "strands": [ { @@ -2107,9 +2107,18 @@ def test_position_specified_with_origin_keyword(self): } """ d = sc.DNADesign.from_scadnano_json_str(json_str) - expected_position = sc.Position3D(1,2,3,4,5,6) + expected_position = sc.Position3D(1,2,3) + expected_pitch = 4 + expected_roll = 5 + expected_yaw = 6 actual_position = d.helices[0].position3d + actual_pitch = d.helices[0].pitch + actual_roll = d.helices[0].roll + actual_yaw = d.helices[0].yaw self.assertEqual(expected_position, actual_position) + self.assertEqual(expected_pitch, actual_pitch) + self.assertEqual(expected_roll, actual_roll) + self.assertEqual(expected_yaw, actual_yaw) def test_json_tristan_example_issue_32(self): json_str = """ @@ -2153,8 +2162,8 @@ def test_to_json__hairpin(self): json = design.to_json() # should be no error getting here - def test_to_json__rotation(self): - helix = sc.Helix(rotation=math.pi / 2, rotation_anchor=31) + def test_to_json__roll(self): + helix = sc.Helix(roll=90) ss_f = sc.Domain(helix=0, forward=True, start=0, end=5) ss_r = sc.Domain(helix=0, forward=False, start=0, end=5) strand_f = sc.Strand([ss_f]) diff --git a/tests_inputs/cadnano_v2_export/test_16_helix_origami_rectangle_no_twist.dna b/tests_inputs/cadnano_v2_export/test_16_helix_origami_rectangle_no_twist.dna index 9e0d92aa..1cc98c7b 100644 --- a/tests_inputs/cadnano_v2_export/test_16_helix_origami_rectangle_no_twist.dna +++ b/tests_inputs/cadnano_v2_export/test_16_helix_origami_rectangle_no_twist.dna @@ -1,5 +1,5 @@ { - "version": "0.7.4", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 448, "grid_position": [0, 0]}, diff --git a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_deletions_insertions.dna b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_deletions_insertions.dna index 2d75fe2c..414e4d15 100644 --- a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_deletions_insertions.dna +++ b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_deletions_insertions.dna @@ -1,5 +1,5 @@ { - "version": "0.7.4", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple.dna b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple.dna index 8b6721a5..a1247476 100644 --- a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple.dna +++ b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple.dna @@ -1,5 +1,5 @@ { - "version": "0.7.4", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple_2.dna b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple_2.dna index 8559ce9f..fc3091b6 100644 --- a/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple_2.dna +++ b/tests_inputs/cadnano_v2_export/test_2_stape_2_helix_origami_extremely_simple_2.dna @@ -1,5 +1,5 @@ { - "version": "0.7.4", + "version": "0.8.0", "grid": "square", "helices": [ {"grid_position": [0, 0]}, diff --git a/tests_inputs/cadnano_v2_export/test_6_helix_origami_rectangle.dna b/tests_inputs/cadnano_v2_export/test_6_helix_origami_rectangle.dna index f5e3abd6..16847909 100644 --- a/tests_inputs/cadnano_v2_export/test_6_helix_origami_rectangle.dna +++ b/tests_inputs/cadnano_v2_export/test_6_helix_origami_rectangle.dna @@ -1,5 +1,5 @@ { - "version": "0.7.4", + "version": "0.8.0", "grid": "square", "helices": [ {"max_offset": 192, "grid_position": [0, 0]},