Skip to content

Commit

Permalink
Updated the installation information
Browse files Browse the repository at this point in the history
  • Loading branch information
jszym committed Feb 11, 2024
1 parent 9c370ee commit 296c9f9
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 9 deletions.
16 changes: 10 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,23 +14,27 @@ Here are some quick highlights, but be sure to [read the documentation](https://

### Installing

To install INTREPPPID, clone the repository and install the dependencies using `pip` and the `requirements.txt` file at
the root of the repository
The easiest way to install PPI Origami is to use [pip](https://pip.pypa.io/en/stable/>) to retrieve the PPI Origami
release from [PyPI](https://pypi.org/project/ppi-origami>).

```bash
pip install intrepppid
```

Alternatively, clone the repository and use [poetry](https://python-poetry.org/) to install the dependencies

```bash
git clone https://github.com/jszym/intrepppid
cd intreppid
python -m virtualenv venv
source venv/bin/activate
pip install -r requirements.txt
poetry install
```

### Training Models

To train INTREPPPID, simply use the `train e2e_rnn_triplet` command like so:

```bash
python -m intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
```

### Documentation
Expand Down
2 changes: 1 addition & 1 deletion docs/cli.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ To train the INTREPPPID model as it was in the manuscript, use the ``train e2e_r

.. code:: bash
$ python -m intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
$ intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
.. list-table:: INTREPPPID Manuscript Values for ``e2e_rnn_triplet``
:widths: 25 25 25 50
Expand Down
2 changes: 1 addition & 1 deletion docs/guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ An example of running the training loop with the values used in the INTREPPPID m

.. code:: bash
$ python -m intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
$ intrepppid train e2e_rnn_triplet DATASET.h5 spm.model 3 100 80 --seed 3927704 --vocab_size 250 --trunc_len 1500 --embedding_size 64 --rnn_num_layers 2 --rnn_dropout_rate 0.3 --variational_dropout false --bi_reduce last --workers 4 --embedding_droprate 0.3 --do_rate 0.3 --log_path logs/e2e_rnn_triplet --beta_classifier 2 --use_projection false --optimizer_type ranger21_xx --lr 1e-2
Checkpoints will be saved in a folder ``logs/e2e_rnn_triplet/model_name/chkpt`` and can be used for inference.

Expand Down
11 changes: 11 additions & 0 deletions docs/install.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
Installation
============

Using ``pip``
-------------

The easiest way to install PPI Origami is to use `pip <https://pip.pypa.io/en/stable/>`_ to retrieve the PPI Origami
release from `PyPI <https://pypi.org/project/ppi-origami>`_.

.. code-block:: bash
pip install intrepppid
From Source
-----------

Expand Down
6 changes: 5 additions & 1 deletion intrepppid/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,9 @@ def __init__(self):
self.train = Train


if __name__ == "__main__":
def main():
fire.Fire(Pipeline)


if __name__ == "__main__":
main()

0 comments on commit 296c9f9

Please sign in to comment.