Python Check Variable Is Array