Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
blackwhitehere committed Jan 29, 2025
1 parent 37f57ab commit d57ced1
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 16 deletions.
20 changes: 7 additions & 13 deletions tutorials/05-access-results/check_result.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -17,7 +17,8 @@
"source": [
"# Fetch currently configured metadata provider\n",
"# The simplest metadata provider is based on local filesystem,\n",
"# but DB providers are also available\n",
"# but API providers are also available\n",
"# this is configured via METAFLOW_DEFAULT_METADATA and METAFLOW_SERVICE_URL env vars\n",
"get_metadata()"
]
},
Expand All @@ -32,7 +33,9 @@
"import getpass\n",
"user = getpass.getuser()\n",
"# namespace function allows us to change namespace from which results are fetched\n",
"namespace(f\"user:{user}\")"
"namespace(f\"user:{user}\")\n",
"# Set to global namespace to get flows across all namespaces available\n",
"# namespace(None)"
]
},
{
Expand All @@ -42,6 +45,7 @@
"outputs": [],
"source": [
"# Show latest runs of all flows in the current namespace\n",
"# Note: if you are using S3 based DataStore, don't forget to refresh your credentials using admin/refresh_credentials.sh script\n",
"flows = list(iter(Metaflow()))\n",
"for flow in flows:\n",
" run = flow.latest_run\n",
Expand Down Expand Up @@ -75,16 +79,6 @@
"else:\n",
" print(\"Run SimpleFlow in tutorials/05-access-results to view artifact results\")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# Set to global namespace to get flows across all namespaces available\n",
"namespace(None)"
]
}
],
"metadata": {
Expand Down
2 changes: 1 addition & 1 deletion tutorials/12-configure-k8-metadata-service/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
See setup in dir `infra/k8` for Kubernetes deployment setup:

# Start minikube
minikube start --memory=3933 --cpus 4
minikube start --memory=3919 --cpus 4
kubectl config use-context minikube
# set env vars in /infra/k8/db.env file: MF_METADATA_DB_PSWD, MF_METADATA_DB_USER, MF_METADATA_DB_NAME, MF_METADATA_DB_HOST, MF_METADATA_DB_PORT, MF_METADATA_DB_SSL_MODE
# Apply kustomization
Expand Down
2 changes: 2 additions & 0 deletions tutorials/15-remote-orchestration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,7 @@

#### To play this episode:
`cd tutorials`
`python 15-remote-orchestration/hello-cloud.py --with retry --with kubernetes --production argo-workflows create`
`python 15-remote-orchestration/hello-cloud.py --with retry --with kubernetes --production --branch experiment argo-workflows create`
`python 15-remote-orchestration/hello-cloud.py --with retry --with kubernetes argo-workflows create`
`python 15-remote-orchestration/hello-cloud.py --with retry argo-workflows trigger`
4 changes: 2 additions & 2 deletions tutorials/15-remote-orchestration/hello-cloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class HelloRemoteOrchestration(FlowSpec):
Run this flow to validate your Kubernetes configuration.
"""
@kubernetes(cpu=0.5, memory=124)
@kubernetes(cpu=0.1, memory=64)
@step
def start(self):
print("HelloRemoteOrchestration is starting.")
Expand All @@ -22,7 +22,7 @@ def hello(self):
print("Metaflow says: %s" % self.message)
self.next(self.end)

@kubernetes(cpu=0.5, memory=124)
@kubernetes(cpu=0.1, memory=64)
@step
def end(self):
print("HelloRemoteOrchestration is finished.")
Expand Down

0 comments on commit d57ced1

Please sign in to comment.