Skip to content

Commit

Permalink
minimal linting here
Browse files Browse the repository at this point in the history
  • Loading branch information
fsoubelet committed Aug 12, 2024
1 parent 4b97daa commit 23cf1d8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions examples/demo_lhc_rigid_waist_shift.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
builds, but you can use any branch you want.
"""
# sphinx_gallery_thumbnail_number = 3
from collections import namedtuple
from multiprocessing import cpu_count
from typing import NamedTuple

import matplotlib.pyplot as plt
import numpy as np
Expand Down Expand Up @@ -324,9 +324,9 @@
# We can use the above to determine these values for different knob settings.
# First, let's define some structures and functions.

Waist = namedtuple("Waist", ["x", "y"])
BetasIP = namedtuple("Betas", ["x", "y"])
Result = namedtuple("Result", ["waists", "betas"])
Waist = NamedTuple("Waist", ["x", "y"])
BetasIP = NamedTuple("Betas", ["x", "y"])
Result = NamedTuple("Result", ["waists", "betas"])


def find_waists(current_twiss: tfs.TfsDataFrame, initial_twiss: tfs.TfsDataFrame) -> Waist:
Expand Down
4 changes: 2 additions & 2 deletions examples/demo_stats_fitting.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,11 +237,11 @@ def chi_dist(num: int, meas_used: int) -> np.ndarray:
label="Generated Chi Distribution",
figsize=(20, 12),
)
dataYLim = ac.get_ylim()
data_ylim = ac.get_ylim()

# Find best fit candidate
best_fit_func, best_fit_params = fitting.best_fit_distribution(chi_data, 200, ac)
ac.set_ylim(dataYLim)
ac.set_ylim(data_ylim)
ac.set_title("All Fitted Distributions")
ac.set_ylabel("Normed Hist Counts")
plt.legend()
Expand Down

0 comments on commit 23cf1d8

Please sign in to comment.