diff --git a/examples/scibert/deploy/deploy.ipynb b/examples/scibert/deploy/deploy.ipynb index 905f369..b35e6b2 100644 --- a/examples/scibert/deploy/deploy.ipynb +++ b/examples/scibert/deploy/deploy.ipynb @@ -182,9 +182,8 @@ " positive_likelihood = torch.nn.Softmax(dim=1)(result.logits)[0][1]\n", " tokens = tensors[\"input_ids\"][0]\n", "\n", - " attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][\n", - " 1:-1\n", - " ] # Tuple of `torch.FloatTensor` (one for each layer) of shape\n", + " attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][1:-1]\n", + " # Tuple of `torch.FloatTensor` (one for each layer) of shape\n", " # `(batch_size, num_heads, sequence_length, sequence_length)`.\n", "\n", " explanation = []\n", diff --git a/examples/scibert/deploy/index.html b/examples/scibert/deploy/index.html index d046d57..b8e6bda 100644 --- a/examples/scibert/deploy/index.html +++ b/examples/scibert/deploy/index.html @@ -2238,9 +2238,8 @@ def get_tokenizer_and_model( positive_likelihood = torch.nn.Softmax(dim=1)(result.logits)[0][1] tokens = tensors["input_ids"][0] - attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][ - 1:-1 - ] # Tuple of `torch.FloatTensor` (one for each layer) of shape + attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][1:-1] + # Tuple of `torch.FloatTensor` (one for each layer) of shape # `(batch_size, num_heads, sequence_length, sequence_length)`. explanation = [] @@ -2302,9 +2301,8 @@ def find_highlights(sentence: str) -> EvaluatedSentence: positive_likelihood = torch.nn.Softmax(dim=1)(result.logits)[0][1] tokens = tensors["input_ids"][0] - attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][ - 1:-1 - ] # Tuple of `torch.FloatTensor` (one for each layer) of shape + attentions = np.sum(result.attentions[-1].numpy()[0], axis=0)[0][1:-1] + # Tuple of `torch.FloatTensor` (one for each layer) of shape # `(batch_size, num_heads, sequence_length, sequence_length)`. explanation = [] @@ -2480,7 +2478,7 @@ To check out the Dockerimage, go to Last update: - July 17, 2022 + July 29, 2022 diff --git a/examples/scibert/train/index.html b/examples/scibert/train/index.html index 49afdfa..bb935ee 100644 --- a/examples/scibert/train/index.html +++ b/examples/scibert/train/index.html @@ -2057,7 +2057,7 @@ If you're only here for great-ai, feel free to skip the next cell.< Dataset.from_dict({"text": X, "label": y}) .map(lambda v: tokenizer(v["text"], truncation=True), batched=True) .remove_columns("text") - .train_test_split(test_size=0.2, shuffle=True) + .train_test_split(test_size=0.2, shuffle=True) # test is actually validation ) f1_score = load_metric("f1") @@ -2121,7 +2121,7 @@ dataset = ( Dataset.from_dict({"text": X, "label": y}) .map(lambda v: tokenizer(v["text"], truncation=True), batched=True) .remove_columns("text") - .train_test_split(test_size=0.2, shuffle=True) + .train_test_split(test_size=0.2, shuffle=True) # test is actually validation ) f1_score = load_metric("f1") @@ -2430,7 +2430,7 @@ Model weights saved in pretrained/pytorch_model.bin Last update: - July 17, 2022 + July 29, 2022 diff --git a/examples/scibert/train/train.ipynb b/examples/scibert/train/train.ipynb index ef3a462..6e96889 100644 --- a/examples/scibert/train/train.ipynb +++ b/examples/scibert/train/train.ipynb @@ -246,7 +246,7 @@ " Dataset.from_dict({\"text\": X, \"label\": y})\n", " .map(lambda v: tokenizer(v[\"text\"], truncation=True), batched=True)\n", " .remove_columns(\"text\")\n", - " .train_test_split(test_size=0.2, shuffle=True)\n", + " .train_test_split(test_size=0.2, shuffle=True) # test is actually validation\n", ")\n", "\n", "f1_score = load_metric(\"f1\")\n", diff --git a/how-to-guides/install/index.html b/how-to-guides/install/index.html index b60d220..e805c5d 100644 --- a/how-to-guides/install/index.html +++ b/how-to-guides/install/index.html @@ -897,7 +897,7 @@
pip install great-ai
 
-

Python 3.8 or later is required.

+

Python 3.7 or later is required.

This will work on all major operating systems.

Command-line tools#

@@ -926,7 +926,7 @@ Last update: - July 15, 2022 + July 29, 2022 diff --git a/how-to-guides/install/install.md b/how-to-guides/install/install.md index de92ff4..84d0058 100644 --- a/how-to-guides/install/install.md +++ b/how-to-guides/install/install.md @@ -5,7 +5,7 @@ Provided you already have [Python3](https://www.python.org/downloads/){ target=_ ```sh pip install great-ai ``` -> Python 3.8 or later is required. +> Python 3.7 or later is required. This will work on all major operating systems. diff --git a/index.html b/index.html index 671f62b..302a10c 100644 --- a/index.html +++ b/index.html @@ -979,6 +979,7 @@
  • Docker support for deployment
  • Deployable Jupyter Notebooks
  • Dashboard for online monitoring and analysing traces
  • +
  • Active support for Python 3.7, 3.8, 3.9, and 3.10
  • Roadmap#