Skip to content

Commit 05369f9

Browse files
authored
Merge pull request #1 from petebachant/main
Add content
2 parents f88c05f + 571d9db commit 05369f9

13 files changed

Lines changed: 200 additions & 2 deletions

File tree

.dvc/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
/config.local
2+
/tmp
3+
/cache

.dvc/config

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[core]
2+
remote = calkit
3+
['remote "calkit"']
4+
url = https://api.calkit.io/projects/petebachant/example-basic/dvc
5+
auth = custom

.dvcignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Add patterns of files dvc should ignore, which could improve
2+
# the performance. Learn more at
3+
# https://dvc.org/doc/user-guide/dvcignore

README.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,14 @@
1-
# example-basic
2-
A basic Calkit example.
1+
# Basic Calkit example
2+
3+
## How this was setup
4+
5+
1. Created a repo on GitHub.
6+
2. Imported into [Calkit](https://calkit.io).
7+
3. Ran `dvc init` and committed changes.
8+
4. Ran `calkit new question "Can we make reproducibility simple?" --commit`.
9+
5. `dvc stage add -n collect-data -o data/raw/data.csv -d scripts/collect-data.py`
10+
6. Ran `dvc repro`, then `git add .` and `git commit -m ...` and `dvc push`
11+
to get everything up to the cloud.
12+
6. Added a script and DVC stage to create a figure, similar to the two steps
13+
above.
14+
7. Added the figure to `calkit.yaml` by editing the `figures` section manually.

calkit.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
questions:
2+
- Can we make reproducibility simple?
3+
datasets:
4+
- path: data/raw/data.csv
5+
title: Raw data
6+
description: This is raw voltage data.
7+
figures:
8+
- path: figures/voltage-time-series.png
9+
title: Raw voltage time series
10+
description: A plot of the raw voltage time series.
11+
publications:
12+
- path: paper/paper.pdf
13+
title: The paper
14+
description: This is the paper.

data/raw/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/data.csv

dvc.lock

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
schema: '2.0'
2+
stages:
3+
collect-data:
4+
cmd: python scripts/collect-data.py
5+
deps:
6+
- path: scripts/collect-data.py
7+
hash: md5
8+
md5: 570acda0f323c18ae0a336583e9d661d
9+
size: 424
10+
outs:
11+
- path: data/raw/data.csv
12+
hash: md5
13+
md5: 1eec95cacd0a1ad08e06b727d8b701c2
14+
size: 43618
15+
plot-voltage:
16+
cmd: python scripts/plot-voltage.py
17+
deps:
18+
- path: data/raw/data.csv
19+
hash: md5
20+
md5: 1eec95cacd0a1ad08e06b727d8b701c2
21+
size: 43618
22+
- path: scripts/plot-voltage.py
23+
hash: md5
24+
md5: 087a567a0c0f6199a908399013d564a1
25+
size: 297
26+
outs:
27+
- path: figures/voltage-time-series.png
28+
hash: md5
29+
md5: a4fc5ebee750a839c23baee1e58bf94a
30+
size: 45123
31+
copy-figures-to-paper-dir:
32+
cmd: cp -r figures paper/figures
33+
deps:
34+
- path: figures
35+
hash: md5
36+
md5: d6fd2418e3b774996ddd0f26715c36ac.dir
37+
size: 45148
38+
nfiles: 2
39+
outs:
40+
- path: paper/figures
41+
hash: md5
42+
md5: d6fd2418e3b774996ddd0f26715c36ac.dir
43+
size: 45148
44+
nfiles: 2
45+
build-paper:
46+
cmd: latexmk -pdf paper.tex
47+
deps:
48+
- path: ../figures
49+
hash: md5
50+
md5: d6fd2418e3b774996ddd0f26715c36ac.dir
51+
size: 45148
52+
nfiles: 2
53+
- path: paper.tex
54+
hash: md5
55+
md5: f0c474020965d39585a2c0cc99d6cb8f
56+
size: 519
57+
outs:
58+
- path: paper.pdf
59+
hash: md5
60+
md5: c736dfef6da2768017e4cb293adcaa3e
61+
size: 89940

dvc.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
stages:
2+
collect-data:
3+
cmd: python scripts/collect-data.py
4+
deps:
5+
- scripts/collect-data.py
6+
outs:
7+
- data/raw/data.csv
8+
plot-voltage:
9+
cmd: python scripts/plot-voltage.py
10+
deps:
11+
- scripts/plot-voltage.py
12+
- data/raw/data.csv
13+
outs:
14+
- figures/voltage-time-series.png
15+
build-paper:
16+
cmd: latexmk -pdf paper.tex
17+
wdir: paper
18+
deps:
19+
- ../figures
20+
- paper.tex
21+
outs:
22+
- paper.pdf

figures/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/voltage-time-series.png

paper/.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
figures
2+
*.aux
3+
*.dvi
4+
*.fdb_latexmk
5+
*.fls
6+
/paper.pdf

0 commit comments

Comments
 (0)