Skip to content

Commit

Permalink
Update model.py python code to enable rendering in sphinx docs (#1452
Browse files Browse the repository at this point in the history
)

* Merge sample command with the example command (#1422)

* Merge sample command with the example command

* Fix example command usage

* Generalize Standard Run  (#1411)

* Modify header calculation to choose from predefined example output file or standard example output file

* Remove the readiness function from SCRA because it is redundant, since those checks are also performed by the amenable function

* Remove unused method

* Make csv serialization work for any kind of model api response

* Remove the standard flag from the CLI since it is now the default run

* Update tests

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Some import cleanup

* Add detailed docstrings and usage examples to Ersilia'a publish module and few update on the utils module (#1448)

* Merge sample command with the example command (#1422)

* Merge sample command with the example command

* Fix example command usage

* Generalize Standard Run  (#1411)

* Modify header calculation to choose from predefined example output file or standard example output file

* Remove the readiness function from SCRA because it is redundant, since those checks are also performed by the amenable function

* Remove unused method

* Make csv serialization work for any kind of model api response

* Remove the standard flag from the CLI since it is now the default run

* Update tests

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Some import cleanup

* Few code fixes

* Few code fixes

* Add detailed docstrings and usage examples to Ersilia'a utils module

* Add detailed docstrings and usage examples to Ersilia'a utils module

* Merge sample command with the example command (#1422)

* Merge sample command with the example command

* Fix example command usage

* Generalize Standard Run  (#1411)

* Modify header calculation to choose from predefined example output file or standard example output file

* Remove the readiness function from SCRA because it is redundant, since those checks are also performed by the amenable function

* Remove unused method

* Make csv serialization work for any kind of model api response

* Remove the standard flag from the CLI since it is now the default run

* Update tests

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Unnecessary files removed

* Some import cleanup

---------

Co-authored-by: Dhanshree Arora <[email protected]>

* fix: correcting the docstring in model.py to be rendered in sphinx doc page

---------

Co-authored-by: Dhanshree Arora <[email protected]>
  • Loading branch information
Abellegese and DhanshreeA authored Dec 23, 2024
1 parent 0685109 commit e3510ee
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ersilia/core/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,25 +77,29 @@ class ErsiliaModel(ErsiliaBase):
Examples
--------
Fetching a model:
Fetching a model this requires to use asyncio since `fetch` is a coroutine.:
.. code-block:: python
model = ErsiliaModel(model="model_id")
model.fetch()
Serving a model:
.. code-block:: python
model = ErsiliaModel(model="model_id")
model.serve()
Running a model:
.. code-block:: python
model = ErsiliaModel(model="model_id")
result = model.run(input="input_data.csv", output="output_data.csv")
Closing a model:
.. code-block:: python
model = ErsiliaModel(model="model_id")
Expand Down

0 comments on commit e3510ee

Please sign in to comment.