endoreg-db 0.4.0__py3-none-any.whl → 0.4.1__py3-none-any.whl
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.
Potentially problematic release.
This version of endoreg-db might be problematic. Click here for more details.
- endoreg_db/data/endoscopy_processor/data.yaml +2 -0
- endoreg_db/migrations/0002_anonymizedimagelabel_anonymousimageannotation_and_more.py +55 -0
- endoreg_db/migrations/0003_anonymousimageannotation_original_image_url_and_more.py +39 -0
- endoreg_db/migrations/0004_alter_rawpdffile_file.py +20 -0
- endoreg_db/models/annotation/__init__.py +2 -1
- endoreg_db/models/annotation/anonymized_image_annotation.py +41 -0
- endoreg_db/models/data_file/import_classes/raw_pdf.py +1 -1
- {endoreg_db-0.4.0.dist-info → endoreg_db-0.4.1.dist-info}/METADATA +1 -1
- {endoreg_db-0.4.0.dist-info → endoreg_db-0.4.1.dist-info}/RECORD +11 -7
- {endoreg_db-0.4.0.dist-info → endoreg_db-0.4.1.dist-info}/LICENSE +0 -0
- {endoreg_db-0.4.0.dist-info → endoreg_db-0.4.1.dist-info}/WHEEL +0 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# Generated by Django 4.2.15 on 2024-08-28 11:05
|
|
2
|
+
|
|
3
|
+
import django.core.files.storage
|
|
4
|
+
import django.core.validators
|
|
5
|
+
from django.db import migrations, models
|
|
6
|
+
import django.db.models.deletion
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class Migration(migrations.Migration):
|
|
10
|
+
|
|
11
|
+
dependencies = [
|
|
12
|
+
('endoreg_db', '0001_initial'),
|
|
13
|
+
]
|
|
14
|
+
|
|
15
|
+
operations = [
|
|
16
|
+
migrations.CreateModel(
|
|
17
|
+
name='AnonymizedImageLabel',
|
|
18
|
+
fields=[
|
|
19
|
+
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
20
|
+
('name', models.CharField(max_length=255, unique=True)),
|
|
21
|
+
('description', models.TextField(blank=True, null=True)),
|
|
22
|
+
],
|
|
23
|
+
),
|
|
24
|
+
migrations.CreateModel(
|
|
25
|
+
name='AnonymousImageAnnotation',
|
|
26
|
+
fields=[
|
|
27
|
+
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
28
|
+
('image_name', models.CharField(max_length=255)),
|
|
29
|
+
('slug', models.SlugField(blank=True, null=True, unique=True)),
|
|
30
|
+
('polyp_count', models.IntegerField()),
|
|
31
|
+
('comments', models.CharField(max_length=255)),
|
|
32
|
+
('gender', models.CharField(max_length=255)),
|
|
33
|
+
('name_image_url', models.CharField(max_length=255)),
|
|
34
|
+
('date_created', models.DateTimeField(auto_now_add=True)),
|
|
35
|
+
('label', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='endoreg_db.label')),
|
|
36
|
+
],
|
|
37
|
+
),
|
|
38
|
+
migrations.AlterField(
|
|
39
|
+
model_name='rawpdffile',
|
|
40
|
+
name='file',
|
|
41
|
+
field=models.FileField(storage=django.core.files.storage.FileSystemStorage(location='/home/agl-admin/agl-validator-backend/agl_validator_backend/erc_data/raw_pdf'), upload_to='raw_pdf/', validators=[django.core.validators.FileExtensionValidator(allowed_extensions=['pdf'])]),
|
|
42
|
+
),
|
|
43
|
+
migrations.CreateModel(
|
|
44
|
+
name='DroppedName',
|
|
45
|
+
fields=[
|
|
46
|
+
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
47
|
+
('name', models.CharField(max_length=255)),
|
|
48
|
+
('gender', models.CharField(max_length=255)),
|
|
49
|
+
('x', models.FloatField()),
|
|
50
|
+
('y', models.FloatField()),
|
|
51
|
+
('name_image_url', models.CharField(max_length=255)),
|
|
52
|
+
('annotation', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='dropped_names', to='endoreg_db.anonymousimageannotation')),
|
|
53
|
+
],
|
|
54
|
+
),
|
|
55
|
+
]
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Generated by Django 4.2.15 on 2024-08-29 07:15
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
import django.db.models.deletion
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class Migration(migrations.Migration):
|
|
8
|
+
|
|
9
|
+
dependencies = [
|
|
10
|
+
('endoreg_db', '0002_anonymizedimagelabel_anonymousimageannotation_and_more'),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.AddField(
|
|
15
|
+
model_name='anonymousimageannotation',
|
|
16
|
+
name='original_image_url',
|
|
17
|
+
field=models.CharField(default='https://example.com/placeholder.jpg', max_length=255),
|
|
18
|
+
),
|
|
19
|
+
migrations.AddField(
|
|
20
|
+
model_name='anonymousimageannotation',
|
|
21
|
+
name='processed',
|
|
22
|
+
field=models.BooleanField(default=False),
|
|
23
|
+
),
|
|
24
|
+
migrations.AddField(
|
|
25
|
+
model_name='droppedname',
|
|
26
|
+
name='box_coordinates',
|
|
27
|
+
field=models.CharField(blank=True, max_length=255, null=True),
|
|
28
|
+
),
|
|
29
|
+
migrations.AlterField(
|
|
30
|
+
model_name='anonymousimageannotation',
|
|
31
|
+
name='comments',
|
|
32
|
+
field=models.TextField(blank=True, null=True),
|
|
33
|
+
),
|
|
34
|
+
migrations.AlterField(
|
|
35
|
+
model_name='anonymousimageannotation',
|
|
36
|
+
name='label',
|
|
37
|
+
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='endoreg_db.anonymizedimagelabel'),
|
|
38
|
+
),
|
|
39
|
+
]
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Generated by Django 4.2.14 on 2024-09-04 19:48
|
|
2
|
+
|
|
3
|
+
import django.core.files.storage
|
|
4
|
+
import django.core.validators
|
|
5
|
+
from django.db import migrations, models
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Migration(migrations.Migration):
|
|
9
|
+
|
|
10
|
+
dependencies = [
|
|
11
|
+
('endoreg_db', '0003_anonymousimageannotation_original_image_url_and_more'),
|
|
12
|
+
]
|
|
13
|
+
|
|
14
|
+
operations = [
|
|
15
|
+
migrations.AlterField(
|
|
16
|
+
model_name='rawpdffile',
|
|
17
|
+
name='file',
|
|
18
|
+
field=models.FileField(storage=django.core.files.storage.FileSystemStorage(location='/home/agl-admin/agl_anonymizer/agl_anonymizer/erc_data/raw_pdf'), upload_to='raw_pdf/', validators=[django.core.validators.FileExtensionValidator(allowed_extensions=['pdf'])]),
|
|
19
|
+
),
|
|
20
|
+
]
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
from .image_classification import ImageClassificationAnnotation
|
|
2
|
-
from .binary_classification_annotation_task import LegacyBinaryClassificationAnnotationTask, BinaryClassificationAnnotationTask
|
|
2
|
+
from .binary_classification_annotation_task import LegacyBinaryClassificationAnnotationTask, BinaryClassificationAnnotationTask
|
|
3
|
+
from .anonymized_image_annotation import AnonymousImageAnnotation, DroppedName, AnonymizedImageLabel
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
from django.db import models
|
|
2
|
+
from django.utils.text import slugify
|
|
3
|
+
|
|
4
|
+
class AnonymizedImageLabel(models.Model):
|
|
5
|
+
name = models.CharField(max_length=255, unique=True) # Ensuring label names are unique
|
|
6
|
+
description = models.TextField(blank=True, null=True) # Optional description field
|
|
7
|
+
|
|
8
|
+
def __str__(self):
|
|
9
|
+
return self.name
|
|
10
|
+
|
|
11
|
+
class AnonymousImageAnnotation(models.Model):
|
|
12
|
+
label = models.ForeignKey(AnonymizedImageLabel, on_delete=models.CASCADE)
|
|
13
|
+
image_name = models.CharField(max_length=255)
|
|
14
|
+
original_image_url = models.CharField(max_length=255, default='https://example.com/placeholder.jpg') # Field for the original image
|
|
15
|
+
slug = models.SlugField(unique=True, blank=True, null=True)
|
|
16
|
+
polyp_count = models.IntegerField()
|
|
17
|
+
comments = models.TextField(blank=True, null=True) # Comments can be longer
|
|
18
|
+
gender = models.CharField(max_length=255) # Overall gender (if applicable)
|
|
19
|
+
name_image_url = models.CharField(max_length=255)
|
|
20
|
+
date_created = models.DateTimeField(auto_now_add=True)
|
|
21
|
+
processed = models.BooleanField(default=False) # Track if this annotation has been processed
|
|
22
|
+
|
|
23
|
+
def save(self, *args, **kwargs):
|
|
24
|
+
if not self.slug:
|
|
25
|
+
self.slug = slugify(f"{self.label}-{self.image_name}")
|
|
26
|
+
super().save(*args, **kwargs)
|
|
27
|
+
|
|
28
|
+
def __str__(self):
|
|
29
|
+
return f"{self.image_name} - {self.label}"
|
|
30
|
+
|
|
31
|
+
class DroppedName(models.Model):
|
|
32
|
+
annotation = models.ForeignKey(AnonymousImageAnnotation, related_name='dropped_names', on_delete=models.CASCADE)
|
|
33
|
+
name = models.CharField(max_length=255)
|
|
34
|
+
gender = models.CharField(max_length=255) # Gender of the individual name
|
|
35
|
+
x = models.FloatField()
|
|
36
|
+
y = models.FloatField()
|
|
37
|
+
name_image_url = models.CharField(max_length=255)
|
|
38
|
+
box_coordinates = models.CharField(max_length=255, blank=True, null=True) # Store box coordinates if needed
|
|
39
|
+
|
|
40
|
+
def __str__(self):
|
|
41
|
+
return f"{self.name} ({self.gender}) at ({self.x}, {self.y})"
|
|
@@ -37,7 +37,7 @@ endoreg_db/data/distribution/numeric/.init,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5
|
|
|
37
37
|
endoreg_db/data/distribution/single_categorical/patient.yaml,sha256=R7beZDRqdOWNaFu-8Bd88E6j3eBc9mqhOW_265EA0e0,156
|
|
38
38
|
endoreg_db/data/emission_factor/green_endoscopy_dashboard_EmissionFactor.yaml,sha256=bBLmr3_uSLXdsbtRa9707WK1Z7Xy8TpBGKOfzWcfC_M,2968
|
|
39
39
|
endoreg_db/data/endoscope_type/data.yaml,sha256=k8uF94svJsU02O-ceaLnQBoozJ6cT3iY_s_aKrvJZqg,242
|
|
40
|
-
endoreg_db/data/endoscopy_processor/data.yaml,sha256=
|
|
40
|
+
endoreg_db/data/endoscopy_processor/data.yaml,sha256=Q72v9DhWjt9zsa0fC-Xty8nWzRcqeyHJpYq-w5UmwXQ,1049
|
|
41
41
|
endoreg_db/data/event/cardiology.yaml,sha256=c2SfXXU8_hOBibNqidxxkZoEaKGGh0UWUTYudjG-Sqo,804
|
|
42
42
|
endoreg_db/data/event/neurology.yaml,sha256=AdpGHQxfBAOuUbKQ234T1MtE3bfHdgKA47HUoyFB5KE,282
|
|
43
43
|
endoreg_db/data/event/surgery.yaml,sha256=hyZWxg8LUNOwf3iybVj0Muta7pUdWhZXmLuuOh7hjek,428
|
|
@@ -145,6 +145,9 @@ endoreg_db/management/commands/load_user_groups.py,sha256=D7SK2FvZEHoE4TIXNGCjDw
|
|
|
145
145
|
endoreg_db/management/commands/register_ai_model.py,sha256=e5hgEyLS-E98XWzINcZ79mgtHvZltmbmAmLYaNrcfQs,2544
|
|
146
146
|
endoreg_db/management/commands/reset_celery_schedule.py,sha256=U-m_FNRTw6LAwJoT9RUE4qrhmQXm7AyFToPcHYyJpIE,386
|
|
147
147
|
endoreg_db/migrations/0001_initial.py,sha256=tIXFN6sFZ2VUIP-TaFSGcobrgARkia0SIOiKN0iokvU,95312
|
|
148
|
+
endoreg_db/migrations/0002_anonymizedimagelabel_anonymousimageannotation_and_more.py,sha256=ABUOr5ZMUHkRQ0FDUhqNaVAvq5K8HOOdyVo1TJ8YMkQ,2605
|
|
149
|
+
endoreg_db/migrations/0003_anonymousimageannotation_original_image_url_and_more.py,sha256=bTb9_FfQBNHYLq1tKw1qmem9xsecRv-z1-aWcl9ig4k,1319
|
|
150
|
+
endoreg_db/migrations/0004_alter_rawpdffile_file.py,sha256=B1LxaapxDnzs08ScrXh1pM_KC2hHHyEHGce_0Ciaex8,712
|
|
148
151
|
endoreg_db/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
149
152
|
endoreg_db/models/__init__.py,sha256=wc1ZyDUNb-sKMZ4P7x_PAb0WtzDhYAq8y19AV8rC7dQ,1552
|
|
150
153
|
endoreg_db/models/ai_model/__init__.py,sha256=rh5npLRGml5iiRocx359gsaA82pGJTW7wdVAfnbZP6w,106
|
|
@@ -152,7 +155,8 @@ endoreg_db/models/ai_model/active_model.py,sha256=r7SE3yg54kbjfOkk0Ei0rgs_Wo3ikx
|
|
|
152
155
|
endoreg_db/models/ai_model/model_meta.py,sha256=YyYW8dScpAceHePnbrnRpgVBYDByi9x7u5Ydh03OJuo,869
|
|
153
156
|
endoreg_db/models/ai_model/model_type.py,sha256=mg1bEuzAjIte25N4TzD0yDhmUQYayJpyrRn2hB6b6eg,638
|
|
154
157
|
endoreg_db/models/ai_model/utils.py,sha256=Vh6_3lbDuFhSVCaaZKKm0CjoGA5Man6gWYe46HUXmbA,270
|
|
155
|
-
endoreg_db/models/annotation/__init__.py,sha256=
|
|
158
|
+
endoreg_db/models/annotation/__init__.py,sha256=9RM6_ZbKToUPzxgNOlFErSlFE3tdLQDY_Qw_z4Oh708,292
|
|
159
|
+
endoreg_db/models/annotation/anonymized_image_annotation.py,sha256=i3DtDOE7OKNJLwK0u5LXDuNNopD6Nql_bCjTwJHXEUM,1961
|
|
156
160
|
endoreg_db/models/annotation/binary_classification_annotation_task.py,sha256=CpvyDxLSJcoJyajtUsDGBt881SNSFcG8lvuQ01knMNM,3292
|
|
157
161
|
endoreg_db/models/annotation/image_classification.py,sha256=Og1tRo1QKBMztwfdbFryUWghnGdsTqQdepn9rOcmVMc,1387
|
|
158
162
|
endoreg_db/models/case_template/__init__.py,sha256=vtq-7Gvpv01l9CuQvBFQugXCKELx9wg2z5HkysrZCNM,369
|
|
@@ -174,7 +178,7 @@ endoreg_db/models/data_file/import_classes/__init__.py,sha256=f5f6dwDU8spd94dpDF
|
|
|
174
178
|
endoreg_db/models/data_file/import_classes/processing_functions/__init__.py,sha256=uathXg8ckLb_XBTRipdHrBXFpZpvKzuouk7lwRN0aqE,932
|
|
175
179
|
endoreg_db/models/data_file/import_classes/processing_functions/pdf.py,sha256=lEd1V_kS8758XuRZ0gj7bVhY5DgTfpEyeDgX3zWHuzE,716
|
|
176
180
|
endoreg_db/models/data_file/import_classes/processing_functions/video.py,sha256=ij3fMdqnZnX1FrS-hscy_pfaYIkxDFKVL7SVjCqCUxs,8530
|
|
177
|
-
endoreg_db/models/data_file/import_classes/raw_pdf.py,sha256=
|
|
181
|
+
endoreg_db/models/data_file/import_classes/raw_pdf.py,sha256=pwN0b6y7m8xA7wd189lR-v6JuGdyO4y1ZhhYKilIn94,6770
|
|
178
182
|
endoreg_db/models/data_file/import_classes/raw_video.py,sha256=j2WLaqxVm86Oq_zKPRAncq3QavmAMP0p3ThalGjieaQ,12444
|
|
179
183
|
endoreg_db/models/data_file/metadata/__init__.py,sha256=Hcv1L5xDnONyERwn4jnj-vI4maYMAEZ9iFPQ8baNrl0,144
|
|
180
184
|
endoreg_db/models/data_file/metadata/pdf_meta.py,sha256=Ipi1LZo36UqP43trHfNY4hamyRWjenxiPg2f_W3di-k,2183
|
|
@@ -303,7 +307,7 @@ endoreg_db/utils/ocr.py,sha256=jkdT1bl-LSCjZ2PvxlX1AG2TmhdMclayxUPrdZWs7UE,7322
|
|
|
303
307
|
endoreg_db/utils/uuid.py,sha256=T4HXqYtKwXFqE5kPyvlgWHyllBBF6LL6N48nl9TpwBk,53
|
|
304
308
|
endoreg_db/utils/video_metadata.py,sha256=HDyXxAeNQOK3cGzQ06xosmObzEnJBARuKjwz9vmmRIM,2613
|
|
305
309
|
endoreg_db/views.py,sha256=xc1IQHrsij7j33TUbo-_oewy3vs03pw_etpBWaMYJl0,63
|
|
306
|
-
endoreg_db-0.4.
|
|
307
|
-
endoreg_db-0.4.
|
|
308
|
-
endoreg_db-0.4.
|
|
309
|
-
endoreg_db-0.4.
|
|
310
|
+
endoreg_db-0.4.1.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
311
|
+
endoreg_db-0.4.1.dist-info/METADATA,sha256=00evXIbn5l5x4dOmbdcvm6UAcpyBnlZuZLYvtq-NX8c,1054
|
|
312
|
+
endoreg_db-0.4.1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
313
|
+
endoreg_db-0.4.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|