Skip to content
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

dream.set_text("a quiet pond underneath the midnight moon") = object has no attribute 'set_text' #76

Closed
nerdyrodent opened this issue Apr 2, 2021 · 6 comments

Comments

@nerdyrodent
Copy link

nerdyrodent commented Apr 2, 2021

Looks like def set_text is now def set_clip_encoding?
Also, various settings aren't honoured using dream.set_clip_encoding then dream (such as save_best = True). Would it be possible / make sense to retain settings from the previous dream?

@NotNANtoN
Copy link
Contributor

Hi! True, it is renamed now and not updated in the README.

But what do you mean when you talk about retaining settings from a previous dream? Was this working before and now it does not work anymore? How does save_best influence all of this?

@nerdyrodent
Copy link
Author

It's back :)

@nerdyrodent
Copy link
Author

nerdyrodent commented Apr 2, 2021

For "save_best", I was thinking for an example like below:

dream = Imagine(
    text = "An apple on fire",
    epochs = 6,
    append_seed = True,
    save_progress = False,
    save_best = True
)
dream()

dream.set_text("A pear on fire")
dream()

epochs, append seed and save_progress, etc all remain set when dreaming the pear, but save_best doesn't and so seems to be the "odd one out"?

@NotNANtoN
Copy link
Contributor

Ah, I see. The issue is that self.current_best_score is not reset to 0 when set_clip_encoding is called, that only happens in the __init__ at the moment. Maybe @lucidrains can quickly edit that?

@lucidrains
Copy link
Owner

@NotNANtoN fixed :)

@nerdyrodent
Copy link
Author

Awesome! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants