-
Notifications
You must be signed in to change notification settings - Fork 423
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
treating sampler types like lists via command line? #73
Comments
This sounds like a more advanced use case then I'd want to support at the command line. I'd suggest just moving to the python interface at that point. Untested code but you get the idea: from imaginairy import ImaginePrompt, imagine_image_files
from imaginairy.samplers.base import SAMPLER_TYPE_OPTIONS
def main():
prompt_text = "a dolphin"
prompts = []
for sampler_type in SAMPLER_TYPE_OPTIONS:
prompt = ImaginePrompt(
prompt_text, width=512, height=512, steps=20, seed=1, sampler_type=sampler_type
)
prompts.append(prompt)
imagine_image_files(prompts, outdir="output")
if __name__ == "__main__":
main() |
great thanks! |
incidentally it possible/desirable to suppress the error/warning messages that happen when using script like above? e.g. it spews out a pile of warnings starting with:
|
from imaginairy.log_utils import configure_logging
configure_logging() |
thanks again! will leave you alone for today :-) |
yeah no worries - thanks for all the great feedback |
just another suggestion..
interesting testing with same prompt + seed with different sampler types led to a thought that having the option for 'each', or 'series' (ddim+plms), or 'random' options on --sampler-type might come in handy..
not sure what syntax would be consistent with command line options but maybe using {} or
_option_
as per prompt syntaxes might work e.g.:_each_
= do 1 each of sampler types available (currently 10, thereby creating ten images)_random_
= choose 1 sampler randomly'+ syntax' for 'series' thereby "--sampler-type ddim + plms + k_huen" = step through sampler series list thereby creating three images
or maybe [] easier to parse, e.g. --sampler-type [ddim plms k_huen]
not sure, leave as whether a sensible/useful idea, and implementation details, for you to decide :-)
The text was updated successfully, but these errors were encountered: