Git Product home page Git Product logo

petab_timecourse's Introduction

PEtab timecourse

This is an example implementation of an extension of PEtab, for the specification of time-dependent conditions.

Installation

Clone this repository then install it into your Python (virtual) environment.

git clone --recurse-submodules https://github.com/dilpath/petab_timecourse
cd petab_timecourse
pip install -e .[examples]

Examples

The examples depend on AMICI for simulation and pyPESTO for optimization, but these are independent of the PEtab extension.

File formats

Timecourse table

A TSV with sequences of experimental conditions/dosing regimes/etc.

timecourseId timecourse
(Unique) [string] [string]
dummyId 0:c0;5:c1;50:c2
  • timecourseId: An ID for the timecourse.
  • timecourse: A semicolon-delimited sequence of times and experimental conditions.
    • in the example, the timecourse starts at time t=0 with experimental condition c0. At t=5, experimental condition switches to c1. From t=50 onwards, experimental condition c2 is used.

TODO

How to specify parameter estimation problem when estimating time?

  • a lot of possible flexibility...
    • use objectivePrior... to apply constraints to the values that each estimated time point can take
    • for consecutively estimated time periods
      • the lower bound of the next period should match the upper bound of the previous period
      • handle via PEtab Control

Timecourse parameters table

WIP

  • all columns from normal PEtab parameters table
  • timecourseIds
  • conditionIds
  • type
    • time to estimate the start time of the period
      • then ignore parameterId etc?!
    • value to estimate the value that the parameter takes during the period

petab_timecourse's People

Contributors

dilpath avatar

Watchers

Frank Bergmann avatar  avatar

Forkers

m-philipps

petab_timecourse's Issues

it should be possible to run the package without pypest / amici

I needed the following changes to have the package run for me:

diff --git a/petab_timecourse/__init__.py b/petab_timecourse/__init__.py
index 4f77a5b..b38cd07 100644
--- a/petab_timecourse/__init__.py
+++ b/petab_timecourse/__init__.py
@@ -22,14 +22,17 @@ from .misc import (
 )
 
 
-from . import amici
-from .amici import (
-    simulate_timecourse,
-)
-
-from .pypesto import (
-    TimecourseObjective,
-)
+try: 
+    from . import amici
+    from .amici import (
+        simulate_timecourse,
+    )
+
+    from .pypesto import (
+        TimecourseObjective,
+    )
+except ImportError:
+    pass
 
 from .problem import Problem
 
diff --git a/petab_timecourse/simulator.py b/petab_timecourse/simulator.py
index fb7a9bf..249b06d 100644
--- a/petab_timecourse/simulator.py
+++ b/petab_timecourse/simulator.py
@@ -23,11 +23,15 @@ from petab.C import (
 from .C import (
     PERIODS,
 )
-from .amici import (
-    precreate_edata_periods,
-    precreate_parameter_mapping_periods,
-    add_output_timepoints_if_missing,
-)
+try:
+    from .amici import (
+        precreate_edata_periods,
+        precreate_parameter_mapping_periods,
+        add_output_timepoints_if_missing,
+    )
+except ImportError:
+    pass
+
 from .misc import (
     get_timecourse,
     subset_petab_problem,

Documentation

  • Format specification in human-friendly format
  • Schema

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.