orionhunts-ai commited on
Commit
5e8692b
β€’
1 Parent(s): 7e911a4

minor auto

Browse files
Files changed (32) hide show
  1. .github/workflows/ci.yaml +53 -0
  2. .gitignore +2 -1
  3. data/raw/hf/.gitattributes +0 -58
  4. data/raw/hf/README.md +0 -55
  5. data/raw/hf/data_did.csv +0 -0
  6. pyproject.toml +2 -2
  7. verida-differential-privacy/.dockerignore +32 -0
  8. verida-differential-privacy/Dockerfile +18 -0
  9. {data β†’ verida-differential-privacy}/__init__.py +0 -0
  10. {data/processed β†’ verida-differential-privacy/data}/__init__.py +0 -0
  11. {data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/artifacts/corr_matrix_PII_Customer_Personality_Analysis_correlation_matrix.csv +0 -0
  12. {data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/artifacts/correlation_matrix.png +0 -0
  13. {data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/data/2024_08_25_PII_Customer_Personality_Analysis_v0.1.csv +0 -0
  14. {data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/data/corr_matrix_PII_Customer_Personality_Analysis_correlation_matrix.csv +0 -0
  15. src/lstm.ipynb β†’ verida-differential-privacy/data/processed/__init__.py +0 -0
  16. {data β†’ verida-differential-privacy/data}/processed/customer_profile_marketing.csv +0 -0
  17. {data β†’ verida-differential-privacy/data}/processed/eda.py.bak +0 -0
  18. {data β†’ verida-differential-privacy/data}/processed/eda_code_final_fixed.py +1 -1
  19. {data β†’ verida-differential-privacy/data}/raw/customer_profile_eda_normalization.ipynb +0 -0
  20. {data β†’ verida-differential-privacy/data}/raw/data_notes.md +0 -0
  21. verida-differential-privacy/data/raw/hf +1 -0
  22. {data β†’ verida-differential-privacy/data}/raw/marketing_campaign.csv +0 -0
  23. {data β†’ verida-differential-privacy/data}/raw/medical_data_raw.ipynb +0 -0
  24. {data β†’ verida-differential-privacy/data}/raw/raw_data.ipynb +0 -0
  25. {gretel_ai β†’ verida-differential-privacy/gretel_ai}/gretel_exp.md +0 -0
  26. medical_records_did β†’ verida-differential-privacy/medical_records_did +0 -0
  27. verida-differential-privacy/src/__init__.py +0 -0
  28. {data/processed β†’ verida-differential-privacy/src}/clustering_ml.py +1 -2
  29. verida-differential-privacy/src/lstm.ipynb +0 -0
  30. push_to_hf.sh β†’ verida-differential-privacy/src/push_to_hf.sh +0 -0
  31. {data/processed β†’ verida-differential-privacy/src}/supervized_ml.py +1 -2
  32. {transformer_models β†’ verida-differential-privacy/transformer_models}/unsloth_model_colab.ipynb +0 -0
.github/workflows/ci.yaml ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: CI/CD Pipeline
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+
11
+ jobs:
12
+ build:
13
+ runs-on: ubuntu-latest
14
+
15
+ steps:
16
+ - uses: actions/checkout@v3
17
+
18
+ - name: Set up Python
19
+ uses: actions/setup-python@v4
20
+ with:
21
+ python-version: '3.11'
22
+
23
+ - name: Install dependencies
24
+ run: pip install --no-cache-dir -r requirements.txt
25
+
26
+ - name: Run tests
27
+ run: pytest
28
+
29
+ docker:
30
+ runs-on: ubuntu-latest
31
+ needs: build
32
+
33
+ steps:
34
+ - uses: actions/checkout@v3
35
+
36
+ - name: Log in to Docker Hub
37
+ run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_USERNAME }}" --password-stdin
38
+
39
+ - name: Build Docker image
40
+ run: docker build -t ${{ secrets.DOCKER_USERNAME }}/app:${{ github.sha }} .
41
+
42
+ - name: Push Docker image
43
+ run: docker push ${{ secrets.DOCKER_USERNAME }}/app:${{ github.sha }}
44
+
45
+ deploy:
46
+ runs-on: ubuntu-latest
47
+ needs: docker
48
+
49
+ steps:
50
+ - name: Deploy to Production
51
+ run: |
52
+ docker pull ${{ secrets.DOCKER_USERNAME }}/app:${{ github.sha }}
53
+ docker run -d -p 80:80 ${{ secrets.DOCKER_USERNAME }}/app:${{ github.sha }}
.gitignore CHANGED
@@ -3,4 +3,5 @@ poetry.lock
3
  *.env
4
  **/.env
5
  .DS_Store
6
- **/wandb/
 
 
3
  *.env
4
  **/.env
5
  .DS_Store
6
+ **/wandb/
7
+ dist/
data/raw/hf/.gitattributes DELETED
@@ -1,58 +0,0 @@
1
- *.7z filter=lfs diff=lfs merge=lfs -text
2
- *.arrow filter=lfs diff=lfs merge=lfs -text
3
- *.bin filter=lfs diff=lfs merge=lfs -text
4
- *.bz2 filter=lfs diff=lfs merge=lfs -text
5
- *.ckpt filter=lfs diff=lfs merge=lfs -text
6
- *.ftz filter=lfs diff=lfs merge=lfs -text
7
- *.gz filter=lfs diff=lfs merge=lfs -text
8
- *.h5 filter=lfs diff=lfs merge=lfs -text
9
- *.joblib filter=lfs diff=lfs merge=lfs -text
10
- *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
- *.lz4 filter=lfs diff=lfs merge=lfs -text
12
- *.mlmodel filter=lfs diff=lfs merge=lfs -text
13
- *.model filter=lfs diff=lfs merge=lfs -text
14
- *.msgpack filter=lfs diff=lfs merge=lfs -text
15
- *.npy filter=lfs diff=lfs merge=lfs -text
16
- *.npz filter=lfs diff=lfs merge=lfs -text
17
- *.onnx filter=lfs diff=lfs merge=lfs -text
18
- *.ot filter=lfs diff=lfs merge=lfs -text
19
- *.parquet filter=lfs diff=lfs merge=lfs -text
20
- *.pb filter=lfs diff=lfs merge=lfs -text
21
- *.pickle filter=lfs diff=lfs merge=lfs -text
22
- *.pkl filter=lfs diff=lfs merge=lfs -text
23
- *.pt filter=lfs diff=lfs merge=lfs -text
24
- *.pth filter=lfs diff=lfs merge=lfs -text
25
- *.rar filter=lfs diff=lfs merge=lfs -text
26
- *.safetensors filter=lfs diff=lfs merge=lfs -text
27
- saved_model/**/* filter=lfs diff=lfs merge=lfs -text
28
- *.tar.* filter=lfs diff=lfs merge=lfs -text
29
- *.tar filter=lfs diff=lfs merge=lfs -text
30
- *.tflite filter=lfs diff=lfs merge=lfs -text
31
- *.tgz filter=lfs diff=lfs merge=lfs -text
32
- *.wasm filter=lfs diff=lfs merge=lfs -text
33
- *.xz filter=lfs diff=lfs merge=lfs -text
34
- *.zip filter=lfs diff=lfs merge=lfs -text
35
- *.zst filter=lfs diff=lfs merge=lfs -text
36
- *tfevents* filter=lfs diff=lfs merge=lfs -text
37
- # Audio files - uncompressed
38
- *.pcm filter=lfs diff=lfs merge=lfs -text
39
- *.sam filter=lfs diff=lfs merge=lfs -text
40
- *.raw filter=lfs diff=lfs merge=lfs -text
41
- # Audio files - compressed
42
- *.aac filter=lfs diff=lfs merge=lfs -text
43
- *.flac filter=lfs diff=lfs merge=lfs -text
44
- *.mp3 filter=lfs diff=lfs merge=lfs -text
45
- *.ogg filter=lfs diff=lfs merge=lfs -text
46
- *.wav filter=lfs diff=lfs merge=lfs -text
47
- # Image files - uncompressed
48
- *.bmp filter=lfs diff=lfs merge=lfs -text
49
- *.gif filter=lfs diff=lfs merge=lfs -text
50
- *.png filter=lfs diff=lfs merge=lfs -text
51
- *.tiff filter=lfs diff=lfs merge=lfs -text
52
- # Image files - compressed
53
- *.jpg filter=lfs diff=lfs merge=lfs -text
54
- *.jpeg filter=lfs diff=lfs merge=lfs -text
55
- *.webp filter=lfs diff=lfs merge=lfs -text
56
- # Video files - compressed
57
- *.mp4 filter=lfs diff=lfs merge=lfs -text
58
- *.webm filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
data/raw/hf/README.md DELETED
@@ -1,55 +0,0 @@
1
- ---
2
- annotations_creators:
3
- - machine-generated
4
- language:
5
- - en
6
- language_creators:
7
- - machine-generated
8
- license:
9
- - mit
10
- multilinguality:
11
- - monolingual
12
- pretty_name: Medical data with DiD's randomly generated
13
- size_categories:
14
- - n<1K
15
- source_datasets:
16
- - original
17
- tags: []
18
- task_categories:
19
- - tabular-classification
20
- - text-classification
21
- task_ids:
22
- - tabular-multi-class-classification
23
- - multi-class-classification
24
- ---
25
-
26
- # Dataset Card for [Dataset Name]
27
-
28
- ## Table of Contents
29
- - [Table of Contents](#table-of-contents)
30
- - [Dataset Description](#dataset-description)
31
- - [Dataset Summary](#dataset-summary)
32
- - [Supported Tasks and Leaderboards](#supported-tasks-and-leaderboards)
33
- - [Languages](#languages)
34
- - [Dataset Structure](#dataset-structure)
35
- - [Data Instances](#data-instances)
36
- - [Data Fields](#data-fields)
37
- - [Data Splits](#data-splits)
38
- - [Dataset Creation](#dataset-creation)
39
- - [Curation Rationale](#curation-rationale)
40
- - [Source Data](#source-data)
41
- - [Annotations](#annotations)
42
- - [Personal and Sensitive Information](#personal-and-sensitive-information)
43
- - [Considerations for Using the Data](#considerations-for-using-the-data)
44
- - [Social Impact of Dataset](#social-impact-of-dataset)
45
- - [Discussion of Biases](#discussion-of-biases)
46
- - [Other Known Limitations](#other-known-limitations)
47
- - [Additional Information](#additional-information)
48
- - [Dataset Curators](#dataset-curators)
49
- - [Licensing Information](#licensing-information)
50
- - [Citation Information](#citation-information)
51
- - [Contributions](#contributions)
52
-
53
- ## Dataset Description
54
- Medical data with DiD's for differential privacy.
55
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
data/raw/hf/data_did.csv DELETED
The diff for this file is too large to render. See raw diff
 
pyproject.toml CHANGED
@@ -10,8 +10,8 @@ readme = "README.md"
10
  python = "^3.10"
11
  pydantic = "^2.8.2"
12
  wandb = "^0.17.7"
13
- python-dotenv = "^1.0.1"
14
- ipykernel = "^6.29.5"
15
  datasets = "^2.21.0"
16
  didkit = "^0.3.3"
17
  scikit-learn = "^1.5.1"
 
10
  python = "^3.10"
11
  pydantic = "^2.8.2"
12
  wandb = "^0.17.7"
13
+ python-dotenv = "1.0.0"
14
+ ipykernel = "6.29.5"
15
  datasets = "^2.21.0"
16
  didkit = "^0.3.3"
17
  scikit-learn = "^1.5.1"
verida-differential-privacy/.dockerignore ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Python files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *.pyo
5
+ *.pyd
6
+ **/*.env
7
+
8
+ # Poetry files
9
+ poetry.lock
10
+
11
+ # Distribution / packaging
12
+ *.egg-info/
13
+ build/
14
+ dist/
15
+
16
+ # Virtual environments
17
+ venv/
18
+ .env
19
+
20
+ # Docker files
21
+ Dockerfile
22
+ .dockerignore
23
+
24
+ # Editor and OS specific files
25
+ .vscode/
26
+ .idea/
27
+ *.swp
28
+ .DS_Store
29
+ Thumbs.db
30
+
31
+ # Logs
32
+ *.log
verida-differential-privacy/Dockerfile ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.11-slim
2
+
3
+ WORKDIR /app
4
+
5
+ RUN apt-get update && apt-get install -y curl && \
6
+ curl -sSL https://install.python-poetry.org | python3 - && \
7
+ apt-get remove -y curl && apt-get autoremove -y && \
8
+ ln -s ~/.local/bin/poetry /usr/local/bin/poetry
9
+
10
+ COPY pyproject.toml poetry.lock ./
11
+
12
+ RUN poetry install --no-root --no-dev
13
+
14
+ COPY . .
15
+
16
+ RUN poetry build
17
+
18
+ CMD ["python", "main.py"]
{data β†’ verida-differential-privacy}/__init__.py RENAMED
File without changes
{data/processed β†’ verida-differential-privacy/data}/__init__.py RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/artifacts/corr_matrix_PII_Customer_Personality_Analysis_correlation_matrix.csv RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/artifacts/correlation_matrix.png RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/data/2024_08_25_PII_Customer_Personality_Analysis_v0.1.csv RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/PII_Customer_Personality_Analysis/data/corr_matrix_PII_Customer_Personality_Analysis_correlation_matrix.csv RENAMED
File without changes
src/lstm.ipynb β†’ verida-differential-privacy/data/processed/__init__.py RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/customer_profile_marketing.csv RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/eda.py.bak RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/processed/eda_code_final_fixed.py RENAMED
@@ -5,11 +5,11 @@ import matplotlib.pyplot as plt
5
  import numpy as np
6
  import pandas as pd
7
  import seaborn as sns
 
8
  from dotenv import load_dotenv
9
  from sklearn.feature_selection import SelectKBest, f_classif
10
  from sklearn.preprocessing import LabelEncoder, StandardScaler
11
 
12
- import wandb
13
  from constants import project, version
14
 
15
  load_dotenv()
 
5
  import numpy as np
6
  import pandas as pd
7
  import seaborn as sns
8
+ import wandb
9
  from dotenv import load_dotenv
10
  from sklearn.feature_selection import SelectKBest, f_classif
11
  from sklearn.preprocessing import LabelEncoder, StandardScaler
12
 
 
13
  from constants import project, version
14
 
15
  load_dotenv()
{data β†’ verida-differential-privacy/data}/raw/customer_profile_eda_normalization.ipynb RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/raw/data_notes.md RENAMED
File without changes
verida-differential-privacy/data/raw/hf ADDED
@@ -0,0 +1 @@
 
 
1
+ Subproject commit 1ccd24f169b40d6f217ccb8e92fd1d684ba2c5f8
{data β†’ verida-differential-privacy/data}/raw/marketing_campaign.csv RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/raw/medical_data_raw.ipynb RENAMED
File without changes
{data β†’ verida-differential-privacy/data}/raw/raw_data.ipynb RENAMED
File without changes
{gretel_ai β†’ verida-differential-privacy/gretel_ai}/gretel_exp.md RENAMED
File without changes
medical_records_did β†’ verida-differential-privacy/medical_records_did RENAMED
File without changes
verida-differential-privacy/src/__init__.py ADDED
File without changes
{data/processed β†’ verida-differential-privacy/src}/clustering_ml.py RENAMED
@@ -2,6 +2,7 @@ import os
2
 
3
  import pandas as pd
4
  import torch
 
5
  from dotenv import load_dotenv
6
  from sklearn.cluster import AgglomerativeClustering, KMeans
7
  from sklearn.metrics import silhouette_score
@@ -9,8 +10,6 @@ from sklearn.model_selection import train_test_split
9
  from sklearn.pipeline import Pipeline
10
  from sklearn.preprocessing import StandardScaler
11
 
12
- import wandb
13
-
14
  load_dotenv()
15
 
16
 
 
2
 
3
  import pandas as pd
4
  import torch
5
+ import wandb
6
  from dotenv import load_dotenv
7
  from sklearn.cluster import AgglomerativeClustering, KMeans
8
  from sklearn.metrics import silhouette_score
 
10
  from sklearn.pipeline import Pipeline
11
  from sklearn.preprocessing import StandardScaler
12
 
 
 
13
  load_dotenv()
14
 
15
 
verida-differential-privacy/src/lstm.ipynb ADDED
File without changes
push_to_hf.sh β†’ verida-differential-privacy/src/push_to_hf.sh RENAMED
File without changes
{data/processed β†’ verida-differential-privacy/src}/supervized_ml.py RENAMED
@@ -5,6 +5,7 @@ from typing import Any, Dict, Tuple
5
 
6
  import pandas as pd
7
  import torch
 
8
  from dotenv import load_dotenv
9
  from sklearn.ensemble import RandomForestClassifier
10
  from sklearn.feature_selection import SelectKBest, f_classif
@@ -15,8 +16,6 @@ from sklearn.model_selection import train_test_split
15
  from sklearn.preprocessing import StandardScaler
16
  from sklearn.svm import SVC
17
 
18
- import wandb
19
-
20
  # Load environment variables
21
  load_dotenv()
22
 
 
5
 
6
  import pandas as pd
7
  import torch
8
+ import wandb
9
  from dotenv import load_dotenv
10
  from sklearn.ensemble import RandomForestClassifier
11
  from sklearn.feature_selection import SelectKBest, f_classif
 
16
  from sklearn.preprocessing import StandardScaler
17
  from sklearn.svm import SVC
18
 
 
 
19
  # Load environment variables
20
  load_dotenv()
21
 
{transformer_models β†’ verida-differential-privacy/transformer_models}/unsloth_model_colab.ipynb RENAMED
File without changes