humans have lived with dogs for thousands of years