Skip to content

Commit

Permalink
Merge pull request #7986 from cvat-ai/release-2.14.1
Browse files Browse the repository at this point in the history
Release v2.14.1
  • Loading branch information
cvat-bot[bot] authored Jun 5, 2024
2 parents 24facf5 + 6bba485 commit c96c5ed
Show file tree
Hide file tree
Showing 258 changed files with 6,785 additions and 4,773 deletions.
1 change: 1 addition & 0 deletions .github/workflows/helm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ jobs:
# They are still tested without Helm
run: |
kubectl cp tests/mounted_file_share/images $(kubectl get pods -l component=server -o jsonpath='{.items[0].metadata.name}'):/home/django/share
kubectl cp tests/mounted_file_share/videos $(kubectl get pods -l component=server -o jsonpath='{.items[0].metadata.name}'):/home/django/share
pytest --timeout 30 --platform=kube -m "not with_external_services" tests/python --log-cli-level DEBUG
- name: Creating a log file from "cvat" container logs
Expand Down
7 changes: 1 addition & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,5 @@
"python.testing.cwd": "${workspaceFolder}/tests",
"cSpell.words": [
"crowdsourcing"
],
"isort.args":["--profile", "black"],
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter",
"editor.formatOnSave": true
}
]
}
47 changes: 47 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,53 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

<!-- scriv-insert-here -->

<a id='changelog-2.14.1'></a>
## \[2.14.1\] - 2024-06-05

### Added

- Improved message of DatasetNotFoundError
(<https://github.com/cvat-ai/cvat/pull/7923>)

### Changed

- Upgraded React and Antd dependencies, it leads to stylistic changes in the user interface
(<https://github.com/cvat-ai/cvat/pull/7466>)

- CVAT now stores users' working time in events of a dedicated type
(<https://github.com/cvat-ai/cvat/pull/7958>)

### Fixed

- The 500 / "The result file does not exist in export cache" error
on dataset export request
(<https://github.com/cvat-ai/cvat/pull/7864>)

- Fix missing serviceName field in kvrocks (issue #7741)
(<https://github.com/cvat-ai/cvat/pull/7924>)

- UI crash on hovering conflict related to hidden objects
(<https://github.com/cvat-ai/cvat/pull/7917>)

- Login when the domain of a user email contains capital symbols and a user was created after being invited to an org
(<https://github.com/cvat-ai/cvat/pull/7906>)

- Exception **"Cannot set properties of undefined (setting 'serverID')"** occurs when attempting
to save a job after removing the first keyframe of a track (<https://github.com/cvat-ai/cvat/pull/7949>)

- Spent working time for a user may not be counted in analytics
(<https://github.com/cvat-ai/cvat/pull/7942>)

- A classifier model can not be used on annotation view (unknown object shape error)
(<https://github.com/cvat-ai/cvat/pull/7839>)

- Optimized memory usage by not keeping all downloaded images/part of images in memory while creating a manifest file
(<https://github.com/cvat-ai/cvat/pull/7969>)
- Optimized the number of requests to CS providers by downloading only images from a specified range
(`use_cache==False`) (<https://github.com/cvat-ai/cvat/pull/7969>)
- Task creation with random sorting and cloud data
(<https://github.com/cvat-ai/cvat/pull/7969>)

<a id='changelog-2.14.0'></a>
## \[2.14.0\] - 2024-05-21

Expand Down
15 changes: 9 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG PIP_VERSION=22.0.2
ARG PIP_VERSION=24.0
ARG BASE_IMAGE=ubuntu:22.04

FROM ${BASE_IMAGE} as build-image-base
Expand Down Expand Up @@ -62,7 +62,7 @@ RUN sed -i '/^av==/!d' /tmp/utils/dataset_manifest/requirements.txt
# Work around https://github.com/PyAV-Org/PyAV/issues/1140
RUN pip install setuptools wheel 'cython<3'

RUN --mount=type=cache,target=/root/.cache/pip/http \
RUN --mount=type=cache,target=/root/.cache/pip/http-v2 \
python3 -m pip wheel --no-binary=av --no-build-isolation \
-r /tmp/utils/dataset_manifest/requirements.txt \
-w /tmp/wheelhouse
Expand All @@ -78,15 +78,15 @@ RUN sed -i '/^av==/d' /tmp/utils/dataset_manifest/requirements.txt

ARG CVAT_CONFIGURATION="production"

RUN --mount=type=cache,target=/root/.cache/pip/http \
RUN --mount=type=cache,target=/root/.cache/pip/http-v2 \
DATUMARO_HEADLESS=1 python3 -m pip wheel --no-deps \
-r /tmp/cvat/requirements/${CVAT_CONFIGURATION}.txt \
-w /tmp/wheelhouse

FROM golang:1.20.5 AS build-smokescreen
FROM golang:1.22.3 AS build-smokescreen

RUN git clone --depth=1 -b v0.0.4 https://github.com/stripe/smokescreen.git
RUN cd smokescreen && go build -o /tmp/smokescreen
RUN git clone --depth=1 https://github.com/stripe/smokescreen.git
RUN cd smokescreen && git checkout eb1ac09 && go build -o /tmp/smokescreen

FROM ${BASE_IMAGE}

Expand Down Expand Up @@ -161,6 +161,9 @@ RUN if [ "$CLAM_AV" = "yes" ]; then \
# Install wheels from the build image
RUN python3 -m venv /opt/venv
ENV PATH="/opt/venv/bin:${PATH}"
# setuptools should be uninstalled after updating google-cloud-storage
# https://github.com/googleapis/python-storage/issues/740
RUN python -m pip install --upgrade setuptools
ARG PIP_VERSION
ARG PIP_DISABLE_PIP_VERSION_CHECK=1

Expand Down
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,15 @@ presentations and covers the following topics:
- **Speeding up your data annotation process: introduction to CVAT and Datumaro**.
What problems do CVAT and Datumaro solve, and how they can speed up your model
training process. Some resources you can use to learn more about how to use them.
- **Deployment and use CVAT**. Use the app online at [app.cvat.ai](app.cvat.ai).
- **Deployment and use CVAT**. Use the app online at [app.cvat.ai](https://app.cvat.ai).
A local deployment. A containerized local deployment with Docker Compose (for regular use),
and a local cluster deployment with Kubernetes (for enterprise users). A 2-minute
tour of the interface, a breakdown of CVAT’s internals, and a demonstration of how
to deploy CVAT using Docker Compose.

[Product tour](https://www.youtube.com/playlist?list=PL0to7Ng4Puua37NJVMIShl_pzqJTigFzg): in this course, we show how to use CVAT, and help to get familiar with CVAT functionality and interfaces. This course does not cover integrations and is dedicated solely to CVAT. It covers the following topics:

- **Pipeline**. In this video, we show how to use [app.cvat.ai](app.cvat.ai): how to sign up, upload your data, annotate it, and download it.
- **Pipeline**. In this video, we show how to use [app.cvat.ai](https://app.cvat.ai): how to sign up, upload your data, annotate it, and download it.

<!--lint enable maximum-line-length-->

Expand Down Expand Up @@ -212,6 +212,11 @@ up to 10x. Here is a list of the algorithms we support, and the platforms they c

The code is released under the [MIT License](https://opensource.org/licenses/MIT).

The code contained within the `/serverless` directory is released under the **MIT License**.
However, it may download and utilize various assets, such as source code, architectures, and weights, among others.
These assets may be distributed under different licenses, including non-commercial licenses.
It is your responsibility to ensure compliance with the terms of these licenses before using the assets.

This software uses LGPL-licensed libraries from the [FFmpeg](https://www.ffmpeg.org) project.
The exact steps on how FFmpeg was configured and compiled can be found in the [Dockerfile](Dockerfile).

Expand Down Expand Up @@ -249,7 +254,6 @@ questions and get our support.
- [How to Use CVAT (Roboflow guide)](https://blog.roboflow.com/cvat/)
- [How to auto-label data in CVAT with one of 50,000+ models on Roboflow Universe](https://blog.roboflow.com/how-to-use-roboflow-models-in-cvat/)

<!-- prettier-ignore-start -->
<!-- Badges -->

[docker-server-pulls-img]: https://img.shields.io/docker/pulls/cvat/server.svg?style=flat-square&label=server%20pulls
Expand Down
2 changes: 1 addition & 1 deletion cvat-canvas/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cvat-canvas",
"version": "2.20.1",
"version": "2.20.2",
"type": "module",
"description": "Part of Computer Vision Annotation Tool which presents its canvas library",
"main": "src/canvas.ts",
Expand Down
6 changes: 5 additions & 1 deletion cvat-canvas/src/typescript/canvasModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -651,8 +651,12 @@ export class CanvasModelImpl extends MasterImpl implements CanvasModel {
}

public highlight(clientIDs: number[], severity: HighlightSeverity | null): void {
const elementsIDs = clientIDs.filter((id: number): boolean => (
this.objects.find((_state: any): boolean => _state.clientID === id)
));

this.data.highlightedElements = {
elementsIDs: clientIDs,
elementsIDs,
severity,
};

Expand Down
4 changes: 2 additions & 2 deletions cvat-cli/requirements/base.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
cvat-sdk~=2.14.0
cvat-sdk~=2.14.1
Pillow>=10.3.0
setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability
setuptools>=70.0.0 # not directly required, pinned by Snyk to avoid a vulnerability
2 changes: 1 addition & 1 deletion cvat-cli/src/cvat_cli/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
VERSION = "2.14.0"
VERSION = "2.14.1"
2 changes: 1 addition & 1 deletion cvat-core/src/annotations-actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ async function runSingleFrameChain(
// Ignore deleted frames
if (!frameData.deleted) {
// Get annotations according to filter
const states: ObjectState[] = await getAnnotations(instance, frame, false, filters, null);
const states: ObjectState[] = await getAnnotations(instance, frame, false, filters);
const frameCollectionIDs = states.reduce<IDsToHandle>((acc, val) => {
if (val.objectType === ObjectType.SHAPE) {
acc.shapes.push(val.clientID as number);
Expand Down
65 changes: 37 additions & 28 deletions cvat-core/src/annotations-objects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,21 @@ function copyShape(state: TrackedShape, data: Partial<TrackedShape> = {}): Track
};
}

function convertTrackedShape(shape: SerializedTrack['shapes'][0]): TrackedShape {
return {
serverID: shape.id,
occluded: shape.occluded,
zOrder: shape.z_order,
points: shape.points,
outside: shape.outside,
rotation: shape.rotation || 0,
attributes: shape.attributes.reduce((attributeAccumulator, attr) => {
attributeAccumulator[attr.spec_id] = attr.value;
return attributeAccumulator;
}, {}),
};
}

function computeNewSource(currentSource: Source): Source {
if ([Source.AUTO, Source.SEMI_AUTO].includes(currentSource)) {
return Source.SEMI_AUTO;
Expand Down Expand Up @@ -330,7 +345,7 @@ class Annotation {
this.serverID = undefined;
}

public updateServerID(body: any): void {
public updateFromServerResponse(body: SerializedShape | SerializedTag | SerializedTrack): void {
this.serverID = body.id;
}

Expand Down Expand Up @@ -817,21 +832,9 @@ export class Track extends Drawn {
injection: AnnotationInjection,
) {
super(data, clientID, color, injection);
this.shapes = data.shapes.reduce((shapeAccumulator, value) => {
shapeAccumulator[value.frame] = {
serverID: value.id,
occluded: value.occluded,
zOrder: value.z_order,
points: value.points,
outside: value.outside,
rotation: value.rotation || 0,
attributes: value.attributes.reduce((attributeAccumulator, attr) => {
attributeAccumulator[attr.spec_id] = attr.value;
return attributeAccumulator;
}, {}),
};

return shapeAccumulator;
this.shapes = data.shapes.reduce((acc, shape) => {
acc[shape.frame] = convertTrackedShape(shape);
return acc;
}, {});
}

Expand Down Expand Up @@ -998,11 +1001,14 @@ export class Track extends Drawn {
return result;
}

public updateServerID(body: SerializedTrack): void {
public updateFromServerResponse(body: SerializedTrack): void {
this.serverID = body.id;
this.frame = body.frame;
const updatedShapes = {};
for (const shape of body.shapes) {
this.shapes[shape.frame].serverID = shape.id;
updatedShapes[shape.frame] = convertTrackedShape(shape);
}
this.shapes = updatedShapes;
}

public clearServerID(): void {
Expand Down Expand Up @@ -2020,11 +2026,11 @@ export class SkeletonShape extends Shape {
};
}

public updateServerID(body: SerializedShape): void {
Shape.prototype.updateServerID.call(this, body);
public updateFromServerResponse(body: SerializedShape): void {
Shape.prototype.updateFromServerResponse.call(this, body);
for (const element of body.elements) {
const thisElement = this.elements.find((_element: Shape) => _element.label.id === element.label_id);
thisElement.updateServerID(element);
const context = this.elements.find((_element: Shape) => _element.label.id === element.label_id);
context.updateFromServerResponse(element);
}
}

Expand Down Expand Up @@ -2906,11 +2912,11 @@ export class SkeletonTrack extends Track {
}).sort((a: Annotation, b: Annotation) => a.label.id - b.label.id);
}

public updateServerID(body: SerializedTrack): void {
Track.prototype.updateServerID.call(this, body);
public updateFromServerResponse(body: SerializedTrack): void {
Track.prototype.updateFromServerResponse.call(this, body);
for (const element of body.elements) {
const thisElement = this.elements.find((_element: Track) => _element.label.id === element.label_id);
thisElement.updateServerID(element);
const context = this.elements.find((_element: Track) => _element.label.id === element.label_id);
context.updateFromServerResponse(element);
}
}

Expand Down Expand Up @@ -3009,7 +3015,7 @@ export class SkeletonTrack extends Track {
return result;
}

public get(frame: number): Omit<Required<SerializedData>, 'parentID'> {
public get(frame: number): Required<SerializedData> {
const { prev, next } = this.boundedKeyframes(frame);
const position = this.getPosition(frame, prev, next);
const elements = this.elements.map((element) => ({
Expand All @@ -3022,6 +3028,7 @@ export class SkeletonTrack extends Track {

return {
...position,
parentID: null,
keyframe: position.keyframe || elements.some((el) => el.keyframe),
attributes: this.getAttributes(frame),
descriptions: [...this.descriptions],
Expand Down Expand Up @@ -3197,7 +3204,7 @@ export class SkeletonTrack extends Track {

protected getPosition(
targetFrame: number, leftKeyframe: number | null, rightKeyframe: number | null,
): Omit<InterpolatedPosition, 'points'> & { keyframe: boolean } {
): InterpolatedPosition & { keyframe: boolean } {
const leftFrame = targetFrame in this.shapes ? targetFrame : leftKeyframe;
const rightPosition = Number.isInteger(rightKeyframe) ? this.shapes[rightKeyframe] : null;
const leftPosition = Number.isInteger(leftFrame) ? this.shapes[leftFrame] : null;
Expand All @@ -3209,6 +3216,7 @@ export class SkeletonTrack extends Track {
outside: leftPosition.outside,
zOrder: leftPosition.zOrder,
keyframe: targetFrame in this.shapes,
points: [],
};
}

Expand All @@ -3220,6 +3228,7 @@ export class SkeletonTrack extends Track {
zOrder: singlePosition.zOrder,
keyframe: targetFrame in this.shapes,
outside: singlePosition === rightPosition ? true : singlePosition.outside,
points: [],
};
}

Expand Down
2 changes: 1 addition & 1 deletion cvat-core/src/annotations-saver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ export default class AnnotationsSaver {
for (const type of Object.keys(indexes)) {
for (let i = 0; i < indexes[type].length; i++) {
const clientID = indexes[type][i];
this.collection.objects[clientID].updateServerID(saved[type][i]);
this.collection.objects[clientID].updateFromServerResponse(saved[type][i]);
}
}
}
Expand Down
3 changes: 1 addition & 2 deletions cvat-core/src/enums.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,7 @@ export enum EventScope {
undoAction = 'action:undo',
redoAction = 'action:redo',

pressShortcut = 'press:shortcut',
debugInfo = 'send:debug_info',
debugInfo = 'debug:info',

annotationsAction = 'run:annotations_action',
clickElement = 'click:element',
Expand Down
Loading

0 comments on commit c96c5ed

Please sign in to comment.