Skip to content

Commit

Permalink
fix users bug and emphasize kernal restart [(#2407)](GoogleCloudPlatf…
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMichaelHu authored and busunkim96 committed Aug 13, 2020
1 parent 142261e commit af31274
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,14 @@
"metadata": {},
"outputs": [],
"source": [
"! pip install --upgrade --quiet google-cloud-automl google-cloud-bigquery"
"! pip3 install --upgrade --quiet google-cloud-automl google-cloud-bigquery"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Restart the kernel to allow `automl_v1beta1` to be imported. The following cell should succeed after a kernel restart:"
"__Restart the kernel__ to allow `automl_v1beta1` to be imported. The following cell should succeed after a kernel restart:"
]
},
{
Expand Down Expand Up @@ -624,10 +624,10 @@
" WHERE user = \"{}\" AND CAST(tables.value AS INT64) = 1\n",
" ORDER BY score DESC\n",
" LIMIT {}\n",
"\"\"\".format(output_uri[5:].replace(\":\", \".\"), training_table, user, n)\n",
"\"\"\".format(output_uri[5:].replace(\":\", \".\"), training_table, users[0], n)\n",
"query_job = bq_client.query(query)\n",
"\n",
"print(\"Top {} song recommended for {}:\".format(n, user))\n",
"print(\"Top {} song recommended for {}:\".format(n, users[0]))\n",
"for idx, row in enumerate(query_job):\n",
" print(\"{}.\".format(idx + 1), row[\"song\"])"
]
Expand Down

0 comments on commit af31274

Please sign in to comment.