Etcs integration#13
Open
Roli15 wants to merge 13 commits into
Open
Conversation
dkouzoup
approved these changes
Jun 22, 2026
dkouzoup
left a comment
Owner
There was a problem hiding this comment.
Thanks for the great work. Impossible to go through all of it in detail but left a few very minor comments.
| @@ -1,12 +1,10 @@ | |||
| import numpy as np | |||
Owner
There was a problem hiding this comment.
why are those imports removed? We do use np. later in the code (and it might still work due to nested imports but I think it's better practice to explicitly import what we need, or not?
|
|
||
|
|
||
| def solve(self, terminalTime, initialTime=0, terminalVelocity=1, initialVelocity=1): | ||
| def solve(self): |
Owner
There was a problem hiding this comment.
am I right to assume that you introduce the journey index in the other PR?
| solver = casadiSolver(train, track, journey, opts) | ||
|
|
||
| df, stats = solver.solve(1541) | ||
| df, stats = solver.solve(journey) |
Owner
There was a problem hiding this comment.
I'm slightly confused, above I read the .solve() takes no arguments while here you pass the journey
| self.r1 = convertUnit(data['rolling resistance r1']['value'], data['rolling resistance r1']['unit']) # linear term [N/(m/s)] | ||
|
|
||
| self.r2 = convertUnit(data['rolling resistance r2']['value'], data['rolling resistance r2']['unit']) # quadratic term [N/(m/s)^2] | ||
| self.r2 = convertUnit(data['rolling resistance r2']['value'], data['rolling resistance r2']['unit']) # quadratic term [N/(m/s)^2 |
Owner
There was a problem hiding this comment.
why is the closing bracket removed?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.