Repository navigation
✨ add support for split utility #380
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 all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
2179d3a
:sparkles: add support for split
sebO-S eeecd82
fix typo in import
sebO-S f95a200
fix again
sebO-S 272c66b
fix issues
sebO-S c434076
fix tests
sebO-S 56b60c2
add unit test
sebO-S 498a5af
fix forgor :skull:
sebO-S a0d6cbf
fix broken syntax for 3.8
sebO-S 1957604
fix test
sebO-S a63ea0a
rename client methods & deprecate old ones
sebO-S 7c23503
move model param logic to their own classes
sebO-S 30a6a75
add full support for split
sebO-S 6c97e7a
revise entire endpoint slug generation system & refactor input parame…
sebO-S 45af404
fix display & test
sebO-S 52a5dd6
fix name
sebO-S 1d46323
add missing name
sebO-S b704ca6
refacto into new syntax
sebO-S e6cf806
fix stupid pycharm messing with random strings
sebO-S cc128a5
preemptively upgrade split syntax to account for future server evolut…
sebO-S 6c4b6d4
fix tests
sebO-S 61ce795
update data
sebO-S c8f10b0
update syntaxes + add code sample
sebO-S 584fb83
update test syntax
sebO-S f13da05
fix CI
sebO-S 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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| from mindee import ClientV2, SplitParameters, SplitResponse, PathInput | ||
|
|
||
| input_path = "/path/to/the/file.ext" | ||
| api_key = "MY_API_KEY" | ||
| model_id = "MY_SPLIT_MODEL_ID" | ||
|
|
||
| # Init a new client | ||
| mindee_client = ClientV2(api_key) | ||
|
|
||
| # Set inference parameters | ||
| params = SplitParameters( | ||
| # ID of the model, required. | ||
| model_id=model_id, | ||
| ) | ||
|
|
||
| # Load a file from disk | ||
| input_source = PathInput(input_path) | ||
|
|
||
| # Send for processing | ||
| response = mindee_client.enqueue_and_get_result( | ||
| SplitResponse, | ||
| input_source, | ||
| params, | ||
| ) | ||
|
|
||
| # Print a brief summary of the parsed data | ||
| print(response.inference) |
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
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.
Uh oh!
There was an error while loading. Please reload this page.