How to Determine if Relay Module Runs on VTA or CPU

'm working on a project where I need to get the intermediate buffers between layers in a graph module. Specifically, I’m trying to achieve something similar to TVM’s get_calibration_data (view-tvm.apache.org/docs/reference/api/python/relay/analysis.html#tvm.relay.analysis.get_calibration_data), but I need this for a specific function rather than between sub-graphs.

Does anyone have any ideas or suggestions on how I can determine if a relay module is running on VTA or CPU, and how I can extract these intermediate buffers?

Thanks in advance for your help!