Comments (1)
Hi @lcx1874000,
As I understand, you want to create the single layer model that contain OV Convolution and run it for inference. Here is an example how to create the single layer model with Divide
operation:
import numpy as np
import openvino.runtime.opset9 as ov
from openvino.runtime import Model, Core
# create a model with TopK
x = ov.parameter([1], name="x", dtype=np.int32)
y = ov.parameter([1], name="y", dtype=np.int32)
divide = ov.divide(x, y)
model = Model([divide], [x, y], "model")
# infer it on CPU
core = Core()
compiled_model = core.compile_model(model, "CPU")
output = compiled_model.infer_new_request({0: np.array([4], dtype=np.int32), 1: np.array([-3], dtype=np.int32)})
Since you want to create with Convolution, please refer to Convolution Python documentation: https://docs.openvino.ai/2024/api/ie_python_api/_autosummary/openvino.runtime.opset14.convolution.html
Examples with convolution in test: https://github.com/openvinotoolkit/openvino/blob/master/src/bindings/python/tests/test_graph/test_convolution.py
Pay attention that we have no eager execution mode for inference.
Please elaborate your request more if I missed somenthing.
Best regards,
Roman
from openvino.
Related Issues (20)
- [Good First Issue] [ARM]: Implement CPU plugin just-in-time emitter for Greater operation
- [Bug]: Error running Inference on integrated GPU HOT 2
- [Good First Issue] [ARM]: Implement CPU plugin just-in-time emitter for LogicalNot operation HOT 6
- [Good First Issue] [ARM]: Implement CPU plugin just-in-time emitter for Sqrt operation
- [Good First Issue] [ARM]: Implement CPU plugin just-in-time emitter for GreaterEqual operation
- [Bug]: First Inference on GPU device is slow when using ov::set_batch for openvino 2024 HOT 2
- [Bug]: Mish activation function crashes openvino model benchmark on NPU
- [Bug]: GroupNormalization crashes openvino model benchmark on NPU
- Getting error in distil-whisper-asr.ipynb notebook in Quantize Distil-Whisper encoder and decoder models for GPU
- [Bug]: The inference result using CPU on MacOS M2 is abnormal, but the result using TEMPLATE device is normal HOT 10
- [Bug]: Memory leak with TBB 2020.3
- [Feature Request]: Rename inputs/outputs HOT 2
- [Bug]: NPU not detected in OpenVINO container HOT 1
- [Bug]: ov::InferRequest::infer() not thread safe when having multiple models HOT 5
- [Performance]: Latency is much longer than RealTime when using benchmark_app for profiling HOT 1
- How to use pre-allocated buffer in output ?
- Openvino Chinese Path and Interface Support HOT 11
- [Bug]: Model infers on Intel CPU, but crashes on ARM CPU (both systems using Ubuntu 22.04) HOT 6
- [Bug]: when loading model, 'Floating point exception (core dumped)‘ happended HOT 2
- [Bug]: Run OpenVINO benchmark_app with Yolo-v4-tf model Failed on NPU HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openvino.