Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "deeranalysis"
version = "2026.0.2"
version = "2026.0.3"
description = "A graphical fitting and data managment tool for DEER spectroscopy, using DeerLab and DeerNet as fitting engines."
authors = [
{name = "Hugo Karas",email = "hkaras@ethz.ch"}
Expand Down
2 changes: 1 addition & 1 deletion src/deeranalysis/components/fit_page_components.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ def distance_slider(page_id):
return dmc.Stack([dmc.Text("Distance Axis (nm): ", size="sm", fw=500, mb=4),
dcc.RangeSlider(
id= {"type": "distance-axis", "page": page_id},
min=1.5,
min=1.25,
max=12,
step=0.25,
value=[1.75, 6],
Expand Down
8 changes: 4 additions & 4 deletions src/deeranalysis/components/model_edit_modal.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
'3pDEER': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_3pdeer.html',
'4pDEER': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_4pdeer.html',
'5pDEER': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_fwd5pdeer.html',
'dqc': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_dqc.html',
'ridme': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_ridme.html',
'DQC': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_dqc.html',
'RIDME': 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.ex_ridme.html',
}

b_model_links = {
Expand Down Expand Up @@ -52,8 +52,8 @@ def make_btn(label, href):

base_path = 'https://jeschkelab.github.io/DeerLab/_autosummary/deerlab.{model}.html'
return [
make_btn("Experiment Model", base_path.format(model=exp_type) if (exp_type and exp_type != 'single') else None),
make_btn("Background Model", base_path.format(model=bg_model) if bg_model else None),
make_btn("Experiment Model", exp_model_links.get(exp_type, None) if (exp_type and exp_type != 'single') else None),
make_btn("Background Model", b_model_links.get(bg_model, None)),
make_btn("Distance Distribution Model", p_model_links.get(p_model)),
]

Expand Down
4 changes: 2 additions & 2 deletions src/deeranalysis/utils/deerlab_normal.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,15 +240,15 @@ def deerlab_fitting(dataset, compactness=True, model=None, exp_type='5pDEER', ve
elif exp_type == "3pDEER":
experimentInfo = dl.ex_3pdeer(tau=tau1,pathways=pathways,pulselength=pulselength)
elif exp_type == "RIDME":
experimentInfo = dl.ex_ridme(tau=tau1,tau2=tau2,pathways=pathways,pulselength=pulselength)
experimentInfo = dl.ex_ridme(tau1=tau1,tau2=tau2,pathways=pathways,pulselength=pulselength)
elif exp_type == "SIFTER":
experimentInfo = dl.ex_sifter(tau1=tau1,tau2=tau2,pathways=pathways,pulselength=pulselength)
elif exp_type == "DQC":
experimentInfo = dl.ex_dqc(tau1=tau1,tau2=tau2,tau3=tau3,pathways=pathways,pulselength=pulselength)
elif exp_type == "single":
experimentInfo = None
else:
raise ValueError(f"Experiment type {exp_type} not recognized. Please specify a valid experiment type (e.g., '4pDEER', '5pDEER', '3pDEER').")
raise ValueError(f"Experiment type {exp_type} not recognized. Please specify a valid experiment type (e.g., '4pDEER', '5pDEER', '3pDEER', 'RIDME', 'SIFTER', 'DQC', 'single').")

if 'r' in kwargs:
r = kwargs.pop('r')
Expand Down
20 changes: 10 additions & 10 deletions src/deeranalysis/utils/deerlab_options.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
]

experiment_type_options = [
{"label": "Single Pathway", "value": "single", "max_pathways": 1, "delays": []},
{"label": "Single Pathway", "value": "single", "max_pathways": 1, "delays": [], 'link': None},
{"label": "4-pulse DEER", "value": "4pDEER", "max_pathways": 4, "delays": ['tau1', 'tau2']},
{"label": "3-pulse DEER", "value": "3pDEER", "max_pathways": 3, "delays": ['tau1']},
{"label": "5-pulse DEER", "value": "5pDEER", "max_pathways": 5, "delays": ['tau1', 'tau2', 'tau3']},
Expand Down Expand Up @@ -593,7 +593,7 @@ def build_model_data(dataset, bg_model_name, pathways, r_range,
Vmodel = bg_model
exp_type='background'
else:
if seq_name == '5pDEER' or ('tau3' in attrs and seq_name != '4pDEER'):
if seq_name == '5pDEER':
exp_type = '5pDEER'
tau1 = attrs['tau1'] / 1e3
tau2 = attrs['tau2'] / 1e3
Expand All @@ -615,21 +615,21 @@ def build_model_data(dataset, bg_model_name, pathways, r_range,
elif seq_name == 'single':
exp_type = 'single'
exp_info = None
elif seq_name == 'ridme':
exp_type = 'ridme'
elif seq_name == 'RIDME':
exp_type = 'RIDME'
tau1 = attrs['tau1'] / 1e3
tau2 = attrs['tau2'] / 1e3
pathways = [p for p in pathways if p <= 2]
exp_info = dl.ex_ridme(tau=tau1, tau2=tau2, pathways=pathways)
elif seq_name == 'dqc':
exp_type = 'dqc'
exp_info = dl.ex_ridme(tau1=tau1, tau2=tau2, pathways=pathways)
elif seq_name == 'DQC':
exp_type = 'DQC'
tau1 = attrs['tau1'] / 1e3
tau2 = attrs['tau2'] / 1e3
tau3 = attrs['tau3'] / 1e3
pathways = [p for p in pathways if p <= 2]
exp_info = dl.ex_dqc(tau=tau1, tau2=tau2, tau3=tau3, pathways=pathways)
elif seq_name == 'sifter':
exp_type = 'sifter'
exp_info = dl.ex_dqc(tau1=tau1, tau2=tau2, tau3=tau3, pathways=pathways)
elif seq_name == 'SIFTER':
exp_type = 'SIFTER'
tau1 = attrs['tau1'] / 1e3
tau2 = attrs['tau2'] / 1e3
pathways = [p for p in pathways if p <= 2]
Expand Down