Esempio n. 1
0
def layer_filters_channels_overview_json(checkpoints, layernames, filters,
                                         channels):
    region = select_region_query(get_models(),
                                 times=checkpoints,
                                 layers=layernames,
                                 filters=filters,
                                 channels=channels)
    #images = mapterminals(show_multiple, region)
    images = region
    return images
Esempio n. 2
0
def layer_filters_channels_image_json(checkpoints, layernames, filters, channels, imagenum):
    corpus = get_image_corpus()
    image = corpus.get_image(imagenum)
    arr = np.array(image.getdata()).reshape(1, 32, 32, 3).astype(np.float32)

    out = select_region_query(
        get_models(), times=checkpoints, layers=layernames, filters=filters, channels=channels, image=arr
    )
    images = out
    # images = mapterminals(show_multiple, out)
    return images
Esempio n. 3
0
def layer_filters_channels_image_json(checkpoints, layernames, filters,
                                      channels, imagenum):
    corpus = get_image_corpus()
    image = corpus.get_image(imagenum)
    arr = np.array(image.getdata()).reshape(1, 32, 32, 3).astype(np.float32)

    out = select_region_query(get_models(),
                              times=checkpoints,
                              layers=layernames,
                              filters=filters,
                              channels=channels,
                              image=arr)
    images = out
    #images = mapterminals(show_multiple, out)
    return images
Esempio n. 4
0
def layer_filters_channels_overview_json(checkpoints, layernames, filters, channels):
    region = select_region_query(get_models(), times=checkpoints, layers=layernames, filters=filters, channels=channels)
    # images = mapterminals(show_multiple, region)
    images = region
    return images