Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/mindee/doctr
/ functions
Functions
871 in github.com/mindee/doctr
⨍
Functions
871
◇
Types & classes
153
↳
Endpoints
52
↓ 1 callers
Function
parse_args
()
scripts/detect_text.py:71
↓ 1 callers
Function
parse_args
()
scripts/evaluate_kie.py:181
↓ 1 callers
Function
parse_args
()
scripts/evaluate.py:188
↓ 1 callers
Function
parse_args
()
references/recognition/train.py:629
↓ 1 callers
Function
parse_args
()
references/recognition/evaluate.py:145
↓ 1 callers
Function
parse_args
()
references/detection/train.py:581
↓ 1 callers
Function
parse_args
()
references/detection/evaluate.py:156
↓ 1 callers
Function
parse_args
()
references/classification/train_orientation.py:470
↓ 1 callers
Function
parse_args
()
references/classification/train_character.py:464
↓ 1 callers
Function
plot_recorder
Display the results of the LR grid search. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py. Args:
references/recognition/utils.py:37
↓ 1 callers
Function
plot_recorder
Display the results of the LR grid search. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py Args:
references/detection/utils.py:46
↓ 1 callers
Function
plot_samples
(images, targets)
references/recognition/utils.py:12
↓ 1 callers
Function
plot_samples
(images, targets: list[dict[str, np.ndarray]])
references/detection/utils.py:12
↓ 1 callers
Function
pretty_str
(envinfo)
scripts/collect_env.py:269
↓ 1 callers
Function
read_html
Read a PDF file and convert it into an image in numpy format >>> from doctr.io import read_html >>> doc = read_html("https://www.yoursite.com
doctr/io/html.py:11
↓ 1 callers
Function
read_img_as_numpy
Read an image file into numpy format >>> from doctr.io import read_img_as_numpy >>> page = read_img_as_numpy("path/to/your/doc.jpg") Arg
doctr/io/image/base.py:16
↓ 1 callers
Function
read_pdf
Read a PDF file and convert it into an image in numpy format >>> from doctr.io import read_pdf >>> doc = read_pdf("path/to/your/doc.pdf")
doctr/io/pdf.py:16
↓ 1 callers
Function
record_lr
Gridsearch the optimal learning rate for the training. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py
references/recognition/train.py:42
↓ 1 callers
Function
record_lr
Gridsearch the optimal learning rate for the training. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py
references/detection/train.py:37
↓ 1 callers
Function
record_lr
Gridsearch the optimal learning rate for the training. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py
references/classification/train_orientation.py:51
↓ 1 callers
Function
record_lr
Gridsearch the optimal learning rate for the training. Adapted from https://github.com/frgfm/Holocron/blob/master/holocron/trainer/core.py
references/classification/train_character.py:40
↓ 1 callers
Function
rect_patch
Create a matplotlib rectangular patch for the element Args: geometry: bounding box of the element page_dimensions: dimensions of
doctr/utils/visualization.py:20
↓ 1 callers
Function
rectify_crops
Rotate each crop of the list according to the predicted orientation: 0: already straight, no rotation 1: 90 ccw, rotate 3 times ccw 2: 180
doctr/models/_utils.py:155
↓ 1 callers
Function
rectify_loc_preds
Orient the quadrangle (Polygon4P) according to the predicted orientation, so that the points are in this order: top L, top R, bot R, bot L if the
doctr/models/_utils.py:174
↓ 1 callers
Function
remap_boxes
Remaps a batch of rotated locpred (N, 4, 2) expressed for an origin_shape to a destination_shape. This does not impact the absolute shape of the b
doctr/utils/geometry.py:200
↓ 1 callers
Function
remove_image_padding
Remove black border padding from an image Args: image: numpy tensor to remove padding from Returns: Image with padding remov
doctr/utils/geometry.py:332
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:128
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:174
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:190
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:237
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:283
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:459
↓ 1 callers
Method
render
Renders the full text of the element
doctr/io/elements.py:617
↓ 1 callers
Method
reparameterize_layer
(self)
doctr/models/modules/layers/pytorch.py:187
↓ 1 callers
Function
replace_bools
(dct, true="Yes", false="No")
scripts/collect_env.py:277
↓ 1 callers
Function
replace_nones
(dct, replacement="Could not collect")
scripts/collect_env.py:270
↓ 1 callers
Function
resnet_stage
Build a ResNet stage
doctr/models/classification/resnet/pytorch.py:65
↓ 1 callers
Function
resolve_enclosing_bbox
Compute enclosing bbox either from: Args: bboxes: boxes in one of the following formats: - an array of boxes: (*, 4), where
doctr/utils/geometry.py:77
↓ 1 callers
Function
resolve_enclosing_rbbox
Compute enclosing rotated bbox either from: Args: rbboxes: boxes in one of the following formats: - an array of boxes: (*, 4
doctr/utils/geometry.py:99
↓ 1 callers
Function
rotate_boxes
Rotate a batch of straight bounding boxes (xmin, ymin, xmax, ymax, c) or rotated bounding boxes (4, 2) of an angle, if angle > min_angle, around t
doctr/utils/geometry.py:226
↓ 1 callers
Function
run_and_read_all
Runs command using run_lambda; reads and returns entire output if rc is 0
scripts/collect_env.py:82
↓ 1 callers
Function
scaled_dot_product_attention
Scaled Dot-Product Attention
doctr/models/modules/transformer/pytorch.py:46
↓ 1 callers
Function
setup
(app)
docs/source/conf.py:141
↓ 1 callers
Method
show
Display the results Args: **kwargs: additional keyword arguments to be passed to `plt.show`
doctr/contrib/artefacts.py:106
↓ 1 callers
Method
show
Overlay the result on a given image Args: interactive: whether the display should be interactive preserve_aspect_rati
doctr/io/elements.py:468
↓ 1 callers
Method
show
Overlay the result on a given image
doctr/io/elements.py:621
↓ 1 callers
Method
summary
Computes the aggregated metrics Returns: a tuple with the recall & precision for each class prediction and the mean IoU
doctr/utils/metrics.py:530
↓ 1 callers
Method
synthesize
Synthesize the page from the predictions Args: **kwargs: keyword arguments passed to the `synthesize_kie_page` method Re
doctr/io/elements.py:485
↓ 1 callers
Method
synthesize
Synthesize all pages from their predictions Args: **kwargs: keyword arguments passed to the `Page.synthesize` method Ret
doctr/io/elements.py:626
↓ 1 callers
Function
synthesize_kie_page
Draw a the content of the element page (OCR response) on a blank page. Args: page: exported Page object to represent draw_proba:
doctr/utils/reconstitution.py:174
↓ 1 callers
Function
synthesize_page
Draw a the content of the element page (OCR response) on a blank page. Args: page: exported Page object to represent draw_proba:
doctr/utils/reconstitution.py:113
↓ 1 callers
Function
visualize_kie_page
Visualize a full page with predicted blocks, lines and words >>> import numpy as np >>> import matplotlib.pyplot as plt >>> from doctr.ut
doctr/utils/visualization.py:279
↓ 1 callers
Function
wandb_log_at_step
(train_loss=None, val_loss=None, lr=None)
references/recognition/train.py:510
↓ 1 callers
Function
wandb_log_at_step
(train_loss=None, val_loss=None, lr=None)
references/detection/train.py:467
↓ 1 callers
Function
wandb_log_at_step
(train_loss=None, val_loss=None, lr=None)
references/classification/train_orientation.py:367
↓ 1 callers
Function
wandb_log_at_step
(train_loss=None, val_loss=None, lr=None)
references/classification/train_character.py:361
↓ 1 callers
Method
windows2img
Merge windowed images back to the original spatial shape. Args: img_splits_hw: A float tensor of shape (b', h_sp*w_sp, c
doctr/models/classification/vip/layers/pytorch.py:422
Method
__call__
(self, loc_preds)
tests/pytorch/test_models_zoo_pt.py:24
Method
__call__
Call the model on the given inputs Args: inputs: the inputs to use Returns: Any: the postprocessed
doctr/contrib/base.py:77
Method
__call__
(self, x: torch.Tensor)
doctr/transforms/modules/pytorch.py:233
Method
__call__
(self, x: Any, target: Any)
doctr/transforms/modules/base.py:40
Method
__call__
(self, img: Any, target: Any)
doctr/transforms/modules/base.py:66
Method
__call__
(self, img: Any)
doctr/transforms/modules/base.py:92
Method
__call__
(self, img: Any, target: np.ndarray | None = None)
doctr/transforms/modules/base.py:115
Method
__call__
(self, img: Any, target: np.ndarray | None = None)
doctr/transforms/modules/base.py:144
Method
__call__
(self, img: Any, target: np.ndarray)
doctr/transforms/modules/base.py:168
Method
__call__
(self, img: Any, target: np.ndarray)
doctr/transforms/modules/base.py:191
Method
__call__
Re-arrange detected words into structured blocks Args: pages: list of N elements, where each element represents the page image
doctr/models/builder.py:285
Method
__call__
Re-arrange detected words into structured predictions Args: pages: list of N elements, where each element represents the page ima
doctr/models/builder.py:371
Method
__call__
( self, logits: torch.Tensor, )
doctr/models/recognition/sar/pytorch.py:325
Method
__call__
( self, logits: torch.Tensor, )
doctr/models/recognition/parseq/pytorch.py:414
Method
__call__
Performs decoding of raw output with CTC and decoding of CTC predictions with label_to_idx mapping dictionary Args: logit
doctr/models/recognition/crnn/pytorch.py:83
Method
__call__
( self, logits: torch.Tensor, )
doctr/models/recognition/master/pytorch.py:263
Method
__call__
Performs decoding of raw output with CTC and decoding of CTC predictions with label_to_idx mapping dictionary Args: logit
doctr/models/recognition/viptr/pytorch.py:71
Method
__call__
( self, logits: torch.Tensor, )
doctr/models/recognition/vitstr/pytorch.py:171
Method
__call__
Performs postprocessing for a list of model outputs Args: proba_map: probability map of shape (N, H, W, C) Returns:
doctr/models/detection/core.py:67
Method
__call__
Prepare document data for model forwarding Args: x: list of images (np.array) or a single image (np.array) of shape (H, W, C)
doctr/models/preprocessor/pytorch.py:79
Method
__getitem__
(self, index: int)
doctr/datasets/datasets/base.py:48
Method
__init__
(self, patience: int = 5, min_delta: float = 0.01)
references/recognition/utils.py:77
Method
__init__
(self, patience: int = 5, min_delta: float = 0.01)
references/detection/utils.py:87
Method
__init__
(self, patience: int = 5, min_delta: float = 0.01)
references/classification/utils.py:77
Method
__init__
(self, batch_size: int, url: str | None = None, model_path: str | None = None, **kwargs)
doctr/contrib/base.py:25
Method
__init__
( self, arch: str = "yolov8_artefact", batch_size: int = 2, model_path: str |
doctr/contrib/artefacts.py:48
Method
__init__
(self)
doctr/utils/metrics.py:73
Method
__init__
( self, iou_thresh: float = 0.5, use_polygons: bool = False, )
doctr/utils/metrics.py:256
Method
__init__
( self, iou_thresh: float = 0.5, use_polygons: bool = False, )
doctr/utils/metrics.py:353
Method
__init__
( self, iou_thresh: float = 0.5, use_polygons: bool = False, )
doctr/utils/metrics.py:483
Method
__init__
(self, **kwargs: Any)
doctr/io/elements.py:38
Method
__init__
(self, artefact_type: str, confidence: float, geometry: BoundingBox)
doctr/io/elements.py:122
Method
__init__
( self, words: list[Word], geometry: BoundingBox | np.ndarray | None = None, o
doctr/io/elements.py:155
Method
__init__
( self, lines: list[Line] = [], artefacts: list[Artefact] = [], geometry: Boun
doctr/io/elements.py:214
Method
__init__
( self, page: np.ndarray, blocks: list[Block], page_idx: int, dimensio
doctr/io/elements.py:267
Method
__init__
( self, page: np.ndarray, predictions: dict[str, list[Prediction]], page_idx:
doctr/io/elements.py:443
Method
__init__
( self, pages: list[Page], )
doctr/io/elements.py:611
Method
__init__
( self, pages: list[KIEPage], )
doctr/io/elements.py:665
Method
__init__
(self, mean: float = 0.0, std: float = 1.0)
doctr/transforms/modules/pytorch.py:139
Method
__init__
(self, sigma: tuple[float, float])
doctr/transforms/modules/pytorch.py:167
Method
__init__
(self)
doctr/transforms/modules/pytorch.py:192
Method
__init__
(self, opacity_range: tuple[float, float] | None = None)
doctr/transforms/modules/pytorch.py:229
Method
__init__
( self, scale_range: tuple[float, float] = (0.3, 0.9), preserve_aspect_ratio: bool | f
doctr/transforms/modules/pytorch.py:275
← previous
next →
301–400 of 871, ranked by callers