code: def gen_mask(ratio, shape):
      return numpy.random.rand(*shape) >= ratio
  
imports: import os
  import tempfile
  import unittest
  import numpy
  import chainer
  from chainer.backends import cuda
  from chainer import gradient_check
  from chainer import links
  from chainer.serializers import npz
  from chainer import testing
  from chainer.testing import attr
  from chainer.utils import type_check
label_desc: Use image node_id 1 for calling a global function with example usage: gen_mask(ratio, shape) and returns: unknown