What advanced methods in contour integration are there? It is well known how to evaluate a definite integral like
$$
\int_{0}^\infty dx\, R(x),
$$
where $R$ is a rational function, using contour integration around a semicircle or a keyhole.
Most complex analysis books only treat well-known and easy examples like this. What I am looking for is examples of integrals that can be evaluated using contour integration, but require more creative tricks, unusual contours, etc. and are not treated in common textbooks.
Useful answers are applicable not just to one integral, but are somewhat general. Needless to say, answers do not have to include the full computation to be useful.
 A: Most interesting examples come from physics, often quantum mechanics. There are interesting methods around asymptotic expansions (when you can't solve an ODE exactly, but still want to know the behavior of the solutions at large values of some parameter, for example), or representation of solutions of ODEs using contour integrals (where you use a Laplace transform, then choose contours to find linearly independent solutions, or at least their asymptotic behavior). 
Check out this EdX class for the "next level" in contour integration. No more using just a tame Hankel contour - the class deforms branch cuts to wrap around multiple branch points while preserving steepest descent directions, and uses contours that lie not on one, but multiple Riemann sheets of multi-valued functions! I couldn't find many references that go so deep in using contour integrals, with so many difficult examples. If you master the exercises in this class, you are set for a while. https://www.edx.org/course/complex-analysis-physical-applications-misisx-18-11x
