Skip to content

Commit

Permalink
Merge pull request #30 from i4Ds/feature/additional-config
Browse files Browse the repository at this point in the history
adds more configs, adds wandb utils
  • Loading branch information
mariusgiger authored Jun 15, 2022
2 parents 0dcbe97 + 73417d3 commit b8edb3b
Show file tree
Hide file tree
Showing 5 changed files with 300 additions and 2 deletions.
2 changes: 1 addition & 1 deletion config/ce-vae/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ data:
value: 8
desc: "Number of samples loaded in advance by each worker. 2 means there will be a total of 2 * num_workers samples prefetched across all workers."
pin_memory:
value: true
value: false
desc: "If true, the data loader will copy Tensors into CUDA pinned memory before returning them"
sdo_ml_v2:
storage_driver:
Expand Down
5 changes: 4 additions & 1 deletion config/ce-vae/run-fhnw-1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ model:
value: null
data:
data_dir:
value: /mnt/nas05/astrodata01/astroml_data/sdomlv2.zarr
value: /mnt/nas05/astrodata01/astroml_data/sdomlv2_full/sdomlv2.zarr
dataset:
value: SDOMLDatasetV2
num_data_loader_workers:
Expand Down Expand Up @@ -39,3 +39,6 @@ predict:
value: "./output/predictions"
log_dir:
value: "./output/train-sdo-ml"
train:
early_stopping:
value: false
46 changes: 46 additions & 0 deletions config/ce-vae/run-fhnw-2-use-geco.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
model:
load_path:
value: null
data:
data_dir:
value: /mnt/nas05/astrodata01/astroml_data/sdomlv2_full/sdomlv2.zarr
dataset:
value: SDOMLDatasetV2
num_data_loader_workers:
value: 16
prefetch_factor:
value: 8
batch_size:
value: 32
sdo_ml_v2:
train_year:
value:
- "2010"
- "2011"
train_start_date:
value: null
train_end_date:
value: null
test_year:
value:
- "2012"
test_start_date:
value: null
test_end_date:
value: null
train_val_split_ratio:
value: 0.8
train_val_split_temporal_chunk_size:
value: 3d
predict:
mode:
value: sample
pred_dir:
value: "./output/predictions"
log_dir:
value: "./output/train-sdo-ml"
train:
early_stopping:
value: false
use_geco:
value: true
49 changes: 49 additions & 0 deletions config/ce-vae/run-fhnw-full-1.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
model:
load_path:
value: null
data:
data_dir:
value: /mnt/nas05/astrodata01/astroml_data/sdomlv2_full/sdomlv2.zarr
dataset:
value: SDOMLDatasetV2
num_data_loader_workers:
value: 16
prefetch_factor:
value: 8
batch_size:
value: 32
sdo_ml_v2:
train_year:
value:
- "2010"
- "2012"
- "2013"
- "2015"
- "2017"
- "2018"
- "2020"
train_start_date:
value: null
train_end_date:
value: null
test_year:
value:
- "2011"
- "2014"
- "2016"
- "2019"
test_start_date:
value: null
test_end_date:
value: null
train_val_split_ratio:
value: 0.8
train_val_split_temporal_chunk_size:
value: 14d
predict:
mode:
value: sample
pred_dir:
value: "./output/predictions"
log_dir:
value: "./output/train-sdo-ml"
200 changes: 200 additions & 0 deletions notebooks/wandb_utils.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,200 @@
{
"cells": [
{
"cell_type": "markdown",
"id": "01e3c258",
"metadata": {},
"source": [
"## W&B Utils\n",
"\n",
"- https://docs.wandb.ai/guides/track/public-api-guide\n",
"- https://docs.wandb.ai/ref/python/public-api/run"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "68d45422",
"metadata": {},
"outputs": [],
"source": [
"import wandb\n",
"\n",
"api = wandb.Api()\n",
"runs = api.runs(\"mariusgiger/sdo-sood\")"
]
},
{
"cell_type": "code",
"execution_count": 5,
"id": "c47e1ca5",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"run 2nuu15v4 with state finished\n",
"run 38xbbrf0 with state failed\n",
"run 3ctkpft0 with state failed\n",
"run l6lejey1 with state failed\n",
"run te606vkj with state finished\n",
"run 10rtm2tv with state failed\n",
"run 2qvg5dhc with state failed\n",
"run 11lp21yf with state crashed\n",
"run lv2aex4j with state crashed\n",
"run 2zqrqpp5 with state failed\n",
"run 1fzn9092 with state failed\n",
"run 71p99trq with state failed\n",
"run 19dqvasr with state failed\n",
"run 1j3cgzq3 with state failed\n",
"run l8kgeqbn with state finished\n",
"run 21m3ucxd with state crashed\n",
"run 1k4qhlud with state crashed\n",
"run 34eoz7ka with state crashed\n",
"run 106bp0qy with state crashed\n",
"run 1tgfv6rt with state failed\n",
"run 329oose2 with state crashed\n",
"run 1ws7f4rc with state finished\n",
"run 913zh6ar with state crashed\n",
"run 1ygauldv with state crashed\n",
"run 28n7ocav with state finished\n",
"run b6qqdqo5 with state finished\n",
"run 2n3ofmuw with state finished\n",
"run 1np3by0g with state finished\n",
"run 5zupatxn with state finished\n",
"run 3ehknwtk with state finished\n",
"run 3k0flaze with state finished\n",
"run 1lkm6ftd with state failed\n",
"run 36tfoo4q with state finished\n",
"run zh2feqlv with state finished\n",
"run 2pcd3hdj with state failed\n",
"run 3oyydq7x with state finished\n",
"run jzo18qkw with state failed\n",
"run 357id1hx with state failed\n",
"run 1xnegvzy with state failed\n",
"run 3m9oz6rl with state finished\n",
"run 39uy76fo with state failed\n",
"run 33xn5hcx with state failed\n",
"run gqr86jwj with state failed\n",
"run 3ce9byck with state failed\n",
"run 3ov4ixu2 with state failed\n",
"run 1uqu0ukw with state failed\n",
"run 1k4cpb9p with state failed\n",
"run 3ewoto0c with state finished\n",
"run xaaxibor with state finished\n",
"run 3l3x9gtu with state finished\n",
"run 2mh7qvup with state crashed\n",
"run 1pydotta with state crashed\n",
"run 3ljg7ntt with state crashed\n",
"run 2bgltqvu with state finished\n",
"run 2vy9wmmj with state crashed\n",
"run p2whcsa2 with state crashed\n",
"run 2yibaqs3 with state crashed\n",
"run 1lf0wfcr with state crashed\n",
"run g5q6wzg1 with state failed\n",
"run 3ochsc1e with state crashed\n",
"run 3lwpsznj with state crashed\n",
"run 1bxx8kc4 with state crashed\n",
"run 1vuwhzl7 with state crashed\n",
"run 3pe2sjgv with state crashed\n",
"run 10qwufqr with state crashed\n",
"run 1mq33277 with state failed\n",
"run 175qf053 with state crashed\n",
"run 2pkajuoi with state finished\n",
"run 1trtx7b9 with state finished\n",
"run 61fvu79a with state finished\n",
"run 2tf5fl2i with state finished\n",
"run 2nop4en9 with state crashed\n",
"run gnwy0bgq with state failed\n",
"run 3l6ulb81 with state failed\n",
"run 23l9wkl4 with state failed\n",
"run 6nhiyno7 with state failed\n",
"run blta96jh with state failed\n",
"run 3fvwxq7r with state failed\n",
"run gjut85w8 with state crashed\n",
"run 2y1uxe3g with state failed\n",
"run 1t453lx9 with state crashed\n",
"run 3pz9nrut with state failed\n",
"run 10rpx2e9 with state failed\n",
"run 8sfx2dk8 with state failed\n",
"run 2ig8kb8m with state failed\n",
"run 19v4g4la with state failed\n",
"run 20csxu2n with state failed\n",
"run 3hsnu271 with state failed\n",
"run 3hp3q8bv with state failed\n",
"run 174b65vr with state failed\n",
"run 2qrtndq3 with state failed\n",
"run srdsl9bo with state crashed\n",
"run 3idsuzra with state finished\n",
"run 3szlcuro with state crashed\n",
"run 3g8l62fm with state crashed\n",
"run 2gursnum with state crashed\n",
"run 22bdbjt7 with state crashed\n",
"run 389bo70b with state crashed\n",
"run tlh0o8w0 with state failed\n",
"run 3b3p9e71 with state failed\n",
"run 29cpbtho with state failed\n",
"run e7qqqj88 with state failed\n",
"run 2s643qei with state failed\n",
"run 1c64xxjb with state failed\n",
"run 1spxk4ls with state failed\n",
"run 19eosjzt with state failed\n",
"run ovcv7y75 with state failed\n",
"run 176gt7i6 with state failed\n",
"run u0yxay0f with state failed\n",
"run 2565yf2t with state crashed\n",
"run 8vhefnkf with state finished\n",
"run 2ahoewvq with state finished\n"
]
}
],
"source": [
"for run in runs:\n",
" print(f\"run {run.id} with state {run.state}\")"
]
},
{
"cell_type": "code",
"execution_count": 6,
"id": "9289ca86",
"metadata": {},
"outputs": [],
"source": [
"# delete invalid runs\n",
"for run in runs:\n",
" if run.state == \"failed\" or run.state == \"crashed\":\n",
" run.delete(delete_artifacts=True)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "658ee585",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "sdo-cli",
"language": "python",
"name": "sdo-cli"
},
"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.13"
}
},
"nbformat": 4,
"nbformat_minor": 5
}

0 comments on commit b8edb3b

Please sign in to comment.