pheval 0.5.1__tar.gz → 0.5.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of pheval might be problematic. Click here for more details.

Files changed (52) hide show
  1. {pheval-0.5.1 → pheval-0.5.2}/PKG-INFO +4 -4
  2. {pheval-0.5.1 → pheval-0.5.2}/README.md +3 -3
  3. {pheval-0.5.1 → pheval-0.5.2}/pyproject.toml +1 -1
  4. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/benchmark.py +37 -17
  5. {pheval-0.5.1 → pheval-0.5.2}/LICENSE +0 -0
  6. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/__init__.py +0 -0
  7. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/__init__.py +0 -0
  8. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/benchmark_db_manager.py +0 -0
  9. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/benchmark_output_type.py +0 -0
  10. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/binary_classification_curves.py +0 -0
  11. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/binary_classification_stats.py +0 -0
  12. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/generate_plots.py +0 -0
  13. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/generate_rank_comparisons.py +0 -0
  14. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/rank_stats.py +0 -0
  15. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/analyse/run_data_parser.py +0 -0
  16. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/cli.py +0 -0
  17. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/cli_pheval.py +0 -0
  18. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/cli_pheval_utils.py +0 -0
  19. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/config_parser.py +0 -0
  20. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/implementations/__init__.py +0 -0
  21. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/infra/__init__.py +0 -0
  22. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/infra/exomiserdb.py +0 -0
  23. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/post_processing/__init__.py +0 -0
  24. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/post_processing/phenopacket_truth_set.py +0 -0
  25. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/post_processing/post_processing.py +0 -0
  26. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/post_processing/validate_result_format.py +0 -0
  27. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/__init__.py +0 -0
  28. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/create_noisy_phenopackets.py +0 -0
  29. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/create_spiked_vcf.py +0 -0
  30. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/custom_exceptions.py +0 -0
  31. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/prepare_corpus.py +0 -0
  32. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/prepare/update_phenopacket.py +0 -0
  33. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/CADA_results.txt +0 -0
  34. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/DeepPVP_results.txt +0 -0
  35. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/OVA_results.txt +0 -0
  36. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/Phen2Gene_results.json +0 -0
  37. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/Phenolyzer_results.txt +0 -0
  38. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/lirical_results.tsv +0 -0
  39. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/alternate_ouputs/svanna_results.tsv +0 -0
  40. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/resources/hgnc_complete_set.txt +0 -0
  41. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/run_metadata.py +0 -0
  42. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/runners/__init__.py +0 -0
  43. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/runners/runner.py +0 -0
  44. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/__init__.py +0 -0
  45. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/docs_gen.py +0 -0
  46. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/docs_gen.sh +0 -0
  47. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/exomiser.py +0 -0
  48. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/file_utils.py +0 -0
  49. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/logger.py +0 -0
  50. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/phenopacket_utils.py +0 -0
  51. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/semsim_utils.py +0 -0
  52. {pheval-0.5.1 → pheval-0.5.2}/src/pheval/utils/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pheval
3
- Version: 0.5.1
3
+ Version: 0.5.2
4
4
  Summary:
5
5
  Author: Yasemin Bridges
6
6
  Author-email: y.bridges@qmul.ac.uk
@@ -32,10 +32,10 @@ Description-Content-Type: text/markdown
32
32
 
33
33
  # PhEval - Phenotypic Inference Evaluation Framework
34
34
 
35
- ![PyPI](https://img.shields.io/pypi/v/pheval)
35
+ [![PyPI](https://img.shields.io/pypi/v/pheval)](https://pypi.org/project/pheval/)
36
36
  ![Build Status](https://img.shields.io/github/actions/workflow/status/monarch-initiative/pheval/pypi-publish.yml?branch=main)
37
37
  ![License](https://img.shields.io/github/license/monarch-initiative/pheval)
38
- ![Python Version](https://img.shields.io/badge/python-3.8%2B-blue)
38
+ ![Python Version](https://img.shields.io/badge/python-3.10%2B-blue)
39
39
  ![Issues](https://img.shields.io/github/issues/monarch-initiative/pheval)
40
40
 
41
41
  ## Overview
@@ -53,7 +53,7 @@ For more information please see the full [documentation](https://monarch-initiat
53
53
 
54
54
  ## Download and Installation
55
55
 
56
- 1. Ensure you have Python 3.8 or greater installed.
56
+ 1. Ensure you have Python 3.10 or greater installed.
57
57
  2. Install with `pip`:
58
58
  ```bash
59
59
  pip install pheval
@@ -1,9 +1,9 @@
1
1
  # PhEval - Phenotypic Inference Evaluation Framework
2
2
 
3
- ![PyPI](https://img.shields.io/pypi/v/pheval)
3
+ [![PyPI](https://img.shields.io/pypi/v/pheval)](https://pypi.org/project/pheval/)
4
4
  ![Build Status](https://img.shields.io/github/actions/workflow/status/monarch-initiative/pheval/pypi-publish.yml?branch=main)
5
5
  ![License](https://img.shields.io/github/license/monarch-initiative/pheval)
6
- ![Python Version](https://img.shields.io/badge/python-3.8%2B-blue)
6
+ ![Python Version](https://img.shields.io/badge/python-3.10%2B-blue)
7
7
  ![Issues](https://img.shields.io/github/issues/monarch-initiative/pheval)
8
8
 
9
9
  ## Overview
@@ -21,7 +21,7 @@ For more information please see the full [documentation](https://monarch-initiat
21
21
 
22
22
  ## Download and Installation
23
23
 
24
- 1. Ensure you have Python 3.8 or greater installed.
24
+ 1. Ensure you have Python 3.10 or greater installed.
25
25
  2. Install with `pip`:
26
26
  ```bash
27
27
  pip install pheval
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pheval"
3
- version = "0.5.1"
3
+ version = "0.5.2"
4
4
  description = ""
5
5
  authors = ["Yasemin Bridges <y.bridges@qmul.ac.uk>",
6
6
  "Julius Jacobsen <j.jacobsen@qmul.ac.uk>",
@@ -23,27 +23,32 @@ def scan_directory(run: RunConfig, benchmark_type: BenchmarkOutputType) -> pl.La
23
23
  run (RunConfig): RunConfig object.
24
24
  benchmark_type (BenchmarkOutputTypeEnum): Benchmark output type.
25
25
  Returns:
26
- pl.LazyFrame: LazyFrame object containing all the results in the directory..
26
+ pl.LazyFrame: LazyFrame object containing all the results in the directory.
27
27
  """
28
28
  logger = get_logger()
29
29
  logger.info(f"Analysing results in {run.results_dir.joinpath(benchmark_type.result_directory)}")
30
30
  return (
31
- pl.scan_parquet(
32
- run.results_dir.joinpath(benchmark_type.result_directory),
33
- include_file_paths="file_path",
34
- ).with_columns(
35
- pl.col("rank").cast(pl.Int64),
36
- pl.col("file_path").str.extract(r"([^/\\]+)$").alias("result_file"),
37
- pl.col("true_positive").fill_null(False),
38
- )
39
- ).filter(
40
31
  (
41
- pl.col("score") >= run.threshold
42
- if run.score_order.lower() == "descending"
43
- else pl.col("score") <= run.threshold
32
+ pl.scan_parquet(
33
+ run.results_dir.joinpath(benchmark_type.result_directory),
34
+ include_file_paths="file_path",
35
+ ).with_columns(
36
+ pl.col("rank").cast(pl.Int64),
37
+ pl.col("file_path").str.extract(r"([^/\\]+)$").alias("result_file"),
38
+ pl.col("true_positive").fill_null(False),
39
+ )
40
+ )
41
+ .filter(
42
+ (
43
+ pl.col("score") >= run.threshold
44
+ if run.score_order.lower() == "descending"
45
+ else pl.col("score") <= run.threshold
46
+ )
47
+ if run.threshold is not None
48
+ else True
44
49
  )
45
- if run.threshold is not None
46
- else True
50
+ .sort("rank")
51
+ .unique(subset=["file_path", *benchmark_type.columns], keep="first")
47
52
  )
48
53
 
49
54
 
@@ -68,14 +73,29 @@ def process_stats(
68
73
  )
69
74
  curve_results.append(compute_curves(run.run_identifier, result_scan))
70
75
  true_positive_cases.append(
71
- result_scan.filter(pl.col("true_positive")).select(
76
+ result_scan.filter(pl.col("true_positive"))
77
+ .select(
72
78
  ["result_file", *benchmark_type.columns, pl.col("rank").alias(run.run_identifier)]
73
79
  )
80
+ .sort(["result_file", *benchmark_type.columns])
74
81
  )
75
82
  return (
76
83
  pl.concat(stats, how="vertical").collect(),
77
84
  pl.concat(curve_results, how="vertical").collect(),
78
- pl.concat(true_positive_cases, how="align_inner").collect(),
85
+ pl.concat(
86
+ [true_positive_cases[0]]
87
+ + [
88
+ df.select(
89
+ [
90
+ col
91
+ for col in df.collect_schema().keys()
92
+ if col not in ["result_file", *benchmark_type.columns]
93
+ ]
94
+ )
95
+ for df in true_positive_cases[1:]
96
+ ],
97
+ how="horizontal",
98
+ ).collect(),
79
99
  )
80
100
 
81
101
 
File without changes
File without changes
File without changes
File without changes
File without changes