code: def linear_forgetting_weights(N, LF):
      assert N >= 0
      assert LF > 0
      if N == 0:
          return np.asarray([])
      elif N < LF:
          return np.ones(N)
      else:
          ramp = np.linspace(old_div(1.0, N), 1.0, num=N - LF)
          flat = np.ones(LF)
          weights = np.concatenate([ramp, flat], axis=0)
          assert weights.shape == (N,), (weights.shape, N)
          return weights
  
imports: from __future__ import print_function
  from __future__ import absolute_import
  from __future__ import division
  from builtins import str
  from builtins import map
  from builtins import zip
  from builtins import range
  from past.utils import old_div
  import logging
  import time
  import numpy
  from scipy.special import erf
  from .None import pyll
  from .pyll import scope
  from .pyll.stochastic import implicit_stochastic
  from .base import miscs_to_idxs_vals
  from .base import miscs_update_idxs_vals
  from .None import rand
label_desc: Use image node_id 13 for calling a global function with example usage: linear_forgetting_weights(N, LF) and returns: np, np, weights