BUG: fix csgraph bug for fully connected graphs