schrodinger.application.matsci.msminimize module

Utilities for minimizing structures

Copyright Schrodinger, LLC. All rights reserved.

schrodinger.application.matsci.msminimize.create_minimizer_if_needed(mizer=None, **kwargs)

Context manager that allows creating a new minimizer or reusing an existing one.

Creating a new minimizer is expensive (~1 - 1.5 seconds) relative to actually minimizing most structures (0.005 - 1.0s), so re-using an existing minimizer may considerably speed up workflows.

Additional keyword arguments are passed on to the newly created Minimizer, or ignored if mizer is passed in.

Parameters

mizer (minimize.Minimizer) – An existing minimizer to use

Ytype

minimize.Minimizer

Yield

A forcefield minimizer