code: def python_bitcount(n):
      """Calculate bit size of the nonnegative integer n."""
      bc = bisect(powers, n)
      if bc != 300:
          return bc
      bc = int(math.log(n, 2)) - 4
      return bc + bctable[n >> bc]
  
imports: import math
  from bisect import bisect
  from .backend import xrange
  from .backend import BACKEND, gmpy, sage, sage_utils, MPZ, MPZ_ONE, MPZ_ZERO
label_desc: Use image node_id 5 for calling a global function with example usage: python_bitcount(n) and returns: unknown, bc