Skip to content

Conversation

Mael-Le-Garrec
Copy link
Contributor

@Mael-Le-Garrec Mael-Le-Garrec commented May 13, 2025

Now that XSuite exists, it's possible to run tracking simulations directly in python. Using harpy requires to create a TbtData object and write an SDDS.
This PR skips the SDDS writing step, as now TbtData objects can be loaded directly.

Harpy's logic was to use the filename to determine the output, a new argument tbt_name is introduced for the user to choose the name of the output.

2025-05-13_11-35-42


2025-05-13_11-37-03

@Mael-Le-Garrec Mael-Le-Garrec added Type: Feature A (suggetion for a) new feature or enhancement in functionality. Priority: Medium Work on this. labels May 13, 2025
Copy link

Code Climate has analyzed commit 31ea6e3 and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 95.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 85.7% (0.0% change).

View more on Code Climate.

@JoschD
Copy link
Member

JoschD commented May 13, 2025

I was thinking that we could possibly add an optional file, info, name or source attribute to the TbTData class (that we might as well even set automatically in the reader for whoever wants to use it for other things, but that's not neccessay for this to work here). And then we could skip the tbt_name argument here and say "try this attribute, if this is not set, use str(files) as before". That way you can just set the name manually directly at the object, keep better track of it and we do not have an additional argument to hio. But that's just an idea, might have downsides that I don't see at the moment (apart from having to also update the tbt package).

@JoschD
Copy link
Member

JoschD commented Jul 11, 2025

@fsoubelet @jgray-19 what do you think? about my last comment?

@fsoubelet
Copy link
Member

@fsoubelet @jgray-19 what do you think? about my last comment?

The bypass would be in hole-in-one?

@JoschD
Copy link
Member

JoschD commented Jul 11, 2025

If I read this PR correctly, the bypass is in hio. The issue is, that we use the filename also for the output file. Maels suggestion is to add another input parameter, that defines the filename. My suggestion is to add an extra field (name? source? ) to the tbt data object, that can be used for this purpose.

@jgray-19
Copy link
Contributor

I think it's actually a decent idea in the TbtData object to pass the origin of the data. Most TFS tables do include an origin. So I like this as a small extension. I think it makes more sense the more output formats that can also include this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: Medium Work on this. Type: Feature A (suggetion for a) new feature or enhancement in functionality.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants