Home of the Squeezebox™ & Transporter® network music players.
Page 1 of 4 123 ... LastLast
Results 1 to 10 of 36
  1. #1
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    740

    [Announce] LMSmusly - play similar music

    LMSmusly creates playlists / mixes based on track similarity - basically, you point it to a song, and it will queue up songs similar to it (comparable to MusicIP).

    Details and installation / usage instructions can be found on the homepage

  2. #2
    Member srasher's Avatar
    Join Date
    Jun 2006
    Location
    Bochum, Germany
    Posts
    85
    Hi Roland,

    thanks a lot for your efforts (also looking into the Essentia plugin)! I tried to install the LMSmusly stuff, first on my desktop computer for database analysis. It's an x86_64 machine running Ubuntu 16.04 LTS, AVX is available in the CPU, python3.5 installed. I put libmusly files into the "/opt/musly..." location mentioned on your instruction page and extracted the tar archive of the pre-built LMSmusly package into the root dir (with sudo, of course).

    When I try to run

    lmsmusly.py -h

    it immediately throws an exception saying "libmusly.lmsmusly - lmsmusly is not a package". Unfortunately I am not tooooo familiar with the python tool chain, so I might have missed something. Can you give any hint on what's going wrong here?

    Thanks a lot in advance!
    Seb

    PS: the OS anyway might be too outdated because when I tried to use the source distribution of LMSmusly, it threw an exception or errored out saying that libavcodec 5.7 isn't installed, which is correct because as far as I could see (maybe I have to look again), apt only gave me the option to install libavcodec 5.7 in my Ubuntu distribution...
    "The only word I know is 'Grunt' - and I can't spell it" (R.I.P. D.A.)

  3. #3
    Junior Member
    Join Date
    Sep 2015
    Posts
    2

    [Announce] LMSmusly - play similar music

    > Am 02.01.2018 um 00:31 schrieb Roland0 <Roland0.8afzrb (AT) no-mx (DOT) forums.slimdevices.com>:
    > LMSmusly creates playlists / mixes based on track similarity -
    > basically, you point it to a song, and it will queue up songs similar to
    > it (comparable to MusicIP).


    Cool addon for LMS!

    Allthough I do not think that it will be possible, it would be great to have such a functionality for online services like Spotify or Deezer. Do you see any chance for this?

    Ciao,

    Schoepp



  4. #4
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    740
    Quote Originally Posted by srasher View Post
    It's an x86_64 machine running Ubuntu 16.04 LTS, AVX is available in the CPU, python3.5 installed. I put libmusly files into the "/opt/musly..." location mentioned on your instruction page and extracted the tar archive of the pre-built LMSmusly package into the root dir (with sudo, of course).
    When I try to run
    lmsmusly.py -h
    it immediately throws an exception saying "libmusly.lmsmusly - lmsmusly is not a package".
    The built distribution is for python 3.6, not 3.5. While lmsmusly should run with older python 3 versions, the module install paths are different, so you'll have to move the 2 folders in the site-packages folder to the correct path, probably from /usr/lib64/python3.6/site-packages to /usr/lib64/python3.5/site-packages
    Check with
    Code:
    [user:~] $ python3
    Python 3.6.3 (default, Dec 16 2017, 20:59:34) 
    [GCC 7.2.0] on linux
    >>> import sys
    >>> print("\n".join( sys.path))
    PS: the OS anyway might be too outdated because when I tried to use the source distribution of LMSmusly, it threw an exception or errored out saying that libavcodec 5.7 isn't installed, which is correct because as far as I could see (maybe I have to look again), apt only gave me the option to install libavcodec 5.7 in my Ubuntu distribution...
    Check out this ppa

  5. #5
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    740
    Quote Originally Posted by schoeppi View Post
    Allthough I do not think that it will be possible, it would be great to have such a functionality for online services like Spotify or Deezer. Do you see any chance for this?
    None at all - the tracks have to be analyzed, which requires access to the audio data.
    However, I would have thought that most online services already include a similar functionality (after all, Spotify bought Echo Nest (RIP) for exactly this - which lead to the SmartMix plugin's demise, which was one of the reasons for writing this application)

  6. #6
    Member srasher's Avatar
    Join Date
    Jun 2006
    Location
    Bochum, Germany
    Posts
    85
    Quote Originally Posted by Roland0 View Post
    The built distribution is for python 3.6, not 3.5. While lmsmusly should run with older python 3 versions, the module install paths are different, so you'll have to move the 2 folders in the site-packages folder to the correct path, probably from /usr/lib64/python3.6/site-packages to /usr/lib64/python3.5/site-packages
    Check with
    Code:
    [user:~] $ python3
    Python 3.6.3 (default, Dec 16 2017, 20:59:34) 
    [GCC 7.2.0] on linux
    >>> import sys
    >>> print("\n".join( sys.path))
    Check out this ppa
    Thanks a lot, the latter tip helped! First one was also right direction but didn't help immediately, the sys.path was having lots of paths but none similar to your site-packages path and I struggled, so I tried the other method and it works. Currently analyzing. On the weekend I will have time to try it on the actual server.

    Cheers,
    Seb
    "The only word I know is 'Grunt' - and I can't spell it" (R.I.P. D.A.)

  7. #7
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    740
    Quote Originally Posted by srasher View Post
    First one was also right direction but didn't help immediately, the sys.path was having lots of paths but none similar to your site-packages path and I struggled,
    It seems Debian has some non-standard python specifics, so maybe the modules have to be in /usr/local/lib/pythonX.Y/dist-packages
    Check the output of
    Code:
    python3 -c "import site; print(site.getsitepackages())"
    (or just continue using the source package - doesn't really make any difference wrt functionality)

  8. #8
    Member srasher's Avatar
    Join Date
    Jun 2006
    Location
    Bochum, Germany
    Posts
    85

    lmsmusly/libmusly install on an Odroid U3 (running Max2play)

    Some more information that might be helpful for others: after analyzing a portion of my collection on the Ubuntu x86_64 machine, I proceeded to installing libmusly and lmsmusly on my server, which is an Odroid U3 running max2play.

    I used the compilation from source for libmusly (because it's a 32-bit machine) which was pretty straightforward (the libmusly source code README contains instructions for necessary dependencies).
    Initially I just left the libs where they were installed by "sudo make install" after compilation, which was "/usr/local/lib".

    I then chose to use the source archive for lmsmusly.

    First error on running lmsmusly.py was that it couldn't find libmusly.so and libmusly_resample.so.

    A recursive grep on the src sub directory leads to the following line:

    Code:
    ./lmsmusly/utils/config.py:MUSLY_LIB = "/opt/musly-0.2/lib/libmusly.so"
    So one can either change that variable value or put the lib into that directory (as instructed on Roland's page). I chose the second option.

    After that I got the same error for "libmusly_resample.so", although it was also put into the directory mentioned above.

    An run of

    Code:
    strace -o strace.log ./lmsmusly.py info
    and latter grep for "libmusly_resample.so" in that log file found that neither "/usr/local/lib" nor "/opt/musly-0.2/lib" are used to search for that lib. So as a dirty solution I put it into "/usr/lib".

    After that I had to install python-requests via

    Code:
    sudo apt install python3-requests
    Then lmsmusly.py works from the command line. Great!

    Next step will be to include it into LMS, will try this tomorrow.

    Cheers,
    Seb
    "The only word I know is 'Grunt' - and I can't spell it" (R.I.P. D.A.)

  9. #9
    Senior Member
    Join Date
    Jan 2009
    Location
    Sor°, Denmark
    Posts
    607
    Quote Originally Posted by schoeppi View Post
    > Am 02.01.2018 um 00:31 schrieb Roland0 <Roland0.8afzrb (AT) no-mx (DOT) forums.slimdevices.com>:
    > LMSmusly creates playlists / mixes based on track similarity -
    > basically, you point it to a song, and it will queue up songs similar to
    > it (comparable to MusicIP).


    Cool addon for LMS!

    Allthough I do not think that it will be possible, it would be great to have such a functionality for online services like Spotify or Deezer. Do you see any chance for this?

    Ciao,

    Schoepp
    The LastMix plugin does this. Works fine with Tidal. I Think it works with Spotty too(as Michael Herger has developed it). I even think it works with Deezer too.
    Callesoroe
    Living room: Transporter, Tact RCS 2.2X digital preamp, Martin Logan Vista speakers, AMPS(Icepower): Acoustic Reality Ear Enigma PLUS(PANELS), Acoustic Reality Ear TWO MKII(Bas)
    Kitchen: Receiver - S.M.S.L DAC, Prodipe Pro 5 active bi-amp speakers. Bedroom: Receiver+UE boombox, Kids: Receiver+Active speakers, Office: Transporter, JBL LSR305 active speakers , TIDAL HIFI flac streaming.
    http://www.last.fm/user/callesoroe

  10. #10
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    740
    Quote Originally Posted by srasher View Post
    Initially I just left the libs where they were installed by "sudo make install" after compilation, which was "/usr/local/lib".
    This is the root cause of all subsequent issues - cmake needs to already configure for the correct final destination (in order to set the correct rpath for the libs).
    Add the following to the beginning of musly's CMakeLists.txt if you build from the shell (if Eigen3 isn't in /tmp, adjust the path):
    Code:
    add_definitions(-DMUSLY_VERSION="${MUSLY_VERSION}")
    # start additions
    SET(CMAKE_INSTALL_PREFIX "/opt/musly-0.2")
    SET(CMAKE_BUILD_TYPE "Release")
    SET(CMAKE_SKIP_INSTALL_RPATH  FALSE)
    SET(CMAKE_SKIP_RPATH  FALSE)
    SET(EIGEN3_INCLUDE_DIR "/tmp/eigen-eigen-5a0156e40feb/")
    
    SET(CMAKE_SKIP_BUILD_RPATH  FALSE)
    SET(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE) 
    SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib")
    # end additions
    Quote Originally Posted by srasher View Post
    After that I got the same error for "libmusly_resample.so", although it was also put into the directory mentioned above.
    python's library loader cannot change the runtime linker path - while the library to load (libmusly.so ) can be anywhere, any dependencies ( in this case, libmusly_resample.so) have to be either in the standard runtime linker path, or in the rpath specified when building libmusly,so

    Quote Originally Posted by srasher View Post
    and latter grep for "libmusly_resample.so" in that log file found that neither "/usr/local/lib" nor "/opt/musly-0.2/lib" are used to search for that lib. So as a dirty solution I put it into "/usr/lib".
    Check if your runtime linker path includes /usr/local/lib (files /etc/ld.so.conf and/or /etc/ld.so.conf.d/). However, if libmusly.so is built as described above, this shouldn't be necessary.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •