Releases: AnyBody-Research-Group/AnyPyTools
AnyPyTools v1.20.4
What's Changed
- Fix crash with pytest plugin when saving output to h5 files.
- Fixed a bug where
ctrl-cevents were not propagated and were silenced. This
fixes an issue where using AnyPyTools in tools liek pytest or snakemake made
it difficult to interrupt the process.
AnyPyTools v.1.20.2
What's Changed
- rollback automatic detection of snakemake env by @melund in #132
- fix: Ensure ctrl-c are not suppressed by @melund in #134
Full Changelog: 1.20.2...1.20.3
AnyPyTools v.1.20.2
- Fixed a deprecation warning from the pytest plugin, and enable pytest 9 support.
AnyPyTools v. 1.20.1
- Fixed an issue with AnyPyTools when running directly in the main thread
of thesnakemakeworkflow tool (i.e., directly in the snakefile). This fix forces
AnyPyTools to use the standard Python subprocess module when running in snakemake.
AnyPyTools v. 1.20
- Fixed a problem that prevented multiple AnyPyTools instances from running
simultaneously in the same process. Previously, other running AnyBody instances
were shut down when the firstAnyPyProcess.start_macro()call finished.
AnyPyTools v.1.19.2
AnyPyTools v.1.19.2
- Fixed missing widget information is user-guide documentation.
1.19.1
AnyPyTools v1.19
Changed:
- The
results.to_dataframe()no longer returns the specialtask_*(meta data) in the output columns.
To get the extra task info useresults.to_dataframe(*, include_task_info=True) - The documentation page updated.
Added:
-
New
macro_commands.ExtendOutput()helper macro that can add arbitrary values
to the results output. This allows adding values that don't need to exist as
variables in the AnyBody model. This is useful for adding extra metadata that will
appear in the results output when creating the macros.macro = [ mc.Load("MyModel.main.any"), mc.ExtendOutput("SubjectID", "S001"), mc.ExtendOutput("SubjectHeight", "1.8"), ] results = app.start_macro(macro) assert results[0]["SubjectID"] == "S001" assert results[0]["SubjectHeight"] == 1.8
-
results.to_dataframe()has a new argument
exclude_task_infowhich can exclude task information (variables starting
with 'task_') when exporting results to a dataframe
AnyPyTools v1.18
Added:
-
New
macro_commands.Export()helper class that can save output with custom names.
Similar to the "Dump" command, but allows variables to be saved with arbitrary names.See the following example:
macro = [ mc.Load("MyModel.main.any"), mc.RunOperation("MyModel.Study.Kinematics"), mc.Export("Main.Study.Output.EKin", "NewShortName"), ] results = app.start_macro(macro)
The
Main.Study.Output.EKinvariable will be available in the results asresults[0]['NewShortName']instead of
using the full variable name.This also allows the same variable to be exported multiple times during a
single simulation with different names in the output. This was not possible
with the "Dump" command, as only the last exported variable would be available in the
results.
Changed:
- When exporting a whole folder hierarchy, the folders themselves will no longer
appear in the results asMain.MyFolder = "...". Instead, only actual values
and strings will be included in the output. - AnyPyTools now requires a minimum of Python 3.10.
- The helper macro class "OperationRun" has been renamed to "RunOperation". The old name still works for backwards compatibility.
AnyPyTools v.1.17.0
Changed:
- Temporary macro files
*.anymcrare now always deleted after a run.