VST3 plugin: how to detect plugin scan/when to load large chunks of samples?

Is there any trick to determine in what context IPluginBase::initialize(FUnknown*) is running? I want to avoid loading samples data during plugin scan. What’s the recommended way to do this? Maybe on the first setActive(true) call?