|
49 | 49 | <li class="toctree-l1"><a class="reference internal" href="overview.html">Overview</a></li> |
50 | 50 | <li class="toctree-l1 current"><a class="current reference internal" href="#">Installation</a><ul> |
51 | 51 | <li class="toctree-l2"><a class="reference internal" href="#install-using-pip">Install using pip</a><ul> |
52 | | -<li class="toctree-l3"><a class="reference internal" href="#step-1-install-mdtraj">Step 1: Install MDTraj</a></li> |
53 | | -<li class="toctree-l3"><a class="reference internal" href="#step-2-install-idpet">Step 2: Install IDPET</a></li> |
| 52 | +<li class="toctree-l3"><a class="reference internal" href="#step-1-recommended-create-a-virtual-environment">Step 1: (Recommended) Create a virtual environment</a></li> |
| 53 | +<li class="toctree-l3"><a class="reference internal" href="#step-2-install-mdtraj-required">Step 2: Install MDTraj (required)</a></li> |
| 54 | +<li class="toctree-l3"><a class="reference internal" href="#step-3-install-idpet">Step 3: Install IDPET</a></li> |
54 | 55 | </ul> |
55 | 56 | </li> |
| 57 | +<li class="toctree-l2"><a class="reference internal" href="#developer-installation-optional">Developer installation (optional)</a></li> |
56 | 58 | </ul> |
57 | 59 | </li> |
58 | 60 | <li class="toctree-l1"><a class="reference internal" href="demo.html">Demo</a></li> |
|
89 | 91 |
|
90 | 92 | <section id="installation"> |
91 | 93 | <h1>Installation<a class="headerlink" href="#installation" title="Link to this heading"></a></h1> |
| 94 | +<p>We recommend installing IDPET in a clean virtual environment to avoid package conflicts. Below are step-by-step instructions for installation using either <cite>venv</cite> or <cite>conda</cite>, along with important setup notes for MDTraj.</p> |
92 | 95 | <section id="install-using-pip"> |
93 | 96 | <h2>Install using pip<a class="headerlink" href="#install-using-pip" title="Link to this heading"></a></h2> |
94 | 97 | <p>To install IDPET using pip, follow these steps:</p> |
95 | | -<section id="step-1-install-mdtraj"> |
96 | | -<h3>Step 1: Install MDTraj<a class="headerlink" href="#step-1-install-mdtraj" title="Link to this heading"></a></h3> |
97 | | -<p>IDPET is built on top of <a class="reference external" href="https://mdtraj.org/">MDTraj</a>. As MDTraj can have compatibility issues on Windows OS, we recommend installing it using conda. This step can be omitted when using Linux.</p> |
98 | | -<div class="highlight-shell notranslate"><div class="highlight"><pre><span></span>conda<span class="w"> </span>install<span class="w"> </span>-c<span class="w"> </span>conda-forge<span class="w"> </span>mdtraj |
| 98 | +<section id="step-1-recommended-create-a-virtual-environment"> |
| 99 | +<h3>Step 1: (Recommended) Create a virtual environment<a class="headerlink" href="#step-1-recommended-create-a-virtual-environment" title="Link to this heading"></a></h3> |
| 100 | +<p><strong>Using venv (standard Python):</strong></p> |
| 101 | +<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>python<span class="w"> </span>-m<span class="w"> </span>venv<span class="w"> </span>idpet-env |
| 102 | + |
| 103 | +<span class="c1"># Activate the environment</span> |
| 104 | +<span class="c1"># On Linux/macOS:</span> |
| 105 | +<span class="nb">source</span><span class="w"> </span>idpet-env/bin/activate |
| 106 | +<span class="c1"># On Windows:</span> |
| 107 | +idpet-env<span class="se">\S</span>cripts<span class="se">\a</span>ctivate |
| 108 | + |
| 109 | +<span class="c1"># Upgrade pip</span> |
| 110 | +pip<span class="w"> </span>install<span class="w"> </span>--upgrade<span class="w"> </span>pip |
99 | 111 | </pre></div> |
100 | 112 | </div> |
| 113 | +<p><strong>Using conda:</strong></p> |
| 114 | +<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>conda<span class="w"> </span>create<span class="w"> </span>-n<span class="w"> </span>idpet-env<span class="w"> </span><span class="nv">python</span><span class="o">=</span><span class="m">3</span>.9<span class="w"> </span>-y |
| 115 | +conda<span class="w"> </span>activate<span class="w"> </span>idpet-env |
| 116 | +</pre></div> |
| 117 | +</div> |
| 118 | +</section> |
| 119 | +<section id="step-2-install-mdtraj-required"> |
| 120 | +<h3>Step 2: Install MDTraj (required)<a class="headerlink" href="#step-2-install-mdtraj-required" title="Link to this heading"></a></h3> |
| 121 | +<p>IDPET is built on top of <a class="reference external" href="https://mdtraj.org/">MDTraj</a>. Since MDTraj can have compatibility issues on Windows, we recommend installing it via <cite>conda</cite>:</p> |
| 122 | +<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>conda<span class="w"> </span>install<span class="w"> </span>-c<span class="w"> </span>conda-forge<span class="w"> </span>mdtraj |
| 123 | +</pre></div> |
| 124 | +</div> |
| 125 | +<p>This step is <strong>optional on Linux</strong>, but still safe and recommended to avoid binary issues.</p> |
101 | 126 | </section> |
102 | | -<section id="step-2-install-idpet"> |
103 | | -<h3>Step 2: Install IDPET<a class="headerlink" href="#step-2-install-idpet" title="Link to this heading"></a></h3> |
104 | | -<p>Finally, you can install IDPET using pip.</p> |
105 | | -<div class="highlight-shell notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>idpet |
| 127 | +<section id="step-3-install-idpet"> |
| 128 | +<h3>Step 3: Install IDPET<a class="headerlink" href="#step-3-install-idpet" title="Link to this heading"></a></h3> |
| 129 | +<p>With your environment active and MDTraj installed, you can now install IDPET from PyPI:</p> |
| 130 | +<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>idpet |
106 | 131 | </pre></div> |
107 | 132 | </div> |
| 133 | +<p>To verify the installation:</p> |
| 134 | +<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="kn">import</span><span class="w"> </span><span class="nn">idpet</span> |
| 135 | +<span class="nb">print</span><span class="p">(</span><span class="n">idpet</span><span class="o">.</span><span class="n">__version__</span><span class="p">)</span> |
| 136 | +</pre></div> |
| 137 | +</div> |
| 138 | +</section> |
108 | 139 | </section> |
| 140 | +<section id="developer-installation-optional"> |
| 141 | +<h2>Developer installation (optional)<a class="headerlink" href="#developer-installation-optional" title="Link to this heading"></a></h2> |
| 142 | +<p>If you wish to contribute to IDPET or work with the source code, you can install it in editable mode:</p> |
| 143 | +<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>git<span class="w"> </span>clone<span class="w"> </span>https://github.com/hamidrgh/idpet.git |
| 144 | +<span class="nb">cd</span><span class="w"> </span>idpet |
| 145 | +pip<span class="w"> </span>install<span class="w"> </span>-e<span class="w"> </span>. |
| 146 | +</pre></div> |
| 147 | +</div> |
| 148 | +<p>This will install IDPET in “editable” mode so any local changes take effect immediately.</p> |
109 | 149 | </section> |
110 | 150 | </section> |
111 | 151 |
|
|
0 commit comments