Make local directories before downloading. Moved query methods to proper section.