paddle 1.1.11__tar.gz → 1.1.15__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {paddle-1.1.11 → paddle-1.1.15}/.bumpversion.cfg +2 -2
- paddle-1.1.11/.github/workflows/bump-and-tag.yaml → paddle-1.1.15/.github/workflows/cd.yml +43 -8
- {paddle-1.1.11 → paddle-1.1.15}/.gitignore +4 -0
- paddle-1.1.15/Makefile +61 -0
- paddle-1.1.15/PKG-INFO +161 -0
- paddle-1.1.15/README.md +129 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/entrypoint.sh +0 -10
- {paddle-1.1.11 → paddle-1.1.15}/docker-compose.override.yaml.tmp +12 -2
- {paddle-1.1.11 → paddle-1.1.15}/docker-compose.yaml +6 -2
- paddle-1.1.15/docs/_static/readme-attach.png +0 -0
- paddle-1.1.15/docs/_static/readme-extension.png +0 -0
- paddle-1.1.15/docs/_static/readme-open-folder.png +0 -0
- paddle-1.1.15/docs/_static/temp_paddle.jpg +0 -0
- paddle-1.1.15/docs/content/notebooks/Tutorial-1-SaturnAdiabat.ipynb +19 -0
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/robert.py +1 -3
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/robert.yaml +9 -2
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/shock.py +1 -1
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/straka.py +1 -3
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/straka.yaml +7 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/__init__.py +1 -1
- {paddle-1.1.11 → paddle-1.1.15}/pyproject.toml +1 -1
- paddle-1.1.11/.github/workflows/cd.yml +0 -55
- paddle-1.1.11/Makefile +0 -26
- paddle-1.1.11/PKG-INFO +0 -110
- paddle-1.1.11/README.md +0 -78
- {paddle-1.1.11 → paddle-1.1.15}/.github/workflows/ci.yml +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/.pre-commit-config.yaml +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/LICENSE +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/.dockerignore +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/Dockerfile +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/Dockerfile.cuda +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/nvim/init.lua +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/nvim/lua/plugins.lua +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/requirements.txt +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/scripts/git-done +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/docker/scripts/git-send +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/.gitignore +0 -0
- {paddle-1.1.11/example_py_scripts/data → paddle-1.1.15/example_py_scripts}/saturn1d.yaml +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/shock.yaml +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/example_py_scripts/test_saturn_adiabat.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/crm.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/evolve_kinetics.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/find_init_params.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/nc2pt.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/pt2nc.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/setup_profile.py +0 -0
- {paddle-1.1.11 → paddle-1.1.15}/paddle/write_profile.py +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
[bumpversion]
|
|
2
|
-
current_version = 1.1.
|
|
2
|
+
current_version = 1.1.15
|
|
3
3
|
commit = True
|
|
4
4
|
tag = True
|
|
5
5
|
|
|
6
|
-
[bumpversion:file:
|
|
6
|
+
[bumpversion:file:paddle/__init__.py]
|
|
7
7
|
search = __version__ = "{current_version}"
|
|
8
8
|
replace = __version__ = "{new_version}"
|
|
9
9
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
name:
|
|
1
|
+
name: Release to PyPI
|
|
2
2
|
|
|
3
3
|
on:
|
|
4
4
|
pull_request:
|
|
@@ -9,41 +9,74 @@ env:
|
|
|
9
9
|
PYTHON_VERSION: "3.11"
|
|
10
10
|
|
|
11
11
|
jobs:
|
|
12
|
-
|
|
12
|
+
release:
|
|
13
|
+
if: github.event.pull_request.merged == true
|
|
13
14
|
runs-on: ubuntu-latest
|
|
14
15
|
permissions:
|
|
15
|
-
contents: write
|
|
16
|
-
pull-requests: write
|
|
16
|
+
contents: write # push commits/tags, create release
|
|
17
|
+
pull-requests: write # comment on PR
|
|
18
|
+
id-token: write # needed by PyPI OIDC if you switch to OIDC auth
|
|
17
19
|
|
|
18
20
|
steps:
|
|
19
21
|
- name: Checkout repository
|
|
20
22
|
uses: actions/checkout@v4
|
|
21
23
|
with:
|
|
22
|
-
fetch-depth: 0
|
|
24
|
+
fetch-depth: 0 # need full history for bumpversion/tags
|
|
23
25
|
|
|
24
26
|
- name: Set up Python
|
|
25
27
|
uses: actions/setup-python@v5
|
|
26
28
|
with:
|
|
27
29
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
30
|
+
cache: pip
|
|
28
31
|
|
|
29
32
|
- name: Configure Git
|
|
30
33
|
run: |
|
|
31
34
|
git config user.name "github-actions[bot]"
|
|
32
35
|
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
33
36
|
|
|
34
|
-
|
|
37
|
+
# 🔹 Bump version & create tag (same as before)
|
|
38
|
+
- name: Bump version and create tag
|
|
35
39
|
id: bump_version
|
|
36
40
|
uses: jasonamyers/github-bumpversion-action@v1.0.5
|
|
37
41
|
env:
|
|
38
42
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
39
43
|
|
|
44
|
+
# 🔹 Push the bump commit and tag back to main
|
|
40
45
|
- name: Push changes
|
|
41
46
|
uses: ad-m/github-push-action@master
|
|
42
47
|
with:
|
|
43
48
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
44
|
-
branch: ${{ github.
|
|
49
|
+
branch: ${{ github.base_ref }}
|
|
45
50
|
tags: true
|
|
46
51
|
|
|
52
|
+
# 🔹 Build distribution artifacts
|
|
53
|
+
- name: Build sdist and wheel
|
|
54
|
+
run: |
|
|
55
|
+
python -m pip install --upgrade pip
|
|
56
|
+
pip install build
|
|
57
|
+
python -m build
|
|
58
|
+
|
|
59
|
+
- name: Upload artifacts
|
|
60
|
+
uses: actions/upload-artifact@v4
|
|
61
|
+
with:
|
|
62
|
+
name: dist
|
|
63
|
+
path: dist/*
|
|
64
|
+
|
|
65
|
+
# 🔹 Publish to PyPI
|
|
66
|
+
- name: Download wheels
|
|
67
|
+
uses: actions/download-artifact@v4
|
|
68
|
+
with:
|
|
69
|
+
name: dist
|
|
70
|
+
path: dist
|
|
71
|
+
|
|
72
|
+
- name: Publish to PyPI
|
|
73
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
74
|
+
with:
|
|
75
|
+
user: __token__
|
|
76
|
+
password: ${{ secrets.PYPI_API_TOKEN }}
|
|
77
|
+
verbose: true
|
|
78
|
+
|
|
79
|
+
# 🔹 Generate Release Notes
|
|
47
80
|
- name: Generate Release Notes
|
|
48
81
|
uses: octokit/request-action@v2.x
|
|
49
82
|
id: get_release_notes
|
|
@@ -53,6 +86,7 @@ jobs:
|
|
|
53
86
|
env:
|
|
54
87
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
55
88
|
|
|
89
|
+
# 🔹 Create GitHub Release
|
|
56
90
|
- name: Create GitHub release
|
|
57
91
|
id: create_release
|
|
58
92
|
uses: actions/create-release@v1.1.4
|
|
@@ -65,6 +99,7 @@ jobs:
|
|
|
65
99
|
prerelease: false
|
|
66
100
|
body: ${{ fromJson(steps.get_release_notes.outputs.data).body }}
|
|
67
101
|
|
|
102
|
+
# 🔹 Comment on the PR with release notes
|
|
68
103
|
- name: Post comment on PR with release notes
|
|
69
104
|
uses: actions/github-script@v7
|
|
70
105
|
with:
|
|
@@ -74,5 +109,5 @@ jobs:
|
|
|
74
109
|
issue_number: context.payload.pull_request.number,
|
|
75
110
|
owner: context.repo.owner,
|
|
76
111
|
repo: context.repo.repo,
|
|
77
|
-
body: `🎉 Released v${{ steps.bump_version.outputs.new_ver }}!\n\n${notes}`
|
|
112
|
+
body: `🎉 Released v${{ steps.bump_version.outputs.new_ver }} to PyPI!\n\n${notes}`
|
|
78
113
|
})
|
paddle-1.1.15/Makefile
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
ENV_FILE := .env
|
|
2
|
+
UID := $$(id -u)
|
|
3
|
+
GID := $$(id -g)
|
|
4
|
+
GITCONFIG := $${HOME}/.gitconfig
|
|
5
|
+
GITCREDENTIALS := $${HOME}/.git-credentials
|
|
6
|
+
|
|
7
|
+
.PHONY: help env up down ps start build
|
|
8
|
+
|
|
9
|
+
# Show help for each target
|
|
10
|
+
help: ## Show this help message
|
|
11
|
+
@echo "Available commands:"
|
|
12
|
+
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | \
|
|
13
|
+
awk 'BEGIN {FS = ":.*?## "}; {printf " \033[36m%-12s\033[0m %s\n", $$1, $$2}'
|
|
14
|
+
|
|
15
|
+
env: ## Generate the .env file with git configs first, then user info
|
|
16
|
+
@# Check if either variable is missing
|
|
17
|
+
@if ! grep -q '^GITCONFIG=' $(ENV_FILE) 2>/dev/null || \
|
|
18
|
+
! grep -q '^GITCREDENTIALS=' $(ENV_FILE) 2>/dev/null; then \
|
|
19
|
+
if [ -f "$${HOME}/.gitconfig" ]; then \
|
|
20
|
+
echo "GITCONFIG=$${HOME}/.gitconfig" > $(ENV_FILE); \
|
|
21
|
+
else \
|
|
22
|
+
touch "$${HOME}/.gitconfig"; \
|
|
23
|
+
echo "GITCONFIG=$${HOME}/.gitconfig" > $(ENV_FILE); \
|
|
24
|
+
fi; \
|
|
25
|
+
if [ -f "$${HOME}/.git-credentials" ]; then \
|
|
26
|
+
echo "GITCREDENTIALS=$${HOME}/.git-credentials" >> $(ENV_FILE); \
|
|
27
|
+
else \
|
|
28
|
+
touch "$${HOME}/.git-credentials"; \
|
|
29
|
+
echo "[credential]" >> "$${HOME}/.gitconfig"; \
|
|
30
|
+
echo " helper = store" >> "$${HOME}/.gitconfig"; \
|
|
31
|
+
echo "GITCREDENTIALS=$${HOME}/.git-credentials" >> $(ENV_FILE); \
|
|
32
|
+
fi; \
|
|
33
|
+
echo "USER=$$(id -un)" >> $(ENV_FILE); \
|
|
34
|
+
echo "USER_UID=$$(id -u)" >> $(ENV_FILE); \
|
|
35
|
+
echo "USER_GID=$$(id -g)" >> $(ENV_FILE); \
|
|
36
|
+
echo "Created $(ENV_FILE):"; cat $(ENV_FILE); \
|
|
37
|
+
fi
|
|
38
|
+
|
|
39
|
+
up: env ## Start docker containers in the background
|
|
40
|
+
@docker compose up -d
|
|
41
|
+
@docker compose exec dev bash -c '\
|
|
42
|
+
USER_HOME=$$(eval echo ~$$USERNAME); \
|
|
43
|
+
if [ -f /etc/git-credentials ] && [ ! -f $$USER_HOME/.git-credentials ]; then \
|
|
44
|
+
cp /etc/git-credentials $$USER_HOME/.git-credentials; \
|
|
45
|
+
chown $${USER_UID}:$${USER_GID} $$USER_HOME/.git-credentials; \
|
|
46
|
+
git config --global credential.helper store; \
|
|
47
|
+
fi \
|
|
48
|
+
'
|
|
49
|
+
|
|
50
|
+
down: env ## Stop and remove docker containers
|
|
51
|
+
@docker compose down
|
|
52
|
+
|
|
53
|
+
ps: env ## Show container status
|
|
54
|
+
@docker compose ps
|
|
55
|
+
|
|
56
|
+
start: env ## Open a bash shell inside the 'dev' container as the host user, exit without error
|
|
57
|
+
@docker compose exec --user $(UID):$(GID) dev \
|
|
58
|
+
bash -c 'git config --global --add safe.directory /paddle; exec bash'
|
|
59
|
+
|
|
60
|
+
build: env ## Build (or rebuild) the 'dev' container and start it
|
|
61
|
+
@docker compose up -d --build dev
|
paddle-1.1.15/PKG-INFO
ADDED
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: paddle
|
|
3
|
+
Version: 1.1.15
|
|
4
|
+
Summary: Python Atmospheric Dynamics: Discovery and Learning about Exoplanets. An open-source, user-friendly python frontend of canoe
|
|
5
|
+
Project-URL: Homepage, https://github.com/elijah-mullens/paddle
|
|
6
|
+
Project-URL: Repository, https://github.com/elijah-mullens/paddle
|
|
7
|
+
Project-URL: Issues, https://github.com/elijah-mullens/paddle/issues
|
|
8
|
+
Author-email: Elijah Mullens <eem85@cornell.edu>, Cheng Li <chengcli@umich.edu>
|
|
9
|
+
License-File: LICENSE
|
|
10
|
+
Classifier: Development Status :: 3 - Alpha
|
|
11
|
+
Classifier: Intended Audience :: Developers
|
|
12
|
+
Classifier: Intended Audience :: Science/Research
|
|
13
|
+
Classifier: Programming Language :: Python
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Topic :: Scientific/Engineering :: Astronomy
|
|
22
|
+
Classifier: Topic :: Scientific/Engineering :: Atmospheric Science
|
|
23
|
+
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
24
|
+
Requires-Python: >=3.9
|
|
25
|
+
Requires-Dist: kintera>=1.1.5
|
|
26
|
+
Requires-Dist: scipy
|
|
27
|
+
Requires-Dist: snapy>=0.8.1
|
|
28
|
+
Requires-Dist: torch<=2.7.1,>=2.7.0
|
|
29
|
+
Provides-Extra: dev
|
|
30
|
+
Requires-Dist: pytest>=7; extra == 'dev'
|
|
31
|
+
Description-Content-Type: text/markdown
|
|
32
|
+
|
|
33
|
+
# Paddle
|
|
34
|
+
|
|
35
|
+
Python Atmospheric Dynamics: Discovering and Learning about Exoplanets. An open-source, user-friendly Python version of [canoe](https://github.com/chengcli/canoe).
|
|
36
|
+
|
|
37
|
+
## Test the package
|
|
38
|
+
|
|
39
|
+
Testing the package can be done very easily by following the steps below. All we need is to create a python virtual environment, install the package, and run the test script.
|
|
40
|
+
|
|
41
|
+
1. Create a python virtual environment
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
python -m venv pyenv
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
2. Install paddle package
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
pip install paddle
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
3. Run test
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
cd tests
|
|
57
|
+
python test_saturn_adiabat.py
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Develop with Docker
|
|
61
|
+
|
|
62
|
+
You may need to install Docker to compose up and install the package inside a container if your device or operating system does not support certain dependencies. Follow the instructions below to install docker and docker-compose plugin.
|
|
63
|
+
|
|
64
|
+
1. Install docker with compose
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
curl -fsSL https://get.docker.com | sudo sh
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
2. Start docker using the command below or open docker desktop if applicable.
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
sudo systemctl start docker
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
After installing Docker, you can use the Makefile commands below to manage your docker containers from the terminal. By default, the container will mount the current directory to `/paddle` inside the container.
|
|
77
|
+
|
|
78
|
+
> Mounting a local directory allows you to edit files on your local machine while running and testing the code inside the container; or use the container as a development environment and sync files to your local machine.
|
|
79
|
+
|
|
80
|
+
If you want to change the mounted directory, you can create a `docker-compose.overrides.yml` file based on the provided `docker-compose.overrides.yml.tmp` template file.
|
|
81
|
+
|
|
82
|
+
- Create a docker container
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
make up
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
- Start a docker container (only if previously created)
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
make start
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
- Terminate a docker container
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
make down
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
- Build a new docker image (rarely used)
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
make build
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
If you use VSCode, it is recommended to install extensions including [Remote Development](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack), [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) and [Container Tools](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-containers) for a better development experience within a container.
|
|
107
|
+
|
|
108
|
+
1. Install the extensions mentioned above.
|
|
109
|
+
2. Start the container using `make up` or `make start`.
|
|
110
|
+
3. Open VSCode and click on the "Containers" icon on the left sidebar. Note that if you have too many extensions installed, the icon may be hidden under the "..." menu.
|
|
111
|
+
|
|
112
|
+
<img src="docs/_static/readme-extension.png" width="200" style="vertical-align: top;">
|
|
113
|
+
<img src="docs/_static/readme-attach.png" width="200" style="vertical-align: top;">
|
|
114
|
+
|
|
115
|
+
4. Right click on the running container named `paddle` with a green triangle icon (indicating it is running), and select "Attach Visual Studio Code" (see above images). This will open a new VSCode window connected to the container.
|
|
116
|
+
5. Open either the default folder `paddle` mounted from your local machine, or any custom workspace folder you have set up inside the `docker-compose.overrides.yml` file. Now you can start developing inside the container as if you were working on your local machine!
|
|
117
|
+
|
|
118
|
+
<img src="docs/_static/readme-open-folder.png" width="500" style="vertical-align: top;">
|
|
119
|
+
|
|
120
|
+
## For Developers
|
|
121
|
+
|
|
122
|
+
Follow the steps below to set up your development environment.
|
|
123
|
+
|
|
124
|
+
1. Clone the repository
|
|
125
|
+
|
|
126
|
+
```bash
|
|
127
|
+
https://github.com/elijah-mullens/paddle
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
2. Cache your github credential. This will prevent you from being prompted for your username and password every time you push changes to github.
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
git config credential.helper 'cache --timeout=86400'
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
3. Create a python virtual environment.
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
python -m venv .pyenv
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
4. Install paddle package
|
|
143
|
+
|
|
144
|
+
```bash
|
|
145
|
+
# Install the package normally
|
|
146
|
+
pip install paddle
|
|
147
|
+
|
|
148
|
+
# [Alternatively] if you want to install in editable mode
|
|
149
|
+
pip install -e .
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
5. Install pre-commit hook. This will automatically format your code before each commit to ensure consistent code style.
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
pip install pre-commit
|
|
156
|
+
pre-commit install
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
## Troubleshooting
|
|
160
|
+
|
|
161
|
+
1. If you have Docker installed but do not have Docker Compose, remove your current Docker installation, which could be docker or docker.io, and re-install it following the guide provided in the [Develop with Docker](#develop-with-docker) section above.
|
paddle-1.1.15/README.md
ADDED
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
# Paddle
|
|
2
|
+
|
|
3
|
+
Python Atmospheric Dynamics: Discovering and Learning about Exoplanets. An open-source, user-friendly Python version of [canoe](https://github.com/chengcli/canoe).
|
|
4
|
+
|
|
5
|
+
## Test the package
|
|
6
|
+
|
|
7
|
+
Testing the package can be done very easily by following the steps below. All we need is to create a python virtual environment, install the package, and run the test script.
|
|
8
|
+
|
|
9
|
+
1. Create a python virtual environment
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
python -m venv pyenv
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
2. Install paddle package
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
pip install paddle
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
3. Run test
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
cd tests
|
|
25
|
+
python test_saturn_adiabat.py
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Develop with Docker
|
|
29
|
+
|
|
30
|
+
You may need to install Docker to compose up and install the package inside a container if your device or operating system does not support certain dependencies. Follow the instructions below to install docker and docker-compose plugin.
|
|
31
|
+
|
|
32
|
+
1. Install docker with compose
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
curl -fsSL https://get.docker.com | sudo sh
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
2. Start docker using the command below or open docker desktop if applicable.
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
sudo systemctl start docker
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
After installing Docker, you can use the Makefile commands below to manage your docker containers from the terminal. By default, the container will mount the current directory to `/paddle` inside the container.
|
|
45
|
+
|
|
46
|
+
> Mounting a local directory allows you to edit files on your local machine while running and testing the code inside the container; or use the container as a development environment and sync files to your local machine.
|
|
47
|
+
|
|
48
|
+
If you want to change the mounted directory, you can create a `docker-compose.overrides.yml` file based on the provided `docker-compose.overrides.yml.tmp` template file.
|
|
49
|
+
|
|
50
|
+
- Create a docker container
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
make up
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
- Start a docker container (only if previously created)
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
make start
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
- Terminate a docker container
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
make down
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
- Build a new docker image (rarely used)
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
make build
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
If you use VSCode, it is recommended to install extensions including [Remote Development](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack), [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) and [Container Tools](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-containers) for a better development experience within a container.
|
|
75
|
+
|
|
76
|
+
1. Install the extensions mentioned above.
|
|
77
|
+
2. Start the container using `make up` or `make start`.
|
|
78
|
+
3. Open VSCode and click on the "Containers" icon on the left sidebar. Note that if you have too many extensions installed, the icon may be hidden under the "..." menu.
|
|
79
|
+
|
|
80
|
+
<img src="docs/_static/readme-extension.png" width="200" style="vertical-align: top;">
|
|
81
|
+
<img src="docs/_static/readme-attach.png" width="200" style="vertical-align: top;">
|
|
82
|
+
|
|
83
|
+
4. Right click on the running container named `paddle` with a green triangle icon (indicating it is running), and select "Attach Visual Studio Code" (see above images). This will open a new VSCode window connected to the container.
|
|
84
|
+
5. Open either the default folder `paddle` mounted from your local machine, or any custom workspace folder you have set up inside the `docker-compose.overrides.yml` file. Now you can start developing inside the container as if you were working on your local machine!
|
|
85
|
+
|
|
86
|
+
<img src="docs/_static/readme-open-folder.png" width="500" style="vertical-align: top;">
|
|
87
|
+
|
|
88
|
+
## For Developers
|
|
89
|
+
|
|
90
|
+
Follow the steps below to set up your development environment.
|
|
91
|
+
|
|
92
|
+
1. Clone the repository
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
https://github.com/elijah-mullens/paddle
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
2. Cache your github credential. This will prevent you from being prompted for your username and password every time you push changes to github.
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
git config credential.helper 'cache --timeout=86400'
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
3. Create a python virtual environment.
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
python -m venv .pyenv
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
4. Install paddle package
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
# Install the package normally
|
|
114
|
+
pip install paddle
|
|
115
|
+
|
|
116
|
+
# [Alternatively] if you want to install in editable mode
|
|
117
|
+
pip install -e .
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
5. Install pre-commit hook. This will automatically format your code before each commit to ensure consistent code style.
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
pip install pre-commit
|
|
124
|
+
pre-commit install
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
## Troubleshooting
|
|
128
|
+
|
|
129
|
+
1. If you have Docker installed but do not have Docker Compose, remove your current Docker installation, which could be docker or docker.io, and re-install it following the guide provided in the [Develop with Docker](#develop-with-docker) section above.
|
|
@@ -34,16 +34,6 @@ done
|
|
|
34
34
|
echo 'export EDITOR=nvim; export VISUAL=nvim' >> "${HOME_DIR}/.bashrc" || true
|
|
35
35
|
chown "${USER_UID}:${USER_GID}" "${HOME_DIR}/.bashrc" || true
|
|
36
36
|
|
|
37
|
-
# Configure git
|
|
38
|
-
if [ -f /host/.gitconfig ] && [ ! -e "${HOME_DIR}/.gitconfig" ]; then
|
|
39
|
-
ln -s /host/.gitconfig "${HOME_DIR}/.gitconfig"
|
|
40
|
-
chown -h "${USER_UID}:${USER_GID}" "${HOME_DIR}/.gitconfig" || true
|
|
41
|
-
|
|
42
|
-
#cp /host/.gitconfig "${HOME_DIR}/.gitconfig"
|
|
43
|
-
#chown "${USER_UID}:${USER_GID}" "${HOME_DIR}/.gitconfig"
|
|
44
|
-
#chmod 600 "${HOME_DIR}/.gitconfig"
|
|
45
|
-
fi
|
|
46
|
-
|
|
47
37
|
# Drop privileges (use tini/gosu if installed; otherwise su-exec/ runuser)
|
|
48
38
|
if command -v gosu >/dev/null 2>&1; then
|
|
49
39
|
exec gosu "${USER_UID}:${USER_GID}" "$@"
|
|
@@ -1,12 +1,22 @@
|
|
|
1
1
|
services:
|
|
2
2
|
dev:
|
|
3
|
+
build:
|
|
4
|
+
dockerfile: docker/Dockerfile.cuda
|
|
5
|
+
args:
|
|
6
|
+
CUDA_VER: "12.9.1"
|
|
7
|
+
deploy:
|
|
8
|
+
resources:
|
|
9
|
+
reservations:
|
|
10
|
+
devices:
|
|
11
|
+
# Activate this if your system supports GPU
|
|
12
|
+
- capabilities: [gpu]
|
|
3
13
|
volumes:
|
|
4
14
|
# This maps your physical locations to locations in docker
|
|
5
15
|
# (lhs:rhs, lhs = workspace on physical machine : rhs = workspace on virtual machine)
|
|
6
16
|
# Here we set up two directorys: your docker workspace directory that stores paddle
|
|
7
|
-
# (all py scripts and notebooks)
|
|
17
|
+
# (all py scripts and notebooks)
|
|
8
18
|
# And your data directory, that stores large data products ('results')
|
|
9
|
-
# While this data directory won't always be used
|
|
19
|
+
# While this data directory won't always be used
|
|
10
20
|
# (you can optionally have smaller outputs stored locally in the workspace directory)
|
|
11
21
|
# It is useful for very large data products, like those of gcm or mcmc scripts.
|
|
12
22
|
- path_to_physical_directory/paddle_docker_workspace:/paddle_docker_workspace
|
|
@@ -11,8 +11,12 @@ services:
|
|
|
11
11
|
- USERNAME=${USER}
|
|
12
12
|
- USER_UID=${USER_UID}
|
|
13
13
|
- USER_GID=${USER_GID}
|
|
14
|
-
|
|
14
|
+
volumes:
|
|
15
|
+
- .:/paddle
|
|
16
|
+
- ${GITCONFIG}:/etc/gitconfig
|
|
17
|
+
- ${GITCREDENTIALS}:/etc/git-credentials
|
|
18
|
+
working_dir: /paddle
|
|
15
19
|
tty: true
|
|
16
20
|
stdin_open: true
|
|
17
21
|
ports:
|
|
18
|
-
- "8888:8888"
|
|
22
|
+
- "8888:8888"
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cells": [
|
|
3
|
+
{
|
|
4
|
+
"cell_type": "code",
|
|
5
|
+
"execution_count": null,
|
|
6
|
+
"id": "17fa4485",
|
|
7
|
+
"metadata": {},
|
|
8
|
+
"outputs": [],
|
|
9
|
+
"source": []
|
|
10
|
+
}
|
|
11
|
+
],
|
|
12
|
+
"metadata": {
|
|
13
|
+
"language_info": {
|
|
14
|
+
"name": "python"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"nbformat": 4,
|
|
18
|
+
"nbformat_minor": 5
|
|
19
|
+
}
|
|
@@ -73,13 +73,12 @@ w[kIDN] = w[kIPR] / (Rd * temp)
|
|
|
73
73
|
|
|
74
74
|
block_vars = {}
|
|
75
75
|
block_vars["hydro_w"] = w
|
|
76
|
-
block_vars = block.initialize(block_vars)
|
|
76
|
+
block_vars, current_time = block.initialize(block_vars)
|
|
77
77
|
|
|
78
78
|
block.set_user_output_func(call_user_output)
|
|
79
79
|
|
|
80
80
|
# integration
|
|
81
81
|
start_time = time.time()
|
|
82
|
-
current_time = 0.0
|
|
83
82
|
block.make_outputs(block_vars, current_time)
|
|
84
83
|
|
|
85
84
|
while not block.intg.stop(block.inc_cycle(), current_time):
|
|
@@ -99,4 +98,3 @@ while not block.intg.stop(block.inc_cycle(), current_time):
|
|
|
99
98
|
block.make_outputs(block_vars, current_time)
|
|
100
99
|
|
|
101
100
|
block.finalize(block_vars, current_time)
|
|
102
|
-
print("elapsed time = ", time.time() - start_time)
|
|
@@ -12,6 +12,13 @@ geometry:
|
|
|
12
12
|
bounds: {x1min: 0., x1max: 1.5e3, x2min: 0., x2max: 1.e3, x3min: -0.5, x3max: 0.5}
|
|
13
13
|
cells: {nx1: 300, nx2: 200, nx3: 1, nghost: 3}
|
|
14
14
|
|
|
15
|
+
distribute:
|
|
16
|
+
backend: gloo
|
|
17
|
+
layout: slab
|
|
18
|
+
nb2: 4
|
|
19
|
+
nb3: 1
|
|
20
|
+
verbose: false
|
|
21
|
+
|
|
15
22
|
dynamics:
|
|
16
23
|
equation-of-state:
|
|
17
24
|
type: ideal-gas
|
|
@@ -24,8 +31,8 @@ dynamics:
|
|
|
24
31
|
pressure-margin: 1.e-6
|
|
25
32
|
|
|
26
33
|
reconstruct:
|
|
27
|
-
vertical: {type: weno5, scale: false, shock:
|
|
28
|
-
horizontal: {type: weno5, scale: false, shock:
|
|
34
|
+
vertical: {type: weno5, scale: false, shock: false}
|
|
35
|
+
horizontal: {type: weno5, scale: false, shock: false}
|
|
29
36
|
|
|
30
37
|
riemann-solver:
|
|
31
38
|
type: lmars
|
|
@@ -42,7 +42,7 @@ solid = torch.where(r1 < 0.1, 1, 0).to(torch.bool)
|
|
|
42
42
|
block_vars = {}
|
|
43
43
|
block_vars["hydro_w"] = w
|
|
44
44
|
block_vars["solid"] = solid
|
|
45
|
-
block_vars = block.initialize(block_vars)
|
|
45
|
+
block_vars, current_time = block.initialize(block_vars)
|
|
46
46
|
|
|
47
47
|
# integration
|
|
48
48
|
current_time = 0.0
|
|
@@ -72,13 +72,12 @@ w[kIDN] = w[kIPR] / (Rd * temp)
|
|
|
72
72
|
|
|
73
73
|
block_vars = {}
|
|
74
74
|
block_vars["hydro_w"] = w
|
|
75
|
-
block_vars = block.initialize(block_vars)
|
|
75
|
+
block_vars, current_time = block.initialize(block_vars)
|
|
76
76
|
|
|
77
77
|
block.set_user_output_func(call_user_output)
|
|
78
78
|
|
|
79
79
|
# integration
|
|
80
80
|
start_time = time.time()
|
|
81
|
-
current_time = 0.0
|
|
82
81
|
block.make_outputs(block_vars, current_time)
|
|
83
82
|
|
|
84
83
|
while not block.intg.stop(block.inc_cycle(), current_time):
|
|
@@ -98,4 +97,3 @@ while not block.intg.stop(block.inc_cycle(), current_time):
|
|
|
98
97
|
block.make_outputs(block_vars, current_time)
|
|
99
98
|
|
|
100
99
|
block.finalize(block_vars, current_time)
|
|
101
|
-
print("elapsed time = ", time.time() - start_time)
|
|
@@ -12,6 +12,13 @@ geometry:
|
|
|
12
12
|
bounds: {x1min: 0., x1max: 6.4e3, x2min: 0., x2max: 25.6e3, x3min: 0., x3max: 25.6e3}
|
|
13
13
|
cells: {nx1: 64, nx2: 256, nx3: 1, nghost: 3}
|
|
14
14
|
|
|
15
|
+
distribute:
|
|
16
|
+
backend: gloo
|
|
17
|
+
layout: slab
|
|
18
|
+
nb2: 1
|
|
19
|
+
nb3: 1
|
|
20
|
+
verbose: false
|
|
21
|
+
|
|
15
22
|
dynamics:
|
|
16
23
|
equation-of-state:
|
|
17
24
|
type: ideal-gas
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "paddle"
|
|
7
|
-
version = "1.1.
|
|
7
|
+
version = "1.1.15"
|
|
8
8
|
description = "Python Atmospheric Dynamics: Discovery and Learning about Exoplanets. An open-source, user-friendly python frontend of canoe"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.9"
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
name: Deploy to PyPI
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [main]
|
|
6
|
-
tags: [v*]
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
build:
|
|
10
|
-
name: Build distribution artifacts
|
|
11
|
-
runs-on: ubuntu-latest
|
|
12
|
-
steps:
|
|
13
|
-
- name: Checkout code
|
|
14
|
-
uses: actions/checkout@v4
|
|
15
|
-
|
|
16
|
-
- name: Setup Host Python
|
|
17
|
-
uses: actions/setup-python@v5
|
|
18
|
-
with:
|
|
19
|
-
python-version: "3.11"
|
|
20
|
-
cache: pip
|
|
21
|
-
|
|
22
|
-
- name: Install build backend
|
|
23
|
-
run: |
|
|
24
|
-
python -m pip install --upgrade pip
|
|
25
|
-
pip install build
|
|
26
|
-
|
|
27
|
-
- name: Build sdist and wheel
|
|
28
|
-
run: python -m build
|
|
29
|
-
|
|
30
|
-
- name: Upload artifacts
|
|
31
|
-
uses: actions/upload-artifact@v4
|
|
32
|
-
with:
|
|
33
|
-
name: dist
|
|
34
|
-
path: dist/*
|
|
35
|
-
|
|
36
|
-
publish-pypi:
|
|
37
|
-
name: Publish to PyPI
|
|
38
|
-
needs: build
|
|
39
|
-
runs-on: ubuntu-latest
|
|
40
|
-
permissions:
|
|
41
|
-
id-token: write
|
|
42
|
-
contents: read
|
|
43
|
-
steps:
|
|
44
|
-
- name: Download wheels
|
|
45
|
-
uses: actions/download-artifact@v4
|
|
46
|
-
with:
|
|
47
|
-
name: dist
|
|
48
|
-
path: dist
|
|
49
|
-
|
|
50
|
-
- name: Publish to PyPI
|
|
51
|
-
uses: pypa/gh-action-pypi-publish@release/v1
|
|
52
|
-
with:
|
|
53
|
-
user: __token__
|
|
54
|
-
password: ${{ secrets.PYPI_API_TOKEN }}
|
|
55
|
-
verbose: true
|
paddle-1.1.11/Makefile
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
ENV_FILE := .env
|
|
2
|
-
UID := $$(id -u)
|
|
3
|
-
GID := $$(id -g)
|
|
4
|
-
|
|
5
|
-
.PHONY: env up down build
|
|
6
|
-
|
|
7
|
-
env:
|
|
8
|
-
@echo "USER=$$(id -un)" > $(ENV_FILE)
|
|
9
|
-
@echo "USER_UID=$$(id -u)" >> $(ENV_FILE)
|
|
10
|
-
@echo "USER_GID=$$(id -g)" >> $(ENV_FILE)
|
|
11
|
-
@echo "Wrote $(ENV_FILE):"; cat $(ENV_FILE)
|
|
12
|
-
|
|
13
|
-
up: env
|
|
14
|
-
@docker compose up -d
|
|
15
|
-
|
|
16
|
-
down:
|
|
17
|
-
@docker compose down
|
|
18
|
-
|
|
19
|
-
ps:
|
|
20
|
-
@docker compose ps
|
|
21
|
-
|
|
22
|
-
start:
|
|
23
|
-
@docker compose exec --user $(UID):$(GID) dev bash
|
|
24
|
-
|
|
25
|
-
build: env
|
|
26
|
-
@docker compose up -d --build dev
|
paddle-1.1.11/PKG-INFO
DELETED
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: paddle
|
|
3
|
-
Version: 1.1.11
|
|
4
|
-
Summary: Python Atmospheric Dynamics: Discovery and Learning about Exoplanets. An open-source, user-friendly python frontend of canoe
|
|
5
|
-
Project-URL: Homepage, https://github.com/elijah-mullens/paddle
|
|
6
|
-
Project-URL: Repository, https://github.com/elijah-mullens/paddle
|
|
7
|
-
Project-URL: Issues, https://github.com/elijah-mullens/paddle/issues
|
|
8
|
-
Author-email: Elijah Mullens <eem85@cornell.edu>, Cheng Li <chengcli@umich.edu>
|
|
9
|
-
License-File: LICENSE
|
|
10
|
-
Classifier: Development Status :: 3 - Alpha
|
|
11
|
-
Classifier: Intended Audience :: Developers
|
|
12
|
-
Classifier: Intended Audience :: Science/Research
|
|
13
|
-
Classifier: Programming Language :: Python
|
|
14
|
-
Classifier: Programming Language :: Python :: 3
|
|
15
|
-
Classifier: Programming Language :: Python :: 3 :: Only
|
|
16
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
17
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
18
|
-
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
-
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
-
Classifier: Topic :: Scientific/Engineering :: Astronomy
|
|
22
|
-
Classifier: Topic :: Scientific/Engineering :: Atmospheric Science
|
|
23
|
-
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
24
|
-
Requires-Python: >=3.9
|
|
25
|
-
Requires-Dist: kintera>=1.1.5
|
|
26
|
-
Requires-Dist: scipy
|
|
27
|
-
Requires-Dist: snapy>=0.8.1
|
|
28
|
-
Requires-Dist: torch<=2.7.1,>=2.7.0
|
|
29
|
-
Provides-Extra: dev
|
|
30
|
-
Requires-Dist: pytest>=7; extra == 'dev'
|
|
31
|
-
Description-Content-Type: text/markdown
|
|
32
|
-
|
|
33
|
-
# paddle
|
|
34
|
-
Python Atmospheric Dynamics: Discovering and Learning about Exoplanets. An open-source, user-friendly python version of canoe.
|
|
35
|
-
|
|
36
|
-
## Install docker and docker-compose plugin
|
|
37
|
-
1. install docker with compose
|
|
38
|
-
```bash
|
|
39
|
-
curl -fsSL https://get.docker.com | sudo sh
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
1. start docker
|
|
43
|
-
sudo systemctl start docker
|
|
44
|
-
|
|
45
|
-
## Test package
|
|
46
|
-
1. Create a python virtual environment
|
|
47
|
-
```bash
|
|
48
|
-
python -m venv pyenv
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
2. Install paddle package
|
|
52
|
-
```bash
|
|
53
|
-
pip install paddle
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
3. Run test
|
|
57
|
-
```bash
|
|
58
|
-
cd tests
|
|
59
|
-
python test_saturn_adiabat.py
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
## Docker user guide
|
|
63
|
-
|
|
64
|
-
2. Create a docker container
|
|
65
|
-
```bash
|
|
66
|
-
make up
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
3. Terminate a docker container
|
|
70
|
-
```bash
|
|
71
|
-
make down
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
4. Start a docker container
|
|
75
|
-
```bash
|
|
76
|
-
make start
|
|
77
|
-
```
|
|
78
|
-
|
|
79
|
-
5. Build a new docker image (rarely used)
|
|
80
|
-
```bash
|
|
81
|
-
make build
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
## For Developer
|
|
85
|
-
|
|
86
|
-
### Clone repository
|
|
87
|
-
```bash
|
|
88
|
-
https://github.com/elijah-mullens/paddle
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
### Cache your github credential
|
|
92
|
-
```bash
|
|
93
|
-
git config credential.helper 'cache --timeout=86400'
|
|
94
|
-
```
|
|
95
|
-
|
|
96
|
-
### Install paddle package
|
|
97
|
-
|
|
98
|
-
### Install pre-commit hook
|
|
99
|
-
```bash
|
|
100
|
-
pip install pre-commit
|
|
101
|
-
```
|
|
102
|
-
|
|
103
|
-
### Install pre-commit hook
|
|
104
|
-
```bash
|
|
105
|
-
pre-commit install
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
## Troubleshooting
|
|
109
|
-
1. If you do not have docker compose
|
|
110
|
-
Remove your current docker installation, it could be docker or docker.io
|
paddle-1.1.11/README.md
DELETED
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
# paddle
|
|
2
|
-
Python Atmospheric Dynamics: Discovering and Learning about Exoplanets. An open-source, user-friendly python version of canoe.
|
|
3
|
-
|
|
4
|
-
## Install docker and docker-compose plugin
|
|
5
|
-
1. install docker with compose
|
|
6
|
-
```bash
|
|
7
|
-
curl -fsSL https://get.docker.com | sudo sh
|
|
8
|
-
```
|
|
9
|
-
|
|
10
|
-
1. start docker
|
|
11
|
-
sudo systemctl start docker
|
|
12
|
-
|
|
13
|
-
## Test package
|
|
14
|
-
1. Create a python virtual environment
|
|
15
|
-
```bash
|
|
16
|
-
python -m venv pyenv
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
2. Install paddle package
|
|
20
|
-
```bash
|
|
21
|
-
pip install paddle
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
3. Run test
|
|
25
|
-
```bash
|
|
26
|
-
cd tests
|
|
27
|
-
python test_saturn_adiabat.py
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
## Docker user guide
|
|
31
|
-
|
|
32
|
-
2. Create a docker container
|
|
33
|
-
```bash
|
|
34
|
-
make up
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
3. Terminate a docker container
|
|
38
|
-
```bash
|
|
39
|
-
make down
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
4. Start a docker container
|
|
43
|
-
```bash
|
|
44
|
-
make start
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
5. Build a new docker image (rarely used)
|
|
48
|
-
```bash
|
|
49
|
-
make build
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
## For Developer
|
|
53
|
-
|
|
54
|
-
### Clone repository
|
|
55
|
-
```bash
|
|
56
|
-
https://github.com/elijah-mullens/paddle
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
### Cache your github credential
|
|
60
|
-
```bash
|
|
61
|
-
git config credential.helper 'cache --timeout=86400'
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
### Install paddle package
|
|
65
|
-
|
|
66
|
-
### Install pre-commit hook
|
|
67
|
-
```bash
|
|
68
|
-
pip install pre-commit
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
### Install pre-commit hook
|
|
72
|
-
```bash
|
|
73
|
-
pre-commit install
|
|
74
|
-
```
|
|
75
|
-
|
|
76
|
-
## Troubleshooting
|
|
77
|
-
1. If you do not have docker compose
|
|
78
|
-
Remove your current docker installation, it could be docker or docker.io
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|