the Python code with which I am trying to achieve this result is:
df[\'column2\'] = np.where(df[\'column1\'] == 0, 1, df[\'column1\'])
Thanks in