Skip to content

Conversation

@tomoleary
Copy link
Member

Adding support for optimization problems, where there is an additional paramter z that is optimized in expectation over the distribution of parameter m, e.g., the prior

@tomoleary tomoleary requested a review from dc-luo November 5, 2022 18:43
@tomoleary
Copy link
Member Author

Should we add evaluation helper arrays to Observable classes in order to avoid constant need for new allocations?

if control_jacobian:
self.Jz = ObservableControlJacobian(self.observable)
output_dimension,control_dimension = self.Jz.shape
control_rank = min(self.parameters['jacobian_rank'],output_dimension,control_dimension)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should this be self.parameters['control_jacobian_rank']

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks!

elif component == ADJOINT:
elif component == hp.ADJOINT:
x = self.problem.generate_state()
elif component == 3:
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think CONTROL is defined in this file. Let's use that instead of 3

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks!

@tomoleary tomoleary requested a review from dc-luo June 14, 2023 13:47
@tomoleary tomoleary merged commit 13ea879 into main Jun 14, 2023
@tomoleary tomoleary deleted the control_dev branch June 14, 2023 14:23
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.

3 participants