Utilities for health informatics
Project description
HIUTILS
A collection of utilities for health informatics
This is pre-alpha, anything might change, i.e. not ready for production use.
Application areas
Text annotation / NLP
Ontologies
Knowledge graphs
Statistics / summary data
Installation
pip install hiutils
Annotations
Overview
We assume that annotations are in the format:
{
document_id: {
entities: {
entitiy_id: {
...properties...,
cui : "concept_id",
meta_anns: {
'meta_ann_name': {'value': 'meta_ann_value',
'confidence': confidence,
'name': 'meta_ann_name'},
...other meta...
}
}
}
}
}
Basic process
The aim is to:
- keep only some annotations based on context
- convert from document->concepts to patient->concepts
- limit to a subset of concepts relevant to our project
- group some specific concepts into more general concepts e.g. specific subtypes of a disease -> any occurence of a that disease
To achieve these aims:
- 1 filter by meta_anns:
filtered = hi.annotations.filter_anns_meta(anns, {'Subject': ['Other']}, inplace=False)
- 2 aggregate to patient level
agg = hi.annotations.aggregate_docs(filtered, item2doc=pt2doc)
- 3+4 group relevant concepts and drop other concepts
groups = {'Group 1': set(['286933003', '70582006']), 'My other group': set(['60046008'])}
merged = hi.merge_concepts(agg, groups, keep_empty=False)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
hiutils-0.2.2.tar.gz
(6.0 kB
view details)
Built Distribution
File details
Details for the file hiutils-0.2.2.tar.gz
.
File metadata
- Download URL: hiutils-0.2.2.tar.gz
- Upload date:
- Size: 6.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e39e6bffe4cc8d40f9465e38a12126f14bb268075bd44a4ba396630cfac8da14 |
|
MD5 | 46d4fb33763c713bb7c477258c7369e1 |
|
BLAKE2b-256 | 55a746cb3f99108700384bdc711c7b8ffd1fba572e66c31f9fdaa4ec530fafa5 |
File details
Details for the file hiutils-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: hiutils-0.2.2-py3-none-any.whl
- Upload date:
- Size: 8.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 84600b54a384160936172c08502e68ef845123db23adef18b5ac72f4d5afc63b |
|
MD5 | f11b81190c8900990e8150b6aeb2a3f8 |
|
BLAKE2b-256 | 742706226315c7a939c978e9336de8b32b0c9e19b188646caae7e1481e67cfe7 |