A library and CLI for ion selection in mass spectrometry data.
Project description
wtv
An implementation of ion selection based on WTV-2.0
Project setup:
1: Clone the code from wtv
2: Create an empty miniconda environment miniconda
3: Manage dependencies with poetry
Running tests:
Using unittest:
To run all tests using unittest, use the following command:
python -m unittest discover -s tests
Using pytest:
-
Ensure
pytestis installed:poetry install --with dev
-
Run tests with
pytest:poetry run pytest
-
Debug test failures: Run
pytestwith verbose output:poetry run pytest -v
-
Generate a test coverage report: Install
pytest-cov:poetry add pytest-cov --group dev
Run tests with coverage:
poetry run pytest --cov=wtv
Testing Documentation Locally
To test the documentation locally, follow these steps:
-
Install MkDocs: Ensure MkDocs and its dependencies are installed. run:
poetry install --with docs
-
Serve the Documentation: Use the following command to serve the documentation locally:
poetry run mkdocs serve
-
Access the Documentation: Open your browser and navigate to
http://127.0.0.1:8000to view the documentation.
Running GitHub Actions Locally with act
To run all GitHub Actions workflows locally using act, follow these steps:
-
Install act: Download and install
actfrom its GitHub repository. -
Set Up Secrets: Create a
.secretsfile in the root of your repository and define the required secrets. For example:PYPI_API_TOKEN=your-real-or-mock-token-for-testing -
Run All Workflows: Use the following command to run all workflows:
act
-
Run a Specific Workflow: To run a specific workflow, use the
-Wflag followed by the path to the workflow file:act -W .github/workflows/package.yaml act -W .github/workflows/publish.yml
-
Specify an Event: If you want to simulate a specific event (e.g.,
push,pull_request, orrelease), use the-eflag:act -e push
-
Use a Specific Runner: By default,
actuses a lightweight Docker image. To use a full-featured image (e.g.,ubuntu-latest), specify it:act -P ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest
Example act Commands
-
Run all workflows:
act
-
Run the
package.yamlworkflow:act -W .github/workflows/package.yaml
-
Run the
publish.ymlworkflow:act -W .github/workflows/publish.yml
-
Simulate a
releaseevent:act -e release
Documentation Deployment
This project uses GitHub Actions to auto-generate and deploy documentation to GitHub Pages. To enable this workflow, ensure the following secret is configured in your repository:
GITHUB_TOKEN: This is automatically provided by GitHub for workflows. No additional setup is required unless you are using a custom token.
Known Issues
- It seems to generate slightly different results based on the OS version and/or Python version.
Acknowledgements
This project is based on the original work by Honglun Yuan, Yiding Jiangfang, Zhenhua Liu, Rong Rong Su, Qiao Li, Chuanying Fang, Sishu Huang, Xianqing Liu, Alisdair Robert Fernie, and Jie Luo, as published in WTV_2.0 and their associated publication.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file wtv-0.1.0.tar.gz.
File metadata
- Download URL: wtv-0.1.0.tar.gz
- Upload date:
- Size: 22.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.11.0 Linux/6.11.0-1015-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a37234a8235c6c39f3e5d80033cc102dc6c37a92ac409b2e851185b952375ac7
|
|
| MD5 |
63953f686c51788a5561b78f503eee9a
|
|
| BLAKE2b-256 |
1f2261fe8e03570c3e50c6e3c48fcfcc1dcd6be0bf05881382fadba2faae2603
|
File details
Details for the file wtv-0.1.0-py3-none-any.whl.
File metadata
- Download URL: wtv-0.1.0-py3-none-any.whl
- Upload date:
- Size: 22.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.11.0 Linux/6.11.0-1015-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dae66d738496829e9a642e01146dd8e0c50dd1cc6a18ea00fda68181049c0d30
|
|
| MD5 |
748361acb794ced6d26ce7b05bb4eca4
|
|
| BLAKE2b-256 |
205cb592f16cddcf6af2de556fe5812bb9cf8811aa35bb346c6da0cc37619eb8
|