Skip to content

Commit 2a3dde4

Browse files
committed
Updates for the release.
1 parent e4939f9 commit 2a3dde4

29 files changed

Lines changed: 1751 additions & 488 deletions

CONTRIBUTING.md

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# How to Contribute
22

3-
We are currently evaluating whether to accept external PRs.
3+
We are currently not accepting external PRs.
44

55
## Before you begin
66

@@ -22,11 +22,3 @@ sign a new one.
2222

2323
This project follows [Google's Open Source Community
2424
Guidelines](https://opensource.google/conduct/).
25-
26-
## Contribution process
27-
28-
### Code Reviews
29-
30-
All submissions, including submissions by project members, require review. We
31-
use [GitHub pull requests](https://docs.github.com/articles/about-pull-requests)
32-
for this purpose.

colabs/fine_tuning_tutorial_jax.ipynb

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191
"1. Visit https://www.kaggle.com/ and create an account.\n",
9292
"2. Go to your account settings, then the 'API' section.\n",
9393
"3. Click 'Create new token' to download your key.\n",
94+
"4. You can either login using the UI interface or by setting your Kaggle username and key via the Colab secrets.\n",
9495
"\n",
9596
"You will also need to acknowledge the Terms and Conditions of the RecrurrentGemma models on https://www.kaggle.com/models/google/recurrentgemma/ in order to be able to download the model weights and the tokenizer.\n",
9697
"\n",
@@ -105,8 +106,15 @@
105106
},
106107
"outputs": [],
107108
"source": [
109+
"import os\n",
110+
"from google.colab import userdata\n",
108111
"import kagglehub\n",
109-
"kagglehub.login()"
112+
"\n",
113+
"try:\n",
114+
" os.environ[\"KAGGLE_KEY\"] = userdata.get(\"KAGGLE_KEY\")\n",
115+
" os.environ[\"KAGGLE_USERNAME\"] = userdata.get(\"KAGGLE_USERNAME\")\n",
116+
"except userdata.SecretNotFoundError:\n",
117+
" kagglehub.login()"
110118
]
111119
},
112120
{
@@ -535,7 +543,10 @@
535543
"source": [
536544
"# Load parameters\n",
537545
"params = recurrentgemma.load_parameters(ckpt_path, \"single_device\")\n",
538-
"config = recurrentgemma.GriffinConfig.from_flax_params_or_variables(params)\n",
546+
"config = recurrentgemma.GriffinConfig.from_flax_params_or_variables(\n",
547+
" params,\n",
548+
" preset=recurrentgemma.Preset.RECURRENT_GEMMA_2B_V1,\n",
549+
")\n",
539550
"model = recurrentgemma.Griffin(config)"
540551
]
541552
},

0 commit comments

Comments
 (0)