Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using pkgx is easier than dependency management with pip / virtualenv #22

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

sanchitram1
Copy link

  • pkgx.sh manages the dependencies like poppler and tesseract, needed to run the code
  • pkgx defers to uv to load all the python requirements
  • the shebang on top of llm_aided_ocr.py means you can just call the file directly

I also tweaked it so that you can pass the arg to the file directly, as opposed to changing the input_pdf_file_path each time. so usage would be:

./llm_aided_ocr.py <FILE_PATH>

readme reflects all of these changes. pretty cool project!

@sanchitram1
Copy link
Author

I use ruff as a linter, and it included a bunch of linting changes as well.

@Dicklesworthstone
Copy link
Owner

Dicklesworthstone commented Feb 1, 2025 via email

@sanchitram1
Copy link
Author

not improving the process itself, but just the distribution / ease of use. I wanted to add my fork to pkgx's scripting library as well, making it easier for other people to find / implement it

fwiw, I found this repo via your blogpost: The Short Case for NVIDIA…a lot of it went over my head, but wanted to get more into understanding the architecture side of things

@sanchitram1
Copy link
Author

also note that the pkgx version uses python 3.11, not 3.12. this is because of the deprecated ImpImporter in the pkgutil library in 3.12. I'm trying to figure out which requirement is specifically causing this…also known is dependency hell. for now, using 3.11 seems to do the job.

See also: https://stackoverflow.com/questions/77364550/attributeerror-module-pkgutil-has-no-attribute-impimporter-did-you-mean

@Dicklesworthstone
Copy link
Owner

Dicklesworthstone commented Feb 1, 2025 via email

@sanchitram1
Copy link
Author

Sounds good. Feel free to incorporate the pkgx if you want. I'll make it available there!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants