Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: [fb2k v2] Random Pools (foo_random_pools) (Read 179457 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #350
To avoid that, I use "2" for the setting "Add when the playback position is X items or less from the end".
I don't know if it's a known bug, or if it can be circumvented ?
This is neither a known bug nor can it be circumvented. It's a just timing problem. Setting the value as you described is the best what you can do.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #351
Hello @fbuser, I just noticed that, with FB v2 beta 34, the "Check for updated components" did not report as new your 3 components: Random Pool 2.0.0., SQLTree 4.0.0 and SQLite Utilities 3.0.2. (this did not prevent me from installing all them manually).
Said that, I also noted that FB v2 beta 34 can detect other updates, thereof I think there is a problem with your components versioning reporting.
Regards, Andrea

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #352
**** Performance problem with new version 2.0.0 ****

Hello @fbuser , my PC is an old 32bit running Win 10.
Stated this, the previous version was able to generate a 50 tracks random playlist in few seconds (I have a large library).
The new V2.0.0 takes 20 times (or so) longer!!!!

To be noted that I have updated the 3 components Random Pool 2.0.0., SQLTree 4.0.0 and SQLite Utilities 3.0.2, and not just the Random Pool.

Can you help me troubleshooting the problem? I really would  like to get back to a decent performance.

Kind regards, Andrea

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #353
Hello @fbuser, I just noticed that, with FB v2 beta 34, the "Check for updated components" did not report as new your 3 components: Random Pool 2.0.0., SQLTree 4.0.0 and SQLite Utilities 3.0.2. (this did not prevent me from installing all them manually).
Said that, I also noted that FB v2 beta 34 can detect other updates, thereof I think there is a problem with your components versioning reporting.
Regards, Andrea
Seems to work now. Had been also a problem for my components.
Quote
Component update: Checking for: foo_uie_sql_tree / SQL Tree / 4.0.0
Component update: Found a match - 4.0.0 vs 4.0.0
Component update: Checking for: foo_sqlite / SQLite Utilities / 3.0.2
Component update: Found a match - 3.0.2 vs 3.0.2

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #354
Yes, as soon as fb2k v2 becomes stable.

Thank you very much for new version of plugin! <3
Error 404; signature server not available.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #355
my PC is an old 32bit running Win 10.
This in combination with this
I have a large library
is actually the problem.

Can you help me troubleshooting the problem? I really would  like to get back to a decent performance.
This might not be possible, but just let me know, which settings you are using for this

Stated this, the previous version was able to generate a 50 tracks random playlist in few seconds (I have a large library).
The new V2.0.0 takes 20 times (or so) longer!!!!

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #356
I've updated plugin today, v2.0.1, and it crashes foobar2000. Windows 11 64 bit, v2.0 works.
Error 404; signature server not available.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #357
I've updated plugin today, v2.0.1, and it crashes foobar2000. Windows 11 64 bit, v2.0 works.
Could you please post the crash report here?
Thanks.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #358
I had the same problem. I was not able to even start foobar without using safe mode and removing the component.

I have multiple crash logs I can upload - let me know if this one works.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #359
I have multiple crash logs I can upload - let me know if this one works.
Thanks, this is sufficient. But I have a few questions:

  • Did you upgrade from random pools version 2.0.0 or did you newly install version 2.0.1?
  • If it was a new installation, did you use the configuration from a fb2k version < 2?
  • If you used the configuration from a fb2k version < 2, what are the versions of fb2k and random pools you take the configuration from?

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #360
I upgraded from 2.0.0. When foobar relaunched after installing 2.0.1, it immediately crashed.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #361
I upgraded from 2.0.0. When foobar relaunched after installing 2.0.1, it immediately crashed.
Thanks for the info. I should have asked also for this scenario: Did you use a configuration from a fb2k version < 2 when you installed random pools version 2.0.0?

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #362
I upgraded from foobar 1.6 where I also had Random Pools installed, so probably yes.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #363
I upgraded from foobar 1.6 where I also had Random Pools installed, so probably yes.
Ok, that explains the cause of the crash. It should be fixed now with the lastet version.

 

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #364
Ok, that explains the cause of the crash. It should be fixed now with the lastet version.

Sorry for late reply, it was the same for me - I've migrated config from 1.6 when installing beta 2.0, 32 to 64 bit. randompools weren't available then, so I waited final version of 2.0, installed 2.0 of randompools, it worked, and then upgraded to 2.0.1, had crash.
Error 404; signature server not available.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #365
Sorry for late reply, it was the same for me - I've migrated config from 1.6 when installing beta 2.0, 32 to 64 bit. randompools weren't available then, so I waited final version of 2.0, installed 2.0 of randompools, it worked, and then upgraded to 2.0.1, had crash.
Hmm, this is a different scenario as that vom @Reith and it's a bit suprising.

In case you still have problems also with 2.0.2, could you please post your config.sqlite from your profile folder, so that I can analyze it?

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #366
Hello,
I am having problems with the new version, starting from V2.0.
Before that version, my PC was taking 15-20 seconds to create a 50 tracks random playlist, while now, using the today last versions of all the components, it is taking 180 to 240 seconds!

[foo_random_pools] 22:25:23.188: Get new pool database connection, db pool size: 0, available connections: 0 ...
[foo_random_pools] 22:25:23.188: Open database C:\Users\AdmAT\AppData\Roaming\foobar2000-v2\configuration\foo_sqlite.user.db ...
[foo_random_pools] 22:25:23.193: Open database C:\Users\AdmAT\AppData\Roaming\foobar2000-v2\configuration\foo_sqlite.user.db: 0:00.004594
[foo_sqlite] 22:25:23.203: Create MetaDB_Module ...
[foo_sqlite] 22:25:23.204: Create MetaDB_Module: 0:00.000126
[foo_random_pools] 22:25:23.204: Attach database C:\Users\AdmAT\AppData\Roaming\foobar2000-v2\configuration\foo_sqlite.materialize.db as materialize ...
[foo_random_pools] 22:25:23.207: Attach database C:\Users\AdmAT\AppData\Roaming\foobar2000-v2\configuration\foo_sqlite.materialize.db as materialize: 0:00.003770
[foo_random_pools] 22:25:23.207: Get new pool database connection, db pool size: 0, available connections: 0: 0:00.019558
[foo_random_pools] 22:25:23.231: Adding pools from pool set Random Tracks SQL ...
[foo_random_pools] 22:25:23.234: Add pool '050 random tracks' from pool set Random Tracks SQL ...
[foo_random_pools] 22:27:38.751: Add pool '050 random tracks' from pool set Random Tracks SQL: 2:15.517329
[foo_random_pools] 22:27:38.762: Adding pools from pool set Random Tracks SQL: 2:15.530664

Anyone out there can help me understanding what's going wrong?
Regards, Andrea

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #367
Anyone out there can help me understanding what's going wrong?
Please, post your settings. Besides this as you are obviously using a SQL query, ensure that you are using a materialized media library table, not the virtual table directly. This should be always faster on your system.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #368
Anyone out there can help me understanding what's going wrong?
Please, post your settings. Besides this as you are obviously using a SQL query, ensure that you are using a materialized media library table, not the virtual table directly. This should be always faster on your system.

Hello @fbuser, I checked my PC and the file "foo_sqlite.materialize.db" is there and has size of 450MB approximatively, while the "metadb.sqlite" file is about 1GB in size.

Regarding my configuration and queries, I am only using the queries you kindly made for me months ago. As well as the "marialization" of the dBase was made following your instructions.
Since then I didn't change anything, also because I don't know anything of SQL.

The queries and materialization instruction you provided me in: Reply #318 – 2022-08-19 21:56:15 and Reply #331 – 2022-08-23 19:21:06 of this thread.

What really happened, it was that along with the release of the final Foobar V2, you also released the new set of 3 components, Random Pool 2.0.0., SQLTree 4.0.0 and SQLite Utilities 3.0.2, and since then I am having this performance issue.

Kindly understand that, due to my ignorance of SQL, I cannot understand if the problem is within the new Foobar V2 or what else.

Said that, I am very happy to do whatever needed to let you understand what's wrong. Please, just tell me step by step what I shall have to do and/to provide you.

Thanks and regards, Andrea

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #369
The queries and materialization instruction you provided me in: Reply #318 – 2022-08-19 21:56:15 and Reply #331 – 2022-08-23 19:21:06 of this thread.
Ok, can you please open the SQLite console, enter the following statement and let me know the result?
Code: [Select]
WITH
Albums AS (
  SELECT album||'|'||coalesce("album artist",artist) Album
  FROM MMediaLibrary
  GROUP BY 1
  ORDER BY random()
  LIMIT 10
)
SELECT path, subsong FROM
MMediaLibrary
WHERE album||'|'||coalesce("album artist",artist) IN (SELECT album FROM Albums)
ORDER BY album||'|'||coalesce("album artist",artist),coalesce(discnumber,1),tracknumber;

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #370
Hello @fbuser , thanks a lot for your support that allowed me to fix the problem.
I noted that the SQL query you provided me in Reply #318 – 2022-08-19 was making use of MediaLibrary instead of MMediaLibrary.
I then put MMediaLibrary also in those set of "random tracks" queries and now I can have a 50 random tracks playlist created in 10 seconds! Perfect so! About 3 times faster than the old good 2022 performance.

Now, solved my "current performance problem", still remaining the big question: why it was anyway working decently in the past with MediaLibrary and not anymore today?

All the best and thanks a lot again for your help, Andrea

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #371
I noted that the SQL query you provided me in Reply #318
It was actually in #324. In #318 was the initial solution without SQL.

still remaining the big question: why it was anyway working decently in the past with MediaLibrary and not anymore today?
Indeed, especially as the performance for that query on my 6 year old standard notebook is 2.3 seconds for MediaLibrary and 1.7 seconds for MMediaLibrary.

So the performance degretion for you is most likely caused by your slow system in the first place in combination with the internal changes including the changes for SQLite itself. But even on your system this should normally not cause such a huge performance difference between both statement versions.

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #372
I'm real close to getting what I want, finally, and I can hardly stand it lol. I want a playlist of one song per artist, that song being the oldest played from that artist, played randomly. So my playlist would be sorted by %ARTIST% - %Last_Played%, then play (or put in a playlist) the first song from each artist.
Is this the plugin that will do it?

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #373
I want a playlist of one song per artist, that song being the oldest played from that artist.

So far I have this for a pool definition...
Group = %artist%
# of groups to add = 1000
# of tracks to add = 1
limit after sorting = yes
sort = %last_played%
sort/limit each group = yes
title format = yes
media library = yes
filter = E:\Music\Brian Music\Albums

One small issue is lots of duplicates, which I can remove with the FB "remove duplicates" menu option. Would there be a SQL Query I could use instead to remove the duplicates? Thank you!

Re: [fb2k v2] Random Pools (foo_random_pools)

Reply #374
One small issue is lots of duplicates

I fixed the dupes by adding another %artist% filter at the end.

One more thing to tackle, if an artist has only one song it will add to the playlist even if recently played. I could use the skip track plugin to not play recent songs, but is there another way using this plugin?

Thank you!