imb 1.0.0__tar.gz → 1.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- imb-1.0.1/PKG-INFO +105 -0
- imb-1.0.1/README.md +70 -0
- imb-1.0.1/imb/__init__.py +0 -0
- imb-1.0.1/imb.egg-info/PKG-INFO +105 -0
- {imb-1.0.0 → imb-1.0.1}/imb.egg-info/SOURCES.txt +4 -5
- imb-1.0.1/imb.egg-info/requires.txt +15 -0
- {imb-1.0.0 → imb-1.0.1}/setup.py +8 -1
- imb-1.0.0/PKG-INFO +0 -30
- imb-1.0.0/README.md +0 -4
- imb-1.0.0/imb/__init__.py +0 -1
- imb-1.0.0/imb/inference_clients/__init__.py +0 -2
- imb-1.0.0/imb.egg-info/PKG-INFO +0 -30
- imb-1.0.0/imb.egg-info/requires.txt +0 -3
- {imb-1.0.0 → imb-1.0.1}/LICENSE +0 -0
- {imb-1.0.0/imb/inference_clients → imb-1.0.1/imb}/base.py +0 -0
- {imb-1.0.0/imb/inference_clients → imb-1.0.1/imb}/onnx.py +0 -0
- {imb-1.0.0/imb/inference_clients → imb-1.0.1/imb}/triton.py +0 -0
- {imb-1.0.0 → imb-1.0.1}/imb.egg-info/dependency_links.txt +0 -0
- {imb-1.0.0 → imb-1.0.1}/imb.egg-info/top_level.txt +0 -0
- {imb-1.0.0 → imb-1.0.1}/setup.cfg +0 -0
imb-1.0.1/PKG-INFO
ADDED
@@ -0,0 +1,105 @@
|
|
1
|
+
Metadata-Version: 2.2
|
2
|
+
Name: imb
|
3
|
+
Version: 1.0.1
|
4
|
+
Summary: Python library for run inference of deep learning models in different backends
|
5
|
+
Home-page: https://github.com/TheConstant3/InferenceMultiBackend
|
6
|
+
Author: p-constant
|
7
|
+
Author-email: nikshorop@gmail.com
|
8
|
+
Classifier: Programming Language :: Python :: 3.8
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
10
|
+
Classifier: Operating System :: OS Independent
|
11
|
+
Requires-Python: >=3.8
|
12
|
+
Description-Content-Type: text/markdown
|
13
|
+
License-File: LICENSE
|
14
|
+
Requires-Dist: numpy
|
15
|
+
Provides-Extra: triton
|
16
|
+
Requires-Dist: tritonclient[all]>=2.38.0; extra == "triton"
|
17
|
+
Provides-Extra: onnxcpu
|
18
|
+
Requires-Dist: onnxruntime>=1.16.0; extra == "onnxcpu"
|
19
|
+
Provides-Extra: onnxgpu
|
20
|
+
Requires-Dist: onnxruntime-gpu>=1.16.0; extra == "onnxgpu"
|
21
|
+
Provides-Extra: all
|
22
|
+
Requires-Dist: tritonclient[all]>=2.38.0; extra == "all"
|
23
|
+
Requires-Dist: onnxruntime>=1.16.0; extra == "all"
|
24
|
+
Requires-Dist: onnxruntime-gpu>=1.16.0; extra == "all"
|
25
|
+
Dynamic: author
|
26
|
+
Dynamic: author-email
|
27
|
+
Dynamic: classifier
|
28
|
+
Dynamic: description
|
29
|
+
Dynamic: description-content-type
|
30
|
+
Dynamic: home-page
|
31
|
+
Dynamic: provides-extra
|
32
|
+
Dynamic: requires-dist
|
33
|
+
Dynamic: requires-python
|
34
|
+
Dynamic: summary
|
35
|
+
|
36
|
+
# InferenceMultiBackend
|
37
|
+
|
38
|
+
Python library for run inference of deep learning models in different backends
|
39
|
+
|
40
|
+
## Installation
|
41
|
+
|
42
|
+
For use triton inference client:
|
43
|
+
```pip install imb[triton]```
|
44
|
+
|
45
|
+
For use onnxruntime-gpu client:
|
46
|
+
```pip install imb[onnxgpu]```
|
47
|
+
|
48
|
+
For use onnxruntime client:
|
49
|
+
```pip install imb[onnxcpu]```
|
50
|
+
|
51
|
+
For support all implemented clients:
|
52
|
+
```pip install imb[all]```
|
53
|
+
|
54
|
+
## Usage
|
55
|
+
|
56
|
+
OnnxClient usage example
|
57
|
+
```
|
58
|
+
onnx_client = OnnxClient(
|
59
|
+
model_path='model.onnx',
|
60
|
+
model_name='any name',
|
61
|
+
providers=['CUDAExecutionProvider', 'CPUExecutionProvider'],
|
62
|
+
max_batch_size=16,
|
63
|
+
return_dict=True,
|
64
|
+
fixed_batch=True,
|
65
|
+
warmup=True
|
66
|
+
)
|
67
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
68
|
+
sample_inputs = onnx_client.sample_inputs
|
69
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
70
|
+
outputs = onnx_client(*sample_inputs)
|
71
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
72
|
+
```
|
73
|
+
|
74
|
+
TritonClient usage example
|
75
|
+
```
|
76
|
+
triton_client = TritonClient(
|
77
|
+
url='localhost:8000',
|
78
|
+
model_name='arcface',
|
79
|
+
max_batch_size=16,
|
80
|
+
timeout=10,
|
81
|
+
resend_count=10,
|
82
|
+
fixed_batch=True,
|
83
|
+
is_async=False,
|
84
|
+
cuda_shm=False,
|
85
|
+
max_shm_regions=2,
|
86
|
+
scheme='http',
|
87
|
+
return_dict=True,
|
88
|
+
warmup=False
|
89
|
+
)
|
90
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
91
|
+
sample_inputs = triton_client.sample_inputs
|
92
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
93
|
+
outputs = triton_client(*sample_inputs)
|
94
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
95
|
+
```
|
96
|
+
|
97
|
+
## Notes
|
98
|
+
|
99
|
+
max_batch_size - maximum batch size for inference. If input data larger that max_batch_size, then input data will be splitted to several batches.
|
100
|
+
|
101
|
+
fixed_batch - if fixed batch is True, then each batch will have fixed size (padding the smallest batch to max_batch_size).
|
102
|
+
|
103
|
+
warmup - if True, model will run several calls on sample_inputs while initialization.
|
104
|
+
|
105
|
+
return_dict - if True, __call__ return dict {'output_name1': output_value1, ...}, else [output_value1, ...]
|
imb-1.0.1/README.md
ADDED
@@ -0,0 +1,70 @@
|
|
1
|
+
# InferenceMultiBackend
|
2
|
+
|
3
|
+
Python library for run inference of deep learning models in different backends
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
For use triton inference client:
|
8
|
+
```pip install imb[triton]```
|
9
|
+
|
10
|
+
For use onnxruntime-gpu client:
|
11
|
+
```pip install imb[onnxgpu]```
|
12
|
+
|
13
|
+
For use onnxruntime client:
|
14
|
+
```pip install imb[onnxcpu]```
|
15
|
+
|
16
|
+
For support all implemented clients:
|
17
|
+
```pip install imb[all]```
|
18
|
+
|
19
|
+
## Usage
|
20
|
+
|
21
|
+
OnnxClient usage example
|
22
|
+
```
|
23
|
+
onnx_client = OnnxClient(
|
24
|
+
model_path='model.onnx',
|
25
|
+
model_name='any name',
|
26
|
+
providers=['CUDAExecutionProvider', 'CPUExecutionProvider'],
|
27
|
+
max_batch_size=16,
|
28
|
+
return_dict=True,
|
29
|
+
fixed_batch=True,
|
30
|
+
warmup=True
|
31
|
+
)
|
32
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
33
|
+
sample_inputs = onnx_client.sample_inputs
|
34
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
35
|
+
outputs = onnx_client(*sample_inputs)
|
36
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
37
|
+
```
|
38
|
+
|
39
|
+
TritonClient usage example
|
40
|
+
```
|
41
|
+
triton_client = TritonClient(
|
42
|
+
url='localhost:8000',
|
43
|
+
model_name='arcface',
|
44
|
+
max_batch_size=16,
|
45
|
+
timeout=10,
|
46
|
+
resend_count=10,
|
47
|
+
fixed_batch=True,
|
48
|
+
is_async=False,
|
49
|
+
cuda_shm=False,
|
50
|
+
max_shm_regions=2,
|
51
|
+
scheme='http',
|
52
|
+
return_dict=True,
|
53
|
+
warmup=False
|
54
|
+
)
|
55
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
56
|
+
sample_inputs = triton_client.sample_inputs
|
57
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
58
|
+
outputs = triton_client(*sample_inputs)
|
59
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
60
|
+
```
|
61
|
+
|
62
|
+
## Notes
|
63
|
+
|
64
|
+
max_batch_size - maximum batch size for inference. If input data larger that max_batch_size, then input data will be splitted to several batches.
|
65
|
+
|
66
|
+
fixed_batch - if fixed batch is True, then each batch will have fixed size (padding the smallest batch to max_batch_size).
|
67
|
+
|
68
|
+
warmup - if True, model will run several calls on sample_inputs while initialization.
|
69
|
+
|
70
|
+
return_dict - if True, __call__ return dict {'output_name1': output_value1, ...}, else [output_value1, ...]
|
File without changes
|
@@ -0,0 +1,105 @@
|
|
1
|
+
Metadata-Version: 2.2
|
2
|
+
Name: imb
|
3
|
+
Version: 1.0.1
|
4
|
+
Summary: Python library for run inference of deep learning models in different backends
|
5
|
+
Home-page: https://github.com/TheConstant3/InferenceMultiBackend
|
6
|
+
Author: p-constant
|
7
|
+
Author-email: nikshorop@gmail.com
|
8
|
+
Classifier: Programming Language :: Python :: 3.8
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
10
|
+
Classifier: Operating System :: OS Independent
|
11
|
+
Requires-Python: >=3.8
|
12
|
+
Description-Content-Type: text/markdown
|
13
|
+
License-File: LICENSE
|
14
|
+
Requires-Dist: numpy
|
15
|
+
Provides-Extra: triton
|
16
|
+
Requires-Dist: tritonclient[all]>=2.38.0; extra == "triton"
|
17
|
+
Provides-Extra: onnxcpu
|
18
|
+
Requires-Dist: onnxruntime>=1.16.0; extra == "onnxcpu"
|
19
|
+
Provides-Extra: onnxgpu
|
20
|
+
Requires-Dist: onnxruntime-gpu>=1.16.0; extra == "onnxgpu"
|
21
|
+
Provides-Extra: all
|
22
|
+
Requires-Dist: tritonclient[all]>=2.38.0; extra == "all"
|
23
|
+
Requires-Dist: onnxruntime>=1.16.0; extra == "all"
|
24
|
+
Requires-Dist: onnxruntime-gpu>=1.16.0; extra == "all"
|
25
|
+
Dynamic: author
|
26
|
+
Dynamic: author-email
|
27
|
+
Dynamic: classifier
|
28
|
+
Dynamic: description
|
29
|
+
Dynamic: description-content-type
|
30
|
+
Dynamic: home-page
|
31
|
+
Dynamic: provides-extra
|
32
|
+
Dynamic: requires-dist
|
33
|
+
Dynamic: requires-python
|
34
|
+
Dynamic: summary
|
35
|
+
|
36
|
+
# InferenceMultiBackend
|
37
|
+
|
38
|
+
Python library for run inference of deep learning models in different backends
|
39
|
+
|
40
|
+
## Installation
|
41
|
+
|
42
|
+
For use triton inference client:
|
43
|
+
```pip install imb[triton]```
|
44
|
+
|
45
|
+
For use onnxruntime-gpu client:
|
46
|
+
```pip install imb[onnxgpu]```
|
47
|
+
|
48
|
+
For use onnxruntime client:
|
49
|
+
```pip install imb[onnxcpu]```
|
50
|
+
|
51
|
+
For support all implemented clients:
|
52
|
+
```pip install imb[all]```
|
53
|
+
|
54
|
+
## Usage
|
55
|
+
|
56
|
+
OnnxClient usage example
|
57
|
+
```
|
58
|
+
onnx_client = OnnxClient(
|
59
|
+
model_path='model.onnx',
|
60
|
+
model_name='any name',
|
61
|
+
providers=['CUDAExecutionProvider', 'CPUExecutionProvider'],
|
62
|
+
max_batch_size=16,
|
63
|
+
return_dict=True,
|
64
|
+
fixed_batch=True,
|
65
|
+
warmup=True
|
66
|
+
)
|
67
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
68
|
+
sample_inputs = onnx_client.sample_inputs
|
69
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
70
|
+
outputs = onnx_client(*sample_inputs)
|
71
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
72
|
+
```
|
73
|
+
|
74
|
+
TritonClient usage example
|
75
|
+
```
|
76
|
+
triton_client = TritonClient(
|
77
|
+
url='localhost:8000',
|
78
|
+
model_name='arcface',
|
79
|
+
max_batch_size=16,
|
80
|
+
timeout=10,
|
81
|
+
resend_count=10,
|
82
|
+
fixed_batch=True,
|
83
|
+
is_async=False,
|
84
|
+
cuda_shm=False,
|
85
|
+
max_shm_regions=2,
|
86
|
+
scheme='http',
|
87
|
+
return_dict=True,
|
88
|
+
warmup=False
|
89
|
+
)
|
90
|
+
# if model has fixed input size (except batch size) then sample_inputs will be created
|
91
|
+
sample_inputs = triton_client.sample_inputs
|
92
|
+
print('inputs shapes', [o.shape for o in sample_inputs])
|
93
|
+
outputs = triton_client(*sample_inputs)
|
94
|
+
print('outputs shapes', [(o_name, o_value.shape) for o_name, o_value in outputs.items()])
|
95
|
+
```
|
96
|
+
|
97
|
+
## Notes
|
98
|
+
|
99
|
+
max_batch_size - maximum batch size for inference. If input data larger that max_batch_size, then input data will be splitted to several batches.
|
100
|
+
|
101
|
+
fixed_batch - if fixed batch is True, then each batch will have fixed size (padding the smallest batch to max_batch_size).
|
102
|
+
|
103
|
+
warmup - if True, model will run several calls on sample_inputs while initialization.
|
104
|
+
|
105
|
+
return_dict - if True, __call__ return dict {'output_name1': output_value1, ...}, else [output_value1, ...]
|
@@ -3,12 +3,11 @@ README.md
|
|
3
3
|
setup.cfg
|
4
4
|
setup.py
|
5
5
|
imb/__init__.py
|
6
|
+
imb/base.py
|
7
|
+
imb/onnx.py
|
8
|
+
imb/triton.py
|
6
9
|
imb.egg-info/PKG-INFO
|
7
10
|
imb.egg-info/SOURCES.txt
|
8
11
|
imb.egg-info/dependency_links.txt
|
9
12
|
imb.egg-info/requires.txt
|
10
|
-
imb.egg-info/top_level.txt
|
11
|
-
imb/inference_clients/__init__.py
|
12
|
-
imb/inference_clients/base.py
|
13
|
-
imb/inference_clients/onnx.py
|
14
|
-
imb/inference_clients/triton.py
|
13
|
+
imb.egg-info/top_level.txt
|
{imb-1.0.0 → imb-1.0.1}/setup.py
RENAMED
@@ -1,4 +1,5 @@
|
|
1
1
|
from setuptools import setup, find_packages
|
2
|
+
from itertools import chain
|
2
3
|
import os
|
3
4
|
|
4
5
|
|
@@ -11,9 +12,14 @@ def readme():
|
|
11
12
|
with open('README.md', 'r') as f:
|
12
13
|
return f.read()
|
13
14
|
|
15
|
+
extras = ['triton', 'onnxcpu', 'onnxgpu']
|
16
|
+
extras_require = {extra: req_file(f"requirements_{extra}.txt") for extra in extras}
|
17
|
+
extras_require["all"] = list(chain(extras_require.values()))
|
18
|
+
|
19
|
+
|
14
20
|
setup(
|
15
21
|
name='imb',
|
16
|
-
version='1.0.
|
22
|
+
version='1.0.1',
|
17
23
|
author='p-constant',
|
18
24
|
author_email='nikshorop@gmail.com',
|
19
25
|
description='Python library for run inference of deep learning models in different backends',
|
@@ -22,6 +28,7 @@ setup(
|
|
22
28
|
url='https://github.com/TheConstant3/InferenceMultiBackend',
|
23
29
|
packages=find_packages(),
|
24
30
|
install_requires=req_file(),
|
31
|
+
extras_require=extras_require,
|
25
32
|
classifiers=[
|
26
33
|
"Programming Language :: Python :: 3.8",
|
27
34
|
"License :: OSI Approved :: MIT License",
|
imb-1.0.0/PKG-INFO
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.2
|
2
|
-
Name: imb
|
3
|
-
Version: 1.0.0
|
4
|
-
Summary: Python library for run inference of deep learning models in different backends
|
5
|
-
Home-page: https://github.com/TheConstant3/InferenceMultiBackend
|
6
|
-
Author: p-constant
|
7
|
-
Author-email: nikshorop@gmail.com
|
8
|
-
Classifier: Programming Language :: Python :: 3.8
|
9
|
-
Classifier: License :: OSI Approved :: MIT License
|
10
|
-
Classifier: Operating System :: OS Independent
|
11
|
-
Requires-Python: >=3.8
|
12
|
-
Description-Content-Type: text/markdown
|
13
|
-
License-File: LICENSE
|
14
|
-
Requires-Dist: onnxruntime-gpu>=1.16.0
|
15
|
-
Requires-Dist: tritonclient[all]>=2.38.0
|
16
|
-
Requires-Dist: numpy>=1.19.4
|
17
|
-
Dynamic: author
|
18
|
-
Dynamic: author-email
|
19
|
-
Dynamic: classifier
|
20
|
-
Dynamic: description
|
21
|
-
Dynamic: description-content-type
|
22
|
-
Dynamic: home-page
|
23
|
-
Dynamic: requires-dist
|
24
|
-
Dynamic: requires-python
|
25
|
-
Dynamic: summary
|
26
|
-
|
27
|
-
# InferenceMultiBackend
|
28
|
-
|
29
|
-
Python library for run inference of deep learning models in different backends
|
30
|
-
|
imb-1.0.0/README.md
DELETED
imb-1.0.0/imb/__init__.py
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
from .inference_clients import OnnxClient, TritonClient
|
imb-1.0.0/imb.egg-info/PKG-INFO
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.2
|
2
|
-
Name: imb
|
3
|
-
Version: 1.0.0
|
4
|
-
Summary: Python library for run inference of deep learning models in different backends
|
5
|
-
Home-page: https://github.com/TheConstant3/InferenceMultiBackend
|
6
|
-
Author: p-constant
|
7
|
-
Author-email: nikshorop@gmail.com
|
8
|
-
Classifier: Programming Language :: Python :: 3.8
|
9
|
-
Classifier: License :: OSI Approved :: MIT License
|
10
|
-
Classifier: Operating System :: OS Independent
|
11
|
-
Requires-Python: >=3.8
|
12
|
-
Description-Content-Type: text/markdown
|
13
|
-
License-File: LICENSE
|
14
|
-
Requires-Dist: onnxruntime-gpu>=1.16.0
|
15
|
-
Requires-Dist: tritonclient[all]>=2.38.0
|
16
|
-
Requires-Dist: numpy>=1.19.4
|
17
|
-
Dynamic: author
|
18
|
-
Dynamic: author-email
|
19
|
-
Dynamic: classifier
|
20
|
-
Dynamic: description
|
21
|
-
Dynamic: description-content-type
|
22
|
-
Dynamic: home-page
|
23
|
-
Dynamic: requires-dist
|
24
|
-
Dynamic: requires-python
|
25
|
-
Dynamic: summary
|
26
|
-
|
27
|
-
# InferenceMultiBackend
|
28
|
-
|
29
|
-
Python library for run inference of deep learning models in different backends
|
30
|
-
|
{imb-1.0.0 → imb-1.0.1}/LICENSE
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|