Skip to content

Conversation

@BryonLewis
Copy link
Collaborator

@BryonLewis BryonLewis commented Nov 23, 2022

This is a PR that was an upstream branch for some other deployments. For right now these changes are in the Web Version only. I can make a separate PR to incorporate these changes into the electron version.

Creates an additive import option for postprocess:
additive means that if an annotation file is found during postprocess it will add the tracks to existing tracks instead of doing a replacement.
additive_prepend is a value that is prepended to all types of the new tracks found. This is to easily filter the tracks in the type editor between the new and old tracks.

Code Changes:

  • Post process has additional flags 'additive' to indicate that the import should be additive to the current tracks.
  • 'additivePrepend' is a prepended type that should be added to all tracks imported using additive. I.E, if you have existing tracks named fish and the import has more tracks named fish, if you use an additivePrepend of 'newer' then all of the new annotations will be renamed to 'newer_fish' for their type.
  • There are some UI changes to support this additive prepend functionality. Mostly allowing from the interface to check off an import as being additive and providing a Prepend name value.
  • Fix for transcoding so that videos that contain multiple video streams it will use the first videostream
  • Custom sorting for annotations. Annotations in CSV files were occasionally given in the wrong frame order. This attempts to fix that order by custom sorting the CSV rows in python.

I apologize for the commit history, if required I can squash it down. During the merge it will become squashed anyways.

@BryonLewis BryonLewis requested a review from marySalvi May 2, 2023 19:22
@BryonLewis BryonLewis changed the title WIP Additive import Additive import May 2, 2023
Comment on lines 170 to 176
<div v-if="additive">
<v-text-field
v-model="additivePrepend"
label="Prepend to types"
clearable
/>
</div>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps a tooltip or hint to explain the functionality of this prepend text

Comment on lines 165 to 168
<v-switch
v-model="additive"
label="Additive"
/>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like additive isn't intuitive. Perhaps instead a checkbox with an 'overwrite' label defaulted to checked.

import lockfile from 'proper-lockfile';
import {
cloneDeep, merge, uniq, pick,
cloneDeep, merge, uniq, pick, add, max,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like add and max isn't used

@BryonLewis
Copy link
Collaborator Author

I am completely open to any other wording or suggestions that you may have for it. I also looked through the code and it looks like I already implemented the Desktop version of this (It's been a branch for too long and I forgot 🤦 )

@marySalvi
Copy link
Collaborator

I also looked through the code and it looks like I already implemented the Desktop version of this (It's been a branch for too long and I forgot )

Heh I noticed that but I thought maybe it wasn't fully hooked up yet. I'll do a visual check on desktop, already checked the code.

@BryonLewis BryonLewis merged commit f1f533f into main May 8, 2023
@BryonLewis BryonLewis deleted the additive-import branch May 8, 2023 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants