title: Running function as a thread in background python and exit before its application
body: <p>I'm executing a function as a thread in python. Now, the program will wait for the function to execute and then terminate after its completion.</p>
  
  <p>My target is to starting the background thread and closing the program calling it.
  how can we do it. As in below code, the thread will take 30 min to execute. I want to stop the main program after calling the thread and let the thread run in background.</p>
  
  <pre><code>thread = threading.Thread(target=function_that_runs_for_30_min)
  thread.start()
  print "Thread Started"
  quit()
  </code></pre>