Release: pseudotime from several start cells, faster and leaner pseudotime on large data, and a fix for NaN pseudotime when a cell is far from every waypoint. Results for a single start cell are unchanged up to floating-point rounding.
New
- Several early cells.
run_palantirandidentify_terminal_statesaccept a list of early cells. Pseudotime then starts from the nearest of them. A warning says when moving the early cells to the diffusion-component boundaries merges some of them (passuse_early_cell_as_start=Trueto start from the early cells themselves), and when automatic detection finds no terminal state. (#146, #185, #188)
Performance
- Faster, leaner pseudotime on large data, with unchanged results. Shortest paths from the waypoints run in
n_jobsprocesses (serially when the joblib backend is threading), the connectivity check usesscipy.sparse.csgraphinstead of networkx, and the refinement works in chunks of cells. (#186, #188)
Fixes
- Pseudotime no longer turns NaN when one cell is far from every waypoint. When a cell was more than ~38 bandwidths from every waypoint, all its waypoint weights underflowed to 0 and normalising them gave 0 / 0, which made the pseudotime of every cell NaN. The weights are now normalised with
scipy.special.softmax, which gives the same values up to floating-point rounding (a few ulp) and stays finite. (#187, #188) - No
Pandas4Warninginfrom_fcs. The deprecatedcopykeyword of theastypecall is dropped. It was inert, so the cast behaves identically on pandas 2 and 3. (#184)
Dependencies
networkxis no longer a runtime dependency; only the test extras (test,test-base) install it.joblib>=1.3is now required.
Thanks
Thanks to @Marius1311 for #185, #186 and #187, to @xyf5432 for #184, and to @TolgaDuz for raising several start cells in #146.
Full changelog: v1.4.5...v1.4.6