{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Test rook workflow with subset chain" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "import os\n", "os.environ['ROOK_URL'] = 'http://rook.dkrz.de/wps'\n", "\n", "from rooki import operators as ops" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "wf = ops.Subset(\n", " ops.Subset(\n", " ops.Input(\n", " 'rlds', ['c3s-cmip6.CMIP.INM.INM-CM5-0.historical.r1i1p1f1.Amon.rlds.gr1.v20190610']\n", " ),\n", " time=\"1890-01-01/1920-12-30\",\n", " ),\n", " time=\"1900-01-01/1900-12-30\",\n", ")\n", " " ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "resp = wf.orchestrate()\n", "assert resp.ok" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "assert 'rlds_Amon_INM-CM5-0_historical_r1i1p1f1_gr1_19000116-19001216.nc' in resp.download_urls()[0]" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.2" } }, "nbformat": 4, "nbformat_minor": 4 }