Skip to content
New issue

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

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

Already on GitHub? # to your account

LABEL IMAGE script gives low time elapsed without ngraph bridge compared to with ngraph bridge implementation #803

Open
nishitchaudhry opened this issue Mar 19, 2021 · 0 comments

Comments

@nishitchaudhry
Copy link

I tried using script of image label classification from examples folder where I tried to compare two scripts one with ngraph bridge configuration and other without it, I found that when I calculate time elapsed using the code mentioned below,

config = tf.compat.v1.ConfigProto()
config_ngraph_enabled = ngraph_bridge.update_config(config)

with tf.compat.v1.Session(graph=graph, config=config_ngraph_enabled) as sess:
# Warmup
sess.run(output_operation.outputs[0], {
input_operation.outputs[0]: t})
# Run
import time
start = time.time()
results = sess.run(output_operation.outputs[0], {
input_operation.outputs[0]: t
})
elapsed = time.time() - start
print('Time elapsed: %f seconds' % elapsed)
results = np.squeeze(results)

I observe that the script without this above ngraph config implementation has faster time elapsed than the script with above ngraph config implementation.

Can anyone please guide me where I am going wrong?

Ideally the script with ngraph should have lesser computation time than the script without ngraph!!

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

No branches or pull requests

1 participant