Skip to content

Commit

Permalink
minor tutorial update
Browse files Browse the repository at this point in the history
  • Loading branch information
alexsquires committed Jul 11, 2024
1 parent 54b73a0 commit 723eaf4
Show file tree
Hide file tree
Showing 2 changed files with 143 additions and 99 deletions.
8 changes: 4 additions & 4 deletions doped/interface/fermi_solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ def scan_temperature(

if chempots is None and limit is not None:
chempots = self._get_limits(limit)
else:
elif chempots is None and limit is None:
raise ValueError("You must specify a limit or chempots dictionary.")

if annealing_temperature_range is not None and quenching_temperature_range is not None:
Expand Down Expand Up @@ -297,7 +297,7 @@ def scan_dopant_concentration(

if chempots is None and limit is not None:
chempots = self._get_limits(limit)
else:
elif chempots is None and limit is None:
raise ValueError("You must specify a limit or chempots dictionary.")

# Existing logic here, now correctly handling floats and lists
Expand Down Expand Up @@ -1298,7 +1298,7 @@ def grid_from_dataframe(
# Combine points with their corresponding interpolated values
grid_with_values = np.hstack((points_inside, values_inside.reshape(-1, 1)))

return pd.DataFrame( # convert to DataFrame and set column names
return pd.DataFrame(
grid_with_values,
columns=[*list(independent_vars.columns), *dependent_variable],
columns=[*list(independent_vars.columns), dependent_variable],
)
234 changes: 139 additions & 95 deletions examples/py_sc_fermi_interface_tutorial.ipynb

Large diffs are not rendered by default.

0 comments on commit 723eaf4

Please sign in to comment.