Torrential rainfall prompts state of emergency in New York City