question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

how can i get a lower vector-field energy?

See original GitHub issue

after reconstructing a field from the velocities, dyn.vf.VectorField(adata, basis='umap', M=1000, pot_curl_div=True, min_vel_corr=0.8, restart_num=500, cores=20 )

I observed a poor energy-decreasing pattern. image

Are there any parameters I can tune to improve this energy behavior?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
chansigitcommented, May 20, 2022

Thank you, I found the “Effects of parameters in vector field reconstruction” part in your paper.

I tried these parameters: M, lambda_ and set MaxIter 5k~10k, and found:

  1. the velocity streamline on the cells did not vary a lot, and the cell potential landscape did not vary a lot either;
  2. the streamlines outside of the cells varied when I set different M and lambda_. Higher lambda_ values made the streamline stubborn and straight as expected (under-fitting). Lower M values increase the sparsity of the streamlines as expected;
  3. the streamlines outside of the cells are not very stable- the arrow directions and the whirlpool locations changed a lot and.
  4. the parameter tuning rarely improved energy descent curve, and the energy keeps oscillating up and down.

image
image
image
image

Let me ask some additional questions:

  1. the convergence of the vector-field energy seems poor in my case, can I tune some optimization hyper-parameters like step length or learning rate to attenuate the oscillation?
  2. some points on the energy curve once reaches the lowest historical local minima and soon went back to higher levels, can I resume the energy to the local minima step after finishing the optimization?
  3. since I have no idea what cell types the streamline-possessing empty area represent, plus the streamline outside of the cells are unstable, how should i interpret these part of the vector field?

Thank you again for your kind help

0reactions
Xiaojieqiucommented, Jul 19, 2022

regarding the energy profile, generally it should decrease dramatically from the first iteration. My experience is that often times the default parameters works well and if you want more refined vector field, try increase basis function M to 500 or 100 as well as increase the maximal learning iterations, maxIter

Read more comments on GitHub >

github_iconTop Results From Across the Web

Stress-energy tensor for a massive vector field
I am trying to work out the symmetric stress-energy tensor for a free massive vector field and show that it is conserved.
Read more >
A topological lower bound for the energy of a unit vector field ...
For a unit vector field on a closed immersed Euclidean hypersurface. M2n+1, n ≥ 1, we exhibit a nontrivial lower bound for its...
Read more >
Vector field - Wikipedia
In vector calculus and physics, a vector field is an assignment of a vector to each point in a subset of space. For...
Read more >
(PDF) A topological lower bound for the energy of a unit vector ...
PDF | For a unit vector field on a closed immersed Euclidean hypersurface, we exhibit a nontrivial lower bound for its energy which...
Read more >
A topological lower bound for the energy ... - Papers With Code
When the hypersurface is the unit sphere S 2 n + 1 , immersed with degree one, this lower bound corresponds to a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found