MCPcopy Create free account

hub / github.com/discus0434/pdf-translator / functions

Functions383 in github.com/discus0434/pdf-translator

Method__init__
(self, scales, fourier_degree=5, num_reconstr_points=50,
utils/ocr_model/ppocr_onnx/ppocr/postprocess/fce_postprocess.py:66
Method__init__
(self, score_thresh=0.5, nms_thresh=0.2, sample_pts_num=2,
utils/ocr_model/ppocr_onnx/ppocr/postprocess/sast_postprocess.py:34
Method__init__
(self, ind)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/drrg_postprocess.py:28
Method__init__
(self, link_thr, **kwargs)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/drrg_postprocess.py:264
Method__init__
(self, layout_dict_path, strides=[8, 16, 32, 64], score_thr
utils/ocr_model/ppocr_onnx/ppocr/postprocess/picodet_postprocess.py:90
Method__init__
(self, score_thresh=0.8, cover_thresh=0.1, nms_thresh=0.2,
utils/ocr_model/ppocr_onnx/ppocr/postprocess/east_postprocess.py:31
Method__init__
(self, **kwargs)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/vqa_token_re_layoutlm_postprocess.py:18
Method__init__
(self, character_dict_path, valid_set, score_thresh,
utils/ocr_model/ppocr_onnx/ppocr/postprocess/pg_postprocess.py:33
Method__init__
(self, label_list=None, key=None, **kwargs)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/cls_postprocess.py:18
Method__init__
(self, args)
utils/ocr_model/ppocr_onnx/tools/infer/predict_rec.py:38
Method__init__
(self, args)
utils/ocr_model/ppocr_onnx/tools/infer/predict_cls.py:39
Method__init__
(self, args)
utils/ocr_model/ppocr_onnx/tools/infer/predict_det.py:38
Method__init__
(self, args)
utils/ocr_model/ppocr_onnx/tools/infer/predict_system.py:42
Method__init__
(self, model_root_dir: Path = Path("/resources/models/"))
server/main.py:58
Method_bbox_decode
(self, bbox, shape)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/table_postprocess.py:172
Method_id_to_class_names
(self)
utils/layout_model.py:79
Method_split
_split(text : string) -> [string] Override original method that only split by 'wordsep_re'. This '_split' split wide-characters into
utils/textwrap_japanese.py:99
Method_wrap_chunks
_wrap_chunks(chunks : [string]) -> [string] Original _wrap_chunks use len() to calculate width. This method respect to wide/fullwidth
utils/textwrap_japanese.py:40
Functionadd_id
Add id for gather feature, for inference.
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:196
Functionadd_profiler_step
Enable the operator-level timing using PaddlePaddle's profiler. The profiler uses a independent variable to count the profiler steps. One
utils/ocr_model/ppocr_onnx/ppocr/utils/profiler.py:82
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:123
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:170
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:251
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:341
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:474
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:505
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:613
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:701
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:751
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:781
Methodadd_special_char
(self, dict_character)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:795
Functionbase64_to_cv2
(b64str)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:479
Functioncheck_gpu
(use_gpu)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:553
Methodclear_temp_dir
API endpoint for clearing the temporary directory.
server/main.py:100
Functionconfirm_model_dir_url
(model_dir, default_model_dir, default_url)
utils/ocr_model/ppocr_onnx/ppocr/utils/network.py:74
Functioncos
(p1, p2)
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/visual.py:161
Functioncreate_predictor
(args, mode, logger)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:155
Functionctc_greedy_decoder
CTC greedy (best path) decoder.
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:79
Methoddecode
convert text-index into text-label.
utils/ocr_model/ppocr_onnx/ppocr/postprocess/rec_postprocess.py:67
Functiondraw_boxes
(image, boxes, scores=None, drop_score=0.5)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:487
Functiondraw_e2e_res
(dt_boxes, strs, img_path)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:229
Functiondraw_ocr
Visualize the results of OCR detection and recognition args: image(Image|array): RGB image boxes(list): boxes with shape(N, 4
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:263
Functiondraw_re_results
(image, result, font_path="doc/fonts/simfang.ttf",
utils/ocr_model/ppocr_onnx/ppocr/utils/visual.py:82
Functiondraw_rectangle
(img_path, boxes)
utils/ocr_model/ppocr_onnx/ppocr/utils/visual.py:118
Functiondraw_ser_results
(image, ocr_results, font_path="doc/fonts/simfang.ttf",
utils/ocr_model/ppocr_onnx/ppocr/utils/visual.py:20
Functiondraw_text_det_res
(dt_boxes, img)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:244
Functionexpand_poly_along_width
expand poly along width.
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:69
Functionextract_main_direction
f_direction: h x w x 2 pos_list: [[y, x], [y, x], [y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:426
Functiongenerate_pivot_list_tt_inference
return center point and end point of TCL instance; filter with the char maps;
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:561
Functionget_check_global_params
(mode)
utils/ocr_model/ppocr_onnx/ppocr/utils/utility.py:39
Functionget_dict
(character_dict_path)
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:27
Functionget_infer_gpuid
()
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:212
Functionget_output_tensors
(args, mode, predictor)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:194
Methodind
(self)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/drrg_postprocess.py:33
Functioninsert_blank
(labels, blank=0)
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:72
Functioninsert_blank
(labels, blank=0)
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:130
Functionintersection_iog
Intersection_iog.
utils/ocr_model/ppocr_onnx/ppocr/postprocess/locality_aware_nms.py:28
Functioniou
(a, b, mask, n_class=2, reduce=True)
utils/ocr_model/ppocr_onnx/ppocr/utils/iou.py:41
Methodlinks
(self)
utils/ocr_model/ppocr_onnx/ppocr/postprocess/drrg_postprocess.py:37
Functionload_model
load model from checkpoint or pretrained_model
utils/ocr_model/ppocr_onnx/ppocr/utils/save_load.py:47
Functionmaybe_download
(model_storage_directory, url)
utils/ocr_model/ppocr_onnx/ppocr/utils/network.py:42
Functionnms
nms.
utils/ocr_model/ppocr_onnx/ppocr/postprocess/locality_aware_nms.py:89
Functionparse_args
()
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:150
Functionpoint_pair2poly
Transfer vertical point_pairs into poly point in clockwise.
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:38
Functionpre_process
(label_list, pos_list, pos_mask, max_text_length, max_text_nums, pad_num, tcl_bs)
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_batchsize.py:54
Functionprint_dict
Recursively visualize a dict and indenting acrrording by the relationship of keys.
utils/ocr_model/ppocr_onnx/ppocr/utils/utility.py:22
Functionresize_image
resize image to a size multiple of max_stride which is required by the network :param im: the resized image :param max_side_len: limit of
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/visual.py:19
Functionresize_image_for_totaltext
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/visual.py:74
Functionresize_image_min
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/visual.py:49
Functionsave_model
save model to the target path
utils/ocr_model/ppocr_onnx/ppocr/utils/save_load.py:185
Functionset_seed
(seed=1024)
utils/ocr_model/ppocr_onnx/ppocr/utils/utility.py:126
Functionsoft_nms
soft_nms :para boxes_in, N x 9 (coords + score) :para threshould, eliminate cases min score(0.001) :para Nt_thres, iou_threshi :p
utils/ocr_model/ppocr_onnx/ppocr/postprocess/locality_aware_nms.py:106
Functionsort_and_expand_with_direction
f_direction: h x w x 2 pos_list: [[y, x], [y, x], [y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:206
Functionsort_and_expand_with_direction
f_direction: h x w x 2 pos_list: [[y, x], [y, x], [y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:228
Functionsort_by_direction_with_image_id
f_direction: h x w x 2 pos_list: [[y, x], [y, x], [y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:455
Functionsort_by_direction_with_image_id
f_direction: h x w x 2 pos_list: [[y, x], [y, x], [y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:521
Functionsort_by_direction_with_image_id_deprecated
f_direction: h x w x 2 pos_list: [[id, y, x], [id, y, x], [id, y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_fast.py:440
Functionsort_by_direction_with_image_id_deprecated
f_direction: h x w x 2 pos_list: [[id, y, x], [id, y, x], [id, y, x] ...]
utils/ocr_model/ppocr_onnx/ppocr/utils/e2e_utils/extract_textpoint_slow.py:506
Functionstandard_nms_inds
Standard nms, retun inds.
utils/ocr_model/ppocr_onnx/ppocr/postprocess/locality_aware_nms.py:72
Functionstr2bool
(v)
utils/ocr_model/ppocr_onnx/tools/infer/utility.py:27
Methodtranslate_pdf
API endpoint for translating PDF files. Parameters ---------- input_pdf: UploadFile Input PDF file Retur
server/main.py:80
Functiontranslate_request
Sends a POST request to the translator server to translate a PDF. Parameters ---------- file : Any the PDF to be translated.
gui.py:14
Methodupdate
update
utils/ocr_model/ppocr_onnx/ppocr/utils/utility.py:143
← previous301–383 of 383, ranked by callers