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

Feature Scaling in DoE #358

Merged
merged 11 commits into from
Aug 21, 2024
Merged

Feature Scaling in DoE #358

merged 11 commits into from
Aug 21, 2024

Conversation

jduerholt
Copy link
Contributor

@jduerholt jduerholt commented Feb 26, 2024

Hi @Osburg,

this is my interpretation of the scaling as discussed in #354 and #343.

What do you think? No testing etc. yet.

Feel also free, to proceed just from this PR, of course only if you want ;)

Best,

Johannes

@jduerholt jduerholt marked this pull request as draft February 26, 2024 10:20
@jduerholt
Copy link
Contributor Author

I also added some tests, and not that I return as jacobian just the diagonal elements of the full matrix.

Copy link
Collaborator

@Osburg Osburg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess you already did most of the work. I mainly integrated your transformations in doe and added a few tests.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed the dependency on n_experiments here. Thought it is not really necessary. Are you fine with this?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Think here we have to scale x first before calling _evaluate_jacobian() (as it is done now), right?

@Osburg
Copy link
Collaborator

Osburg commented Mar 2, 2024

Hi @jduerholt,

hmm, on my machine the tests are not failing... possible that they just randomly failed? <-- seems like this is the case.
Apart from this: do my additions roughly look like you wanted it?

Cheers
Aaron :)

@Osburg Osburg marked this pull request as ready for review March 2, 2024 22:44
@Osburg
Copy link
Collaborator

Osburg commented Apr 27, 2024

Hi @jduerholt :)

is this one ready to be merged? (don't want to approve my own changes without showing it to sb before :D)

cheers
Aaron

@jduerholt
Copy link
Contributor Author

Hi @Osburg,

thx for the reminder, I will have a look over the week.

Best,

Johannes

Copy link
Contributor Author

@jduerholt jduerholt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Osburg,

sorry that it took so long. I was in parental leave and could not motivate me.

I have in principle only one comment regarding the design of the classes.

What do you think?

Best,

Johannes

bofire/data_models/strategies/doe.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/space_filling.py Outdated Show resolved Hide resolved
@Osburg
Copy link
Collaborator

Osburg commented Jul 28, 2024

Hey Johannes,

sry for being inactive for so long, I was very busy with university recently. I removed the TransformEnum and added validators for the feature range. Does it look somewhat similar to what you had in mind?
I think the error in type checking comes from pytorch see here

Cheers
Aaron :)

@jduerholt jduerholt mentioned this pull request Jul 31, 2024
Copy link
Contributor Author

@jduerholt jduerholt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Osburg,

thank you very much. I pushed a PR in which I created a reusable bound feature: #423 Can you use it also here?

bofire/data_models/strategies/doe.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/space_filling.py Outdated Show resolved Hide resolved
bofire/strategies/enum.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/doe.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/space_filling.py Outdated Show resolved Hide resolved
@jduerholt
Copy link
Contributor Author

In the PR, also the typing issue is fixed.

@jduerholt
Copy link
Contributor Author

So just merge main into your branch, as the PR is already accepted.

@Osburg
Copy link
Collaborator

Osburg commented Aug 18, 2024

Hey! in the current version the new Bounds type is used instead. Does it look ok to you now? :)

Copy link
Contributor Author

@jduerholt jduerholt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much. Looks good to me. If you want you can change the three sugestions that I made. If not, I merge it in as is and change it later.

Just do as you want.

I cannot officially approve it as I am also author of the PR. But I can then force merge it. Just tell me how you want to do it ;)

bofire/data_models/strategies/doe.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/space_filling.py Outdated Show resolved Hide resolved
bofire/data_models/strategies/space_filling.py Outdated Show resolved Hide resolved
Osburg and others added 4 commits August 19, 2024 16:34
Co-authored-by: Johannes P. Dürholt <johannespeter.duerholt@evonik.com>
Co-authored-by: Johannes P. Dürholt <johannespeter.duerholt@evonik.com>
Co-authored-by: Johannes P. Dürholt <johannespeter.duerholt@evonik.com>
Copy link
Collaborator

@Osburg Osburg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright, then I approve it. Feel free to merge it in whenever you like :)

@jduerholt
Copy link
Contributor Author

Perfect, I did not know that this was working. I will then make the two changes this evening and merge it then in. Thanks!

@jduerholt jduerholt merged commit b730c29 into main Aug 21, 2024
20 checks passed
@jduerholt jduerholt deleted the feature/doe_scaling branch August 21, 2024 07:37
@jduerholt jduerholt mentioned this pull request Aug 21, 2024
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

Successfully merging this pull request may close these issues.

2 participants