how to create empty file in python : <p>I would like to create an empty file in Python. But I have difficulty creating one..Below is the Python code I used to create but it gives me error:</p>

<pre><code>gdsfile  = "/home/hha/temp.gds"
if not (os.path.isfile(gdsfile)):
    os.system(touch gdsfile)
</code></pre>

<p>Error I got:
 File "/home/hha/bin/test.py", line 29
    os.system(touch gdsfile)
                          ^
SyntaxError: invalid syntax</p>

<p>But from the command line, I am able to create new file using: touch </p>

<p>Thank you very much for your help
Howard</p>
