title: Filter for instances of classes in python
body: <p>I'm making a plugin manager in python. My plan is to append all of my possible plugins (which could consist of classes, functions, and instances of classes) to a single list and then use custom filter functions to get out the appropriate objects. </p>
  
  <p>How do you get all class instances out of a list? The class instances can be of any class.</p>
  
  <p>example:</p>
  
  <pre><code>class A:
      pass
  
  def func():
      pass
  
  instance_a = A()
  
  plugins = [func, A, instance_a]
  </code></pre>
  
  <p>Now how do I get only <code>instance_a</code> out of <code>plugins</code>, assuming that I don't have a reference to the class instance <code>A</code>? Is it even possible?</p>