Exactly like in the SubsetRandomSampler, my class also derives from Sampler and does not have a data_source.  However, I don’t think it’s common practice not to call the base classes’ initializer to avoid having to specify an argument that does nothing in the base class.
Unfortunately, I don’t understand how this is related to type inspection. Could you clarify? Thank you.