Skip to content

Commit db6a4f4

Browse files
committed
Merge branch 'main' of github.com:dara-network/gooey-gpu into seamless_v2
# Conflicts: # celeryconfig.py # chart/model-values.yaml # common/requirements.txt
2 parents 73ff9c5 + beaaafd commit db6a4f4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

79 files changed

+1290
-62101
lines changed

.dockerignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
checkpoints/
1+
checkpoints/
2+
.github

.github/workflows/gitleaks.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: gitleaks
2+
on: [pull_request, push, workflow_dispatch]
3+
jobs:
4+
scan:
5+
name: gitleaks
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v3
9+
with:
10+
fetch-depth: 0
11+
- uses: gitleaks/gitleaks-action@v2
12+
env:
13+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
14+
GITLEAKS_LICENSE: ${{ secrets.GITLEAKS_LICENSE}}
15+
GITLEAKS_NOTIFY_USER_LIST: '@sandergi'

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,5 +206,7 @@ cython_debug/
206206
# Poetry local configuration file - https://python-poetry.org/docs/configuration/#local-configuration
207207
poetry.toml
208208

209+
# Gitleaks
210+
gitleaks-baseline.json
209211

210212
# End of https://www.toptal.com/developers/gitignore/api/python,macOS

.gitleaksignore

Whitespace-only changes.

.pre-commit-config.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# See https://pre-commit.com for more information
2+
# See https://pre-commit.com/hooks.html for more hooks
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v4.6.0
6+
hooks:
7+
- id: end-of-file-fixer
8+
- id: check-yaml
9+
- repo: https://github.com/gitleaks/gitleaks
10+
rev: v8.18.4
11+
hooks:
12+
- id: gitleaks

LICENSE

Lines changed: 0 additions & 201 deletions
This file was deleted.

LICENSE.md

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
# Functional Source License, Version 1.1, Apache 2.0 Future License
2+
3+
## Abbreviation
4+
5+
FSL-1.1-Apache-2.0
6+
7+
## Notice
8+
9+
Copyright 2024 Dara.network Inc
10+
11+
## Terms and Conditions
12+
13+
### Licensor ("We")
14+
15+
The party offering the Software under these Terms and Conditions.
16+
17+
### The Software
18+
19+
The "Software" is each version of the software that we make available under
20+
these Terms and Conditions, as indicated by our inclusion of these Terms and
21+
Conditions with the Software.
22+
23+
### License Grant
24+
25+
Subject to your compliance with this License Grant and the Patents,
26+
Redistribution and Trademark clauses below, we hereby grant you the right to
27+
use, copy, modify, create derivative works, publicly perform, publicly display
28+
and redistribute the Software for any Permitted Purpose identified below.
29+
30+
### Permitted Purpose
31+
32+
A Permitted Purpose is any purpose other than a Competing Use. A Competing Use
33+
means making the Software available to others in a commercial product or
34+
service that:
35+
36+
1. substitutes for the Software;
37+
38+
2. substitutes for any other product or service we offer using the Software
39+
that exists as of the date we make the Software available; or
40+
41+
3. offers the same or substantially similar functionality as the Software.
42+
43+
Permitted Purposes specifically include using the Software:
44+
45+
1. for your internal use and access;
46+
47+
2. for non-commercial education;
48+
49+
3. for non-commercial research; and
50+
51+
4. in connection with professional services that you provide to a licensee
52+
using the Software in accordance with these Terms and Conditions.
53+
54+
### Patents
55+
56+
To the extent your use for a Permitted Purpose would necessarily infringe our
57+
patents, the license grant above includes a license under our patents. If you
58+
make a claim against any party that the Software infringes or contributes to
59+
the infringement of any patent, then your patent license to the Software ends
60+
immediately.
61+
62+
### Redistribution
63+
64+
The Terms and Conditions apply to all copies, modifications and derivatives of
65+
the Software.
66+
67+
If you redistribute any copies, modifications or derivatives of the Software,
68+
you must include a copy of or a link to these Terms and Conditions and not
69+
remove any copyright notices provided in or with the Software.
70+
71+
### Disclaimer
72+
73+
THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR
74+
IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR
75+
PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT.
76+
77+
IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE
78+
SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES,
79+
EVEN IF WE HAVE BEEN INFORMED OF THEIR POSSIBILITY IN ADVANCE.
80+
81+
### Trademarks
82+
83+
Except for displaying the License Details and identifying us as the origin of
84+
the Software, you have no right under these Terms and Conditions to use our
85+
trademarks, trade names, service marks or product names.
86+
87+
## Grant of Future License
88+
89+
We hereby irrevocably grant you an additional license to use the Software under
90+
the Apache License, Version 2.0 that is effective on the second anniversary of
91+
the date we make the Software available. On or after that date, you may use the
92+
Software under the Apache License, Version 2.0, in which case the following
93+
will apply:
94+
95+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
96+
this file except in compliance with the License.
97+
98+
You may obtain a copy of the License at
99+
100+
http://www.apache.org/licenses/LICENSE-2.0
101+
102+
Unless required by applicable law or agreed to in writing, software distributed
103+
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
104+
CONDITIONS OF ANY KIND, either express or implied. See the License for the
105+
specific language governing permissions and limitations under the License.
106+
107+

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ gooey-gpu also provides a small python helper library to make it easy to write c
177177
print(result.get()) # { "image": "..." }
178178
```
179179
180-
9. During this, try to record the GPU usage using `nvidia-smi`.
180+
9. During this, try to record the GPU usage using [`nvitop`](https://github.com/XuehaiPan/nvitop) (or `nvidia-smi`)
181181
182182
This will come handy to define the resource limits in the helm chart.
183183
Once you have this number, you need to convert this to the equivalent CPU memory limit.
@@ -187,10 +187,10 @@ gooey-gpu also provides a small python helper library to make it easy to write c
187187
```
188188
cpu_memory_limit = (cpu_memory_capacity / gpu_memory_capacity) * gpu_memory_limit
189189
```
190-
E.g. for an azure Standard_NC24ads_A100_v4 with 220Gi CPU memory and 80Gi GPU memory, and a diffusion model with a max GPU memory usage of 7Gib, the CPU memory limit would be:
190+
E.g. for an azure Standard_NC24ads_A100_v4 with 216 Gib CPU memory and 80 Gib GPU memory, and a diffusion model with a max GPU memory usage of 7 Gib, the CPU memory limit would be:
191191
192192
```
193-
(220 / 80) * 7 ~= 20Gi
193+
(216 / 80) * 7 ~= 20Gi
194194
```
195195
196196
This helps us put multiple models in the same GPU and avoid CUDA OOM errors.
@@ -273,6 +273,8 @@ The recommended way to turn a set of research scripts like [Wav2Lip](https://git
273273
274274
4. Once you have these written, you can follow the same steps as the common models to deploy the model.
275275
276+
### 💣 Secret Scanning
276277
278+
Gitleaks will automatically run pre-commit (see `pre-commit-config.yaml` for details) to prevent commits with secrets in the first place. To test this without committing, run `pre-commit` from the terminal. To skip this check, use `SKIP=gitleaks git commit -m "message"` to commit changes. Preferably, label false positives with the `#gitleaks:allow` comment instead of skipping the check.
277279
278-
280+
Gitleaks will also run in the CI pipeline as a GitHub action on push and pull request (can also be manually triggered in the actions tab on GitHub). To update the baseline of ignored secrets, run `python ./scripts/create_gitleaks_baseline.py` from the venv and commit the changes to `.gitleaksignore`.

celeryconfig.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
imports=os.environ["IMPORTS"].split(),
1616
worker_prefetch_multiplier=1,
1717
task_track_started=True,
18-
task_acks_late=True,
18+
# task_acks_late=True,
1919
)
2020

2121

0 commit comments

Comments
 (0)