def url_match(condition, data_format, data_type):
 inds = np.logical_and((conditions == condition), (data_formats == data_format))
 inds = np.logical_and(inds, (data_types == data_type))
 inds = np.logical_and(inds, (data_formats == data_format))
 good_urls = list(urls[inds])
 for (gi, g) in enumerate(good_urls):
  good_urls[gi] = (url_root + g)
 if (len(good_urls) == 0):
  raise ValueError(('No MEGSIM dataset found with condition="%s",\ndata_format="%s", data_type="%s"' % (condition, data_format, data_type)))
 return good_urls

def url_match ( condition , data_format , data_type ) : inds = np . logical_and ( ( conditions == condition ) , ( data_formats == data_format ) ) inds = np . logical_and ( inds , ( data_types == data_type ) ) inds = np . logical_and ( inds , ( data_formats == data_format ) ) good_urls = list ( urls [ inds ] ) for ( gi , g ) in enumerate ( good_urls ) : good_urls [ gi ] = ( url_root + g ) if ( len ( good_urls ) == 0 ) : raise ValueError ( ( 'No MEGSIM dataset found with condition="%s",\ndata_format="%s", data_type="%s"' % ( condition , data_format , data_type ) ) ) return good_urls
function to match megsim data files .