Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates of forward tracking since November of 2022 #107

Open
wants to merge 104 commits into
base: development
Choose a base branch
from

Conversation

tongtongcao
Copy link
Collaborator

@tongtongcao tongtongcao commented Sep 19, 2023

The PR is for updates of forward tracking since November of 2022.
Note: some updates, such as new conditions for iteration termination, issue fixing for fast math package have been merged into development for pass2 cooking.
Main updates in the PR include:

  1. Moved and refactored KF package from DC reconstruction package group to common-tools package group
  2. Improved pattern recognition
  3. Reset covariance matrix for seed
  4. Reset initial covariance matrix for the second and following iterations in tracking
  5. Developed uRWell-DC tracking package
  6. Applied Deterministic Annealing Filter (DAF)

Here are links for talk 1 and talk 2 , which summarize updates.
Here is a link for validation

@@ -22,7 +23,8 @@ public abstract class AMeasVecs {

public void setMeasVecs(List<Surface> measSurfaces) {
measurements = new ArrayList<>();
Collections.sort(measSurfaces);
if(measSurfaces.get(0).type != Type.LINEDOCA && measSurfaces.get(0).type != Type.PLANEURWELL) // Measurements from URWell and DC has been sorted
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CVT has a similar issue and, for this reason, surfaces have "index"

}
}

// For DC, there could be two hits at a measurement
public double[] dhDoca(int k, StateVec stateVec) {
double value[] = {Double.NaN, Double.NaN};
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An alternative to redefining "h" for doublets would be to create a new surface with two lines

}

// For URWell
public Surface(int sector, double x, double y, double z, double x_err, double y_err) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't the measurement a line? can we use the existing PLANESTRIP?

public Surface(int region, double z, double x, double tilt, double wireMaxSag, double[] doca, double[] unc, double error, Line3D[] wireLine) {
type = Type.LINEDOCA;
this.region = region;
this.z = z;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are all these variables really used? for example, wiremaxsag is not really used in reconstruction

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to make a separate pull request for URWell

if(LOGGER.getLevel()==Level.FINE) {
startTime = System.currentTimeMillis();
}
int q = this.calcInitTrkQ(theta1, theta3, TORSCALE);
int q = this.calcInitTrkQ(traj.getA(), TORSCALE);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same comment...

for(int i = 0; i < kFZRef.kfStateVecsAlongTrajectory.size(); i++) {
org.jlab.clas.tracking.kalmanfilter.AStateVecs.StateVec svc = kFZRef.kfStateVecsAlongTrajectory.get(i);
org.jlab.rec.dc.trajectory.StateVec sv = new org.jlab.rec.dc.trajectory.StateVec(svc.x, svc.y, svc.tx, svc.ty);
sv.setZ(svc.z);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it seems like it would be useful to have a copy method for state vectors

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to a separate pull request

@@ -8,6 +8,7 @@
import org.jlab.rec.dc.Constants;
import org.jlab.rec.dc.cross.Cross;
import trackfitter.fitter.LineFitter;
import Jama.Matrix;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is Jama still used?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to a separate pull request

@tongtongcao tongtongcao mentioned this pull request Apr 8, 2024
@baltzell baltzell added the dc1 label Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants