Commit ·
343fba1
1
Parent(s): 37dd697
upload bigbiohub.py to hub from bigbio repo
Browse files3 unmodified lines45677899101112131415147 unmodified lines1631641651651661671681693 unmodified linesimport loggingfrom pathlib import Pathfrom types import SimpleNamespacefrom typing import Dict, Iterable, List, Tuplefrom typing import TYPE_CHECKING, Dict, Iterable, List, Tuple
import biocimport datasets
if TYPE_CHECKING: import bioc
logger = logging.getLogger(__name__)
147 unmodified lines)
def get_texts_and_offsets_from_bioc_ann(ann: bioc.BioCAnnotation) -> Tuple:def get_texts_and_offsets_from_bioc_ann(ann: "bioc.BioCAnnotation") -> Tuple:
offsets = [(loc.offset, loc.offset + loc.length) for loc in ann.locations]
bigbiohub.py+4-3