{"id":22467738,"url":"https://github.com/dyscolab/scipy-events","last_synced_at":"2026-02-26T13:01:27.518Z","repository":{"id":266734934,"uuid":"899206138","full_name":"dyscolab/scipy-events","owner":"dyscolab","description":"A library of events for scipy.integrate.solve_ivp.","archived":false,"fork":false,"pushed_at":"2025-09-25T15:00:15.000Z","size":264,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-17T04:29:30.826Z","etag":null,"topics":["events","ode-solver","scipy","scipy-integrate"],"latest_commit_sha":null,"homepage":"https://pypi.org/p/scipy-events","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dyscolab.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-12-05T20:18:12.000Z","updated_at":"2025-09-25T15:00:19.000Z","dependencies_parsed_at":"2024-12-05T20:39:16.368Z","dependency_job_id":"0579e655-3cc2-4e45-ad14-19f3e5f212e6","html_url":"https://github.com/dyscolab/scipy-events","commit_stats":null,"previous_names":["maurosilber/scipy-events","dyscolab/scipy-events"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/dyscolab/scipy-events","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dyscolab%2Fscipy-events","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dyscolab%2Fscipy-events/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dyscolab%2Fscipy-events/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dyscolab%2Fscipy-events/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dyscolab","download_url":"https://codeload.github.com/dyscolab/scipy-events/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dyscolab%2Fscipy-events/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29860109,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-26T08:51:08.701Z","status":"ssl_error","status_checked_at":"2026-02-26T08:50:19.607Z","response_time":89,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["events","ode-solver","scipy","scipy-integrate"],"created_at":"2024-12-06T11:12:42.274Z","updated_at":"2026-02-26T13:01:27.472Z","avatar_url":"https://github.com/dyscolab.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# scipy_events\n\n[![Copier Badge][copier-badge]][copier-url]\n[![Pixi Badge][pixi-badge]][pixi-url]\n![License][license-badge]\n[![CI Badge][ci-badge]][ci-url]\n[![conda-forge Badge][conda-forge-badge]][conda-forge-url]\n[![PyPI Badge][pypi-badge]][pypi-url]\n[![Python version Badge][pypi-version-badge]][pypi-version-url]\n\nA library of events for `scipy.integrate.solve_ivp`.\n\nIt provides the following events:\n\n- `ChangeWhen` to apply a change when a given event happens.\n- `ChangeAt` to apply a change at some given times.\n\n## Usage\n\n```python\nimport numpy as np\nfrom scipy_events import ChangeAt, solve_ivp\n\nresult = solve_ivp(\n    lambda t, y: -y,\n    t_span=(0, 16),\n    y0=[1],\n    events=[\n        ChangeAt(\n            times=[4, 8],\n            change=lambda t, y, args: (np.full_like(y, 1), args),\n        )\n    ],\n)\n```\n\n![](docs/figures/change-at.png)\n\n```python\nimport numpy as np\nfrom scipy_events import ChangeWhen, solve_ivp\n\nresult = solve_ivp(\n    lambda t, y: -y,\n    t_span=(0, 16),\n    y0=[1],\n    events=[\n        ChangeWhen(\n            condition=lambda t, y: y[0] - 1e-2,\n            change=lambda t, y, args: (np.full_like(y, 1), args),\n        )\n    ],\n)\n```\n\n![](docs/figures/change-when.png)\n\n## Install\n\nUsing [pixi][pixi-url],\ninstall from PyPI with:\n\n```sh\npixi add --pypi scipy-events\n```\n\nor install the latest development version from GitHub with:\n\n```sh\npixi add --pypi scipy-events@https://github.com/dyscolab/scipy-events.git\n```\n\nOtherwise,\nuse `pip` or your `pip`-compatible package manager:\n\n```sh\npip install scipy-events  # from PyPI\npip install git+https://github.com/dyscolab/scipy-events.git  # from GitHub\n```\n\n## Development\n\nThis project is managed by [pixi][pixi-url].\nYou can install it for development using:\n\n```sh\ngit clone https://github.com/dyscolab/scipy-events\ncd scipy-events\npixi run pre-commit-install\n```\n\nPre-commit hooks are used to lint and format the project.\n\n### Testing\n\nRun tests using:\n\n```sh\npixi run test\n```\n\n### Publishing to PyPI\n\nWhen a tagged commit is pushed to GitHub,\nthe GitHub Action defined in `.github/workflows/ci.yml`\nbuilds and publishes the package to PyPI.\n\nTag a commit and push the tags with:\n\n```sh\ngit tag \u003cmy-tag\u003e\ngit push --tags\n```\n\nTrusted publishing must be enabled once in [PyPI Publishing](https://pypi.org/manage/account/publishing/).\nFill the following values in the form:\n\n```\nPyPI Project Name: scipy-events\n            Owner: maurosilber\n  Repository name: scipy-events\n    Workflow name: ci.yml\n Environment name: pypi\n```\n\n[ci-badge]: https://img.shields.io/github/actions/workflow/status/dyscolab/scipy-events/ci.yml\n[ci-url]: https://github.com/dyscolab/scipy-events/actions/workflows/ci.yml\n[conda-forge-badge]: https://img.shields.io/conda/vn/conda-forge/scipy-events?logoColor=white\u0026logo=conda-forge\n[conda-forge-url]: https://prefix.dev/channels/conda-forge/packages/scipy-events\n[copier-badge]: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/copier-org/copier/master/img/badge/badge-black.json\n[copier-url]: https://github.com/copier-org/copier\n[license-badge]: https://img.shields.io/badge/license-MIT-blue\n[pixi-badge]: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/prefix-dev/pixi/main/assets/badge/v0.json\n[pixi-url]: https://pixi.sh\n[pypi-badge]: https://img.shields.io/pypi/v/scipy-events.svg?logo=pypi\u0026logoColor=white\n[pypi-url]: https://pypi.org/project/scipy-events\n[pypi-version-badge]: https://img.shields.io/pypi/pyversions/scipy-events?logoColor=white\u0026logo=python\n[pypi-version-url]: https://pypi.org/project/scipy-events\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdyscolab%2Fscipy-events","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdyscolab%2Fscipy-events","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdyscolab%2Fscipy-events/lists"}