Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incremental save of annotation. #120

Merged
merged 13 commits into from
Oct 15, 2018
6 changes: 5 additions & 1 deletion cvat/apps/dashboard/static/dashboard/js/dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -542,11 +542,15 @@ function uploadAnnotationRequest() {
return;
}

const exportData = createExportContainer();
exportData.create = parsed;
exportData.pre_erase = true;

let asyncSave = function() {
$.ajax({
url: '/save/annotation/task/' + window.cvat.dashboard.taskID,
type: 'POST',
data: JSON.stringify(parsed),
data: JSON.stringify(exportData),
contentType: 'application/json',
success: function() {
let message = 'Annotation successfully uploaded';
Expand Down
533 changes: 447 additions & 86 deletions cvat/apps/engine/annotation.py

Large diffs are not rendered by default.

38 changes: 38 additions & 0 deletions cvat/apps/engine/migrations/0010_auto_20181009_0938.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Generated by Django 2.0.3 on 2018-10-09 06:38

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('engine', '0009_auto_20180917_1424'),
]

operations = [
migrations.AddField(
model_name='labeledbox',
name='client_id',
field=models.IntegerField(default=-1),
),
migrations.AddField(
model_name='labeledpoints',
name='client_id',
field=models.IntegerField(default=-1),
),
migrations.AddField(
model_name='labeledpolygon',
name='client_id',
field=models.IntegerField(default=-1),
),
migrations.AddField(
model_name='labeledpolyline',
name='client_id',
field=models.IntegerField(default=-1),
),
migrations.AddField(
model_name='objectpath',
name='client_id',
field=models.IntegerField(default=-1),
),
]
1 change: 1 addition & 0 deletions cvat/apps/engine/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ class Annotation(models.Model):
label = models.ForeignKey(Label, on_delete=models.CASCADE)
frame = models.PositiveIntegerField()
group_id = models.PositiveIntegerField(default=0)
client_id = models.IntegerField(default=-1)
class Meta:
abstract = True

Expand Down
280 changes: 0 additions & 280 deletions cvat/apps/engine/static/engine/js/3rdparty/md5.js

This file was deleted.

Loading