History talk:Calculate Track Times

From MusicBrainz Wiki
(Redirected from Talk:Calculate Track Times)
Jump to navigationJump to search

When you say "setTimesFromDiscID(findMedianDiscID())", do you mean that one of the 2-or-more disc IDs is selected as the median, then the times are set from that (thus, the track times exactly correspond to one of the disc IDs)? Or, do you mean that for each track, the median track length (based on each TOC) is calculated?

If it's the former (pick a disc ID, use that), how exactly is the disc ID selected?

If it's the latter (average for each track separately), what happens when the number of disc IDs is even (e.g. 2)?

- DaveEvans


Ok, maybe I didn't think that through far enough. I said in Proposed Algorithm above that one of the DiscIDs is selected as the median, and that's used for the track times.

But have to say I didn't think of what to do if you have 2 discIDs :)

Shall we abandon the idea of automatically choosing the right DiscID? Since we only have to pick for releases with 3+ DiscIDs (which according to http://musicbrainz.org/stats.html is about 3% of releases), is it worth the complexity? If a DiscID is completely wrong, it should be deleted, otherwise, it doesn't matter so much if it's a second or so wrong. In any case, it's not like the number of discIds on any one release is statistically significant!

How about: Only auto-update the track times when there's 1 DiscID (when DiscIDs are added/removed or there's a merge), but add the moderation type to allow users to choose the "correct" DiscID?

(now changed proposal to reflect this)

--ZeroGravitas


The new simpler proposal is definitely better. Note that there is already a "one-off" script (it runs every night) but it only changes the times if they are all undefined (?:??). I still have a problem with the fact that your proposed change to this script would blindly use a (possibly incorrect) DiscID, and thereby lose (permanently, modulo re-importing) the FreeDB track times, which might well be correct.

My preference is just for a SetTrackTimesFromDiscID EditType, together with a report that lists releases where the track times and the disc ids differ greatly (> 5 seconds) - moderators can then look and decide whether to (re)move the disc ids, or reset the track times.

@alex