Skip to content

Commit

Permalink
update nlpsig-networks to sig-networks in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
rchan26 committed Dec 21, 2023
1 parent 0c2cb36 commit c9b2435
Show file tree
Hide file tree
Showing 19 changed files with 28 additions and 25 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ library that applies models first developed in
by Tseriotou et al. (2023) which presented a novel extension of neural
sequential models using the notion of path signatures from rough path theory.

For more details of this library, see our demo paper [Sig-Networks Toolkit: Signature Networks for Longitudinal Language Modelling](https://arxiv.org/abs/2312.03523).
For more details of this library, see our demo paper
[Sig-Networks Toolkit: Signature Networks for Longitudinal Language Modelling](https://arxiv.org/abs/2312.03523).

## Installation

Expand Down Expand Up @@ -87,7 +88,9 @@ fashion. The key components are:
- The SeqSigNet-Attention-BiLSTM model:
[`sig_networks.SeqSigNetAttentionBiLSTM`](src/sig_networks/seqsignet_attention_bilstm.py)

Also see our demo paper [Sig-Networks Toolkit: Signature Networks for Longitudinal Language Modelling](https://arxiv.org/abs/2312.03523) for details of each of these model components.
Also see our demo paper
[Sig-Networks Toolkit: Signature Networks for Longitudinal Language Modelling](https://arxiv.org/abs/2312.03523)
for details of each of these model components.

### `nlpsig`: Preparing the data

Expand Down
4 changes: 2 additions & 2 deletions examples/AnnoMI/anno_mi-client-seqsignet-example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
" id_to_label_client,\n",
")\n",
"\n",
"from nlpsig_networks.scripts.seqsignet_functions import (\n",
"from sig_networks.scripts.seqsignet_functions import (\n",
" obtain_SeqSigNet_input,\n",
" implement_seqsignet,\n",
")"
Expand Down Expand Up @@ -411,7 +411,7 @@
"source": [
"**Note**: we only do a small number of epochs and try to reduce the number of parameters in this model than what we usually run so that this notebook runs a bit quicker.\n",
"\n",
"Here, we set up most of the arguments to the SWNU-Network model as well as some training arguments such as the number of epochs, the learning rate, the loss function. We are going to do a $K$-fold analysis over a deafult of $5$ splits.\n",
"Here, we set up most of the arguments to the SWNU-Network model as well as some training arguments such as the number of epochs, the learning rate, the loss function. We are going to do a $K$-fold analysis over a default of $5$ splits.\n",
"\n",
"Since we're doing $K$-fold analysis, we get a randomly initialised SWNU-Network model (if we set `k_fold=False`, then we would get a trained model trained on the the training split using a validation set), and a results dataframe.\n",
"\n",
Expand Down
4 changes: 2 additions & 2 deletions examples/AnnoMI/anno_mi-client-swnu-example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@
" id_to_label_client,\n",
")\n",
"\n",
"from nlpsig_networks.scripts.swnu_network_functions import (\n",
"from sig_networks.scripts.swnu_network_functions import (\n",
" obtain_SWNUNetwork_input,\n",
" implement_swnu_network,\n",
")\n",
"\n",
"from nlpsig_networks.swnu import SWNU\n",
"from sig_networks.swnu import SWNU\n",
"\n",
"import signatory"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Stance/stance-baseline-ffn-history.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.ffn_baseline_functions import (\n",
"from sig_networks.scripts.ffn_baseline_functions import (\n",
" histories_baseline_hyperparameter_search,\n",
")"
]
Expand Down
8 changes: 4 additions & 4 deletions examples/Talklife_MoC/talklifemoc-baseline-bert.ipynb

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.lstm_baseline_functions import (\n",
"from sig_networks.scripts.lstm_baseline_functions import (\n",
" lstm_hyperparameter_search,\n",
")"
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.lstm_baseline_functions import (\n",
"from sig_networks.scripts.lstm_baseline_functions import (\n",
" lstm_hyperparameter_search,\n",
")"
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.lstm_baseline_functions import (\n",
"from sig_networks.scripts.lstm_baseline_functions import (\n",
" lstm_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-baseline-bilstm-w5.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.lstm_baseline_functions import (\n",
"from sig_networks.scripts.lstm_baseline_functions import (\n",
" lstm_hyperparameter_search,\n",
" obtain_path,\n",
")"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.ffn_baseline_functions import (\n",
"from sig_networks.scripts.ffn_baseline_functions import (\n",
" histories_baseline_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-baseline-ffn.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.ffn_baseline_functions import (\n",
"from sig_networks.scripts.ffn_baseline_functions import (\n",
" ffn_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swmhau-w11.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swmhau_network_functions import (\n",
"from sig_networks.scripts.swmhau_network_functions import (\n",
" swmhau_network_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swmhau-w20.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swmhau_network_functions import (\n",
"from sig_networks.scripts.swmhau_network_functions import (\n",
" swmhau_network_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swmhau-w5.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swmhau_network_functions import (\n",
"from sig_networks.scripts.swmhau_network_functions import (\n",
" swmhau_network_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swnu-bilstm-35.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.seqsignet_functions import seqsignet_hyperparameter_search"
"from sig_networks.scripts.seqsignet_functions import seqsignet_hyperparameter_search"
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swnu-bilstm.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.seqsignet_functions import seqsignet_hyperparameter_search"
"from sig_networks.scripts.seqsignet_functions import seqsignet_hyperparameter_search"
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swnu-w11.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swnu_network_functions import (\n",
"from sig_networks.scripts.swnu_network_functions import (\n",
" swnu_network_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swnu-w20.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swnu_network_functions import (\n",
"from sig_networks.scripts.swnu_network_functions import (\n",
" swnu_network_hyperparameter_search,\n",
")"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/Talklife_MoC/talklifemoc-swnu-w5.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"metadata": {},
"outputs": [],
"source": [
"from nlpsig_networks.scripts.swnu_network_functions import (\n",
"from sig_networks.scripts.swnu_network_functions import (\n",
" swnu_network_hyperparameter_search,\n",
")"
]
Expand Down

0 comments on commit c9b2435

Please sign in to comment.