"tools/print_config.py" did not exist on "219deef165d905dcc78100b9bd4485c988a01820"
  1. 09 Sep, 2024 1 commit
    • myhloli's avatar
      feat(ocr): pass language parameter for custom model init · 4b372f3f
      myhloli authored
      Pass the `lang` parameter to `custom_model_init` in `doc_analyze` to support language-specific OCR configurations. This enhancement allows the use of language information to improve OCR accuracy when processing PDFs.
      4b372f3f
  2. 03 Sep, 2024 3 commits
    • Xiaomeng Zhao's avatar
      refactor(pdf_extract_kit): implement singleton pattern for atomic models (#533) · aac91094
      Xiaomeng Zhao authored
      Refactor the pdf_extract_kit module to utilize a singleton pattern when initializing
      atomic models. This change ensures that atomic models are instantiated at most once,
      optimizing memory usage and reducing redundant initialization steps. The AtomModelSingleton
      class now manages the instantiation and retrieval of atomic models, improving the
      overall structure and efficiency of the codebase.
      aac91094
    • icecraft's avatar
      Feat/support footnote in figure (#532) · 03469909
      icecraft authored
      
      
      * feat: support figure footnote
      
      * feat: using the relative position to combine footnote, table, image
      
      * feat: add the readme of projects
      
      * fix: code spell in unittest
      
      ---------
      Co-authored-by: default avataricecraft <xurui1@pjlab.org.cn>
      03469909
    • Kaiwen Liu's avatar
      fix: resolve inaccuracy of drawing layout box caused by paragraphs combination #384 (#542) · a7e615ff
      Kaiwen Liu authored
      * fix: resolve inaccuracy of drawing layout box caused by paragraphs combination
      
      * fix: resolve inaccuracy of drawing layout box caused by paragraphs combination #384
      
      * fix: resolve inaccuracy of drawing layout box caused by paragraphs combination #384
      
      * fix: resolve inaccuracy of drawing layout box caused by paragraphs combination #384
      a7e615ff
  3. 02 Sep, 2024 4 commits
  4. 30 Aug, 2024 2 commits
    • icecraft's avatar
      Feat/support rag (#510) · b72d4ebd
      icecraft authored
      
      
      * Create requirements-docker.txt
      
      * feat: update deps to support rag
      
      * feat: add support to rag, add rag_data_reader api for rag integration
      
      * feat: let user retrieve the filename of the processed file
      
      * feat: add projects demo for rag integrations
      
      ---------
      Co-authored-by: default avatarXiaomeng Zhao <moe@myhloli.com>
      Co-authored-by: default avataricecraft <xurui1@pjlab.org.cn>
      b72d4ebd
    • Xiaomeng Zhao's avatar
      feat(cli&analyze&pipeline): add start_page and end_page args for pagination (#507) · 0f91fcf6
      Xiaomeng Zhao authored
      * feat(cli&analyze&pipeline): add start_page and end_page args for paginationAdd start_page_id and end_page_id arguments to various components of the PDF parsing
      pipeline to support pagination functionality. This feature allows users to specify the
      range of pages to be processed, enhancing the efficiency and flexibility of the system.
      
      * feat(cli&analyze&pipeline): add start_page and end_page args for paginationAdd start_page_id and end_page_id arguments to various components of the PDF parsing
      pipeline to support pagination functionality. This feature allows users to specify the
      range of pages to be processed, enhancing the efficiency and flexibility of the system.
      
      * feat(cli&analyze&pipeline): add start_page and end_page args for paginationAdd start_page_id and end_page_id arguments to various components of the PDF parsing
      pipeline to support pagination functionality. This feature allows users to specify the
      range of pages to be processed, enhancing the efficiency and flexibility of the system.
      0f91fcf6
  5. 28 Aug, 2024 3 commits
  6. 20 Aug, 2024 6 commits
    • Xiaomeng Zhao's avatar
      fix(ocr_mkcontent): revise table caption output (#397) · dd19f59e
      Xiaomeng Zhao authored
      
      
      * fix(ocr_mkcontent): revise table caption output
      
      - Ensuring that
        table captions are properly included in the output.
      - Remove the redundant `table_caption` variable。
      
      * Update cla.yml
      
      * Update bug_report.yml
      
      * feat(cli): add debug option for detailed error handling
      
      Enable users to invoke the CLI command with a new debug flag to get detailed debugging information.
      
      * fix(pdf-extract-kit): adjust crop_paste parameters for better accuracyThe crop_paste_x and crop_paste_y values in the pdf_extract_kit.py have been modified
      to improve the accuracy and consistency of OCR processing. The new values are set to 25
      to ensure more precise image cropping and pasting which leads to better OCR recognition
      results.
      
      * Update README_zh-CN.md (#404)
      
      correct FAQ url
      
      * Update README_zh-CN.md (#404) (#409) (#410)
      
      correct FAQ url
      Co-authored-by: default avatarsfk <18810651050@163.com>
      
      * Update FAQ_zh_cn.md
      
      add new issue
      
      * Update FAQ_en_us.md
      
      * Update README_Windows_CUDA_Acceleration_zh_CN.md
      
      * Update README_zh-CN.md
      
      * @Thepathakarpit has signed the CLA in opendatalab/MinerU#418
      
      * fix(pdf-extract-kit): increase crop_paste margin for OCR processingDouble the crop_paste margin from25 to 50 to ensure better OCR accuracy and
      handling of border cases. This change will help in improving the overall quality of
      OCR'ed text by providing more context around the detected text areas.
      
      * fix(common): deep copy model list before drawing model bbox
      
      Use a deep copy of the original model list in `drow_model_bbox` to avoid potential
      modifications to the source data. This ensures the integrity of the original models
      is maintained while generating the model bounding boxes visualization.
      
      ---------
      Co-authored-by: default avatarsfk <18810651050@163.com>
      Co-authored-by: default avatardrunkpig <60862764+drunkpig@users.noreply.github.com>
      Co-authored-by: default avatargithub-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
      dd19f59e
    • Kaiwen Liu's avatar
    • icecraft's avatar
      feat: rename the file generated by command line tools (#401) · c9a51491
      icecraft authored
      
      
      * feat: rename the file generated by command line tools
      
      * feat: add pdf filename as prefix to {span,layout,model}.pdf
      
      ---------
      Co-authored-by: default avataricecraft <tmortred@gmail.com>
      Co-authored-by: default avataricecraft <xurui1@pjlab.org.cn>
      c9a51491
    • Xiaomeng Zhao's avatar
      fix(pdf-extract): adjust box threshold for OCR detection (#447) · 041b9465
      Xiaomeng Zhao authored
      Tuned the detection box threshold parameter in the OCR model initialization to improve the
      accuracy of text extraction from images. The threshold was modified from 0.6 to
      0.3 to filter out smaller detection boxes, which is expected to enhance the quality of the extracted
      text by reducing noise and false positives in the OCR process.
      041b9465
    • Xiaomeng Zhao's avatar
      fix(self_modify): merge detection boxes for optimized text region detection (#448) · 3da5c411
      Xiaomeng Zhao authored
      Merge adjacent and overlapping detection boxes to optimize text region detection in
      the document. Post processing of text boxes is enhanced by consolidating them into
      larger text lines, taking into account their vertical and horizontal alignment. This
      improvement reduces fragmentation and improves the readability of detected text blocks.
      3da5c411
    • Xiaomeng Zhao's avatar
      fix(ocr_mkcontent): improve language detection and content formatting (#458) · 66e3ce9c
      Xiaomeng Zhao authored
      Optimize the language detection logic to enhance content formatting.  This
      change addresses issues with long word segmentation. Language detection now uses a
      threshold to determine the language of a text based on the proportion of English characters.
      Formatting rules for content have been updated to consider a list of languages (initially
      including Chinese, Japanese, and Korean) where no space is added between content segments
      for inline equations and text spans, improving the handling of Asian languages.
      
      The impact of these changes includes improved accuracy in language detection, better
      segmentation of long words, and more appropriate spacing in content formatting for multiple
      languages.
      66e3ce9c
  7. 09 Aug, 2024 6 commits
  8. 07 Aug, 2024 2 commits
  9. 06 Aug, 2024 1 commit
  10. 05 Aug, 2024 2 commits
  11. 04 Aug, 2024 3 commits
  12. 02 Aug, 2024 3 commits
    • xuchao's avatar
      delete old magic-pdf cli · 8d88330d
      xuchao authored
      8d88330d
    • xuchao's avatar
    • Kaiwen Liu's avatar
      feat(model inference): add table recognition and conversion to LaTeX (#284) · 37925f36
      Kaiwen Liu authored
      * # add table recognition using struct-eqtable
      ## Changelog
      31/07/20204
      - Support table recognition. Table images will be converted into html.
      
      ### how to use the new feature:
      set the attribute 'table-mode' to 'true' in magic-pdf.json
      
      ### caution:
      it takes 200s to 500s to convert a single table image using cpu
      
      * # add table recognition using struct-eqtable
      ## Changelog
      31/07/20204
      - Support table recognition. Table images will be converted into LaTex.
      
      ### how to use the new feature:
      set the attribute 'table-mode' to 'true' in magic-pdf.json
      
      ### caution:
      it takes 200s to 500s to convert a single table image using cpu
      
      * # feat(model inference): add table recognition and convertion to LaTeX
      
      # What's Changed
      
      ### New Features
      
      - Add table content recognition, we use weights of [StructEqTable](https://github.com/UniModal4Reasoning/StructEqTable-Deploy) to convert table image to LaTex.
      
      ### Instruction
      
      - pip install pypandoc struct-eqtable==0.1.0
      - Download [StructEqTable weights](https://huggingface.co/wanderkid/PDF-Extract-Kit/tree/main/models/TabRec
      
      ) and put it under models/ directory.
      - Edit 'table-mode' value to turn on table recognition function which is turned off by default.
      - If you did not download any models before, refer to [how to download models](docs/how_to_download_models_zh_cn.md)。
      
      * add table recognition and convertion to LaTeX
      
      * add table recognition and conversion to LaTeX
      
      * add table recognition and conversion to LaTeX
      
      * add table recognition and conversion to LaTeX
      
      ---------
      Co-authored-by: default avatarliukaiwen <liukaiwen@pjlab.org.cn>
      37925f36
  13. 01 Aug, 2024 4 commits