Announcement

Collapse
No announcement yet.

Announce: Bliss DSTM mixer

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Announce: Bliss DSTM mixer

    This is a mixer for "Don't Stop the Music" that uses the results of bliss analysis to find suitable tracks. For details about bliss itself please refer to its website.

    There are two parts to this mixer:
    1. A Linux/macOS/Windows app to analyse your music, save results to an SQLite database, and upload results to LMS
    2. An LMS plugin that contains pre-built mixer binaries for Linux (x86_64, arm, 64-bit arm), macOS (fat binary), and Windows


    The LMS plugin can be installed from my repo

    Binaries for the analyser will be placed on the Github releases page. This analyser requires ffmpeg to be installed for Linux and macOS (homebrew), but libraries are bundled with the Windows version. Contained within each ZIP is a README.md file with detailed usage steps. The current ZIPs can be downloaded from:


    As a quick guide:
    1. Install the LMS plugin
    2. Download the relevant ZIP of bliss-analyser
    3. Install ffmpeg for Linux or macOS
    4. Edit 'config.ini' in the bliss-analyser folder to contain the correct path to your music files, and the correct LMS hostname or IP address
    5. Analyse your files with: bliss-analyser analyse
    6. Once analysed, upload DB to LMS with: bliss-analyser upload
    7. Choose 'Bliss' as DSTM mixer in LMS


    On a 2015-era i7 8 core laptop with SSD I can analyse almost 14000 tracks/hour. Obviously this will vary depending upon track lengths, etc, but gives a rough idea of how long the analysis stage will take.

    The analyser only stores relative paths in its database - hence you can analyse on one machine and run the mixer on another. e.g. If you music is stored in /home/user/Music, then /home/user/Music/Artist/Album/01-Track.mp3 is stored in the database as Artist/Album/01-Track.mp3

    This mixer and analyser are Rust ports of the Bliss part of MusicSimilarity. I started that plugin to see if merging Essentia with Musly results would improve things, then discovered Bliss. For my music collection Bliss appears to create better mixes, and is much faster than Essentia. Hence this plugin.

    to-bliss.py can be used to convert a MusicSimilarity DB file (if it has bliss analysis) into a bliss.db - saving the need to re-analyse music if it has already been analysed with bliss.
    Last edited by cpd73; 2022-12-20, 17:32.
    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

    #2
    Originally posted by cpd73 View Post
    This is a mixer for "Don't Stop the Music" that uses the results of bliss analysis to find suitable tracks. For details about bliss itself please refer to its website.

    There are two parts to this mixer:
    1. A Linux/macOS/Windows app to analyse your music, save results to an SQLite database, and upload results to LMS
    2. An LMS plugin that contains pre-built mixer binaries for Linux(x86_64, arm, 64-bit arm), macOS (fat binary), and Windows


    The LMS plugin can be installed from my repo

    Binaries for the analyser will be placed on the Github releases page. This analyser requires ffmpeg to be installed for Linux and macOS (homebrew), but libraries are bundled with the Windows version. Contained within each ZIP is a README.md file with detailed usage steps. The current 0.0.1 ZIPs can be downloaded from:


    As a quick guide:
    1. Install the LMS plugin
    2. Download the relevant ZIP of bliss-analyser
    3. Install ffmpeg for Linux or macOS
    4. Edit 'config.ini' in the bliss-analyser folder to contain the correct path to your music files, and the correct LMS hostname or IP address
    5. Analyse your files with: bliss-analyser analyse
    6. Once analysed, upload DB to LMS with: bliss-analyser upload
    7. Choose 'Bliss' as DSTM mixer in LMS


    On a 2015-era i7 8 core laptop with SSD I can analyse almost 14000 tracks/hour. Obviously this will vary depending upon track lengths, etc, but gives a rough idea of how long the analysis stage will take.

    The analyser only stores relative paths in its database - hence you can analyse on one machine and run the mixer on another. e.g. If you music is stored in /home/user/Music, then /home/user/Music/Artist/Album/01-Track.mp3 is stored in the database as Artist/Album/01-Track.mp3

    This mixer and analyser are Rust ports of the Bliss part of MusicSimilarity. I started that plugin to see if merging Essentia with Musly results would improve things, then discovered Bliss. For my music collection Bliss appears to create better mixes, and is much faster than Essentia. Hence this plugin. However, whilst MusicSimilarity supports CUE files (it splits them apart for analysis) bliss-analyser currently does not. I realised I only had 3 CUE albums, and it was easier to just split them into individual files.

    to-bliss.py can be used to convert a MusicSimilarity DB file (if it has bliss analysis) into a bliss.db - saving the need to re-analyse music if it has already been analysed with bliss.
    I currently use MusicIP which adds fingerprinting in a track's tags. If I understand correctly Bliss doesn't use tags but stores info in a database.
    I add my music to a portable USB drive connected to a Windows laptop where I add tags, apply replaygain and analyse using MusicIP.
    I then copy the music to another USB drive plugged into a Pi4 using FreeFileSync.
    From the description it sounds like I can analyse on the laptop then upload the database to LMS on the Pi.
    If I add new music to my library is it possible to only analyse the new music or does the analyser analyse the whole library skipping the tracks already in the database?
    By the way the link in your post to Bliss doesn't work, is this the correct one?
    An open-source music analyzing library that is used to compute distance between songs


    Sent from my Pixel 3a using Tapatalk
    Living Room: Touch or Squeezelite (Pi3B) > Topping E30 > Audiolab 8000A > Monitor Audio S5 + BK200-XLS DF
    Bedroom: Radio
    Bathroom: Radio

    Comment


      #3
      Originally posted by slartibartfast View Post
      I currently use MusicIP which adds fingerprinting in a track's tags. If I understand correctly Bliss doesn't use tags but stores info in a database.
      That is correct. Whilst the analysis data is quite small (20 floating point numbers) and could be stored in a tag, I didn't want to touch the actual music files. Plus reading data from a DB is quicker then re-reading tags from all files.

      Originally posted by slartibartfast View Post
      From the description it sounds like I can analyse on the laptop then upload the database to LMS on the Pi.
      Yes, that's what I do. I scan on my i7 laptop, but the mixer (and LMS) run on a Pi4.

      Originally posted by slartibartfast View Post
      If I add new music to my library is it possible to only analyse the new music or does the analyser analyse the whole library skipping the tracks already in the database?
      Only new files that are not in its DB are analysed, and any old files are removed from the DB (unless --keep-old is used).

      Originally posted by slartibartfast View Post
      By the way the link in your post to Bliss doesn't work, is this the correct one?
      https://lelele.io/bliss.html
      That link is correct. However, the link in my original post works for me - tried on both desktop and mobile.
      Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

      Comment


        #4
        Originally posted by cpd73 View Post
        That is correct. Whilst the analysis data is quite small (20 floating point numbers) and could be stored in a tag, I didn't want to touch the actual music files. Plus reading data from a DB is quicker then re-reading tags from all files.



        Yes, that's what I do. I scan on my i7 laptop, but the mixer (and LMS) run on a Pi4.



        Only new files that are not in its DB are analysed, and any old files are removed from the DB (unless --keep-old is used).



        That link is correct. However, the link in my original post works for me - tried on both desktop and mobile.
        I tried the link from Tapatalk where it doesn't work but it does work from a browser [emoji2]. I'll give this a try.

        Sent from my Pixel 3a using Tapatalk
        Living Room: Touch or Squeezelite (Pi3B) > Topping E30 > Audiolab 8000A > Monitor Audio S5 + BK200-XLS DF
        Bedroom: Radio
        Bathroom: Radio

        Comment


          #5
          Sounds interesting, I currently run LMS on a Win10 server but am considering migrating to a PCP solution for the server. Would I be able to upload the Bliss DB to the PCP server and run the plugin/DTSM mixer on that platform?

          I currently use MusicIP tags to drive the DSTM mixer but this is not easily transferable to the PCP platform, plus the analysis is slow.
          Location 1: LMS 8.3 on Win 10 Brix Server, x3 SB Radios, x1 Touch, x1 Controller : Location 2: LMS 8.3 on Win 10 Brix Server, x2 SB Radios, x1 Duet Receiver, x1 Controller : Alexa Mediaserver Smart Skill, Material Android, SqueezeliteX control

          Comment


            #6
            Originally posted by staresy View Post
            Sounds interesting, I currently run LMS on a Win10 server but am considering migrating to a PCP solution for the server. Would I be able to upload the Bliss DB to the PCP server and run the plugin/DTSM mixer on that platform?
            That's the idea. Don't use pCP so cannot confirm it works, but I see no reason why it should not.
            Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

            Comment


              #7
              Originally posted by cpd73 View Post
              That's the idea. Don't use pCP so cannot confirm it works, but I see no reason why it should not.
              Edit, tried a different extraction tool (7zip), it extracts swresample-4.dll, but on running it says the file is corrupt/damaged.

              Thanks,
              When I try to extract the win analyser from the zip I get "An unexpected error is keeping you from extracting the file.... swresample-4.dll"

              Any ideas?

              Thanks
              Last edited by staresy; 2022-03-05, 12:13.
              Location 1: LMS 8.3 on Win 10 Brix Server, x3 SB Radios, x1 Touch, x1 Controller : Location 2: LMS 8.3 on Win 10 Brix Server, x2 SB Radios, x1 Duet Receiver, x1 Controller : Alexa Mediaserver Smart Skill, Material Android, SqueezeliteX control

              Comment


                #8
                Originally posted by staresy View Post
                Edit, tried a different extration tool (7zip), it extracts swresample-4.dll, but on running it says the file is corrupt/damaged.

                Thanks,
                When I try to extract the win analyser from the zip I get "An unexpected error is keeping you from extracting the file.... swresample-4.dll"

                Any ideas?

                Thanks
                Same here.
                Checksum error in bliss-analyser-windows-0.0.1\swresample-4.dll. The file is corrupt.

                Sent from my Pixel 3a using Tapatalk
                Living Room: Touch or Squeezelite (Pi3B) > Topping E30 > Audiolab 8000A > Monitor Audio S5 + BK200-XLS DF
                Bedroom: Radio
                Bathroom: Radio

                Comment


                  #9
                  I read through the announcement post, thinking "Finally, a similarity plugin that seems simple enough for me to understand"! But then I got to the part about bliss-analyser not dealing with CUE files. Most of my library is in the form of CDs ripped to a single file with a separate CUE file.

                  Given your statement that Bliss seems to create better mixes for your collection, I'd like to give it a go, but I'm not clear what my best option is. It appears that I can analyse with MusicSimilarity then convert the output to a Bliss database for use with this Bliss DSTM mixer - is that correct? Is there a Mac M1 binary for the MusicSimilarity analysis, or should I use the python script, and can that script be configured to do only a Bliss analysis?

                  Comment


                    #10
                    Originally posted by staresy View Post
                    Edit, tried a different extraction tool (7zip), it extracts swresample-4.dll, but on running it says the file is corrupt/damaged.

                    Thanks,
                    When I try to extract the win analyser from the zip I get "An unexpected error is keeping you from extracting the file.... swresample-4.dll"

                    Any ideas?

                    Thanks
                    Looks like the ZIP got corrupted on upload to github. I have re-uploaded, this. I have also downloaded the new linked version, and it unzips OK for me - but I am on Linux, not Windows.
                    Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

                    Comment


                      #11
                      Originally posted by chill View Post
                      I read through the announcement post, thinking "Finally, a similarity plugin that seems simple enough for me to understand"! But then I got to the part about bliss-analyser not dealing with CUE files. Most of my library is in the form of CDs ripped to a single file with a separate CUE file.

                      Given your statement that Bliss seems to create better mixes for your collection, I'd like to give it a go, but I'm not clear what my best option is. It appears that I can analyse with MusicSimilarity then convert the output to a Bliss database for use with this Bliss DSTM mixer - is that correct? Is there a Mac M1 binary for the MusicSimilarity analysis, or should I use the python script, and can that script be configured to do only a Bliss analysis?
                      The reason this does not support CUE files is basically because its coded in Rust (the bliss-rs library, which does the actual analysis, is written in Rust) and these are the first ever Rust programs I have written, so I'm not sure how to run external executables, etc. And as I had so few CUE files it just made more sense to not bother with these. The analyser links to ffmpeg, so if CUE splitting were to be supported I'd ideally just do it in-code rather than calling out to ffmpeg, etc. But, that will be a non-trivial task. The mixer code itself, which the plugin invokes, also does not handle CUE files. Earlier versions did, and it would be trivial to re-add this, I just removed it as the analyser does not support them.

                      I guess if there is a high-demand then I can look into it.

                      For now, you could just use MusicSimilarity configured just for Bliss - but the analyser used there has not been built for Windows.
                      Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

                      Comment


                        #12
                        Originally posted by cpd73 View Post
                        Looks like the ZIP got corrupted on upload to github. I have re-uploaded, this. I have also downloaded the new linked version, and it unzips OK for me - but I am on Linux, not Windows.
                        Thanks, working.

                        It's sat there analysing my library now, seems pretty quick, I reckon it'll take ~1hr for my >10k tracks on my old win M/C...
                        Location 1: LMS 8.3 on Win 10 Brix Server, x3 SB Radios, x1 Touch, x1 Controller : Location 2: LMS 8.3 on Win 10 Brix Server, x2 SB Radios, x1 Duet Receiver, x1 Controller : Alexa Mediaserver Smart Skill, Material Android, SqueezeliteX control

                        Comment


                          #13
                          In the repo I see the Bliss Mixer plugin is called Auto Play, is that right? There is also another plugin with the same name but a different description.

                          Sent from my Pixel 3a using Tapatalk
                          Living Room: Touch or Squeezelite (Pi3B) > Topping E30 > Audiolab 8000A > Monitor Audio S5 + BK200-XLS DF
                          Bedroom: Radio
                          Bathroom: Radio

                          Comment


                            #14
                            Originally posted by slartibartfast View Post
                            In the repo I see the Bliss Mixer plugin is called Auto Play, is that right? There is also another plugin with the same name but a different description.
                            Ah, oops! Should be fixed now!
                            Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.

                            Comment


                              #15
                              Originally posted by cpd73 View Post
                              For now, you could just use MusicSimilarity configured just for Bliss - but the analyser used there has not been built for Windows.
                              Thank you. I'm caught up on the MusicSimilarity thread now - should have done that before posting, sorry. Good point about the mixer code for this plugin not handling CUE files - I guess it's not suitable for my setup yet. I'll give MusicSimilarity a go. Is there a Mac build of the analyser?

                              I have a follow-up question about MusicSimilarity, but I'll post it in that thread to avoid polluting this thread.
                              Last edited by chill; 2022-03-05, 13:28.

                              Comment

                              Working...
                              X