Exemplo n.º 1
0
def test_remove_monitored_link_via_delete_node(fixed_nodenet):
    uid = micropsi.add_link_monitor(fixed_nodenet, 'n0005', 'gen', 'n0003',
                                    'gen', 'weight', 'Testmonitor')
    micropsi.delete_nodes(fixed_nodenet, ['n0005'])
    micropsi.step_nodenet(fixed_nodenet)
    monitor = micropsi.export_monitor_data(fixed_nodenet)
    assert monitor[uid]['values'][1] is None
Exemplo n.º 2
0
def test_remove_monitored_node(fixed_nodenet):
    uid = micropsi.add_gate_monitor(fixed_nodenet,
                                    'n0001',
                                    'gen',
                                    sheaf='default')
    micropsi.delete_nodes(fixed_nodenet, ['n0001'])
    micropsi.step_nodenet(fixed_nodenet)
    monitor = micropsi.export_monitor_data(fixed_nodenet)
    assert monitor[uid]['values'][1] is None
Exemplo n.º 3
0
def delete_nodes(nodenet_uid, node_uids):
    return runtime.delete_nodes(nodenet_uid, node_uids)
Exemplo n.º 4
0
def test_remove_monitored_link_via_delete_node(fixed_nodenet):
    uid = micropsi.add_link_monitor(fixed_nodenet, 'n0005', 'gen', 'n0003', 'gen', 'weight', 'Testmonitor')
    micropsi.delete_nodes(fixed_nodenet, ['n0005'])
    micropsi.step_nodenet(fixed_nodenet)
    monitor = micropsi.export_monitor_data(fixed_nodenet)
    assert monitor[uid]['values'][1] is None
Exemplo n.º 5
0
def test_remove_monitored_node(fixed_nodenet):
    uid = micropsi.add_gate_monitor(fixed_nodenet, 'n0001', 'gen', sheaf='default')
    micropsi.delete_nodes(fixed_nodenet, ['n0001'])
    micropsi.step_nodenet(fixed_nodenet)
    monitor = micropsi.export_monitor_data(fixed_nodenet)
    assert monitor[uid]['values'][1] is None
Exemplo n.º 6
0
def delete_nodes(nodenet_uid, node_uids):
    """ Delete the given nodes. Expects a list of uids"""
    return runtime.delete_nodes(nodenet_uid, node_uids)