title: Why would the element of the original dictionary changes when I change the one of the copy dictionary?
body: <pre><code>import numpy as np  
  
  var_np = np.zeros(shape=[2])
  
  dic_orig = {'var_np':var_np.copy(), 'var_int':0}
  
  dic_copy = dic_orig.copy()
  
  dic_copy['var_np'] += 1
  dic_copy['var_int'] += 1
  
  #problem
  print(dic_orig['var_int']) #ouput: 0  --&gt;Didn't chagne, Good！ 
  print(dic_orig['var_np']) #ouput:[1,1] --&gt;This change, Bad!
  
  #The output shows that this two have different id
  #The how would the problem happen?
  print(id(dic_orig['var_int'])) #ouput:1474134096
  print(id(dic_copy['var_int'])) #ouput:1474134128
  </code></pre>
  <p>As shown in the code demo,</p>
  <p>when the element of a dictionary are a numpy array,</p>
  <p>the element of the original dictionary would change if I chagne the copy version of this dictionary.</p>
  <p>This might causes some potential and latent bugs,</p>
  <p>and actually I don't want this happen.</p>
  <p>Why would this happen? Didn't the copy operation isolates the original and copy-verision dictionary?
  How can I solve this problem?</p>
  <p>I have google it, and seems like no one ask it before. Thank you so much for your sincerely help!</p>