Visium HD proseg error "ScaleTooSmall"
Hello!
I notice this error initially addressed in #109, but I am not finding the resolution I am looking for.
I have six Visium HD samples. They were all run through SpaceRanger with the same settings, and then run in proseg with all the default parameters. Interestingly, three of my samples ran without error. On the other hand, three errored out with the same message:
proseg-3.0.8/src/sampler/paramsampler.rs:119:18:
called `Result::unwrap()` on an `Err` value: ScaleTooSmall
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
It is worth noting that there are no clear differences between the three samples that ran and those that did not (not split by experiment groups, etc.). They also seem to have similar metrics in the SpaceRanger "Cell Segmentation Metrics" tab.
I appreciate any insight you might be able to provide for this!
Hmm, I have some ideas but it's hard to know for sure. I'll see if I can find a dataset I can reproduce this on.
This may be too much of a pain, but if you could run it like RUST_LOG=info proseg ... and reproduce the error, that may give some useful info. In particular I'd be curious to see what what the last line that looks like "component_population: ..." says before it breaks.
Hmm, I have some ideas but it's hard to know for sure. I'll see if I can find a dataset I can reproduce this on.
This may be too much of a pain, but if you could run it like
RUST_LOG=info proseg ...and reproduce the error, that may give some useful info. In particular I'd be curious to see what what the last line that looks like "component_population: ..." says before it breaks.
I will go ahead and do this and let you know what I find. Thanks!
@dcjones These are the results I am seeing when I run with RUST_LOG=info. I am not seeing anything about component population. Might I need to run RUST_BACKTRACE=full to get that information?
thread 'main' panicked at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/proseg-3.0.8/src/sampler/paramsampler.rs:119:18:
called `Result::unwrap()` on an `Err` value: ScaleTooSmall
stack backtrace:
0: __rustc::rust_begin_unwind
at /rustc/6b00bc3880198600130e1cf62b8f8a93494488cc/library/std/src/panicking.rs:697:5
1: core::panicking::panic_fmt
at /rustc/6b00bc3880198600130e1cf62b8f8a93494488cc/library/core/src/panicking.rs:75:14
2: core::result::unwrap_failed
at /rustc/6b00bc3880198600130e1cf62b8f8a93494488cc/library/core/src/result.rs:1732:5
3: core::result::Result<T,E>::unwrap
at /rustc/6b00bc3880198600130e1cf62b8f8a93494488cc/library/core/src/result.rs:1137:23
4: proseg::sampler::paramsampler::ParamSampler::sample_volume_params::{{closure}}
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/proseg-3.0.8/src/sampler/paramsampler.rs:115:23
5: ndarray::zip::Zip<(P1,P2),D>::for_each::{{closure}}
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ndarray-0.16.1/src/zip/mod.rs:585:41
6: ndarray::zip::Zip<P,D>::inner
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ndarray-0.16.1/src/zip/mod.rs:355:31
7: ndarray::zip::Zip<P,D>::for_each_core_contiguous
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ndarray-0.16.1/src/zip/mod.rs:334:18
8: ndarray::zip::Zip<P,D>::for_each_core
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ndarray-0.16.1/src/zip/mod.rs:319:13
9: ndarray::zip::Zip<(P1,P2),D>::for_each
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ndarray-0.16.1/src/zip/mod.rs:583:17
10: proseg::sampler::paramsampler::ParamSampler::sample_volume_params
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/proseg-3.0.8/src/sampler/paramsampler.rs:112:9
11: proseg::sampler::paramsampler::ParamSampler::sample
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/proseg-3.0.8/src/sampler/paramsampler.rs:37:9
12: proseg::main
at .cargo/registry/src/index.crates.io-1949cf8c6b5b557f/proseg-3.0.8/src/main.rs:902:9
13: core::ops::function::FnOnce::call_once
at /rustc/6b00bc3880198600130e1cf62b8f8a93494488cc/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
Finished processing D1_120_13-5-dko
Thu Oct 16 16:13:36 CDT 2025