-
Couldn't load subscription status.
- Fork 13.5k
convert.py: add python logging instead of print() #6511
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
Merged
Merged
Changes from 32 commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
573dcec
convert.py: add python logging instead of print()
mofosyne 88c1e2f
convert.py: verbose flag takes priority over dump flag log suppression
mofosyne e8be0c8
convert.py: named instance logging
mofosyne 8008082
convert.py: use explicit logger id string
mofosyne e6b9d91
convert.py: convert extra print() to named logger
mofosyne 3670e16
convert.py: sys.stderr.write --> logger.error
mofosyne f00454f
*.py: Convert all python scripts to use logging module
mofosyne 9ad587a
requirements.txt: remove extra line
mofosyne c220e35
flake8: update flake8 ignore and exclude to match ci settings
mofosyne 8d855b1
gh-actions: add flake8-no-print to flake8 lint step
mofosyne dd8b977
pre-commit: add flake8-no-print to flake8 and also update pre-commit …
mofosyne 44b058d
convert-hf-to-gguf.py: print() to logger conversion
mofosyne 1cc38d8
*.py: logging basiconfig refactor to use conditional expression
mofosyne c2e5abd
*.py: removed commented out logging
mofosyne dc2bff4
fixup! *.py: logging basiconfig refactor to use conditional expression
mofosyne cf38b4b
constant.py: logger.error then exit should be a raise exception instead
mofosyne dc798d2
*.py: Convert logger error and sys.exit() into a raise exception (for…
mofosyne ea44905
gguf-convert-endian.py: refactor convert_byteorder() to use tqdm prog…
mofosyne e0372a1
verify-checksum-model.py: This is the result of the program, it shoul…
mofosyne 510dea0
compare-llama-bench.py: add blank line for readability during missing…
mofosyne 62da83a
reader.py: read_gguf_file() use print() over logging
mofosyne 1b1c2ed
convert.py: warning goes to stderr and won't hurt the dump output
mofosyne 3a55ae4
gguf-dump.py: dump_metadata() should print to stdout
mofosyne aefd749
convert-hf-to-gguf.py: print --> logger.debug or ValueError()
mofosyne 1b7c800
verify-checksum-models.py: use print() for printing table
mofosyne b0b51e7
*.py: refactor logging.basicConfig()
mofosyne fe1d7f6
gguf-py/gguf/*.py: use __name__ as logger name
mofosyne ad53853
python-lint.yml: use .flake8 file instead
mofosyne 58d5a5d
constants.py: logger no longer required
mofosyne 2d2bc99
convert-hf-to-gguf.py: add additional logging
mofosyne 5e5e74e
convert-hf-to-gguf.py: print() --> logger
mofosyne fcc5a5e
*.py: fix flake8 warnings
mofosyne 6d42f3d
revert changes to convert-hf-to-gguf.py for get_name()
mofosyne 154ad12
convert-hf-to-gguf-update.py: use triple quoted f-string instead
mofosyne 08e2b77
*.py: accidentally corrected the wrong line
mofosyne 52d0567
*.py: add compilade warning suggestions and style fixes
mofosyne File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,4 @@ | ||
| [flake8] | ||
| max-line-length = 125 | ||
| ignore = W503 | ||
| ignore = E203,E211,E221,E225,E231,E241,E251,E261,E266,E501,E701,E704,W503 | ||
| exclude = examples/*,examples/*/**,*/**/__init__.py |
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be better to use f"""-string here (then you wouldn't have to
noqaevery line either), but it might be overreaching for this PR? @ggerganov ?