<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def draw_im(self, fname):
 """Draw and save the influence map in a file. Parameters fname : str The name of the file to save the influence map in. The extension of the file will determine the file format, typically png or pdf. """

        im = self.get_im()
        im_agraph = nx.nx_agraph.to_agraph(im)
        im_agraph.draw(fname, prog='dot')