desy-ml / cheetah

Fast and differentiable particle accelerator optics simulation for reinforcement learning and optimisation applications.
https://cheetah-accelerator.readthedocs.io
GNU General Public License v3.0
32 stars 13 forks source link

Ensure dipoles get a unique name #186

Closed Hespe closed 3 months ago

Hespe commented 3 months ago

Description

Removes an unnecessary name assignment within the dipole element to ensure all accelerator elements are assigned unique names if none are provided.

Motivation and Context

Closes #181

Types of changes

Checklist

Note: We are using a maximum length of 88 characters per line

Hespe commented 3 months ago

I checked all other elements as well and none seem to have the same unnecessary overwrite. Not sure though which line in quadrupole.py you meant in #181, @jank324?

jank324 commented 3 months ago

I think I meant dipole.py. It was late and I was working on multiple issues at the same time. 😄