fastpdb
Advanced tools
+139
| <?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
| <svg | ||
| xmlns:dc="http://purl.org/dc/elements/1.1/" | ||
| xmlns:cc="http://creativecommons.org/ns#" | ||
| xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" | ||
| xmlns:svg="http://www.w3.org/2000/svg" | ||
| xmlns="http://www.w3.org/2000/svg" | ||
| xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" | ||
| xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" | ||
| width="512" | ||
| height="512" | ||
| viewBox="0 0 135.46667 135.46666" | ||
| version="1.1" | ||
| id="svg8" | ||
| inkscape:version="1.0.2 (1.0.2+r75+1)" | ||
| sodipodi:docname="icon.svg" | ||
| inkscape:export-filename="/home/kunzmann/data/coding/fastpdb/logo.png" | ||
| inkscape:export-xdpi="96" | ||
| inkscape:export-ydpi="96"> | ||
| <defs | ||
| id="defs2"> | ||
| <marker | ||
| inkscape:stockid="Arrow1Lstart" | ||
| orient="auto" | ||
| refY="0" | ||
| refX="0" | ||
| id="Arrow1Lstart" | ||
| style="overflow:visible" | ||
| inkscape:isstock="true"> | ||
| <path | ||
| id="path5415" | ||
| d="M 0,0 5,-5 -12.5,0 5,5 Z" | ||
| style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt" | ||
| transform="matrix(0.8,0,0,0.8,10,0)" /> | ||
| </marker> | ||
| </defs> | ||
| <sodipodi:namedview | ||
| id="base" | ||
| pagecolor="#ffffff" | ||
| bordercolor="#666666" | ||
| borderopacity="1.0" | ||
| inkscape:pageopacity="0.0" | ||
| inkscape:pageshadow="2" | ||
| inkscape:zoom="0.70710678" | ||
| inkscape:cx="355.23663" | ||
| inkscape:cy="402.66706" | ||
| inkscape:document-units="px" | ||
| inkscape:current-layer="layer1" | ||
| showgrid="false" | ||
| units="px" | ||
| inkscape:window-width="2493" | ||
| inkscape:window-height="1385" | ||
| inkscape:window-x="67" | ||
| inkscape:window-y="27" | ||
| inkscape:window-maximized="1" | ||
| showguides="true" | ||
| inkscape:guide-bbox="true" | ||
| inkscape:lockguides="false" | ||
| inkscape:measure-start="145.66,389.051" | ||
| inkscape:measure-end="69.1955,256.216" | ||
| inkscape:snap-global="true" | ||
| inkscape:document-rotation="0"> | ||
| <sodipodi:guide | ||
| position="223.0097,67.733332" | ||
| orientation="0,1" | ||
| id="guide1444" | ||
| inkscape:label="" | ||
| inkscape:locked="false" | ||
| inkscape:color="rgb(0,0,255)" /> | ||
| </sodipodi:namedview> | ||
| <metadata | ||
| id="metadata5"> | ||
| <rdf:RDF> | ||
| <cc:Work | ||
| rdf:about=""> | ||
| <dc:format>image/svg+xml</dc:format> | ||
| <dc:type | ||
| rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> | ||
| <dc:title></dc:title> | ||
| </cc:Work> | ||
| </rdf:RDF> | ||
| </metadata> | ||
| <g | ||
| inkscape:label="Layer 1" | ||
| inkscape:groupmode="layer" | ||
| id="layer1" | ||
| transform="translate(0,-161.53336)"> | ||
| <g | ||
| id="g1007" | ||
| transform="matrix(0.87087794,0,0,0.87087794,0,29.621848)" | ||
| style="stroke-width:1.14827"> | ||
| <path | ||
| id="path4599" | ||
| d="M 25.823956,252.3405 51.528652,297.00003 90.596627,229.33231 39.1457,229.26651 Z" | ||
| style="fill:#dc7000;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="path4573" | ||
| d="m 25.823956,252.3405 -25.782405,44.52493 51.528313,0.0682 z" | ||
| style="fill:#b45c00;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="path4593" | ||
| d="m 0,161.60254 25.782158,44.52408 25.745927,-44.59326 z" | ||
| style="fill:#ff982d;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="rect4514" | ||
| d="m 51.528085,161.53336 -25.70413,44.65922 13.321745,23.07394 51.450367,-0.0654 z" | ||
| style="fill:#ff8405;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| </g> | ||
| <g | ||
| id="g1017" | ||
| transform="matrix(0.87087794,0,0,0.87087794,56.568061,29.621848)" | ||
| style="stroke-width:1.14827"> | ||
| <path | ||
| id="path1009" | ||
| d="M 25.823956,252.3405 51.528652,297.00003 90.596627,229.33231 39.1457,229.26651 Z" | ||
| style="fill:#dc7000;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="path1011" | ||
| d="m 25.823956,252.3405 -25.782405,44.52493 51.528313,0.0682 z" | ||
| style="fill:#b45c00;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="path1013" | ||
| d="m 0,161.60254 25.782158,44.52408 25.745927,-44.59326 z" | ||
| style="fill:#ff982d;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| <path | ||
| id="path1015" | ||
| d="m 51.528085,161.53336 -25.70413,44.65922 13.321745,23.07394 51.450367,-0.0654 z" | ||
| style="fill:#ff8405;fill-opacity:1;stroke:none;stroke-width:0.810893;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" | ||
| inkscape:connector-curvature="0" /> | ||
| </g> | ||
| </g> | ||
| </svg> |
@@ -14,6 +14,2 @@ name: Builds | ||
| - os: ubuntu-latest | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| source: false | ||
| - os: ubuntu-latest | ||
| python: '3.8' | ||
@@ -25,8 +21,8 @@ numpy: '1.16' | ||
| numpy: '1.19' | ||
| source: false | ||
| - os: ubuntu-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
| source: true | ||
| - os: macos-latest | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| source: false | ||
| - os: macos-latest | ||
| python: '3.8' | ||
@@ -39,5 +35,5 @@ numpy: '1.16' | ||
| source: false | ||
| - os: windows-latest | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| - os: macos-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
| source: false | ||
@@ -52,2 +48,6 @@ - os: windows-latest | ||
| source: false | ||
| - os: windows-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
| source: false | ||
@@ -54,0 +54,0 @@ runs-on: ${{ matrix.os }} |
@@ -11,15 +11,12 @@ name: Tests | ||
| include: | ||
| - os: ubuntu-18.04 | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| - os: ubuntu-18.04 | ||
| - os: ubuntu-latest | ||
| python: '3.8' | ||
| numpy: '1.16' | ||
| - os: ubuntu-18.04 | ||
| - os: ubuntu-latest | ||
| python: '3.9' | ||
| numpy: '1.19' | ||
| - os: ubuntu-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
| - os: macos-latest | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| - os: macos-latest | ||
| python: '3.8' | ||
@@ -30,6 +27,6 @@ numpy: '1.16' | ||
| numpy: '1.19' | ||
| - os: macos-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
| - os: windows-latest | ||
| python: '3.7' | ||
| numpy: '1.15' | ||
| - os: windows-latest | ||
| python: '3.8' | ||
@@ -40,2 +37,5 @@ numpy: '1.16' | ||
| numpy: '1.19' | ||
| - os: windows-latest | ||
| python: '3.10' | ||
| numpy: '1.21' | ||
@@ -55,3 +55,3 @@ runs-on: ${{ matrix.os }} | ||
| - name: Installing dependencies | ||
| run: conda install -c conda-forge numpy=$NUMPY_VERSION "biotite>=0.29" maturin pytest | ||
| run: conda install -c conda-forge numpy=$NUMPY_VERSION "biotite>=0.33" maturin pytest | ||
| env: | ||
@@ -58,0 +58,0 @@ NUMPY_VERSION: ${{ matrix.numpy }} |
+0
-1
@@ -54,3 +54,2 @@ # Generated by Cargo | ||
| *.pyo | ||
| *.py{} | ||
| *.py-e | ||
@@ -57,0 +56,0 @@ |
+0
-2
@@ -99,6 +99,4 @@ import time | ||
| ax.yaxis.set_major_formatter(ticker.FormatStrFormatter("%d×")) | ||
| #ax.grid(axis="y") | ||
| #ax.set_ylim(0, 20) | ||
| fig.tight_layout() | ||
| plt.savefig("benchmark.svg") |
+63
-79
@@ -9,7 +9,7 @@ <?xml version="1.0" encoding="utf-8" standalone="no"?> | ||
| <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/> | ||
| <dc:date>2021-10-07T18:07:40.322632</dc:date> | ||
| <dc:date>2022-04-28T11:55:52.602501</dc:date> | ||
| <dc:format>image/svg+xml</dc:format> | ||
| <dc:creator> | ||
| <cc:Agent> | ||
| <dc:title>Matplotlib v3.4.2, https://matplotlib.org/</dc:title> | ||
| <dc:title>Matplotlib v3.4.3, https://matplotlib.org/</dc:title> | ||
| </cc:Agent> | ||
@@ -42,6 +42,6 @@ </dc:creator> | ||
| <g id="patch_3"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 83.987045 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 83.987045 256.16 | ||
| L 129.611136 256.16 | ||
| L 129.611136 176.801224 | ||
| L 83.987045 176.801224 | ||
| L 129.611136 176.306068 | ||
| L 83.987045 176.306068 | ||
| z | ||
@@ -51,6 +51,6 @@ " style="fill:#0a6efd;stroke:#000000;stroke-linejoin:miter;"/> | ||
| <g id="patch_4"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 266.483409 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 266.483409 256.16 | ||
| L 312.1075 256.16 | ||
| L 312.1075 128.837933 | ||
| L 266.483409 128.837933 | ||
| L 312.1075 143.384126 | ||
| L 266.483409 143.384126 | ||
| z | ||
@@ -60,3 +60,3 @@ " style="fill:#0a6efd;stroke:#000000;stroke-linejoin:miter;"/> | ||
| <g id="patch_5"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 448.979773 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 448.979773 256.16 | ||
| L 494.603864 256.16 | ||
@@ -69,6 +69,6 @@ L 494.603864 35.069091 | ||
| <g id="patch_6"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 129.611136 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 129.611136 256.16 | ||
| L 175.235227 256.16 | ||
| L 175.235227 235.507445 | ||
| L 129.611136 235.507445 | ||
| L 175.235227 232.784664 | ||
| L 129.611136 232.784664 | ||
| z | ||
@@ -78,6 +78,6 @@ " style="fill:#e1301d;stroke:#000000;stroke-linejoin:miter;"/> | ||
| <g id="patch_7"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 312.1075 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 312.1075 256.16 | ||
| L 357.731591 256.16 | ||
| L 357.731591 235.507445 | ||
| L 312.1075 235.507445 | ||
| L 357.731591 232.784664 | ||
| L 312.1075 232.784664 | ||
| z | ||
@@ -87,6 +87,6 @@ " style="fill:#e1301d;stroke:#000000;stroke-linejoin:miter;"/> | ||
| <g id="patch_8"> | ||
| <path clip-path="url(#p3f95facf3d)" d="M 494.603864 256.16 | ||
| <path clip-path="url(#pdde81a6178)" d="M 494.603864 256.16 | ||
| L 540.227955 256.16 | ||
| L 540.227955 235.507445 | ||
| L 494.603864 235.507445 | ||
| L 540.227955 232.784664 | ||
| L 494.603864 232.784664 | ||
| z | ||
@@ -101,6 +101,6 @@ " style="fill:#e1301d;stroke:#000000;stroke-linejoin:miter;"/> | ||
| L 0 3.5 | ||
| " id="m37efa55f1f" style="stroke:#000000;stroke-width:0.8;"/> | ||
| " id="m5a13ee7696" style="stroke:#000000;stroke-width:0.8;"/> | ||
| </defs> | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="129.611136" xlink:href="#m37efa55f1f" y="256.16"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="129.611136" xlink:href="#m5a13ee7696" y="256.16"/> | ||
| </g> | ||
@@ -301,3 +301,3 @@ </g> | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="312.1075" xlink:href="#m37efa55f1f" y="256.16"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="312.1075" xlink:href="#m5a13ee7696" y="256.16"/> | ||
| </g> | ||
@@ -363,3 +363,3 @@ </g> | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="494.603864" xlink:href="#m37efa55f1f" y="256.16"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="494.603864" xlink:href="#m5a13ee7696" y="256.16"/> | ||
| </g> | ||
@@ -443,6 +443,6 @@ </g> | ||
| L -3.5 0 | ||
| " id="m7fcad94283" style="stroke:#000000;stroke-width:0.8;"/> | ||
| " id="mc26de41ad9" style="stroke:#000000;stroke-width:0.8;"/> | ||
| </defs> | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="235.507445"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="232.784664"/> | ||
| </g> | ||
@@ -452,3 +452,3 @@ </g> | ||
| <!-- 1× --> | ||
| <g transform="translate(36.484375 240.066507)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 237.343727)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -493,3 +493,3 @@ <path d="M 794 531 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="214.854889"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="209.409329"/> | ||
| </g> | ||
@@ -499,3 +499,3 @@ </g> | ||
| <!-- 2× --> | ||
| <g transform="translate(36.484375 219.413952)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 213.968391)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -535,3 +535,3 @@ <path d="M 1228 531 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="194.202334"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="186.033993"/> | ||
| </g> | ||
@@ -541,3 +541,3 @@ </g> | ||
| <!-- 3× --> | ||
| <g transform="translate(36.484375 198.761396)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 190.593056)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -585,3 +585,3 @@ <path d="M 2597 2516 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="173.549778"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="162.658657"/> | ||
| </g> | ||
@@ -591,3 +591,3 @@ </g> | ||
| <!-- 4× --> | ||
| <g transform="translate(36.484375 178.108841)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 167.21772)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -622,3 +622,3 @@ <path d="M 2419 4116 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="152.897223"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="139.283322"/> | ||
| </g> | ||
@@ -628,3 +628,3 @@ </g> | ||
| <!-- 5× --> | ||
| <g transform="translate(36.484375 157.456285)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 143.842384)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -665,3 +665,3 @@ <path d="M 691 4666 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="132.244667"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="115.907986"/> | ||
| </g> | ||
@@ -671,3 +671,3 @@ </g> | ||
| <!-- 6× --> | ||
| <g transform="translate(36.484375 136.80373)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 120.467049)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -713,3 +713,3 @@ <path d="M 2113 2584 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="111.592112"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="92.53265"/> | ||
| </g> | ||
@@ -719,3 +719,3 @@ </g> | ||
| <!-- 7× --> | ||
| <g transform="translate(36.484375 116.151174)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 97.091713)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -741,3 +741,3 @@ <path d="M 525 4666 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="90.939556"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="69.157315"/> | ||
| </g> | ||
@@ -747,3 +747,3 @@ </g> | ||
| <!-- 8× --> | ||
| <g transform="translate(36.484375 95.498619)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 73.716377)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -798,3 +798,3 @@ <path d="M 2034 2216 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="70.287001"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="45.781979"/> | ||
| </g> | ||
@@ -804,3 +804,3 @@ </g> | ||
| <!-- 9× --> | ||
| <g transform="translate(36.484375 74.846063)scale(0.12 -0.12)"> | ||
| <g transform="translate(36.484375 50.341042)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -846,3 +846,3 @@ <path d="M 703 97 | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="49.634445"/> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#mc26de41ad9" y="22.406643"/> | ||
| </g> | ||
@@ -852,3 +852,3 @@ </g> | ||
| <!-- 10× --> | ||
| <g transform="translate(28.849375 54.193508)scale(0.12 -0.12)"> | ||
| <g transform="translate(28.849375 26.965706)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -883,18 +883,3 @@ <path d="M 2034 4250 | ||
| </g> | ||
| <g id="ytick_11"> | ||
| <g id="line2d_14"> | ||
| <g> | ||
| <use style="stroke:#000000;stroke-width:0.8;" x="61.175" xlink:href="#m7fcad94283" y="28.98189"/> | ||
| </g> | ||
| </g> | ||
| <g id="text_14"> | ||
| <!-- 11× --> | ||
| <g transform="translate(28.849375 33.540952)scale(0.12 -0.12)"> | ||
| <use xlink:href="#DejaVuSans-31"/> | ||
| <use x="63.623047" xlink:href="#DejaVuSans-31"/> | ||
| <use x="127.246094" xlink:href="#DejaVuSans-d7"/> | ||
| </g> | ||
| </g> | ||
| </g> | ||
| <g id="text_15"> | ||
| <g id="text_14"> | ||
| <!-- Speedup --> | ||
@@ -1013,5 +998,5 @@ <g transform="translate(22.35375 160.9825)rotate(-90)scale(0.12 -0.12)"> | ||
| </g> | ||
| <g id="text_16"> | ||
| <!-- 3.8× --> | ||
| <g transform="translate(92.229403 171.305599)scale(0.12 -0.12)"> | ||
| <g id="text_15"> | ||
| <!-- 3.4× --> | ||
| <g transform="translate(92.229403 170.810443)scale(0.12 -0.12)"> | ||
| <defs> | ||
@@ -1028,2 +1013,11 @@ <path d="M 684 794 | ||
| <use x="63.623047" xlink:href="#DejaVuSans-2e"/> | ||
| <use x="95.410156" xlink:href="#DejaVuSans-34"/> | ||
| <use x="159.033203" xlink:href="#DejaVuSans-d7"/> | ||
| </g> | ||
| </g> | ||
| <g id="text_16"> | ||
| <!-- 4.8× --> | ||
| <g transform="translate(274.725767 137.888501)scale(0.12 -0.12)"> | ||
| <use xlink:href="#DejaVuSans-34"/> | ||
| <use x="63.623047" xlink:href="#DejaVuSans-2e"/> | ||
| <use x="95.410156" xlink:href="#DejaVuSans-38"/> | ||
@@ -1034,20 +1028,10 @@ <use x="159.033203" xlink:href="#DejaVuSans-d7"/> | ||
| <g id="text_17"> | ||
| <!-- 6.2× --> | ||
| <g transform="translate(274.725767 123.342308)scale(0.12 -0.12)"> | ||
| <use xlink:href="#DejaVuSans-36"/> | ||
| <!-- 9.5× --> | ||
| <g transform="translate(457.222131 29.573466)scale(0.12 -0.12)"> | ||
| <use xlink:href="#DejaVuSans-39"/> | ||
| <use x="63.623047" xlink:href="#DejaVuSans-2e"/> | ||
| <use x="95.410156" xlink:href="#DejaVuSans-32"/> | ||
| <use x="95.410156" xlink:href="#DejaVuSans-35"/> | ||
| <use x="159.033203" xlink:href="#DejaVuSans-d7"/> | ||
| </g> | ||
| </g> | ||
| <g id="text_18"> | ||
| <!-- 10.7× --> | ||
| <g transform="translate(453.404631 29.573466)scale(0.12 -0.12)"> | ||
| <use xlink:href="#DejaVuSans-31"/> | ||
| <use x="63.623047" xlink:href="#DejaVuSans-30"/> | ||
| <use x="127.246094" xlink:href="#DejaVuSans-2e"/> | ||
| <use x="159.033203" xlink:href="#DejaVuSans-37"/> | ||
| <use x="222.65625" xlink:href="#DejaVuSans-d7"/> | ||
| </g> | ||
| </g> | ||
| <g id="legend_1"> | ||
@@ -1062,3 +1046,3 @@ <g id="patch_13"> | ||
| </g> | ||
| <g id="text_19"> | ||
| <g id="text_18"> | ||
| <!-- fastpdb --> | ||
@@ -1163,3 +1147,3 @@ <g transform="translate(105.575 32.878125)scale(0.12 -0.12)"> | ||
| </g> | ||
| <g id="text_20"> | ||
| <g id="text_19"> | ||
| <!-- biotite --> | ||
@@ -1180,3 +1164,3 @@ <g transform="translate(105.575 50.491875)scale(0.12 -0.12)"> | ||
| <defs> | ||
| <clipPath id="p3f95facf3d"> | ||
| <clipPath id="pdde81a6178"> | ||
| <rect height="243.2" width="501.865" x="61.175" y="12.96"/> | ||
@@ -1183,0 +1167,0 @@ </clipPath> |
+1
-1
| [package] | ||
| name = "fastpdb" | ||
| version = "1.0.0" | ||
| version = "1.0.1" | ||
| edition = "2018" | ||
@@ -5,0 +5,0 @@ |
+3
-32
| Metadata-Version: 2.1 | ||
| Name: fastpdb | ||
| Version: 1.0.0 | ||
| Version: 1.0.1 | ||
| Classifier: Development Status :: 5 - Production/Stable | ||
@@ -14,2 +14,3 @@ Classifier: Intended Audience :: Science/Research | ||
| Requires-Dist: biotite >= 0.29 | ||
| License-File: LICENSE | ||
| Summary: A high performance drop-in replacement for Biotite's PDBFile. | ||
@@ -19,36 +20,6 @@ Keywords: pdb-files | ||
| Maintainer: Patrick Kunzmann | ||
| License: BSD 3-Clause License | ||
| Copyright (c) 2021, Patrick Kunzmann | ||
| All rights reserved. | ||
| Redistribution and use in source and binary forms, with or without | ||
| modification, are permitted provided that the following conditions are met: | ||
| 1. Redistributions of source code must retain the above copyright notice, this | ||
| list of conditions and the following disclaimer. | ||
| 2. Redistributions in binary form must reproduce the above copyright notice, | ||
| this list of conditions and the following disclaimer in the documentation | ||
| and/or other materials provided with the distribution. | ||
| 3. Neither the name of the copyright holder nor the names of its | ||
| contributors may be used to endorse or promote products derived from | ||
| this software without specific prior written permission. | ||
| THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
| DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE | ||
| FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
| DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR | ||
| SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER | ||
| CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, | ||
| OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
| OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
| Requires-Python: >=3.7 | ||
| Description-Content-Type: text/x-rst; charset=UTF-8 | ||
| Project-URL: repository, https://github.com/biotite-dev/fastpdb | ||
| Project-URL: homepage, https://github.com/biotite-dev/fastpdb | ||
| Project-URL: repository, https://github.com/biotite-dev/fastpdb | ||
@@ -55,0 +26,0 @@ .. image:: https://raw.githubusercontent.com/biotite-dev/fastpdb/main/logo.svg |
+1
-1
| [project] | ||
| name = "fastpdb" | ||
| version = "1.0.0" | ||
| version = "1.0.1" | ||
| description = "A high performance drop-in replacement for Biotite's PDBFile." | ||
@@ -5,0 +5,0 @@ readme = "README.rst" |
| __name__ = "fastpdb" | ||
| __author__ = "Patrick Kunzmann" | ||
| __all__ = ["PDBFile"] | ||
| __version__ = "1.0.0" | ||
| __version__ = "1.0.1" | ||
@@ -378,20 +378,11 @@ import numpy as np | ||
| if isinstance(atoms, struc.AtomArray): | ||
| self._pdb_file.write_single_model( | ||
| coord, chain_id, res_id, ins_code, | ||
| res_name, hetero, atom_name, element, | ||
| atom_id, b_factor, occupancy, charge | ||
| ) | ||
| elif isinstance(atoms, struc.AtomArrayStack): | ||
| self._pdb_file.write_multi_model( | ||
| coord, chain_id, res_id, ins_code, | ||
| res_name, hetero, atom_name, element, | ||
| atom_id, b_factor, occupancy, charge | ||
| ) | ||
| else: | ||
| raise TypeError( | ||
| f"Expected AtomArray or AtomArrayStack, " | ||
| f"but got {type(atoms).__name__}" | ||
| ) | ||
| # Treat a single model as multi-model structure | ||
| if coord.ndim == 2: | ||
| coord = coord[np.newaxis, :, :] | ||
| self._pdb_file.write_models( | ||
| coord, chain_id, res_id, ins_code, | ||
| res_name, hetero, atom_name, element, | ||
| atom_id, b_factor, occupancy, charge | ||
| ) | ||
@@ -398,0 +389,0 @@ # Write 'CONECT' records |
+30
-77
@@ -62,3 +62,3 @@ //! Low-level PDB file parsing and writing. | ||
| if line.len() < 80 { | ||
| return Err(BadStructureError::new_err("Line is too short")) | ||
| return Err(InvalidFileError::new_err("Line is too short")) | ||
| } | ||
@@ -189,3 +189,3 @@ let len_a = parse_number(&line[ 6..15])?; | ||
| if line.len() < 80 { | ||
| return Err(BadStructureError::new_err("Line is too short")) | ||
| return Err(InvalidFileError::new_err("Line is too short")) | ||
| } | ||
@@ -221,3 +221,3 @@ write_string_to_array(&mut chain_id, atom_i, line[21..22].trim()); | ||
| number = raw_number.to_digit(10).ok_or_else( || | ||
| BadStructureError::new_err(format!( | ||
| InvalidFileError::new_err(format!( | ||
| "'{}' cannot be parsed into a number", raw_number | ||
@@ -312,65 +312,4 @@ )) | ||
| /// Write a single model to this [`PDBFile`] based on the given coordinates and annotation | ||
| /// arrays. | ||
| fn write_single_model(&mut self, | ||
| coord: Py<PyArray<f32, Ix2>>, | ||
| chain_id: Py<PyArray<u32, Ix2>>, | ||
| res_id: Py<PyArray<i64, Ix1>>, | ||
| ins_code: Py<PyArray<u32, Ix2>>, | ||
| res_name: Py<PyArray<u32, Ix2>>, | ||
| hetero: Py<PyArray<bool, Ix1>>, | ||
| atom_name: Py<PyArray<u32, Ix2>>, | ||
| element: Py<PyArray<u32, Ix2>>, | ||
| atom_id: Option<Py<PyArray<i64, Ix1>>>, | ||
| b_factor: Option<Py<PyArray<f64, Ix1>>>, | ||
| occupancy: Option<Py<PyArray<f64, Ix1>>>, | ||
| charge: Option<Py<PyArray<i64, Ix1>>>) -> PyResult<()> { | ||
| Python::with_gil(|py| { | ||
| let coord = coord.as_ref(py).to_owned_array(); | ||
| let chain_id = chain_id.as_ref(py).to_owned_array(); | ||
| let res_id = res_id.as_ref(py).to_owned_array(); | ||
| let ins_code = ins_code.as_ref(py).to_owned_array(); | ||
| let res_name = res_name.as_ref(py).to_owned_array(); | ||
| let hetero = hetero.as_ref(py).to_owned_array(); | ||
| let atom_name = atom_name.as_ref(py).to_owned_array(); | ||
| let element = element.as_ref(py).to_owned_array(); | ||
| let atom_id = atom_id.map(|arr| arr.as_ref(py).to_owned_array()); | ||
| let b_factor = b_factor.map(|arr| arr.as_ref(py).to_owned_array()); | ||
| let occupancy = occupancy.map(|arr| arr.as_ref(py).to_owned_array()); | ||
| let charge = charge.map(|arr| arr.as_ref(py).to_owned_array()); | ||
| for i in 0..coord.shape()[0] { | ||
| self.lines.push(format!( | ||
| "{:6}{:>5} {:4} {:3} {:1}{:>4}{:1} {:>8.3}{:>8.3}{:>8.3}{:>6.2}{:>6.2} {:>2}{}", | ||
| if hetero[i] { "HETATM" } else { "ATOM" }, | ||
| atom_id.as_ref().map_or((i+1) as i64, |arr| truncate_id(arr[i], 99999)), | ||
| parse_string_from_array(&atom_name, i)?, | ||
| parse_string_from_array(&res_name, i)?, | ||
| parse_string_from_array(&chain_id, i)?, | ||
| truncate_id(res_id[i], 9999), | ||
| parse_string_from_array(&ins_code, i)?, | ||
| coord[[i,0]], | ||
| coord[[i,1]], | ||
| coord[[i,2]], | ||
| occupancy.as_ref().map_or(1f64, |arr| arr[i]), | ||
| b_factor.as_ref().map_or(0f64, |arr| arr[i]), | ||
| parse_string_from_array(&element, i)?, | ||
| charge.as_ref().map_or(String::from(" "), |arr| { | ||
| let c = arr[i]; | ||
| match c.cmp(&0) { | ||
| Ordering::Greater => format!("{:1}+", c), | ||
| Ordering::Less => format!("{:1}-", -c), | ||
| Ordering::Equal => String::from(" ") | ||
| } | ||
| }), | ||
| )); | ||
| } | ||
| Ok(()) | ||
| }) | ||
| } | ||
| /// Write a multiple models to this [`PDBFile`] based on the given coordinates and annotation | ||
| /// arrays. | ||
| fn write_multi_model(&mut self, | ||
| /// Write models to this [`PDBFile`] based on the given coordinates and annotation arrays. | ||
| fn write_models(&mut self, | ||
| coord: Py<PyArray<f32, Ix3>>, | ||
@@ -402,2 +341,4 @@ chain_id: Py<PyArray<u32, Ix2>>, | ||
| let is_multi_model = coord.shape()[0] > 1; | ||
| // These will contain the ATOM records for each atom | ||
@@ -408,8 +349,16 @@ // These are reused in every model by adding the coordinates to the string | ||
| let mut suffix: Vec<String> = Vec::new(); | ||
| for i in 0..coord.shape()[1] { | ||
| let element_i = parse_string_from_array(&element, i)?; | ||
| let atom_name_i = parse_string_from_array(&atom_name, i)?; | ||
| prefix.push(format!( | ||
| "{:6}{:>5} {:4} {:3} {:1}{:>4}{:1} ", | ||
| "{:6}{:>5} {:4} {:>3} {:1}{:>4}{:1} ", | ||
| if hetero[i] { "HETATM" } else { "ATOM" }, | ||
| atom_id.as_ref().map_or((i+1) as i64, |arr| truncate_id(arr[i], 99999)), | ||
| parse_string_from_array(&atom_name, i)?, | ||
| if element_i.len() == 1 && atom_name_i.len() < 4 { | ||
| format!(" {}", atom_name_i) | ||
| } else { | ||
| atom_name_i | ||
| }, | ||
| parse_string_from_array(&res_name, i)?, | ||
@@ -425,3 +374,3 @@ parse_string_from_array(&chain_id, i)?, | ||
| b_factor.as_ref().map_or(0f64, |arr| arr[i]), | ||
| parse_string_from_array(&element, i)?, | ||
| element_i, | ||
| charge.as_ref().map_or(String::from(" "), |arr| { | ||
@@ -439,3 +388,5 @@ let c = arr[i]; | ||
| for model_i in 0..coord.shape()[0] { | ||
| self.lines.push(format!("MODEL {:>8}", model_i+1)); | ||
| if is_multi_model { | ||
| self.lines.push(format!("MODEL {:>8}", model_i+1)); | ||
| } | ||
| for atom_i in 0..coord.shape()[1] { | ||
@@ -450,3 +401,5 @@ let coord_string = format!( | ||
| } | ||
| self.lines.push(String::from("ENDMDL")); | ||
| if is_multi_model { | ||
| self.lines.push(String::from("ENDMDL")); | ||
| } | ||
| } | ||
@@ -522,6 +475,6 @@ Ok(()) | ||
| if line.len() < 80 { | ||
| return Err(BadStructureError::new_err("Line is too short")) | ||
| return Err(InvalidFileError::new_err("Line is too short")) | ||
| } | ||
| coord[[atom_i, 0]] = line[30..38].trim().parse().map_err(|_| | ||
| BadStructureError::new_err(format!( | ||
| InvalidFileError::new_err(format!( | ||
| "'{}' cannot be parsed into a float", line[30..38].trim() | ||
@@ -531,3 +484,3 @@ )) | ||
| coord[[atom_i, 1]] = line[38..46].trim().parse().map_err(|_| | ||
| BadStructureError::new_err(format!( | ||
| InvalidFileError::new_err(format!( | ||
| "'{}' cannot be parsed into a float", line[38..46].trim() | ||
@@ -537,3 +490,3 @@ )) | ||
| coord[[atom_i, 2]] = line[46..54].trim().parse().map_err(|_| | ||
| BadStructureError::new_err(format!( | ||
| InvalidFileError::new_err(format!( | ||
| "'{}' cannot be parsed into a float", line[46..54].trim() | ||
@@ -633,3 +586,3 @@ )) | ||
| None => length = Some(model_length), | ||
| Some(l) => if model_length != l { return Err(BadStructureError::new_err( | ||
| Some(l) => if model_length != l { return Err(InvalidFileError::new_err( | ||
| "Inconsistent number of models" | ||
@@ -682,3 +635,3 @@ )); } | ||
| string.trim().parse().map_err(|_| | ||
| BadStructureError::new_err(format!( | ||
| InvalidFileError::new_err(format!( | ||
| "'{}' cannot be parsed into a number", string.trim() | ||
@@ -685,0 +638,0 @@ )) |
Alert delta unavailable
Currently unable to show alert delta for PyPI packages.
13273297
031
3.33%575
-1.88%