Skip to content

Commit

Permalink
Get riid.patch to apply
Browse files Browse the repository at this point in the history
  • Loading branch information
mnishida committed Jun 9, 2022
1 parent 4bc9600 commit 6cd8036
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 27 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ repos:
# args: ["--profile", "black", "--filter-files"]

- repo: https://github.com/psf/black
rev: "21.7b0"
rev: "22.3.0"
hooks:
- id: black

Expand Down
31 changes: 11 additions & 20 deletions src/riip/data/riid.patch
Original file line number Diff line number Diff line change
@@ -1,23 +1,14 @@
diff --git a/database/library.yml b/database/library.yml
index bfc09515..d9386ad5 100644
index 4816bdab..91e1078a 100644
--- a/database/library.yml
+++ b/database/library.yml
@@ -599,7 +599,7 @@
- PAGE: Song-sHOPG-o
name: "Song et al. 2018: s-HOPG; n,k(o) 0.193-1.69 µm"
data: "main/C/Song-sHOPG-o.yml"
- - PAGE: Song-cHOPG-e
+ - PAGE: Song-sHOPG-e
name: "Song et al. 2018: s-HOPG; n(e) 0.193-1.69 µm"
data: "main/C/Song-sHOPG-e.yml"
- DIVIDER: "Graphene"
@@ -8556,9 +8556,6 @@
- PAGE: D-ZLAF52LA
name: "D-ZLAF52LA"
data: "glass/cdgm/D-ZLAF52LA.yml"
- - PAGE: D-ZLAF52LA
- name: "D-ZLAF52LA"
- data: "glass/cdgm/D-ZLAF52LA.yml"
- PAGE: D-ZLAF61
name: "D-ZLAF61"
data: "glass/cdgm/D-ZLAF61.yml"
@@ -10941,9 +10941,6 @@
- PAGE: Wu-29.9C-o
name: "Wu et al. 1993: n(o) 0.4–0.8 µm; 29.9 °C"
data: "other/liquid crystals/5CB/Wu-29.9C-o.yml"
- - PAGE: Wu-29.9C-e
- name: "Wu et al. 1993: n(e) 0.4–0.8 µm; 29.9 °C"
- data: "other/liquid crystals/5CB/Wu-29.9C-e.yml"
- PAGE: Wu-32.6C-o
name: "Wu et al. 1993: n(o) 0.4–0.8 µm; 32.6 °C"
data: "other/liquid crystals/5CB/Wu-32.6C-o.yml"
12 changes: 6 additions & 6 deletions src/riip/dataframe.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,13 +121,13 @@ def _load_catalog_and_raw_data(self) -> tuple[DataFrame, DataFrame]:
logger.warning("Catalog file not found.")
if not os.path.isfile(os.path.join(self._db_path, "library.yml")):
logger.warning("Cloning Repository...")
# repo = git.Repo.clone_from(
# _ri_database_repo, self._ri_database, branch="master"
# )
# repo.git.apply(_ri_database_patch)
git.Repo.clone_from(
repo = git.Repo.clone_from(
_ri_database_repo, self._ri_database, branch="master"
)
repo.git.apply(_ri_database_patch)
# git.Repo.clone_from(
# _ri_database_repo, self._ri_database, branch="master"
# )
logger.warning("Done.")
logger.warning("Creating catalog file...")
catalog = self._add_my_db_to_catalog(self._create_catalog())
Expand Down Expand Up @@ -654,7 +654,7 @@ def plot(
plt.plot(wls, ks, fmt2, label=label, **kwargs)
plt.ylabel(r"$k$")
elif comp == "eps":
eps_r = ns ** 2 - ks ** 2
eps_r = ns**2 - ks**2
eps_i = 2 * ns * ks
(line,) = plt.plot(wls, eps_r, fmt1, label=label, **kwargs)
color = line.get_color()
Expand Down

0 comments on commit 6cd8036

Please sign in to comment.