core.utils
core.utils#
Utility module for soulsgym.
- soulsgym.core.utils.get_pid(process_name: str) int#
Get the ID of a process.
- Parameters
process_name – The name of the process.
- Returns
The process ID.
- Raises
RuntimeError – No process with name
process_namecurrently open.
- soulsgym.core.utils.wrap_to_pi(x: Union[float, numpy.ndarray]) Union[float, numpy.ndarray]#
Wrap an angle into the interval of [-pi, pi].
- Parameters
x – Single angle or array of angles in radians.
- Returns
The wrapped angle.
- class soulsgym.core.utils.Singleton#
Metaclass for singletons.