# Import SACD with "missing" tracks?

**URL:** <https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392>\
**Category:** Help\
**Created:** [August 31, 2023, 6:33pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392 "2023-08-31T18:33:05Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![IncredibleRay](https://avatars.discourse-cdn.com/v4/letter/i/8491ac/32.png) [@IncredibleRay](https://discourse.beets.io/u/IncredibleRay)\
**Post date:** [August 31, 2023, 6:33pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/1 "2023-08-31T18:33:05Z")

</div>

I ripped a hybrid SACD and would like to import the tracks. There are 10 tracks on the disc, but of course that means 10 red book tracks, 10 stereo SACD tracks, and 10 multichannel SACD tracks. I can’t play multichannel from my computer and don’t want to import the redbook tracks, what’s the best way of importing an “incomplete” album like this?

The album in question: [https://musicbrainz.org/release/df8fe008-36fa-332d-bca2-8b1c745c09ad](https://musicbrainz.org/release/df8fe008-36fa-332d-bca2-8b1c745c09ad)

I guess I also have the reverse question since sometimes I do want the redbook tracks and the Music Brainz style guide says, “When a hybrid SACD has the same tracklist on both layers it is acceptable (for the sake of convenience) to enter it as just a single medium (set to “Hybrid SACD”)” Or does beets have logic to handle the “Hybrid SACD” medium?

---

<div class="post-metadata">

**Author:** ![RollingStar](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/rollingstar/32/728_2.png) [@RollingStar](https://discourse.beets.io/u/RollingStar)\
**Post date:** [September 1, 2023, 11:14pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/2 "2023-09-01T23:14:42Z")

</div>

At the risk of redundancy:

1. there is an undocumented feature called distance\_weights. Lower will reduce the penalty on missing tracks. see config\_default.yaml in the main codebase.

> <https://github.com/beetbox/beets/blob/master/beets/config_default.yaml>

> <https://github.com/RollingStar/dial-beets/blob/b96c8f0e16472d9d0aac2eaae5eb3b0bfaf11e01/config.yaml#L31>

1. There is already a special case to handle/ignore data tracks (like on PlayStation 1 games).

[https://github.com/search?q=repo%3Abeetbox%2Fbeets%20"data%20track"&type=code](https://github.com/search?q=repo%3Abeetbox%2Fbeets%20%22data%20track%22&type=code)

> does beets have logic to handle the “Hybrid SACD” medium?

As far as I know, beets takes whatever Musicbrainz gives it. I don’t even think there’s any mapping/normalization to what is provided.

[https://musicbrainz.org/doc/Release/Format](https://musicbrainz.org/doc/Release/Format)

You can see how I handled formats in my config, but it’s untested. This doesn’t change anything about the beets db, just the filenames/folders:

> <https://github.com/RollingStar/dial-beets/blob/master/config.yaml#L328>

1. 

> what’s the best way of importing an “incomplete” album like this?

The devs can chime in here. But I wonder if you’re better off just always picking hybrid SACD or SACD non-surround. It’s your library, you can treat it how you want. But I would avoid as-is imports as much as possible, they’re hard to work with and have no backend DB to query.

---

<div class="post-metadata">

**Author:** ![IncredibleRay](https://avatars.discourse-cdn.com/v4/letter/i/8491ac/32.png) [@IncredibleRay](https://discourse.beets.io/u/IncredibleRay)\
**Post date:** [September 9, 2023, 9:11pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/3 "2023-09-09T21:11:28Z")

</div>

Thank you very much for this, it’s really helpful.

> [@RollingStar](#):
>
> But I would avoid as-is imports as much as possible, they’re hard to work with and have no backend DB to query.

I think I understand, but just to be clear, if I enter an ID and it complains about missing tracks and I hit apply anyway, that’s not “as-is”, right?

---

<div class="post-metadata">

**Author:** ![RollingStar](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/rollingstar/32/728_2.png) [@RollingStar](https://discourse.beets.io/u/RollingStar)\
**Post date:** [May 18, 2024, 8:55pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/4 "2024-05-18T20:55:53Z")

</div>

Correct, “as-is” means no Musicbrainz/discogs/spotify back end. If you accept with missing tracks that should still create the MB\_ALBUMID etc in your beets library/db and the music tags.

---

<div class="post-metadata">

**Author:** ![IncredibleRay](https://avatars.discourse-cdn.com/v4/letter/i/8491ac/32.png) [@IncredibleRay](https://discourse.beets.io/u/IncredibleRay)\
**Post date:** [May 18, 2024, 11:53pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/5 "2024-05-18T23:53:12Z")

</div>

Thanks for responding, In the past year I’ve decided that it’s probably just easiest to import all layers.

I was running into issues doing that in beets so I’ve submitted a PR to fix my issue, but it’s hard to tell how to get folks to review it:

> <https://github.com/beetbox/beets/pull/5149>
>
> \## Description
> 
> Fixes #5148.  
> 
> When importing, the code that matches tracks… does not consider the medium number. This causes problems on Hybrid SACDs where the artists, track numbers, titles, and lengths are the same on both layers.
> 
> I added a distance penalty for mismatching medium numbers.
> 
> Before:
> 
> \`\`\`
> $ beet imp .
> 
> /Volumes/Music/ti/Red Garland/1958 - All Mornin' Long - 1 (6 items)
> 
> Match (95.4%):
> The Red Garland Quintet - All Mornin' Long
> ≠ media, year
> MusicBrainz, 2xHybrid SACD (CD layer), 2013, US, Analogue Productions, CPRJ 7130 SA, mono
> https://musicbrainz.org/release/6a584522-58ea-470b-81fb-e60e5cd7b21e
> \* Artist: The Red Garland Quintet
> \* Album: All Mornin' Long
> \* Hybrid SACD (CD layer) 1
> ≠ (#2-1) All Mornin' Long (20:21) -\> (#1-1) All Mornin' Long (20:21)
> ≠ (#2-2) They Can't Take That Away From Me (10:24) -\> (#1-2) They Can't Take That Away From Me (10:27)
> ≠ (#2-3) Our Delight (6:23) -\> (#1-3) Our Delight (6:23)
> \* Hybrid SACD (CD layer) 2
> ≠ (#1-1) All mornin' long (20:21) -\> (#2-1) All Mornin' Long (20:21)
> ≠ (#1-2) They can't take that away from me (10:27) -\> (#2-2) They Can't Take That Away From Me (10:25)
> ≠ (#1-3) Our delight (6:23) -\> (#2-3) Our Delight (6:23)
> ➜ \[A\]pply, More candidates, Skip, Use as-is, as Tracks, Group albums,
> Enter search, enter Id, aBort, eDit, edit Candidates?
> \`\`\`
> 
> Note that all tracks tagged with disc 1 get moved to disc 2 and vice versa.
> 
> After:
> 
> \`\`\`
> $ beet-test imp .
> 
> /Volumes/Music/ti/Red Garland/1958 - All Mornin' Long - 1 (6 items)
> 
> Match (95.4%):
> The Red Garland Quintet - All Mornin' Long
> ≠ media, year
> MusicBrainz, 2xMedia, 2013, US, Analogue Productions, CPRJ 7130 SA, mono
> https://musicbrainz.org/release/6a584522-58ea-470b-81fb-e60e5cd7b21e
> \* Artist: The Red Garland Quintet
> \* Album: All Mornin' Long
> \* Hybrid SACD (CD layer) 1
> ≠ (#1-1) All mornin' long (20:21) -\> (#1-1) All Mornin' Long (20:21)
> ≠ (#1-2) They can't take that away from me (10:27) -\> (#1-2) They Can't Take That Away From Me (10:27)
> ≠ (#1-3) Our delight (6:23) -\> (#1-3) Our Delight (6:23)
> \* Hybrid SACD (SACD layer) 2
> \* (#2-1) All Mornin' Long (20:21)
> \* (#2-2) They Can't Take That Away From Me (10:24)
> \* (#2-3) Our Delight (6:23)
> ➜ \[A\]pply, More candidates, Skip, Use as-is, as Tracks, Group albums,
> Enter search, enter Id, aBort, eDit, edit Candidates?
> \`\`\`
> 
> Yay!
> 
> 
> \## To Do
> 
> \<!--
> \- If you believe one of below checkpoints is not required for the change you
> are submitting, cross it out and check the box nonetheless to let us know.
> For example: - \[x\] ~Changelog~
> \- Regarding the changelog, often it makes sense to add your entry only once
> reviewing is finished. That way you might prevent conflicts from other PR's in
> that file, as well as keep the chance high your description fits with the
> latest revision of your feature/fix.
> \- Regarding documentation, bugfixes often don't require additions to the docs.
> \- Please remove the descriptive sentences in braces from the enumeration below,
> which helps to unclutter your PR description.
> \--\>
> 
> \- \[\] ~Documentation. (If you've added a new command-line flag, for example, find the appropriate page under \`docs/\` to describe it.)~
> \- \[X\] Changelog. (Add an entry to \`docs/changelog.rst\` to the bottom of one of the lists near the top of the document.)
> \- \[\] Tests. (Very much encouraged but not strictly required.) (I don't really know how to do this effectively and would appreciate pointers.)

---

<div class="post-metadata">

**Author:** ![grosjean](https://avatars.discourse-cdn.com/v4/letter/g/ad7895/32.png) [@grosjean](https://discourse.beets.io/u/grosjean)\
**Post date:** [July 4, 2024, 12:08pm UTC](https://discourse.beets.io/t/import-sacd-with-missing-tracks/2392/7 "2024-07-04T12:08:11Z")

</div>

Having the following in the match section of the config:

```auto
ignored_media: ['Hybrid SACD (CD layer)', 'Hybrid SACD (SACD layer, multichannel)']

```

help me a lot in fact
