Create dictionary where keys are variable names
<p>I quite regularly want to create a dictionary where keys are variable names. For example if I have variables <code>a</code> and <code>b</code> I want to generate: <code>{"a":a, "b":b}</code>  (typically to return data at the end of a function).</p>

<p>Are there any (ideally built in) ways in python to do this automatically? i.e to have a function such that <code>create_dictionary(a,b)</code> returns <code>{"a":a, "b":b}</code></p>