natverse / neuprintr

R client utilities for interacting with the neuPrint connectome analysis service
http://natverse.org/neuprintr
3 stars 3 forks source link

neuprint_read_neurons() fails for some neurons without a warning #54

Closed mmc46 closed 4 years ago

mmc46 commented 4 years ago

Example from https://github.com/natverse/neuprintr/blob/master/vignettes/hemibrain_opns.Rmd neuprint_search() with default OmitFailures = NA

opn.info = neuprint_search(".*mPN1.*")
length(opn.info$bodyid)
[1] 109
opns = neuprint_read_neurons(opn.info$bodyid)
length(opns)
[1] 99
mmc46 commented 4 years ago

There is an error when using neuprint_read_neuron_simple().

test = neuprint_read_neuron_simple(opn.info$bodyid)
  21/109 [=============>----------------------------------------------------------]  eta: 47sError in as.neuron.ngraph(as.ngraph(x), vertexData = x, ...) : 
  Invalid neuron! Must contain at least one segment with 2 points
In addition: There were 19 warnings (use warnings() to see them)
warnings()
Warning messages:
1: In as.seglist.igraph(masterg <- x, origin = origin, Verbose = Verbose) :
  Multiple origins found! Using first origin.
2: In as.seglist.igraph(masterg <- x, origin = origin, Verbose = Verbose) :
  Multiple origins found! Using first origin.
3: In as.seglist.igraph(masterg <- x, origin = origin, Verbose = Verbose) :
  Multiple origins found! Using first origin.
...
alexanderbates commented 4 years ago

Warnings have been added to the new branch new-heal so will be operable when this branch is merged into master later this week. This branch works, so you can use it for no w if you like:

remotes::install_github("natverse/neuprintr", ref="new-heal")

jefferis commented 4 years ago

Can I confirm that all 109 neurons are read in that case?

jefferis commented 4 years ago

Closed by #76