I have a image generator which samples a few fairly large datasets (around 10K words per category).

The user selects a dataset , from which a word is randomly selected.

As such , I only need to load the dataset which is currently selected.

I’d like for the other datasets to be un-loaded until the user selects them.

Is there a way to do this?

Or , can this problem be resolved by other means?

  • VioneT@lemmy.worldM
    link
    fedilink
    English
    arrow-up
    3
    ·
    8 months ago

    Just some clarification, currently it gives the whole generator i.e. not only the specified output at the $output. I’m not saying that it is bad, but I would guess that it is counter-intuitive with how the regular imports work. Possibly an option?

      • allo@lemmy.world
        link
        fedilink
        English
        arrow-up
        2
        ·
        7 months ago

        only thing out of place catches my eye is this sentence: Due to the above points, you should only use this plugin if the loading speed of your generator significantly impacted by the large number of imports that you have.

        like how mine was missing a word, yours is missing a word :) 10 points if you automatically caught that mine was missing a word. another 10 points if u automatically caught where the target sentence was missing a word.