This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from mypy_extensions import TypedDict | |
from typing import List | |
class RegionAnnotation(TypedDict): | |
x: int | |
y: int | |
height: int | |
width: int | |
name: str | |
class TextDict(TypedDict): | |
name: str | |
text: str | |
def render_regions_on_image(image: np.ndarray, regions: List[RegionAnnotation], texts: List[TextDict]) -> np.ndarray: | |
... | |
return image |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment