diff --git a/.gitignore b/.gitignore
index c0062a7..e052fd1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,7 +1,4 @@
./datasets
*/__pycache__/
*/.idea
-docs/_build/
-docs/_cache/
-docs/_templates/
-docs/_static
+./outputs
diff --git a/.idea/.gitignore b/.idea/.gitignore
new file mode 100755
index 0000000..26d3352
--- /dev/null
+++ b/.idea/.gitignore
@@ -0,0 +1,3 @@
+# Default ignored files
+/shelf/
+/workspace.xml
diff --git a/.idea/inspectionProfiles/profiles_settings.xml b/.idea/inspectionProfiles/profiles_settings.xml
new file mode 100755
index 0000000..105ce2d
--- /dev/null
+++ b/.idea/inspectionProfiles/profiles_settings.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/misc.xml b/.idea/misc.xml
new file mode 100755
index 0000000..3e3ee3e
--- /dev/null
+++ b/.idea/misc.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/.idea/modules.xml b/.idea/modules.xml
new file mode 100755
index 0000000..8c69269
--- /dev/null
+++ b/.idea/modules.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/simca.iml b/.idea/simca.iml
new file mode 100755
index 0000000..bbabeb1
--- /dev/null
+++ b/.idea/simca.iml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
new file mode 100755
index 0000000..35eb1dd
--- /dev/null
+++ b/.idea/vcs.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.ipynb_checkpoints/Untitled-checkpoint.ipynb b/.ipynb_checkpoints/Untitled-checkpoint.ipynb
new file mode 100755
index 0000000..b01303d
--- /dev/null
+++ b/.ipynb_checkpoints/Untitled-checkpoint.ipynb
@@ -0,0 +1,195 @@
+{
+ "cells": [
+ {
+ "cell_type": "code",
+ "execution_count": 1,
+ "id": "2db4fa17-8bda-4dad-8c5f-6a24ac30954f",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "from opticalglass.glassfactory import get_glass_catalog\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "id": "971c1d93-4dcb-46a6-847b-6a4170a6f9a1",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "category NaN abbe number NaN \\\n",
+ "data item nd ne vd ve Colour code \n",
+ "glass \n",
+ "F2 1.62004 1.62408 36.37 36.11 35/32 \n",
+ "F2HT 1.62004 1.62408 36.37 36.11 35/32 \n",
+ "F5 1.60342 1.60718 38.03 37.77 35/32 \n",
+ "FK5HTi 1.48748 1.48913 70.47 70.29 29/25 \n",
+ "K10 1.50137 1.50349 56.41 56.15 33/30 \n",
+ "... ... ... ... ... ... \n",
+ "SF56A 1.7847 1.7918 26.08 25.87 42/37 \n",
+ "SF57 1.84666 1.85504 23.83 23.64 40/37* \n",
+ "SF57HTultra 1.84666 1.85504 23.83 23.64 39/36* \n",
+ "SF6 1.80518 1.81265 25.43 25.24 42/36 \n",
+ "SF6HT 1.80518 1.81265 25.43 25.24 41/36 \n",
+ "\n",
+ "category dispersion coefficients \\\n",
+ "data item B1 B2 B3 C1 C2 \n",
+ "glass \n",
+ "F2 1.345334 0.209073 0.937357 0.009977 0.047045 \n",
+ "F2HT 1.345334 0.209073 0.937357 0.009977 0.047045 \n",
+ "F5 1.310446 0.196034 0.96613 0.009586 0.045763 \n",
+ "FK5HTi 0.909362 0.279077 0.891813 0.005201 0.015894 \n",
+ "K10 1.156871 0.064263 0.872376 0.008094 0.038605 \n",
+ "... ... ... ... ... ... \n",
+ "SF56A 1.705793 0.344223 1.096018 0.013387 0.057956 \n",
+ "SF57 1.816514 0.428894 1.071863 0.01437 0.05928 \n",
+ "SF57HTultra 1.816514 0.428894 1.071863 0.01437 0.05928 \n",
+ "SF6 1.724485 0.390105 1.045729 0.013487 0.056932 \n",
+ "SF6HT 1.724485 0.390105 1.045729 0.013487 0.056932 \n",
+ "\n",
+ "category ... NaN \\\n",
+ "data item ... DP g,F DP i,g Glascode \n",
+ "glass ... \n",
+ "F2 ... 0.0002 0.0006 620364.360 \n",
+ "F2HT ... 0.0002 0.0006 620364.360 \n",
+ "F5 ... -0.0003 -0.0028 603380.347 \n",
+ "FK5HTi ... 0.0036 0.0321 487705.245 \n",
+ "K10 ... -0.0015 -0.0048 501564.252 \n",
+ "... ... ... ... ... \n",
+ "SF56A ... 0.0098 785261.492 \n",
+ "SF57 ... 0.0123 847238.551 \n",
+ "SF57HTultra ... 0.0123 847238.551 \n",
+ "SF6 ... 0.0092 0.0669 805254.518 \n",
+ "SF6HT ... 0.0092 0.0669 805254.518 \n",
+ "\n",
+ "category \\\n",
+ "data item Remarks Date \n",
+ "glass \n",
+ "F2 lead containing glass type 2014-02-01 \n",
+ "F2HT lead containing glass type 2014-02-01 \n",
+ "F5 lead containing glass type 2014-02-01 \n",
+ "FK5HTi i-line glass 2013-05-17 \n",
+ "K10 lead containing glass type 2014-02-01 \n",
+ "... ... ... \n",
+ "SF56A lead containing glass type 2014-02-01 \n",
+ "SF57 lead containing glass type, suitable for preci... 2018-02-21 \n",
+ "SF57HTultra lead containing glass type, suitable for preci... 2018-02-21 \n",
+ "SF6 lead containing glass type 2014-02-01 \n",
+ "SF6HT lead containing glass type 2014-02-01 \n",
+ "\n",
+ "category \n",
+ "data item rel. Price WR-J SR-J AT Abrasion HG-J \n",
+ "glass \n",
+ "F2 1.241862 \n",
+ "F2HT NaN NaN NaN NaN \n",
+ "F5 1.84953 \n",
+ "FK5HTi NaN NaN NaN NaN \n",
+ "K10 2.58259 \n",
+ "... ... ... ... ... ... \n",
+ "SF56A 2.693513 \n",
+ "SF57 2.56571 1 6 449 344 \n",
+ "SF57HTultra 1 6 449 344 \n",
+ "SF6 1.938751 NaN \n",
+ "SF6HT \n",
+ "\n",
+ "[123 rows x 154 columns]\n"
+ ]
+ }
+ ],
+ "source": [
+ "\n",
+ "hoya_pd = get_glass_catalog('Schott')\n",
+ "\n",
+ "print(hoya_pd.df)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "id": "5a4644d0-f2e9-4f4b-b162-a86a9bbd527f",
+ "metadata": {},
+ "outputs": [
+ {
+ "ename": "SyntaxError",
+ "evalue": "invalid syntax (1074339294.py, line 6)",
+ "output_type": "error",
+ "traceback": [
+ "\u001b[0;36m Cell \u001b[0;32mIn[6], line 6\u001b[0;36m\u001b[0m\n\u001b[0;31m B = (nd-1)/constant\u001b[0m\n\u001b[0m ^\u001b[0m\n\u001b[0;31mSyntaxError\u001b[0m\u001b[0;31m:\u001b[0m invalid syntax\n"
+ ]
+ }
+ ],
+ "source": [
+ "nd = 1.6204\n",
+ "vd = 36.37\n",
+ "nm = 1*10**-9\n",
+ "constant = (1/(589.3*nm)**2 - 1/(656.3*nm)**2\n",
+ "\n",
+ "B = (nd-1)/constant\n",
+ "A = nd - B/(589.3*nm)**2"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 8,
+ "id": "7ee33c71-678d-49c3-aa4b-f3497b428db6",
+ "metadata": {},
+ "outputs": [
+ {
+ "ename": "NameError",
+ "evalue": "name 'nm' is not defined",
+ "output_type": "error",
+ "traceback": [
+ "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
+ "\u001b[0;31mNameError\u001b[0m Traceback (most recent call last)",
+ "Cell \u001b[0;32mIn[8], line 1\u001b[0m\n\u001b[0;32m----> 1\u001b[0m lambda_ \u001b[38;5;241m=\u001b[39m \u001b[38;5;241m602\u001b[39m\u001b[38;5;241m*\u001b[39m\u001b[43mnm\u001b[49m\n\u001b[1;32m 2\u001b[0m n \u001b[38;5;241m=\u001b[39m A \u001b[38;5;241m+\u001b[39m B\u001b[38;5;241m/\u001b[39mlambda_\u001b[38;5;241m*\u001b[39m\u001b[38;5;241m*\u001b[39m\u001b[38;5;241m2\u001b[39m\n",
+ "\u001b[0;31mNameError\u001b[0m: name 'nm' is not defined"
+ ]
+ }
+ ],
+ "source": [
+ "lambda_ = 602*nm\n",
+ "n = A + B/lambda_**2"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": null,
+ "id": "86d6c502-4d3d-4186-a5c4-abb620f4e9c5",
+ "metadata": {},
+ "outputs": [],
+ "source": []
+ },
+ {
+ "cell_type": "code",
+ "execution_count": null,
+ "id": "017a93e6-a720-4d23-be45-5118ca4aabdf",
+ "metadata": {},
+ "outputs": [],
+ "source": []
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "Python 3 (ipykernel)",
+ "language": "python",
+ "name": "python3"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 3
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython3",
+ "version": "3.9.16"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 5
+}
diff --git a/MST/LICENSE.txt b/MST/LICENSE.txt
deleted file mode 100755
index 18bb3c9..0000000
--- a/MST/LICENSE.txt
+++ /dev/null
@@ -1,21 +0,0 @@
-MIT License
-
-Copyright (c) 2022 Yuanhao Cai
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
diff --git a/MST/README.md b/MST/README.md
deleted file mode 100755
index e7cea45..0000000
--- a/MST/README.md
+++ /dev/null
@@ -1,596 +0,0 @@
-[](https://paperswithcode.com/sota/spectral-reconstruction-on-arad-1k?p=mst-multi-stage-spectral-wise-transformer-for)
-[](https://paperswithcode.com/sota/spectral-reconstruction-on-cave?p=degradation-aware-unfolding-half-shuffle)
-
-[](https://paperswithcode.com/sota/spectral-reconstruction-on-kaist?p=degradation-aware-unfolding-half-shuffle)
-[](https://paperswithcode.com/sota/spectral-reconstruction-on-real-hsi?p=degradation-aware-unfolding-half-shuffle)
-
-
-# A Toolbox for Spectral Compressive Imaging
-[](https://github.com/caiyuanhao1998/MST-plus-plus/)
-[](https://zhuanlan.zhihu.com/p/501101943)
-[](https://zhuanlan.zhihu.com/p/544979161)
-[](https://zhuanlan.zhihu.com/p/576280023)
-
-#### Authors
-Yuanhao Cai*, Jing Lin*, Xiaowan Hu, Haoqian Wang, Xin Yuan, Yulun Zhang, Radu Timofte, and Luc Van Gool
-
-#### Papers
-- [Binarized Spectral Compressive Imaging (NeurIPS 2023)](https://arxiv.org/abs/2305.10299)
-- [Mask-guided Spectral-wise Transformer for Efficient Hyperspectral Image Reconstruction (CVPR 2022)](https://arxiv.org/abs/2111.07910)
-- [Coarse-to-Fine Sparse Transformer for Hyperspectral Image Reconstruction (ECCV 2022)](https://arxiv.org/abs/2203.04845)
-- [Degradation-Aware Unfolding Half-Shuffle Transformer for Spectral Compressive Imaging (NeurIPS 2022)](https://arxiv.org/abs/2205.10102)
-- [MST++: Multi-stage Spectral-wise Transformer for Efficient Spectral Reconstruction (CVPRW 2022)](https://arxiv.org/abs/2111.07910)
-- [HDNet: High-resolution Dual-domain Learning for Spectral Compressive Imaging (CVPR 2022)](https://arxiv.org/abs/2203.02149)
-
-
-
-#### Awards
-
-
-
-#### News
-- **2024.02.15 :** [NTIRE 2024 Challenge on Low Light Enhancement](https://codalab.lisn.upsaclay.fr/competitions/17640) begins. Welcome to use our [Retinexformer](https://github.com/caiyuanhao1998/Retinexformer) or [MST++](https://github.com/caiyuanhao1998/MST-plus-plus) (NTIRE 2022 Spectral Reconstruction Challenge Winner) to participate in this challenge! :trophy:
-- **2023.12.02 :** Codes for real experiments have been updated. Welcome to check and use them. 🥳
-- **2023.11.24 :** Code, models, and results of [BiSRNet](https://arxiv.org/pdf/2305.10299.pdf) (NeurIPS 2023) are released at this repo. We also develop a toolbox [BiSCI](https://github.com/caiyuanhao1998/BiSCI) for binarized SCI reconstruction. Feel free to check and use them. 🌟
-- **2023.11.02 :** MST, MST++, CST, and DAUHST are added to the [Awesome-Transformer-Attention](https://github.com/cmhungsteve/Awesome-Transformer-Attention/blob/main/README_2.md#image-restoration) collection. 💫
-- **2023.09.21 :** Our new work [BiSRNet](https://arxiv.org/pdf/2305.10299.pdf) is accepted by NeurIPS 23. Code will be released at this repo and [BiSCI](https://github.com/caiyuanhao1998/BiSCI)
-- **2023.02.26 :** We release the RGB images of [five real scenes](https://drive.google.com/drive/folders/1VTMgEbfX9MVpGo98XVVFKaANtQfgApAg?usp=sharing) and [ten simulation scenes](https://drive.google.com/drive/folders/1EkJsOxYKgyehZdOgKUeY75dU19GHZgE-?usp=sharing). Please feel free to check and use them. 🌟
-- **2022.11.02 :** We have provided more visual results of state-of-the-art methods and the function to evaluate the parameters and computational complexity of models. Please feel free to check and use them. :high_brightness:
-- **2022.10.23 :** Code, models, and reconstructed HSI results of [DAUHST](https://arxiv.org/abs/2205.10102) have been released. 🔥
-- **2022.09.15 :** Our [DAUHST](https://arxiv.org/abs/2205.10102) has been accepted by NeurIPS 2022, code and models are coming soon. :rocket:
-- **2022.07.20 :** Code, models, and reconstructed HSI results of [CST](https://arxiv.org/abs/2203.04845) have been released. 🔥
-- **2022.07.04 :** Our paper [CST](https://arxiv.org/abs/2203.04845) has been accepted by ECCV 2022, code and models are coming soon. :rocket:
-- **2022.06.14 :** Code and models of [MST](https://arxiv.org/abs/2111.07910) and [MST++](https://arxiv.org/abs/2111.07910) have been released. This repo supports 12 learning-based methods to serve as toolbox for Spectral Compressive Imaging. The model zoo will be enlarged. 🔥
-- **2022.05.20 :** Our work [DAUHST](https://arxiv.org/abs/2205.10102) is on arxiv. :dizzy:
-- **2022.04.02 :** Further work [MST++](https://github.com/caiyuanhao1998/MST-plus-plus/) has won the NTIRE 2022 Spectral Reconstruction Challenge. :trophy:
-- **2022.03.09 :** Our work [CST](https://arxiv.org/abs/2203.04845) is on arxiv. :dizzy:
-- **2022.03.02 :** Our paper MST has been accepted by CVPR 2022, code and models are coming soon. :rocket:
-
-| *Scene 2* | *Scene 3* | *Scene 4* | *Scene 7* |
-| :----------------------------------------------------------: | :----------------------------------------------------------: | :----------------------------------------------------------: | :----------------------------------------------------------: |
-|
|
|
|
|
-
-
-
-
-
-## 1. Comparison with State-of-the-art Methods
-This repo is a baseline and toolbox containing 12 learning-based algorithms for spectral compressive imaging.
-
-
-Supported algorithms:
-
-* [x] [MST](https://arxiv.org/abs/2111.07910) (CVPR 2022)
-* [x] [CST](https://arxiv.org/abs/2203.04845) (ECCV 2022)
-* [x] [DAUHST](https://arxiv.org/abs/2205.10102) (NeurIPS 2022)
-* [x] [BiSRNet](https://arxiv.org/abs/2305.10299) (NeurIPS 2023)
-* [x] [MST++](https://arxiv.org/abs/2111.07910) (CVPRW 2022)
-* [x] [HDNet](https://arxiv.org/abs/2203.02149) (CVPR 2022)
-* [x] [BIRNAT](https://ieeexplore.ieee.org/abstract/document/9741335/) (TPAMI 2022)
-* [x] [DGSMP](https://arxiv.org/abs/2103.07152) (CVPR 2021)
-* [x] [GAP-Net](https://arxiv.org/abs/2012.08364) (Arxiv 2020)
-* [x] [TSA-Net](https://link.springer.com/chapter/10.1007/978-3-030-58592-1_12) (ECCV 2020)
-* [x] [ADMM-Net](https://openaccess.thecvf.com/content_ICCV_2019/html/Ma_Deep_Tensor_ADMM-Net_for_Snapshot_Compressive_Imaging_ICCV_2019_paper.html) (ICCV 2019)
-* [x] [λ-Net](https://ieeexplore.ieee.org/document/9010044) (ICCV 2019)
-
-
-
-
-We are going to enlarge our model zoo in the future.
-
-| MST vs. SOTA | CST vs. MST |
-| :----------------------------------------------: | :-----------------------------------------: |
-|
|
|
-| MST++ vs. SOTA | DAUHST vs. SOTA |
-|
|
|
-
-| BiSRNet vs. SOTA BNNs |
-| :----------------------------------------------: |
-|
|
-
-
-
-
-### Quantitative Comparison on Simulation Dataset
-
-| Method | Params (M) | FLOPS (G) | PSNR | SSIM | Model Zoo | Simulation Result | Real Result |
-| :----------------------------------------------------------: | :--------: | :-------: | :---: | :---: | :----------------------------------------------------------: | :----------------------------------------------------------: | :----------------------------------------------------------: |
-| [λ-Net](https://ieeexplore.ieee.org/document/9010044) | 62.64 | 117.98 | 28.53 | 0.841 | [Google Drive](https://drive.google.com/drive/folders/11DwTFdgtG7sRnBwvkxxfN9rcOICsEdpC?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1xXkL2p4_mCLeTGa68wEbNQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1csOZ2Kfto_tWIiSD0hc2nzKjR4Ze7ftA?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1-0LjvHnkINW8YYaBiA4-VA?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1vVjlVLUm7Gb5zkDxH-mBwM-KnjXbgsjp?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Ah9NxFyBhKuzQaAL9WsmRw?pwd=mst1) |
-| [TSA-Net](https://link.springer.com/chapter/10.1007/978-3-030-58592-1_12) | 44.25 | 110.06 | 31.46 | 0.894 | [Google Drive](https://drive.google.com/drive/folders/1f29eS8WqXu31310nD-7mRR81XfLBYKBd?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1riGZ83AXXkcjHiGVNrNeYg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1BOXBIu2Ze-L__XuLRUu4y9-lq0fw2FJd?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1icqxYnsD27zrDQ95STfRvw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1OPZF0PpThWhC7aqNqhPEh3dX63OwGTC4?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1T3HX_Z7IqmC2imNLfgyBpg?pwd=mst1) |
-| [DGSMP](https://arxiv.org/abs/2103.07152) | 3.76 | 646.65 | 32.63 | 0.917 | [Google Drive](https://drive.google.com/drive/folders/1j1k8mYKWh8FVe77Cz8hj69nI2lK2D5QC?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1v-uqYJZ5mQxOupLc6E_C1g?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1PjnTYEEDfWlTpe0jzCmImxxXLfy5Viva?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Y1AJICGUqUJEV-74Eg2FEg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1Sw5FPMCOrkF5a9IltYWA-QaYXkpKRw5-?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1BLb2w-yT25OTeeFwGFyMkQ?pwd=mst1) |
-| [GAP-Net](https://arxiv.org/abs/2012.08364) | 4.27 | 78.58 | 33.26 | 0.917 | [Google Drive](https://drive.google.com/drive/folders/1AF3P42DZtBzKpWvjTVKYoLmGHsL2f_SL?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1hraGGd_HEsfCkSGv5QyOaw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/16_kqEj4nlE_KlHzu8Q6zQCizTTBII82F?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/12azFFSEOic7iNTFGmC7wMw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1u7MoHnZraM4NL2uAxC7U04sBhy4AoY_S?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1YDqnQ9BlqWmvdfQKx5vMQw?pwd=mst1) |
-| [ADMM-Net](https://openaccess.thecvf.com/content_ICCV_2019/html/Ma_Deep_Tensor_ADMM-Net_for_Snapshot_Compressive_Imaging_ICCV_2019_paper.html) | 4.27 | 78.58 | 33.58 | 0.918 | [Google Drive](https://drive.google.com/drive/folders/1I9JqdyikulUVjXcdciHaJxfAceqfaF2G?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1ddkA9TazTq0rZReFYgGHMg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1WT0QYfC5dbigl9znD_JFNHpH0k_rTDc-?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1b2sRrJaS3PKYqqQErmtIJg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1MJKLjAo7Yzq_eF1JQK89-r40ItLUq4c8?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1aESUHFHjeMSL7shES3YmSw?pwd=mst1) |
-| [BIRNAT](https://ieeexplore.ieee.org/abstract/document/9741335/) | 4.40 | 2122.66 | 37.58 | 0.960 | [Google Drive](https://drive.google.com/drive/folders/1bwhy0csM6GSNY0Qe9RS7_U3Bm9JJjHoc?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1HDMQu3jWvQ9X1yQA5dprGg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1fp4-D1-RGx9bICSmzpIiKBRAEmDOE3gD?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1pHfEKypguCLydNsmCGojpw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1BUmusDHR-E533NdlHDLCYm_CwSCBJ0IF?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1l77HQkVbH7R6vbWNwwksTA?pwd=mst1) |
-| [HDNet](https://arxiv.org/abs/2203.02149) | 2.37 | 154.76 | 34.97 | 0.943 | [Google Drive](https://drive.google.com/drive/folders/1F41BlUQulzPCf5yNo-q6V6Mdtr7bPV6-?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1mCoGHT22cw7ElVSaXgU5Lw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1oUrgFUWIKR-96zAT2Y42UlAM6l5NVJsf?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Nb5IE02iAClMBC4OHcnePQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1vhzRWzIbhYxeZL-N2ZxaW2WqeT80Jogm?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1BXyMsecmENSoU9mCUKU2xA?pwd=mst1) |
-| [MST-S](https://arxiv.org/abs/2111.07910) | 0.93 | 12.96 | 34.26 | 0.935 | [Google Drive](https://drive.google.com/drive/folders/176f_PammL0ZrIg3lVaQwd6Vr6Ui8FANs?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1ZQ08_Ec3a_-8YYAa5ms5PQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1afMG9PndlvjDTtl7UJZoElmDe5FtpCoW?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1xzJRVjnI-7A54Rj_zi3crA?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1FSwDZKAC03B8XhyAkaL9t1MWFz6q985y?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1H1pT1oKfK_o4EDXkts8VMQ?pwd=mst1) |
-| [MST-M](https://arxiv.org/abs/2111.07910) | 1.50 | 18.07 | 34.94 | 0.943 | [Google Drive](https://drive.google.com/drive/folders/176f_PammL0ZrIg3lVaQwd6Vr6Ui8FANs?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1ZQ08_Ec3a_-8YYAa5ms5PQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1hnEuwYO9luwLmPeT98cUaik_zCPK6z30?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1OUuozfd3zLqzBjHnf6evCQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1FSwDZKAC03B8XhyAkaL9t1MWFz6q985y?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1H1pT1oKfK_o4EDXkts8VMQ?pwd=mst1) |
-| [MST-L](https://arxiv.org/abs/2111.07910) | 2.03 | 28.15 | 35.18 | 0.948 | [Google Drive](https://drive.google.com/drive/folders/176f_PammL0ZrIg3lVaQwd6Vr6Ui8FANs?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1ZQ08_Ec3a_-8YYAa5ms5PQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/18ZF5wC1LRmqOh6VDeXD4eB8mP0Dvv6jb?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1imed0w1CWqx7IOlSpVh7qw?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1FSwDZKAC03B8XhyAkaL9t1MWFz6q985y?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1H1pT1oKfK_o4EDXkts8VMQ?pwd=mst1) |
-| [MST++](https://arxiv.org/abs/2111.07910) | 1.33 | 19.42 | 35.99 | 0.951 | [Google Drive](https://drive.google.com/drive/folders/1rbV8LYD5k1RVR4usMORoXxY2szlFsr_9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1QUx_MpYCBSU4Zas5gpao2g?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/14sz-y99fEAJDQAN1itE5K-BlMHC1Tt3z?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1s3btC7QQrasW1NqFzOm8fQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/14CgUhfUp4BFalyigL4RDnTYyGiN5ojRK?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1fYsAvAjXTLLWpzlt_S2ppQ?pwd=mst1) |
-| [CST-S](https://arxiv.org/abs/2203.04845) | 1.20 | 11.67 | 34.71 | 0.940 | [Google Drive](https://drive.google.com/drive/folders/1-SZDH0PuUyjLlvKfON-LL02dkr2LBuL9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Xq_YV6yO0zN6AULwU9ZPyg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1AdcUGiiPTfdt366NcBV8Texuu1Qw7_DI?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Vl6xufpmLWXSmhaVCsKkzQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/11RNDmA3VrPWdbj4H-mInGfZa60W86YEc?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1m3abRwjuaneFf1cCE85yMw?pwd=mst1) |
-| [CST-M](https://arxiv.org/abs/2203.04845) | 1.36 | 16.91 | 35.31 | 0.947 | [Google Drive](https://drive.google.com/drive/folders/1-SZDH0PuUyjLlvKfON-LL02dkr2LBuL9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Xq_YV6yO0zN6AULwU9ZPyg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1FpMTtKSIN-t_natQIX2gKcu8MfPQLCG1?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1u3IjojML3H7AwSMe0CxV_Q?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/11RNDmA3VrPWdbj4H-mInGfZa60W86YEc?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1m3abRwjuaneFf1cCE85yMw?pwd=mst1) |
-| [CST-L](https://arxiv.org/abs/2203.04845) | 3.00 | 27.81 | 35.85 | 0.954 | [Google Drive](https://drive.google.com/drive/folders/1-SZDH0PuUyjLlvKfON-LL02dkr2LBuL9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Xq_YV6yO0zN6AULwU9ZPyg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1MRFeMoi4JzhFrf_346USCFq98kdds9HY?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1UXwTyr-xZtDR68wzmeaCEA?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/11RNDmA3VrPWdbj4H-mInGfZa60W86YEc?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1m3abRwjuaneFf1cCE85yMw?pwd=mst1) |
-| [CST-L-Plus](https://arxiv.org/abs/2203.04845) | 3.00 | 40.10 | 36.12 | 0.957 | [Google Drive](https://drive.google.com/drive/folders/1-SZDH0PuUyjLlvKfON-LL02dkr2LBuL9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1Xq_YV6yO0zN6AULwU9ZPyg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1sGHrkbYKjN3XqsduQL2mesXqO1XMeqGI?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1PsoJwVfZ7qYi6mnq_q_gDA?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/11RNDmA3VrPWdbj4H-mInGfZa60W86YEc?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1m3abRwjuaneFf1cCE85yMw?pwd=mst1) |
-| [DAUHST-2stg](https://arxiv.org/abs/2205.10102) | 1.40 | 18.44 | 36.34 | 0.952 | [Google Drive](https://drive.google.com/drive/folders/1zhYRhFP8ee4YHk3-M0Nrl6KE_-n0gDLr?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1O2bxz-wEMF0mnrnOXHpC3A?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1qOrnp1crkk1z5ha56UoyOqDMFGfWlLC7?usp=sharing) /[Baidu Disk]( https://pan.baidu.com/s/1_RxqZQpCcYH50nxhSWeb0w?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1SgQhXXPYn6mYGSRMz5Ntsnab26XdjOc9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1S2MKaSKdU2v53_CZnuYkpQ?pwd=mst1) |
-| [DAUHST-3stg](https://arxiv.org/abs/2205.10102) | 2.08 | 27.17 | 37.21 | 0.959 | [Google Drive](https://drive.google.com/drive/folders/1zhYRhFP8ee4YHk3-M0Nrl6KE_-n0gDLr?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1O2bxz-wEMF0mnrnOXHpC3A?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1uwXh5JrD4rnh_xYBpF4K4wI4lcTD1j4p?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1iYtxPuf1rkFWut5UdEYqtg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1SgQhXXPYn6mYGSRMz5Ntsnab26XdjOc9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1S2MKaSKdU2v53_CZnuYkpQ?pwd=mst1) |
-| [DAUHST-5stg](https://arxiv.org/abs/2205.10102) | 3.44 | 44.61 | 37.75 | 0.962 | [Google Drive](https://drive.google.com/drive/folders/1zhYRhFP8ee4YHk3-M0Nrl6KE_-n0gDLr?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1O2bxz-wEMF0mnrnOXHpC3A?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1snTVZSUsbtzjJ5lxbPbaKhpTJX28Byuh?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1k1q0Y8QPgMZhThBEfzGKzQ?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1SgQhXXPYn6mYGSRMz5Ntsnab26XdjOc9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1S2MKaSKdU2v53_CZnuYkpQ?pwd=mst1) |
-| [DAUHST-9stg](https://arxiv.org/abs/2205.10102) | 6.15 | 79.50 | 38.36 | 0.967 | [Google Drive](https://drive.google.com/drive/folders/1zhYRhFP8ee4YHk3-M0Nrl6KE_-n0gDLr?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1O2bxz-wEMF0mnrnOXHpC3A?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1rzZG1L-s2rYmR-wHXg9KnnGPbOIT5GaP?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/10vGcOirPk2L8sQg6uJoJkg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1SgQhXXPYn6mYGSRMz5Ntsnab26XdjOc9?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1S2MKaSKdU2v53_CZnuYkpQ?pwd=mst1) |
-| [BiSRNet](https://arxiv.org/abs/2305.10299) | 0.036 | 1.18 | 29.76 | 0.837 | [Google Drive](https://drive.google.com/file/d/1MIsuIHuAaETZIRosjnKh2cvVgVDh9ZHv/view?usp=drive_link) / [Baidu Disk](https://pan.baidu.com/s/1wrHExqzl07niPS0fdMCAhg?pwd=mst1) | [Google Drive](https://drive.google.com/file/d/1QpZV6MzkijtwFI9MJp87bow4XxAok50m/view?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/11ifwb4tUDAVk7oTlFBKfUg?pwd=mst1) | [Google Drive](https://drive.google.com/drive/folders/1Hgdq43kbmHm1HG9SdLGryiIakBsBWuZp?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1I8051aIYsQEG8ybfSdPF0g?pwd=mst1) |
-
-The performance are reported on 10 scenes of the KAIST dataset. The test size of FLOPS is 256 x 256.
-
-We also provide the RGB images of [five real scenes](https://drive.google.com/drive/folders/1VTMgEbfX9MVpGo98XVVFKaANtQfgApAg?usp=sharing) and [ten simulation scenes](https://drive.google.com/drive/folders/1EkJsOxYKgyehZdOgKUeY75dU19GHZgE-?usp=sharing) for your convenience to draw a figure.
-
-Note: access code for `Baidu Disk` is `mst1`
-
-
-
-
-
-## 2. Create Environment:
-
-- Python 3 (Recommend to use [Anaconda](https://www.anaconda.com/download/#linux))
-
-- NVIDIA GPU + [CUDA](https://developer.nvidia.com/cuda-downloads)
-
-- Python packages:
-
-```shell
- pip install -r requirements.txt
-```
-
-
-
-
-
-## 3. Prepare Dataset:
-Download cave_1024_28 ([Baidu Disk](https://pan.baidu.com/s/1X_uXxgyO-mslnCTn4ioyNQ), code: `fo0q` | [One Drive](https://bupteducn-my.sharepoint.com/:f:/g/personal/mengziyi_bupt_edu_cn/EmNAsycFKNNNgHfV9Kib4osB7OD4OSu-Gu6Qnyy5PweG0A?e=5NrM6S)), CAVE_512_28 ([Baidu Disk](https://pan.baidu.com/s/1ue26weBAbn61a7hyT9CDkg), code: `ixoe` | [One Drive](https://mailstsinghuaeducn-my.sharepoint.com/:f:/g/personal/lin-j21_mails_tsinghua_edu_cn/EjhS1U_F7I1PjjjtjKNtUF8BJdsqZ6BSMag_grUfzsTABA?e=sOpwm4)), KAIST_CVPR2021 ([Baidu Disk](https://pan.baidu.com/s/1LfPqGe0R_tuQjCXC_fALZA), code: `5mmn` | [One Drive](https://mailstsinghuaeducn-my.sharepoint.com/:f:/g/personal/lin-j21_mails_tsinghua_edu_cn/EkA4B4GU8AdDu0ZkKXdewPwBd64adYGsMPB8PNCuYnpGlA?e=VFb3xP)), TSA_simu_data ([Baidu Disk](https://pan.baidu.com/s/1LI9tMaSprtxT8PiAG1oETA), code: `efu8` | [One Drive](https://1drv.ms/u/s!Au_cHqZBKiu2gYFDwE-7z1fzeWCRDA?e=ofvwrD)), TSA_real_data ([Baidu Disk](https://pan.baidu.com/s/1RoOb1CKsUPFu0r01tRi5Bg), code: `eaqe` | [One Drive](https://1drv.ms/u/s!Au_cHqZBKiu2gYFTpCwLdTi_eSw6ww?e=uiEToT)), and then put them into the corresponding folders of `datasets/` and recollect them as the following form:
-
-```shell
-|--MST
- |--real
- |-- test_code
- |-- train_code
- |--simulation
- |-- test_code
- |-- train_code
- |--visualization
- |--datasets
- |--cave_1024_28
- |--scene1.mat
- |--scene2.mat
- :
- |--scene205.mat
- |--CAVE_512_28
- |--scene1.mat
- |--scene2.mat
- :
- |--scene30.mat
- |--KAIST_CVPR2021
- |--1.mat
- |--2.mat
- :
- |--30.mat
- |--TSA_simu_data
- |--mask.mat
- |--Truth
- |--scene01.mat
- |--scene02.mat
- :
- |--scene10.mat
- |--TSA_real_data
- |--mask.mat
- |--Measurements
- |--scene1.mat
- |--scene2.mat
- :
- |--scene5.mat
-```
-
-Following TSA-Net and DGSMP, we use the CAVE dataset (cave_1024_28) as the simulation training set. Both the CAVE (CAVE_512_28) and KAIST (KAIST_CVPR2021) datasets are used as the real training set.
-
-
-
-
-
-## 4. Simulation Experiement:
-
-### 4.1 Training
-
-```shell
-cd MST/simulation/train_code/
-
-# MST_S
-python train.py --template mst_s --outf ./exp/mst_s/ --method mst_s
-
-# MST_M
-python train.py --template mst_m --outf ./exp/mst_m/ --method mst_m
-
-# MST_L
-python train.py --template mst_l --outf ./exp/mst_l/ --method mst_l
-
-# CST_S
-python train.py --template cst_s --outf ./exp/cst_s/ --method cst_s
-
-# CST_M
-python train.py --template cst_m --outf ./exp/cst_m/ --method cst_m
-
-# CST_L
-python train.py --template cst_l --outf ./exp/cst_l/ --method cst_l
-
-# CST_L_Plus
-python train.py --template cst_l_plus --outf ./exp/cst_l_plus/ --method cst_l_plus
-
-# GAP-Net
-python train.py --template gap_net --outf ./exp/gap_net/ --method gap_net
-
-# ADMM-Net
-python train.py --template admm_net --outf ./exp/admm_net/ --method admm_net
-
-# TSA-Net
-python train.py --template tsa_net --outf ./exp/tsa_net/ --method tsa_net
-
-# HDNet
-python train.py --template hdnet --outf ./exp/hdnet/ --method hdnet
-
-# DGSMP
-python train.py --template dgsmp --outf ./exp/dgsmp/ --method dgsmp
-
-# BIRNAT
-python train.py --template birnat --outf ./exp/birnat/ --method birnat
-
-# MST_Plus_Plus
-python train.py --template mst_plus_plus --outf ./exp/mst_plus_plus/ --method mst_plus_plus
-
-# λ-Net
-python train.py --template lambda_net --outf ./exp/lambda_net/ --method lambda_net
-
-# DAUHST-2stg
-python train.py --template dauhst_2stg --outf ./exp/dauhst_2stg/ --method dauhst_2stg
-
-# DAUHST-3stg
-python train.py --template dauhst_3stg --outf ./exp/dauhst_3stg/ --method dauhst_3stg
-
-# DAUHST-5stg
-python train.py --template dauhst_5stg --outf ./exp/dauhst_5stg/ --method dauhst_5stg
-
-# DAUHST-9stg
-python train.py --template dauhst_9stg --outf ./exp/dauhst_9stg/ --method dauhst_9stg
-
-# BiSRNet
-python train.py --template bisrnet --outf ./exp/bisrnet/ --method bisrnet
-```
-
-- The training log, trained model, and reconstrcuted HSI will be available in `MST/simulation/train_code/exp/`
-
-
-### 4.2 Testing
-
-Download the pretrained model zoo from ([Google Drive](https://drive.google.com/drive/folders/1zgB7jHqTzY1bjCSzdX4lKQEGyK3bpWIx?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1CH4uq_NZPpo5ra2tFzAdfQ?pwd=mst1), code: `mst1`) and place them to `MST/simulation/test_code/model_zoo/`
-
-Run the following command to test the model on the simulation dataset.
-
-```python
-cd MST/simulation/test_code/
-
-# MST_S
-python test.py --template mst_s --outf ./exp/mst_s/ --method mst_s --pretrained_model_path ./model_zoo/mst/mst_s.pth
-
-# MST_M
-python test.py --template mst_m --outf ./exp/mst_m/ --method mst_m --pretrained_model_path ./model_zoo/mst/mst_m.pth
-
-# MST_L
-python test.py --template mst_l --outf ./exp/mst_l/ --method mst_l --pretrained_model_path ./model_zoo/mst/mst_l.pth
-
-# CST_S
-python test.py --template cst_s --outf ./exp/cst_s/ --method cst_s --pretrained_model_path ./model_zoo/cst/cst_s.pth
-
-# CST_M
-python test.py --template cst_m --outf ./exp/cst_m/ --method cst_m --pretrained_model_path ./model_zoo/cst/cst_m.pth
-
-# CST_L
-python test.py --template cst_l --outf ./exp/cst_l/ --method cst_l --pretrained_model_path ./model_zoo/cst/cst_l.pth
-
-# CST_L_Plus
-python test.py --template cst_l_plus --outf ./exp/cst_l_plus/ --method cst_l_plus --pretrained_model_path ./model_zoo/cst/cst_l_plus.pth
-
-# GAP_Net
-python test.py --template gap_net --outf ./exp/gap_net/ --method gap_net --pretrained_model_path ./model_zoo/gap_net/gap_net.pth
-
-# ADMM_Net
-python test.py --template admm_net --outf ./exp/admm_net/ --method admm_net --pretrained_model_path ./model_zoo/admm_net/admm_net.pth
-
-# TSA_Net
-python test.py --template tsa_net --outf ./exp/tsa_net/ --method tsa_net --pretrained_model_path ./model_zoo/tsa_net/tsa_net.pth
-
-# HDNet
-python test.py --template hdnet --outf ./exp/hdnet/ --method hdnet --pretrained_model_path ./model_zoo/hdnet/hdnet.pth
-
-# DGSMP
-python test.py --template dgsmp --outf ./exp/dgsmp/ --method dgsmp --pretrained_model_path ./model_zoo/dgsmp/dgsmp.pth
-
-# BIRNAT
-python test.py --template birnat --outf ./exp/birnat/ --method birnat --pretrained_model_path ./model_zoo/birnat/birnat.pth
-
-# MST_Plus_Plus
-python test.py --template mst_plus_plus --outf ./exp/mst_plus_plus/ --method mst_plus_plus --pretrained_model_path ./model_zoo/mst_plus_plus/mst_plus_plus.pth
-
-# λ-Net
-python test.py --template lambda_net --outf ./exp/lambda_net/ --method lambda_net --pretrained_model_path ./model_zoo/lambda_net/lambda_net.pth
-
-# DAUHST-2stg
-python test.py --template dauhst_2stg --outf ./exp/dauhst_2stg/ --method dauhst_2stg --pretrained_model_path ./model_zoo/dauhst_2stg/dauhst_2stg.pth
-
-# DAUHST-3stg
-python test.py --template dauhst_3stg --outf ./exp/dauhst_3stg/ --method dauhst_3stg --pretrained_model_path ./model_zoo/dauhst_3stg/dauhst_3stg.pth
-
-# DAUHST-5stg
-python test.py --template dauhst_5stg --outf ./exp/dauhst_5stg/ --method dauhst_5stg --pretrained_model_path ./model_zoo/dauhst_5stg/dauhst_5stg.pth
-
-# DAUHST-9stg
-python test.py --template dauhst_9stg --outf ./exp/dauhst_9stg/ --method dauhst_9stg --pretrained_model_path ./model_zoo/dauhst_9stg/dauhst_9stg.pth
-
-# BiSRNet
-python test.py --template bisrnet --outf ./exp/bisrnet/ --method bisrnet --pretrained_model_path ./model_zoo/bisrnet/bisrnet.pth
-```
-
-- The reconstrcuted HSIs will be output into `MST/simulation/test_code/exp/`. Then place the reconstructed results into `MST/simulation/test_code/Quality_Metrics/results` and run the following MATLAB command to calculate the PSNR and SSIM of the reconstructed HSIs.
-
-```shell
-Run cal_quality_assessment.m
-```
-
-
-
-- #### Evaluating the Params and FLOPS of models
-
- We provide two functions `my_summary()` and `my_summary_bnn()` in `simulation/test_code/utils.py`. Use them to evaluate the parameters and FLOPS of full-precision and binarized models
-
-```shell
-from utils import my_summary, my_summary_bnn
-my_summary(MST(), 256, 256, 28, 1)
-my_summary_bnn(BiSRNet(), 256, 256, 28, 1)
-```
-
-### 4.3 Visualization
-
-- Put the reconstruted HSI in `MST/visualization/simulation_results/results` and rename it as method.mat, e.g., mst_s.mat.
-
-- Generate the RGB images of the reconstructed HSIs
-
-```shell
- cd MST/visualization/
- Run show_simulation.m
-```
-
-- Draw the spetral density lines
-
-```shell
-cd MST/visualization/
-Run show_line.m
-```
-
-
-
-
-
-## 5. Real Experiement:
-
-### 5.1 Training
-
-```shell
-cd MST/real/train_code/
-
-# MST_S
-python train.py --template mst_s --outf ./exp/mst_s/ --method mst_s
-
-# MST_M
-python train.py --template mst_m --outf ./exp/mst_m/ --method mst_m
-
-# MST_L
-python train.py --template mst_l --outf ./exp/mst_l/ --method mst_l
-
-# CST_S
-python train.py --template cst_s --outf ./exp/cst_s/ --method cst_s
-
-# CST_M
-python train.py --template cst_m --outf ./exp/cst_m/ --method cst_m
-
-# CST_L
-python train.py --template cst_l --outf ./exp/cst_l/ --method cst_l
-
-# CST_L_Plus
-python train.py --template cst_l_plus --outf ./exp/cst_l_plus/ --method cst_l_plus
-
-# GAP-Net
-python train.py --template gap_net --outf ./exp/gap_net/ --method gap_net
-
-# ADMM-Net
-python train.py --template admm_net --outf ./exp/admm_net/ --method admm_net
-
-# TSA-Net
-python train.py --template tsa_net --outf ./exp/tsa_net/ --method tsa_net
-
-# HDNet
-python train.py --template hdnet --outf ./exp/hdnet/ --method hdnet
-
-# DGSMP
-python train.py --template dgsmp --outf ./exp/dgsmp/ --method dgsmp
-
-# BIRNAT
-python train.py --template birnat --outf ./exp/birnat/ --method birnat
-
-# MST_Plus_Plus
-python train.py --template mst_plus_plus --outf ./exp/mst_plus_plus/ --method mst_plus_plus
-
-# λ-Net
-python train.py --template lambda_net --outf ./exp/lambda_net/ --method lambda_net
-
-# DAUHST-2stg
-python train.py --template dauhst_2stg --outf ./exp/dauhst_2stg/ --method dauhst_2stg
-
-# DAUHST-3stg
-python train.py --template dauhst_3stg --outf ./exp/dauhst_3stg/ --method dauhst_3stg
-
-# DAUHST-5stg
-python train.py --template dauhst_5stg --outf ./exp/dauhst_5stg/ --method dauhst_5stg
-
-# DAUHST-9stg
-python train.py --template dauhst_9stg --outf ./exp/dauhst_9stg/ --method dauhst_9stg
-
-# BiSRNet
-python train_s.py --outf ./exp/bisrnet/ --method bisrnet
-```
-
-- If you do not have a large memory GPU, add `--size 128` to use a small patch size.
-
-- The training log, trained model, and reconstrcuted HSI will be available in `MST/real/train_code/exp/`
-
-- Note: you can use `train_s.py` for other methods except BiSRNet if you cannot access the mask data or you have limited GPU resources. In this case, you need to replace the `--method` paramter in the above commands and make some modifications.
-
-
-### 5.2 Testing
-
-The pretrained model of BiSRNet can be download from ([Google Drive](https://drive.google.com/file/d/1zQ7PFuiaEgIpulBl8TA7S_8Am93nAKPb/view?usp=sharing) / [Baidu Disk](https://pan.baidu.com/s/1hiPbuUEBnIGQP6Ks9agfWQ?pwd=mst1), code: `mst1`) and place them to `MST/real/test_code/model_zoo/`
-
-```python
-cd MST/real/test_code/
-
-# MST_S
-python test.py --outf ./exp/mst_s/ --pretrained_model_path ./model_zoo/mst/mst_s.pth
-
-# MST_M
-python test.py --outf ./exp/mst_m/ --pretrained_model_path ./model_zoo/mst/mst_m.pth
-
-# MST_L
-python test.py --outf ./exp/mst_l/ --pretrained_model_path ./model_zoo/mst/mst_l.pth
-
-# CST_S
-python test.py --outf ./exp/cst_s/ --pretrained_model_path ./model_zoo/cst/cst_s.pth
-
-# CST_M
-python test.py --outf ./exp/cst_m/ --pretrained_model_path ./model_zoo/cst/cst_m.pth
-
-# CST_L
-python test.py --outf ./exp/cst_l/ --pretrained_model_path ./model_zoo/cst/cst_l.pth
-
-# CST_L_Plus
-python test.py --outf ./exp/cst_l_plus/ --pretrained_model_path ./model_zoo/cst/cst_l_plus.pth
-
-# GAP_Net
-python test.py --outf ./exp/gap_net/ --pretrained_model_path ./model_zoo/gap_net/gap_net.pth
-
-# ADMM_Net
-python test.py --outf ./exp/admm_net/ --pretrained_model_path ./model_zoo/admm_net/admm_net.pth
-
-# TSA_Net
-python test.py --outf ./exp/tsa_net/ --pretrained_model_path ./model_zoo/tsa_net/tsa_net.pth
-
-# HDNet
-python test.py --template hdnet --outf ./exp/hdnet/ --method hdnet --pretrained_model_path ./model_zoo/hdnet/hdnet.pth
-
-# DGSMP
-python test.py --outf ./exp/dgsmp/ --pretrained_model_path ./model_zoo/dgsmp/dgsmp.pth
-
-# BIRNAT
-python test.py --outf ./exp/birnat/ --pretrained_model_path ./model_zoo/birnat/birnat.pth
-
-# MST_Plus_Plus
-python test.py --outf ./exp/mst_plus_plus/ --pretrained_model_path ./model_zoo/mst_plus_plus/mst_plus_plus.pth
-
-# λ-Net
-python test.py --outf ./exp/lambda_net/ --pretrained_model_path ./model_zoo/lambda_net/lambda_net.pth
-
-# DAUHST_2stg
-python test.py --outf ./exp/dauhst_2stg/ --pretrained_model_path ./model_zoo/dauhst/dauhst_2stg.pth
-
-# DAUHST_3stg
-python test.py --outf ./exp/dauhst_3stg/ --pretrained_model_path ./model_zoo/dauhst/dauhst_3stg.pth
-
-# DAUHST_5stg
-python test.py --outf ./exp/dauhst_5stg/ --pretrained_model_path ./model_zoo/dauhst/dauhst_5stg.pth
-
-# DAUHST_9stg
-python test.py --outf ./exp/dauhst_9stg/ --pretrained_model_path ./model_zoo/dauhst/dauhst_9stg.pth
-
-# BiSRNet
-python test.py --outf ./exp/bisrnet --pretrained_model_path ./model_zoo/bisrnet/bisrnet.pth --method bisrnet
-```
-
-- The reconstrcuted HSI will be output into `MST/real/test_code/exp/`
-
-### 5.3 Visualization
-
-- Put the reconstruted HSI in `MST/visualization/real_results/results` and rename it as method.mat, e.g., mst_plus_plus.mat.
-
-- Generate the RGB images of the reconstructed HSI
-
-```shell
-cd MST/visualization/
-Run show_real.m
-```
-
-
-
-
-
-## 6. Citation
-If this repo helps you, please consider citing our works:
-
-
-```shell
-
-
-# MST
-@inproceedings{mst,
- title={Mask-guided Spectral-wise Transformer for Efficient Hyperspectral Image Reconstruction},
- author={Yuanhao Cai and Jing Lin and Xiaowan Hu and Haoqian Wang and Xin Yuan and Yulun Zhang and Radu Timofte and Luc Van Gool},
- booktitle={CVPR},
- year={2022}
-}
-
-
-# CST
-@inproceedings{cst,
- title={Coarse-to-Fine Sparse Transformer for Hyperspectral Image Reconstruction},
- author={Yuanhao Cai and Jing Lin and Xiaowan Hu and Haoqian Wang and Xin Yuan and Yulun Zhang and Radu Timofte and Luc Van Gool},
- booktitle={ECCV},
- year={2022}
-}
-
-
-# DAUHST
-@inproceedings{dauhst,
- title={Degradation-Aware Unfolding Half-Shuffle Transformer for Spectral Compressive Imaging},
- author={Yuanhao Cai and Jing Lin and Haoqian Wang and Xin Yuan and Henghui Ding and Yulun Zhang and Radu Timofte and Luc Van Gool},
- booktitle={NeurIPS},
- year={2022}
-}
-
-
-# BiSCI
-@inproceedings{bisci,
- title={Binarized Spectral Compressive Imaging},
- author={Yuanhao Cai and Yuxin Zheng and Jing Lin and Xin Yuan and Yulun Zhang and Haoqian Wang},
- booktitle={NeurIPS},
- year={2023}
-}
-
-
-# MST++
-@inproceedings{mst_pp,
- title={MST++: Multi-stage Spectral-wise Transformer for Efficient Spectral Reconstruction},
- author={Yuanhao Cai and Jing Lin and Zudi Lin and Haoqian Wang and Yulun Zhang and Hanspeter Pfister and Radu Timofte and Luc Van Gool},
- booktitle={CVPRW},
- year={2022}
-}
-
-
-# HDNet
-@inproceedings{hdnet,
- title={HDNet: High-resolution Dual-domain Learning for Spectral Compressive Imaging},
- author={Xiaowan Hu and Yuanhao Cai and Jing Lin and Haoqian Wang and Xin Yuan and Yulun Zhang and Radu Timofte and Luc Van Gool},
- booktitle={CVPR},
- year={2022}
-}
-
-```
diff --git a/MST/figure/MST.png b/MST/figure/MST.png
deleted file mode 100755
index c8f25ee..0000000
Binary files a/MST/figure/MST.png and /dev/null differ
diff --git a/MST/figure/bisrnet.png b/MST/figure/bisrnet.png
deleted file mode 100755
index 266616b..0000000
Binary files a/MST/figure/bisrnet.png and /dev/null differ
diff --git a/MST/figure/compare_fig.png b/MST/figure/compare_fig.png
deleted file mode 100755
index 68cf9f9..0000000
Binary files a/MST/figure/compare_fig.png and /dev/null differ
diff --git a/MST/figure/cst.png b/MST/figure/cst.png
deleted file mode 100755
index cac6cc6..0000000
Binary files a/MST/figure/cst.png and /dev/null differ
diff --git a/MST/figure/cst_mst.png b/MST/figure/cst_mst.png
deleted file mode 100755
index ee7900f..0000000
Binary files a/MST/figure/cst_mst.png and /dev/null differ
diff --git a/MST/figure/dauhst.png b/MST/figure/dauhst.png
deleted file mode 100755
index 7ab9a41..0000000
Binary files a/MST/figure/dauhst.png and /dev/null differ
diff --git a/MST/figure/frame2channel12.gif b/MST/figure/frame2channel12.gif
deleted file mode 100755
index 10608ba..0000000
Binary files a/MST/figure/frame2channel12.gif and /dev/null differ
diff --git a/MST/figure/frame3channel21.gif b/MST/figure/frame3channel21.gif
deleted file mode 100755
index badb431..0000000
Binary files a/MST/figure/frame3channel21.gif and /dev/null differ
diff --git a/MST/figure/frame4channel28.gif b/MST/figure/frame4channel28.gif
deleted file mode 100755
index a90aa47..0000000
Binary files a/MST/figure/frame4channel28.gif and /dev/null differ
diff --git a/MST/figure/frame7channel4.gif b/MST/figure/frame7channel4.gif
deleted file mode 100755
index 3f95906..0000000
Binary files a/MST/figure/frame7channel4.gif and /dev/null differ
diff --git a/MST/figure/logo_MST.png b/MST/figure/logo_MST.png
deleted file mode 100755
index 6498499..0000000
Binary files a/MST/figure/logo_MST.png and /dev/null differ
diff --git a/MST/figure/main.png b/MST/figure/main.png
deleted file mode 100755
index 33f9d24..0000000
Binary files a/MST/figure/main.png and /dev/null differ
diff --git a/MST/figure/mst_pp.png b/MST/figure/mst_pp.png
deleted file mode 100755
index ed2399d..0000000
Binary files a/MST/figure/mst_pp.png and /dev/null differ
diff --git a/MST/figure/ntire.png b/MST/figure/ntire.png
deleted file mode 100755
index 43d891c..0000000
Binary files a/MST/figure/ntire.png and /dev/null differ
diff --git a/MST/figure/pipeline.png b/MST/figure/pipeline.png
deleted file mode 100755
index f95e6e2..0000000
Binary files a/MST/figure/pipeline.png and /dev/null differ
diff --git a/MST/figure/real.png b/MST/figure/real.png
deleted file mode 100755
index f335be7..0000000
Binary files a/MST/figure/real.png and /dev/null differ
diff --git a/MST/figure/robocup_1.png b/MST/figure/robocup_1.png
deleted file mode 100755
index 9e79e38..0000000
Binary files a/MST/figure/robocup_1.png and /dev/null differ
diff --git a/MST/figure/robocup_2.png b/MST/figure/robocup_2.png
deleted file mode 100755
index 38ef009..0000000
Binary files a/MST/figure/robocup_2.png and /dev/null differ
diff --git a/MST/figure/robocup_3.png b/MST/figure/robocup_3.png
deleted file mode 100755
index 7ddad67..0000000
Binary files a/MST/figure/robocup_3.png and /dev/null differ
diff --git a/MST/figure/robocup_cyh.png b/MST/figure/robocup_cyh.png
deleted file mode 100755
index 557f22d..0000000
Binary files a/MST/figure/robocup_cyh.png and /dev/null differ
diff --git a/MST/figure/simulation.png b/MST/figure/simulation.png
deleted file mode 100755
index bf8d642..0000000
Binary files a/MST/figure/simulation.png and /dev/null differ
diff --git a/MST/real/test_code/__pycache__/utils.cpython-36.pyc b/MST/real/test_code/__pycache__/utils.cpython-36.pyc
deleted file mode 100755
index 08c3059..0000000
Binary files a/MST/real/test_code/__pycache__/utils.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/test_code/architecture/ADMM_Net.py b/MST/real/test_code/architecture/ADMM_Net.py
deleted file mode 100755
index 64f61b4..0000000
--- a/MST/real/test_code/architecture/ADMM_Net.py
+++ /dev/null
@@ -1,201 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
-
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
-
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class ADMM_net(nn.Module):
-
- def __init__(self):
- super(ADMM_net, self).__init__()
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma2 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma3 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma4 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma5 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma6 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma7 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma8 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma9 = torch.nn.Parameter(torch.Tensor([0]))
-
- def forward(self, y, input_mask=None, input_mask_s=None):
- if input_mask == None:
- Phi = torch.rand((1, 28, 256, 310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- theta = At(y,Phi)
- b = torch.zeros_like(Phi)
- ### 1-3
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma1),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet1(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma2),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet2(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma3),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet3(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 4-6
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma4),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet4(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma5),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet5(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma6),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet6(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 7-9
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma7),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet7(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma8),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet8(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma9),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet9(x1)
- theta = shift_3d(theta)
- return theta[:, :, :, :384]
diff --git a/MST/real/test_code/architecture/BIRNAT.py b/MST/real/test_code/architecture/BIRNAT.py
deleted file mode 100755
index 3b9fce7..0000000
--- a/MST/real/test_code/architecture/BIRNAT.py
+++ /dev/null
@@ -1,365 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-
-class self_attention(nn.Module):
- def __init__(self, ch):
- super(self_attention, self).__init__()
- self.conv1 = nn.Conv2d(ch, ch // 8, 1)
- self.conv2 = nn.Conv2d(ch, ch // 8, 1)
- self.conv3 = nn.Conv2d(ch, ch, 1)
- self.conv4 = nn.Conv2d(ch, ch, 1)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.ch = ch
-
- def forward(self, x):
- batch_size = x.shape[0]
-
- f = self.conv1(x)
- g = self.conv2(x)
- h = self.conv3(x)
- ht = h.reshape([batch_size, self.ch, -1])
-
- ft = f.reshape([batch_size, self.ch // 8, -1])
- n = torch.matmul(ft.permute([0, 2, 1]), g.reshape([batch_size, self.ch // 8, -1]))
- beta = F.softmax(n, dim=1)
-
- o = torch.matmul(ht, beta)
- o = o.reshape(x.shape) # [bs, C, h, w]
-
- o = self.conv4(o)
-
- x = self.gamma1 * o + x
-
- return x
-
-
-class res_part(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(res_part, self).__init__()
- self.conv1 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv2 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv3 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
-
- def forward(self, x):
- x1 = self.conv1(x)
- x = x1 + x
- x1 = self.conv2(x)
- x = x1 + x
- x1 = self.conv3(x)
- x = x1 + x
- return x
-
-
-class down_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(down_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- # nn.Conv2d(20, 40, 5, stride=2, padding=2),
- # nn.Conv2d(40, out_ch, 5, stride=2, padding=2),
- nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 40, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(40, out_ch, 3, stride=1, padding=1),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-
-class up_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(up_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.ConvTranspose2d(in_ch, 40, 3, stride=2, padding=1, output_padding=1),
- # nn.ConvTranspose2d(40, 20, 3, stride=2, padding=1, output_padding=1),
- nn.Conv2d(in_ch, 40, 3, stride=1, padding=1),
- nn.Conv2d(40, 30, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(30, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- nn.Conv2d(20, out_ch, 1),
- # nn.Sigmoid(),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-class cnn1(nn.Module):
- # 输入meas concat mask
- # 3 下采样
-
- def __init__(self, B):
- super(cnn1, self).__init__()
- self.conv1 = nn.Conv2d(B + 1, 32, kernel_size=5, stride=1, padding=2)
- self.relu1 = nn.LeakyReLU(inplace=True)
- self.conv2 = nn.Conv2d(32, 64, kernel_size=3, stride=1, padding=1)
- self.relu2 = nn.LeakyReLU(inplace=True)
- self.conv3 = nn.Conv2d(64, 64, kernel_size=1, stride=1)
- self.relu3 = nn.LeakyReLU(inplace=True)
- self.conv4 = nn.Conv2d(64, 128, kernel_size=3, stride=2, padding=1)
- self.relu4 = nn.LeakyReLU(inplace=True)
- self.conv5 = nn.ConvTranspose2d(128, 64, kernel_size=3, stride=2, padding=1, output_padding=1)
- self.relu5 = nn.LeakyReLU(inplace=True)
- self.conv51 = nn.Conv2d(64, 32, kernel_size=3, stride=1, padding=1)
- self.relu51 = nn.LeakyReLU(inplace=True)
- self.conv52 = nn.Conv2d(32, 16, kernel_size=1, stride=1)
- self.relu52 = nn.LeakyReLU(inplace=True)
- self.conv6 = nn.Conv2d(16, 1, kernel_size=3, stride=1, padding=1)
- self.res_part1 = res_part(128, 128)
- self.res_part2 = res_part(128, 128)
- self.res_part3 = res_part(128, 128)
- self.conv7 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu7 = nn.LeakyReLU(inplace=True)
- self.conv8 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
- self.conv9 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu9 = nn.LeakyReLU(inplace=True)
- self.conv10 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
-
- self.att1 = self_attention(128)
-
- def forward(self, meas=None, nor_meas=None, PhiTy=None):
- data = torch.cat([torch.unsqueeze(nor_meas, dim=1), PhiTy], dim=1)
- out = self.conv1(data)
-
- out = self.relu1(out)
- out = self.conv2(out)
- out = self.relu2(out)
- out = self.conv3(out)
- out = self.relu3(out)
- out = self.conv4(out)
- out = self.relu4(out)
- out = self.res_part1(out)
- out = self.conv7(out)
- out = self.relu7(out)
- out = self.conv8(out)
- out = self.res_part2(out)
- out = self.conv9(out)
- out = self.relu9(out)
- out = self.conv10(out)
- out = self.res_part3(out)
-
- # out = self.att1(out)
-
- out = self.conv5(out)
- out = self.relu5(out)
- out = self.conv51(out)
- out = self.relu51(out)
- out = self.conv52(out)
- out = self.relu52(out)
- out = self.conv6(out)
-
- return out
-
-
-class forward_rnn(nn.Module):
-
- def __init__(self):
- super(forward_rnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt1, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
- xt = xt1
-
- step = 2
- [bs, nC, row, col] = xt1.shape
-
- out = xt1
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, ii, :, :], out[:, ii, :, :])
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, ii, :, :], torch.squeeze(nor_meas))
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
- out = torch.cat([out, xt], dim=1)
-
- return out, ht
-
-
-class backrnn(nn.Module):
-
- def __init__(self):
- super(backrnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt8, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
-
- step = 2
- [bs, nC, row, col] = xt8.shape
-
- xt = torch.unsqueeze(xt8[:, cs_rate - 1, :, :], 1)
-
- out = torch.zeros(bs, cs_rate, row, col).cuda()
- out[:, cs_rate - 1, :, :] = xt[:, 0, :, :]
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], out[:, cs_rate - 1 - ii, :, :].clone())
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], xt8[:, cs_rate - 1 - ii, :, :].clone())
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
-
- out[:, cs_rate - 2 - i, :, :] = xt[:, 0, :, :]
-
- return out
-
-def shift_gt_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, i, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- if inputs.is_cuda:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- else:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-class BIRNAT(nn.Module):
-
- def __init__(self):
- super(BIRNAT, self).__init__()
- self.cs_rate = 28
- self.first_frame_net = cnn1(self.cs_rate).cuda()
- self.rnn1 = forward_rnn().cuda()
- self.rnn2 = backrnn().cuda()
-
- def gen_meas_torch(self, meas, shift_mask):
- batch_size, H = meas.shape[0:2]
- mask_s = torch.sum(shift_mask, 1)
- nor_meas = torch.div(meas, mask_s)
- temp = torch.mul(torch.unsqueeze(nor_meas, dim=1).expand([batch_size, 28, H, shift_mask.shape[3]]), shift_mask)
- return nor_meas, temp
-
- def forward(self, meas, shift_mask=None, input_mask_s=None):
- if shift_mask==None:
- shift_mask = torch.zeros(1, 28, 256, 310).cuda()
- H, W = meas.shape[-2:]
- nor_meas, PhiTy = self.gen_meas_torch(meas, shift_mask)
- h0 = torch.zeros(meas.shape[0], 20, H, W).cuda()
- xt1 = self.first_frame_net(meas, nor_meas, PhiTy)
- model_out1, h1 = self.rnn1(xt1, meas, nor_meas, PhiTy, shift_mask, h0, self.cs_rate)
- model_out2 = self.rnn2(model_out1, meas, nor_meas, PhiTy, shift_mask, h1, self.cs_rate)
- model_out2 = shift_gt_back(model_out2)
-
- return model_out2
diff --git a/MST/real/test_code/architecture/BiSRNet.py b/MST/real/test_code/architecture/BiSRNet.py
deleted file mode 100755
index 2986689..0000000
--- a/MST/real/test_code/architecture/BiSRNet.py
+++ /dev/null
@@ -1,426 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-import os
-from pdb import set_trace as stx
-
-
-# --------------------------------------------- Binarized Basic Units -----------------------------------------------------------------
-
-
-class LearnableBias(nn.Module):
- def __init__(self, out_chn):
- super(LearnableBias, self).__init__()
- self.bias = nn.Parameter(torch.zeros(1, out_chn, 1, 1), requires_grad=True)
-
- def forward(self, x):
- # stx()
- out = x + self.bias.expand_as(x)
- return out
-
-
-class ReDistribution(nn.Module):
- def __init__(self, out_chn):
- super(ReDistribution, self).__init__()
- self.b = nn.Parameter(torch.zeros(1, out_chn, 1, 1), requires_grad=True)
- self.k = nn.Parameter(torch.ones(1, out_chn, 1, 1), requires_grad=True)
-
- def forward(self, x):
- out = x * self.k.expand_as(x) + self.b.expand_as(x)
- return out
-
-
-class RPReLU(nn.Module):
- def __init__(self, inplanes):
- super(RPReLU, self).__init__()
- self.pr_bias0 = LearnableBias(inplanes)
- self.pr_prelu = nn.PReLU(inplanes)
- self.pr_bias1 = LearnableBias(inplanes)
-
- def forward(self, x):
- x = self.pr_bias1(self.pr_prelu(self.pr_bias0(x)))
- return x
-
-
-class Spectral_Binary_Activation(nn.Module):
- def __init__(self):
- super(Spectral_Binary_Activation, self).__init__()
- self.beta = nn.Parameter(torch.ones(1), requires_grad=True)
-
- def forward(self, x):
- binary_activation_no_grad = torch.sign(x)
- tanh_activation = torch.tanh(x * self.beta)
-
- out = binary_activation_no_grad.detach() - tanh_activation.detach() + tanh_activation
- return out
-
-
-class HardBinaryConv(nn.Conv2d):
- def __init__(self, in_chn, out_chn, kernel_size=3, stride=1, padding=1, groups=1, bias=True):
- super(HardBinaryConv, self).__init__(
- in_chn,
- out_chn,
- kernel_size,
- stride=stride,
- padding=padding,
- groups=groups,
- bias=bias
- )
-
- def forward(self, x):
- real_weights = self.weight
- scaling_factor = torch.mean(torch.mean(torch.mean(abs(real_weights), dim=3, keepdim=True), dim=2, keepdim=True),
- dim=1, keepdim=True)
- scaling_factor = scaling_factor.detach()
- # stx()
- binary_weights_no_grad = scaling_factor * torch.sign(real_weights)
- # stx()
- cliped_weights = torch.clamp(real_weights, -1.0, 1.0)
- binary_weights = binary_weights_no_grad.detach() - cliped_weights.detach() + cliped_weights
- y = F.conv2d(x, binary_weights, self.bias, stride=self.stride, padding=self.padding, groups=self.groups)
-
- return y
-
-
-class BinaryConv2d(nn.Module):
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d, self).__init__()
-
- self.move0 = ReDistribution(in_channels)
- self.binary_activation = Spectral_Binary_Activation()
- self.binary_conv = HardBinaryConv(in_chn=in_channels,
- out_chn=in_channels,
- kernel_size=kernel_size,
- stride=stride,
- padding=padding,
- bias=bias,
- groups=groups)
- self.relu = RPReLU(in_channels)
-
- def forward(self, x):
- out = self.move0(x)
- out = self.binary_activation(out)
- out = self.binary_conv(out)
- out = self.relu(out)
- out = out + x
- return out
-
-
-class BinaryConv2d_Down(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Down, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.avg_pool = nn.AvgPool2d(kernel_size=2, stride=2, padding=0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h/2,w/2
- '''
- out = self.avg_pool(x)
- out_1 = out
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-class BinaryConv2d_Up(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Up, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,2h,2w
- '''
- b, c, h, w = x.shape
- out = F.interpolate(x, scale_factor=2, mode='bilinear')
-
- out_1 = out[:, :c // 2, :, :]
- out_2 = out[:, c // 2:, :, :]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Decrease(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,h,w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Decrease, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,h,w
- '''
- b, c, h, w = x.shape
- out = x
-
- out_1 = out[:, :c // 2, :, :]
- out_2 = out[:, c // 2:, :, :]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Increase(nn.Module):
- '''
- input: b,c,h,w
- output: b,2c,h,w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Increase, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h,w
- '''
- # stx()
- out_1 = x
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-# ---------------------------------------------------------- Binarized UNet------------------------------------------------------
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-def shift_back(inputs, step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256 // row
- step = float(step) / float(down_sample * down_sample)
- out_col = row
- for i in range(nC):
- inputs[:, i, :, :out_col] = \
- inputs[:, i, :, int(step * i):int(step * i) + out_col]
- return inputs[:, :, :, :out_col]
-
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=2):
- super().__init__()
- self.net = nn.Sequential(
- BinaryConv2d_Fusion_Increase(dim, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Increase(dim * mult, dim * mult * mult, 1, 1, bias=False),
- RPReLU(dim * mult * mult),
- BinaryConv2d(dim * mult * mult, dim * mult * mult, 3, 1, 1, bias=False, groups=dim),
- RPReLU(dim * mult * mult),
- BinaryConv2d_Fusion_Decrease(dim * mult * mult, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-
-class BiSRNet_Block(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(
- PreNorm(dim, FeedForward(dim=dim))
- )
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for ff in self.blocks:
- # x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class BiSRNet_body(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2, 4, 4]):
- super(BiSRNet_body, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = BinaryConv2d(in_dim, self.dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- BiSRNet_Block(dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- BinaryConv2d_Down(dim_stage, dim_stage * 2, 3, 1, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = BiSRNet_Block(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- BinaryConv2d_Up(dim_stage, dim_stage // 2, 3, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim_stage, dim_stage // 2, 1, 1, bias=False),
- BiSRNet_Block(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = BinaryConv2d(self.dim, out_dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (BiSRNet_Block, FeaDownSample) in self.encoder_layers:
- # stx()
- fea = BiSRNet_Block(fea)
- fea_encoder.append(fea)
- # stx()
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, BiSRNet_Block) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage - 1 - i]], dim=1))
- fea = BiSRNet_Block(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-class BiSRNet(nn.Module):
- '''
- Only 3 layers are 32-bit conv
- '''
-
- def __init__(self, in_channels=28, out_channels=28, n_feat=28, stage=3, num_blocks=[1, 1, 1]):
- super(BiSRNet, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,
- bias=False) # 1-bit -> 32-bit
- modules_body = [BiSRNet_body(dim=n_feat, stage=2, num_blocks=num_blocks) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True) # 1-bit -> 32-bit
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,
- bias=False) # 1-bit -> 32-bit
-
- def y2x(self, y):
- ## Spilt operator
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- return x
-
- def forward(self, y, input_mask=None, input_mask_s=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.y2x(y)
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
\ No newline at end of file
diff --git a/MST/real/test_code/architecture/CST.py b/MST/real/test_code/architecture/CST.py
deleted file mode 100755
index 14fda4c..0000000
--- a/MST/real/test_code/architecture/CST.py
+++ /dev/null
@@ -1,600 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-from collections import defaultdict, Counter
-import numpy as np
-from tqdm import tqdm
-import random
-
-def uniform(a, b, shape, device='cuda'):
- return (b - a) * torch.rand(shape, device=device) + a
-
-class AsymmetricTransform:
-
- def Q(self, *args, **kwargs):
- raise NotImplementedError('Query transform not implemented')
-
- def K(self, *args, **kwargs):
- raise NotImplementedError('Key transform not implemented')
-
-class LSH:
- def __call__(self, *args, **kwargs):
- raise NotImplementedError('LSH scheme not implemented')
-
- def compute_hash_agreement(self, q_hash, k_hash):
- return (q_hash == k_hash).min(dim=-1)[0].sum(dim=-1)
-
-class XBOXPLUS(AsymmetricTransform):
-
- def set_norms(self, x):
- self.x_norms = x.norm(p=2, dim=-1, keepdim=True)
- self.MX = torch.amax(self.x_norms, dim=-2, keepdim=True)
-
- def X(self, x):
- device = x.device
- ext = torch.sqrt((self.MX**2).to(device) - (self.x_norms**2).to(device))
- zero = torch.tensor(0.0, device=x.device).repeat(x.shape[:-1], 1).unsqueeze(-1)
- return torch.cat((x, ext, zero), -1)
-
-def lsh_clustering(x, n_rounds, r=1):
- salsh = SALSH(n_rounds=n_rounds, dim=x.shape[-1], r=r, device=x.device)
- x_hashed = salsh(x).reshape((n_rounds,) + x.shape[:-1])
- return x_hashed.argsort(dim=-1)
-
-class SALSH(LSH):
- def __init__(self, n_rounds, dim, r, device='cuda'):
- super(SALSH, self).__init__()
- self.alpha = torch.normal(0, 1, (dim, n_rounds), device=device)
- self.beta = uniform(0, r, shape=(1, n_rounds), device=device)
- self.dim = dim
- self.r = r
-
- def __call__(self, vecs):
- projection = vecs @ self.alpha
- projection_shift = projection + self.beta
- projection_rescale = projection_shift / self.r
- return projection_rescale.permute(2, 0, 1)
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
-
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
-
- variance = scale / denom
-
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def batch_scatter(output, src, dim, index):
- """
- :param output: [b,n,c]
- :param src: [b,n,c]
- :param dim: int
- :param index: [b,n]
- :return: output: [b,n,c]
- """
- b,k,c = src.shape
- index = index[:, :, None].expand(-1, -1, c)
- output, src, index = map(lambda t: rearrange(t, 'b k c -> (b c) k'), (output, src, index))
- output.scatter_(dim,index,src)
- output = rearrange(output, '(b c) k -> b k c', b=b)
- return output
-
-def batch_gather(x, index, dim):
- """
- :param x: [b,n,c]
- :param index: [b,n//2]
- :param dim: int
- :return: output: [b,n//2,c]
- """
- b,n,c = x.shape
- index = index[:,:,None].expand(-1,-1,c)
- x, index = map(lambda t: rearrange(t, 'b n c -> (b c) n'), (x, index))
- output = torch.gather(x,dim,index)
- output = rearrange(output, '(b c) n -> b n c', b=b)
- return output
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class SAH_MSA(nn.Module):
- def __init__(self, heads=4, n_rounds=2, channels=64, patch_size=144,
- r=1):
- super(SAH_MSA, self).__init__()
- self.heads = heads
- self.n_rounds = n_rounds
- inner_dim = channels*3
- self.to_q = nn.Linear(channels, inner_dim, bias=False)
- self.to_k = nn.Linear(channels, inner_dim, bias=False)
- self.to_v = nn.Linear(channels, inner_dim, bias=False)
- self.to_out = nn.Linear(inner_dim, channels, bias=False)
-
- self.xbox_plus = XBOXPLUS()
- self.clustering_params = {
- 'r': r,
- 'n_rounds': self.n_rounds
- }
- self.q_attn_size = patch_size[0] * patch_size[1]
- self.k_attn_size = patch_size[0] * patch_size[1]
-
- def forward(self, input):
- """
- :param input: [b,n,c]
- :return: output: [b,n,c]
- """
-
- B, N, C_inp = input.shape
- query = self.to_q(input)
- key = self.to_k(input)
- value = self.to_v(input)
- input_hash = input.view(B, N, self.heads, C_inp//self.heads)
- x_hash = rearrange(input_hash, 'b t h e -> (b h) t e')
- bs, x_seqlen, dim = x_hash.shape
- with torch.no_grad():
- self.xbox_plus.set_norms(x_hash)
- Xs = self.xbox_plus.X(x_hash)
- x_positions = lsh_clustering(Xs, **self.clustering_params)
- x_positions = x_positions.reshape(self.n_rounds, bs, -1)
-
- del Xs
-
- C = query.shape[-1]
- query = query.view(B, N, self.heads, C // self.heads)
- key = key.view(B, N, self.heads, C // self.heads)
- value = value.view(B, N, self.heads, C // self.heads)
-
- query = rearrange(query, 'b t h e -> (b h) t e') # [bs, q_seqlen,c]
- key = rearrange(key, 'b t h e -> (b h) t e')
- value = rearrange(value, 'b s h d -> (b h) s d')
-
- bs, q_seqlen, dim = query.shape
- bs, k_seqlen, dim = key.shape
- v_dim = value.shape[-1]
-
- x_rev_positions = torch.argsort(x_positions, dim=-1)
- x_offset = torch.arange(bs, device=query.device).unsqueeze(-1) * x_seqlen
- x_flat = (x_positions + x_offset).reshape(-1)
-
- s_queries = query.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.q_attn_size, dim)
- s_keys = key.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, dim)
- s_values = value.reshape(-1, v_dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, v_dim)
-
- inner = s_queries @ s_keys.transpose(2, 1)
- norm_factor = 1
- inner = inner / norm_factor
-
- # free memory
- del x_positions
-
- # softmax denominator
- dots_logsumexp = torch.logsumexp(inner, dim=-1, keepdim=True)
- # softmax
- dots = torch.exp(inner - dots_logsumexp)
- # dropout
-
- # n_rounds outs
- bo = (dots @ s_values).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- # undo sort
- x_offset = torch.arange(bs * self.n_rounds, device=query.device).unsqueeze(-1) * x_seqlen
- x_rev_flat = (x_rev_positions.reshape(-1, x_seqlen) + x_offset).reshape(-1)
- o = bo.reshape(-1, v_dim).index_select(0, x_rev_flat).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- slogits = dots_logsumexp.reshape(self.n_rounds, bs, -1)
- logits = torch.gather(slogits, 2, x_rev_positions)
-
- # free memory
- del x_rev_positions
-
- # weighted sum multi-round attention
- probs = torch.exp(logits - torch.logsumexp(logits, dim=0, keepdim=True))
- out = torch.sum(o * probs.unsqueeze(-1), dim=0)
- out = rearrange(out, '(b h) t d -> b t h d', h=self.heads)
- out = out.reshape(B, N, -1)
- out = self.to_out(out)
-
- return out
-
-class SAHAB(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(16, 16),
- heads=8,
- shift_size=0,
- sparse=False
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- self.attn = PreNorm(dim, SAH_MSA(heads=heads, n_rounds=2, r=1, channels=dim, patch_size=patch_size))
- self.ffn = PreNorm(dim, FeedForward(dim=dim))
- self.shift_size = shift_size
- self.patch_size = patch_size
- self.sparse = sparse
-
- def forward(self, x, mask=None):
- """
- x: [b,h,w,c]
- mask: [b,h,w]
- return out: [b,h,w,c]
- """
- b,h,w,c = x.shape
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- mask = torch.roll(mask, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- w_size = self.patch_size
-
- # Split into large patches
- x = rearrange(x, 'b (nh hh) (nw ww) c-> b (nh nw) (hh ww c)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- mask = rearrange(mask, 'b (nh hh) (nw ww) -> b (nh nw) (hh ww)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- N = x.shape[1]
-
- mask = torch.mean(mask,dim=2,keepdim=False) # [b,nh*nw]
- if self.sparse:
- mask_select = mask.topk(mask.shape[1] // 2, dim=1)[1] # [b,nh*nw//2]
- x_select = batch_gather(x, mask_select, 1) # [b,nh*nw//2,hh*ww*c]
- x_select = x_select.reshape(b*N//2,-1,c)
- x_select = self.attn(x_select)+x_select
- x_select = x_select.view(b,N//2,-1)
- x = batch_scatter(x.clone(), x_select, 1, mask_select)
- else:
- x = x.view(b*N,-1,c)
- x = self.attn(x) + x
- x = x.view(b, N, -1)
- x = rearrange(x, 'b (nh nw) (hh ww c) -> b (nh hh) (nw ww) c', nh=h//(w_size[0] * 2), hh=w_size[0] * 2, ww=w_size[1] * 2)
-
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(self.shift_size, self.shift_size), dims=(1, 2))
-
- x = self.ffn(x) + x
-
- return x
-
-
-class SAHABs(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(8, 8),
- heads=8,
- num_blocks=2,
- sparse=False
- ):
- super().__init__()
- blocks = []
- for _ in range(num_blocks):
- blocks.append(
- SAHAB(heads=heads, dim=dim, patch_size=patch_size,sparse=sparse,
- shift_size=0 if (_ % 2 == 0) else patch_size[0]))
- self.blocks = nn.Sequential(*blocks)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,1,h,w]
- return x: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- mask = mask.squeeze(1)
- for block in self.blocks:
- x = block(x, mask)
- x = x.permute(0, 3, 1, 2)
- return x
-
-class ASPPConv(nn.Sequential):
- def __init__(self, in_channels, out_channels, dilation):
- modules = [
- nn.Conv2d(in_channels, out_channels, 3, padding=dilation, dilation=dilation, bias=False),
- nn.ReLU()
- ]
- super(ASPPConv, self).__init__(*modules)
-
-
-class ASPPPooling(nn.Sequential):
- def __init__(self, in_channels, out_channels):
- super(ASPPPooling, self).__init__(
- nn.AdaptiveAvgPool2d(1),
- nn.Conv2d(in_channels, out_channels, 1, bias=False),
- nn.ReLU())
-
- def forward(self, x):
- size = x.shape[-2:]
- for mod in self:
- x = mod(x)
- return F.interpolate(x, size=size, mode='bilinear', align_corners=False)
-
-
-class ASPP(nn.Module):
- def __init__(self, in_channels, atrous_rates, out_channels):
- super(ASPP, self).__init__()
- modules = []
-
- rates = tuple(atrous_rates)
- for rate in rates:
- modules.append(ASPPConv(in_channels, out_channels, rate))
-
- modules.append(ASPPPooling(in_channels, out_channels))
-
- self.convs = nn.ModuleList(modules)
-
- self.project = nn.Sequential(
- nn.Conv2d(len(self.convs) * out_channels, out_channels, 1, bias=False),
- nn.ReLU(),
- nn.Dropout(0.5))
-
- def forward(self, x):
- res = []
- for conv in self.convs:
- res.append(conv(x))
- res = torch.cat(res, dim=1)
- return self.project(res)
-
-class Sparsity_Estimator(nn.Module):
- def __init__(self, dim=28, expand=2, sparse=False):
- super(Sparsity_Estimator, self).__init__()
- self.dim = dim
- self.stage = 2
- self.sparse = sparse
-
- # Input projection
- self.in_proj = nn.Conv2d(28, dim, 1, 1, 0, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(2):
- self.encoder_layers.append(nn.ModuleList([
- nn.Conv2d(dim_stage, dim_stage * expand, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage * expand, dim_stage * expand, 3, 2, 1, bias=False, groups=dim_stage * expand),
- nn.Conv2d(dim_stage * expand, dim_stage*expand, 1, 1, 0, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = ASPP(dim_stage, [3,6], dim_stage)
-
- # Decoder:
- self.decoder_layers = nn.ModuleList([])
- for i in range(2):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage // 2, dim_stage, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage, dim_stage, 3, 1, 1, bias=False, groups=dim_stage),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, 0, bias=False),
- ]))
- dim_stage //= 2
-
- # Output projection
- if sparse:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim+1, 3, 1, 1, bias=False)
- else:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- # Input projection
- fea = self.lrelu(self.in_proj(x))
- # Encoder
- fea_encoder = [] # [c 2c 4c 8c]
- for (Conv1, Conv2, Conv3) in self.encoder_layers:
- fea_encoder.append(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- # Bottleneck
- fea = self.bottleneck(fea)+fea
- # Decoder
- for i, (FeaUpSample, Conv1, Conv2, Conv3) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- fea = fea + fea_encoder[self.stage-1-i]
- # Output projection
- out = self.out_conv2(fea)
- if self.sparse:
- error_map = out[:,-1:,:,:]
- return out[:,:-1], error_map
- return out
-
-class CST(nn.Module):
- def __init__(self, dim=28, stage=2, num_blocks=[2, 2, 2], sparse=False):
- super(CST, self).__init__()
- self.dim = dim
- self.stage = stage
- self.sparse = sparse
-
- # Fution physical mask and shifted measurement
- self.fution = nn.Conv2d(28, 28, 1, 1, 0, bias=False)
-
- # Sparsity Estimator
- if num_blocks==[2,4,6]:
- self.fe = nn.Sequential(Sparsity_Estimator(dim=28,expand=2,sparse=False),
- Sparsity_Estimator(dim=28, expand=2, sparse=sparse))
- else:
- self.fe = Sparsity_Estimator(dim=28, expand=2, sparse=sparse)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- SAHABs(dim=dim_stage, num_blocks=num_blocks[i], heads=dim_stage // dim, sparse=sparse),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.AvgPool2d(kernel_size=2, stride=2),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = SAHABs(
- dim=dim_stage, heads=dim_stage // dim, num_blocks=num_blocks[-1], sparse=sparse)
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- SAHABs(dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i],
- heads=(dim_stage // 2) // dim, sparse=sparse),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.out_proj = nn.Conv2d(self.dim, dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :return: x: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.initial_x(x)
-
- # Feature Extraction
- if self.sparse:
- fea,mask = self.fe(x)
- else:
- fea = self.fe(x)
- mask = torch.randn((b,1,h,w)).cuda()
-
- # Encoder
- fea_encoder = []
- masks = []
- for (Blcok, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = Blcok(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Blcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = fea + fea_encoder[self.stage - 1 - i]
- mask = masks[self.stage - 1 - i]
- fea = Blcok(fea, mask)
-
- # Output projection
- out = self.out_proj(fea) + x
- if self.sparse:
- return out, mask
- return out
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/test_code/architecture/DAUHST.py b/MST/real/test_code/architecture/DAUHST.py
deleted file mode 100755
index bc3f420..0000000
--- a/MST/real/test_code/architecture/DAUHST.py
+++ /dev/null
@@ -1,364 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch import einsum
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-class HS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=28,
- heads=8,
- only_local_branch=False
- ):
- super().__init__()
-
- self.dim = dim
- self.heads = heads
- self.scale = dim_head ** -0.5
- self.window_size = window_size
- self.only_local_branch = only_local_branch
-
- # position embedding
- if only_local_branch:
- seq_l = window_size[0] * window_size[1]
- self.pos_emb = nn.Parameter(torch.Tensor(1, heads, seq_l, seq_l))
- trunc_normal_(self.pos_emb)
- else:
- seq_l1 = window_size[0] * window_size[1]
- self.pos_emb1 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l1, seq_l1))
- h,w = 384//self.heads, 384//self.heads
- seq_l2 = h*w//seq_l1
- self.pos_emb2 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l2, seq_l2))
- trunc_normal_(self.pos_emb1)
- trunc_normal_(self.pos_emb2)
-
- inner_dim = dim_head * heads
- self.to_q = nn.Linear(dim, inner_dim, bias=False)
- self.to_kv = nn.Linear(dim, inner_dim * 2, bias=False)
- self.to_out = nn.Linear(inner_dim, dim)
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x.shape
- w_size = self.window_size
- assert h % w_size[0] == 0 and w % w_size[1] == 0, 'fmap dimensions must be divisible by the window size'
- if self.only_local_branch:
- x_inp = rearrange(x, 'b (h b0) (w b1) c -> (b h w) (b0 b1) c', b0=w_size[0], b1=w_size[1])
- q = self.to_q(x_inp)
- k, v = self.to_kv(x_inp).chunk(2, dim=-1)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.heads), (q, k, v))
- q *= self.scale
- sim = einsum('b h i d, b h j d -> b h i j', q, k)
- sim = sim + self.pos_emb
- attn = sim.softmax(dim=-1)
- out = einsum('b h i j, b h j d -> b h i d', attn, v)
- out = rearrange(out, 'b h n d -> b n (h d)')
- out = self.to_out(out)
- out = rearrange(out, '(b h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- else:
- q = self.to_q(x)
- k, v = self.to_kv(x).chunk(2, dim=-1)
- q1, q2 = q[:,:,:,:c//2], q[:,:,:,c//2:]
- k1, k2 = k[:,:,:,:c//2], k[:,:,:,c//2:]
- v1, v2 = v[:,:,:,:c//2], v[:,:,:,c//2:]
-
- # local branch
- q1, k1, v1 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q1, k1, v1))
- q1, k1, v1 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q1, k1, v1))
- q1 *= self.scale
- sim1 = einsum('b n h i d, b n h j d -> b n h i j', q1, k1)
- sim1 = sim1 + self.pos_emb1
- attn1 = sim1.softmax(dim=-1)
- out1 = einsum('b n h i j, b n h j d -> b n h i d', attn1, v1)
- out1 = rearrange(out1, 'b n h mm d -> b n mm (h d)')
-
- # non-local branch
- q2, k2, v2 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q2, k2, v2))
- q2, k2, v2 = map(lambda t: t.permute(0, 2, 1, 3), (q2.clone(), k2.clone(), v2.clone()))
- q2, k2, v2 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q2, k2, v2))
- q2 *= self.scale
- sim2 = einsum('b n h i d, b n h j d -> b n h i j', q2, k2)
-
- pos_emb2_interp = []
- for i in range(sim2.shape[0]):
- pos_emb2_interp.append(torch.nn.functional.interpolate(self.pos_emb2[i], size=sim2.shape[-2:], mode='bilinear',
- align_corners=False))
- pos_emb2_interp = torch.stack(pos_emb2_interp, dim=0)
- sim2 = sim2 + pos_emb2_interp
- attn2 = sim2.softmax(dim=-1)
- out2 = einsum('b n h i j, b n h j d -> b n h i d', attn2, v2)
- out2 = rearrange(out2, 'b n h mm d -> b n mm (h d)')
- out2 = out2.permute(0, 2, 1, 3)
-
- out = torch.cat([out1,out2],dim=-1).contiguous()
- out = self.to_out(out)
- out = rearrange(out, 'b (h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- return out
-
-class HSAB(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- PreNorm(dim, HS_MSA(dim=dim, window_size=window_size, dim_head=dim_head, heads=heads, only_local_branch=(heads==1))),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class HST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]):
- super(HST, self).__init__()
- self.dim = dim
- self.scales = len(num_blocks)
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_scale = dim
- for i in range(self.scales-1):
- self.encoder_layers.append(nn.ModuleList([
- HSAB(dim=dim_scale, num_blocks=num_blocks[i], dim_head=dim, heads=dim_scale // dim),
- nn.Conv2d(dim_scale, dim_scale * 2, 4, 2, 1, bias=False),
- ]))
- dim_scale *= 2
-
- # Bottleneck
- self.bottleneck = HSAB(dim=dim_scale, dim_head=dim, heads=dim_scale // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(self.scales-1):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_scale, dim_scale // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_scale, dim_scale // 2, 1, 1, bias=False),
- HSAB(dim=dim_scale // 2, num_blocks=num_blocks[self.scales - 2 - i], dim_head=dim,
- heads=(dim_scale // 2) // dim),
- ]))
- dim_scale //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 16, 16
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
-
- # Embedding
- fea = self.embedding(x)
- x = x[:,:28,:,:]
-
- # Encoder
- fea_encoder = []
- for (HSAB, FeaDownSample) in self.encoder_layers:
- fea = HSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, HSAB) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.scales-2-i]], dim=1))
- fea = HSAB(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out[:, :, :h_inp, :w_inp]
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class HyPaNet(nn.Module):
- def __init__(self, in_nc=29, out_nc=8, channel=64):
- super(HyPaNet, self).__init__()
- self.fution = nn.Conv2d(in_nc, channel, 1, 1, 0, bias=True)
- self.down_sample = nn.Conv2d(channel, channel, 3, 2, 1, bias=True)
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.mlp = nn.Sequential(
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, out_nc, 1, padding=0, bias=True),
- nn.Softplus())
- self.relu = nn.ReLU(inplace=True)
- self.out_nc = out_nc
-
- def forward(self, x):
- x = self.down_sample(self.relu(self.fution(x)))
- x = self.avg_pool(x)
- x = self.mlp(x) + 1e-6
- return x[:,:self.out_nc//2,:,:], x[:,self.out_nc//2:,:,:]
-
-class DAUHST(nn.Module):
-
- def __init__(self, num_iterations=1):
- super(DAUHST, self).__init__()
- self.para_estimator = HyPaNet(in_nc=28, out_nc=num_iterations*2)
- self.fution = nn.Conv2d(28, 28, 1, padding=0, bias=True)
- self.num_iterations = num_iterations
- self.denoisers = nn.ModuleList([])
- for _ in range(num_iterations):
- self.denoisers.append(
- HST(in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]),
- )
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :param Phi_PhiT: [b,256,310]
- :return: z_crop: [b,28,256,256]
- """
- x = self.initial_x(x)
- for i in range(self.num_iterations):
- x = self.denoisers[i](x)
- return x[:, :, :, 0:384]
-
diff --git a/MST/real/test_code/architecture/DGSMP.py b/MST/real/test_code/architecture/DGSMP.py
deleted file mode 100755
index cf30aaf..0000000
--- a/MST/real/test_code/architecture/DGSMP.py
+++ /dev/null
@@ -1,322 +0,0 @@
-import torch
-import torch.nn as nn
-from torch.nn.parameter import Parameter
-import torch.nn.functional as F
-
-
-class Resblock(nn.Module):
- def __init__(self, HBW):
- super(Resblock, self).__init__()
- self.block1 = nn.Sequential(nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1))
- self.block2 = nn.Sequential(nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1))
-
- def forward(self, x):
- tem = x
- r1 = self.block1(x)
- out = r1 + tem
- r2 = self.block2(out)
- out = r2 + out
- return out
-
-class Encoding(nn.Module):
- def __init__(self):
- super(Encoding, self).__init__()
- self.E1 = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E2 = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E3 = nn.Sequential(nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E4 = nn.Sequential(nn.Conv2d(in_channels=64, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E5 = nn.Sequential(nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
-
- def forward(self, x):
- ## encoding blocks
- E1 = self.E1(x)
- E2 = self.E2(F.avg_pool2d(E1, kernel_size=2, stride=2))
- E3 = self.E3(F.avg_pool2d(E2, kernel_size=2, stride=2))
- E4 = self.E4(F.avg_pool2d(E3, kernel_size=2, stride=2))
- E5 = self.E5(F.avg_pool2d(E4, kernel_size=2, stride=2))
- return E1, E2, E3, E4, E5
-
-class Decoding(nn.Module):
- def __init__(self, Ch=28, kernel_size=[7,7,7]):
- super(Decoding, self).__init__()
- self.upMode = 'bilinear'
- self.Ch = Ch
- out_channel1 = Ch * kernel_size[0]
- out_channel2 = Ch * kernel_size[1]
- out_channel3 = Ch * kernel_size[2]
- self.D1 = nn.Sequential(nn.Conv2d(in_channels=128+128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D2 = nn.Sequential(nn.Conv2d(in_channels=128+64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D3 = nn.Sequential(nn.Conv2d(in_channels=64+64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D4 = nn.Sequential(nn.Conv2d(in_channels=64+32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
-
- self.w_generator = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=self.Ch, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=self.Ch, out_channels=self.Ch, kernel_size=1, stride=1, padding=0)
- )
-
- self.filter_g_1 = nn.Sequential(nn.Conv2d(64 + 32, out_channel1, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel1, out_channel1, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel1, out_channel1, 1, 1, 0)
- )
-
- self.filter_g_2 = nn.Sequential(nn.Conv2d(64 + 32, out_channel2, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel2, out_channel2, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel2, out_channel2, 1, 1, 0)
- )
-
- self.filter_g_3 = nn.Sequential(nn.Conv2d(64 + 32, out_channel3, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel3, out_channel3, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel3, out_channel3, 1, 1, 0)
- )
-
-
- def forward(self, E1, E2, E3, E4, E5):
- ## decoding blocks
- D1 = self.D1(torch.cat([E4, F.interpolate(E5, scale_factor=2, mode=self.upMode)], dim=1))
- D2 = self.D2(torch.cat([E3, F.interpolate(D1, scale_factor=2, mode=self.upMode)], dim=1))
- D3 = self.D3(torch.cat([E2, F.interpolate(D2, scale_factor=2, mode=self.upMode)], dim=1))
- D4 = self.D4(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
-
- ## estimating the regularization parameters w
- w = self.w_generator(D4)
-
- ## generate 3D filters
- f1 = self.filter_g_1(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- f2 = self.filter_g_2(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- f3 = self.filter_g_3(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- return w, f1, f2, f3
-
-
-class HSI_CS(nn.Module):
- def __init__(self, Ch, stages):
- super(HSI_CS, self).__init__()
- self.Ch = Ch
- self.s = stages
- self.filter_size = [7,7,7] ## 3D filter size
-
- ## The modules for learning the measurement matrix A and A^T
- self.AT = nn.Sequential(nn.Conv2d(Ch, 64, kernel_size=3, stride=1, padding=1), nn.LeakyReLU(),
- Resblock(64), Resblock(64),
- nn.Conv2d(64, Ch, kernel_size=3, stride=1, padding=1), nn.LeakyReLU())
- self.A = nn.Sequential(nn.Conv2d(Ch, 64, kernel_size=3, stride=1, padding=1), nn.LeakyReLU(),
- Resblock(64), Resblock(64),
- nn.Conv2d(64, Ch, kernel_size=3, stride=1, padding=1), nn.LeakyReLU())
-
- ## Encoding blocks
- self.Encoding = Encoding()
-
- ## Decoding blocks
- self.Decoding = Decoding(Ch=self.Ch, kernel_size=self.filter_size)
-
- ## Dense connection
- self.conv = nn.Conv2d(Ch, 32, kernel_size=3, stride=1, padding=1)
- self.Den_con1 = nn.Conv2d(32 , 32, kernel_size=1, stride=1, padding=0)
- self.Den_con2 = nn.Conv2d(32 * 2, 32, kernel_size=1, stride=1, padding=0)
- self.Den_con3 = nn.Conv2d(32 * 3, 32, kernel_size=1, stride=1, padding=0)
- self.Den_con4 = nn.Conv2d(32 * 4, 32, kernel_size=1, stride=1, padding=0)
- # self.Den_con5 = nn.Conv2d(32 * 5, 32, kernel_size=1, stride=1, padding=0)
- # self.Den_con6 = nn.Conv2d(32 * 6, 32, kernel_size=1, stride=1, padding=0)
-
-
- self.delta_0 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_1 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_2 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_3 = Parameter(torch.ones(1), requires_grad=True)
- # self.delta_4 = Parameter(torch.ones(1), requires_grad=True)
- # self.delta_5 = Parameter(torch.ones(1), requires_grad=True)
-
- self._initialize_weights()
- torch.nn.init.normal_(self.delta_0, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_1, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_2, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_3, mean=0.1, std=0.01)
- # torch.nn.init.normal_(self.delta_4, mean=0.1, std=0.01)
- # torch.nn.init.normal_(self.delta_5, mean=0.1, std=0.01)
-
-
- def _initialize_weights(self):
- for m in self.modules():
- if isinstance(m, nn.Conv2d):
- nn.init.xavier_normal_(m.weight.data)
- nn.init.constant_(m.bias.data, 0.0)
- elif isinstance(m, nn.Linear):
- nn.init.xavier_normal_(m.weight.data)
- nn.init.constant_(m.bias.data, 0.0)
-
-
- def Filtering_1(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube, [self.filter_size[0] // 2, self.filter_size[0] // 2, 0, 0], mode='replicate')
- img_stack = []
- for i in range(self.filter_size[0]):
- img_stack.append(cube_pad[:, :, :, i:i + width])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def Filtering_2(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube, [0, 0, self.filter_size[1] // 2, self.filter_size[1] // 2], mode='replicate')
- img_stack = []
- for i in range(self.filter_size[1]):
- img_stack.append(cube_pad[:, :, i:i + height, :])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def Filtering_3(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube.unsqueeze(0).unsqueeze(0), pad=(0, 0, 0, 0, self.filter_size[2] // 2, self.filter_size[2] // 2)).squeeze(0).squeeze(0)
- img_stack = []
- for i in range(self.filter_size[2]):
- img_stack.append(cube_pad[:, i:i + bandwidth, :, :])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def recon(self, res1, res2, Xt, i):
- if i == 0 :
- delta = self.delta_0
- elif i == 1:
- delta = self.delta_1
- elif i == 2:
- delta = self.delta_2
- elif i == 3:
- delta = self.delta_3
- # elif i == 4:
- # delta = self.delta_4
- # elif i == 5:
- # delta = self.delta_5
-
- Xt = Xt - 2 * delta * (res1 + res2)
- return Xt
-
- def y2x(self, y):
- ## Spilt operator
- sz = y.size()
- if len(sz) == 3:
- y = y.unsqueeze(1)
- bs = sz[0]
- sz = y.size()
- x = torch.zeros([bs, 28, sz[2], sz[2]]).cuda()
- for t in range(28):
- temp = y[:, :, :, 0 + 2 * t : sz[2] + 2 * t]
-
- x[:, t, :, :] = temp.squeeze(1)
- return x
-
- def x2y(self, x):
- ## Shift and Sum operator
- sz = x.size()
- if len(sz) == 3:
- x = x.unsqueeze(0).unsqueeze(0)
- bs = 1
- else:
- bs = sz[0]
- sz = x.size()
- y = torch.zeros([bs, sz[2], sz[2]+2*27]).cuda()
- for t in range(28):
- y[:, :, 0 + 2 * t : sz[2] + 2 * t] = x[:, t, :, :] + y[:, :, 0 + 2 * t : sz[2] + 2 * t]
- return y
-
- def forward(self, y, input_mask=None, input_mask_s=None):
- ## The measurements y is split into a 3D data cube of size H × W × L to initialize x.
- y = y / 28 * 2
- Xt = self.y2x(y)
- feature_list = []
-
- for i in range(0, self.s):
- AXt = self.x2y(self.A(Xt)) # y = Ax
- Res1 = self.AT(self.y2x(AXt - y)) # A^T * (Ax − y)
-
- fea = self.conv(Xt)
-
- if i == 0:
- feature_list.append(fea)
- fufea = self.Den_con1(fea)
- elif i == 1:
- feature_list.append(fea)
- fufea = self.Den_con2(torch.cat(feature_list, 1))
- elif i == 2:
- feature_list.append(fea)
- fufea = self.Den_con3(torch.cat(feature_list, 1))
- elif i == 3:
- feature_list.append(fea)
- fufea = self.Den_con4(torch.cat(feature_list, 1))
- # elif i == 4:
- # feature_list.append(fea)
- # fufea = self.Den_con5(torch.cat(feature_list, 1))
- # elif i == 5:
- # feature_list.append(fea)
- # fufea = self.Den_con6(torch.cat(feature_list, 1))
-
- E1, E2, E3, E4, E5 = self.Encoding(fufea)
- W, f1, f2, f3 = self.Decoding(E1, E2, E3, E4, E5)
-
- batch_size, p, height, width = f1.size()
- f1 = F.normalize(f1.view(batch_size, self.filter_size[0], self.Ch, height, width),dim=1)
- batch_size, p, height, width = f2.size()
- f2 = F.normalize(f2.view(batch_size, self.filter_size[1], self.Ch, height, width),dim=1)
- batch_size, p, height, width = f3.size()
- f3 = F.normalize(f3.view(batch_size, self.filter_size[2], self.Ch, height, width),dim=1)
-
- ## Estimating the local means U
- u1 = self.Filtering_1(Xt, f1)
- u2 = self.Filtering_2(u1, f2)
- U = self.Filtering_3(u2, f3)
-
- ## w * (x − u)
- Res2 = (Xt - U).mul(W)
-
- ## Reconstructing HSIs
- Xt = self.recon(Res1, Res2, Xt, i)
-
- return Xt
diff --git a/MST/real/test_code/architecture/GAP_Net.py b/MST/real/test_code/architecture/GAP_Net.py
deleted file mode 100755
index 687b775..0000000
--- a/MST/real/test_code/architecture/GAP_Net.py
+++ /dev/null
@@ -1,189 +0,0 @@
-import torch.nn.functional as F
-import torch
-import torch.nn as nn
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- # nn.Conv2d(64, 64, (1,2), padding=(0,1)),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-
-class DoubleConv(nn.Module):
- """(convolution => [BN] => ReLU) * 2"""
-
- def __init__(self, in_channels, out_channels, mid_channels=None):
- super().__init__()
- if not mid_channels:
- mid_channels = out_channels
- self.double_conv = nn.Sequential(
- nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(mid_channels),
- nn.ReLU(inplace=True),
- nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(out_channels),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- return self.double_conv(x)
-
-class GAP_net(nn.Module):
-
- def __init__(self):
- super(GAP_net, self).__init__()
-
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
-
- def forward(self, y, input_mask=None, input_mask_s=None):
- if input_mask==None:
- Phi = torch.rand((1,28,256,310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask, input_mask_s
- x_list = []
- x = At(y, Phi) # v0=H^T y
- ### 1-3
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet1(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet2(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet3(x)
- x = shift_3d(x)
- ### 4-6
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet4(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet5(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet6(x)
- x = shift_3d(x)
- # ### 7-9
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet7(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet8(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet9(x)
- x = shift_3d(x)
- return x[:, :, :, :384]
\ No newline at end of file
diff --git a/MST/real/test_code/architecture/HDNet.py b/MST/real/test_code/architecture/HDNet.py
deleted file mode 100755
index 6820558..0000000
--- a/MST/real/test_code/architecture/HDNet.py
+++ /dev/null
@@ -1,390 +0,0 @@
-import torch
-import torch.nn as nn
-import math
-
-def default_conv(in_channels, out_channels, kernel_size, bias=True):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias)
-
-class MeanShift(nn.Conv2d):
- def __init__(
- self, rgb_range,
- rgb_mean=(0.4488, 0.4371, 0.4040), rgb_std=(1.0, 1.0, 1.0), sign=-1):
-
- super(MeanShift, self).__init__(3, 3, kernel_size=1)
- std = torch.Tensor(rgb_std)
- self.weight.data = torch.eye(3).view(3, 3, 1, 1) / std.view(3, 1, 1, 1)
- self.bias.data = sign * rgb_range * torch.Tensor(rgb_mean) / std
- for p in self.parameters():
- p.requires_grad = False
-
-class BasicBlock(nn.Sequential):
- def __init__(
- self, conv, in_channels, out_channels, kernel_size, stride=1, bias=False,
- bn=True, act=nn.ReLU(True)):
-
- m = [conv(in_channels, out_channels, kernel_size, bias=bias)]
- if bn:
- m.append(nn.BatchNorm2d(out_channels))
- if act is not None:
- m.append(act)
-
- super(BasicBlock, self).__init__(*m)
-
-class ResBlock(nn.Module):
- def __init__(
- self, conv, n_feats, kernel_size,
- bias=True, bn=False, act=nn.ReLU(True), res_scale=1):
-
- super(ResBlock, self).__init__()
- m = []
- for i in range(2):
- m.append(conv(n_feats, n_feats, kernel_size, bias=bias))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if i == 0:
- m.append(act)
-
- self.body = nn.Sequential(*m)
- self.res_scale = res_scale
-
- def forward(self, x):
- res = self.body(x).mul(self.res_scale) # So res_scale is a scaler? just scale all elements in each feature's residual? Why?
- res += x
-
- return res
-
-class Upsampler(nn.Sequential):
- def __init__(self, conv, scale, n_feats, bn=False, act=False, bias=True):
-
- m = []
- if (scale & (scale - 1)) == 0:
- for _ in range(int(math.log(scale, 2))):
- m.append(conv(n_feats, 4 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(2))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
-
- elif scale == 3:
- m.append(conv(n_feats, 9 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(3))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
- else:
- raise NotImplementedError
-
- super(Upsampler, self).__init__(*m)
-
-_NORM_BONE = False
-
-def constant_init(module, val, bias=0):
- if hasattr(module, 'weight') and module.weight is not None:
- nn.init.constant_(module.weight, val)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-
-def kaiming_init(module,
- a=0,
- mode='fan_out',
- nonlinearity='relu',
- bias=0,
- distribution='normal'):
- assert distribution in ['uniform', 'normal']
- if distribution == 'uniform':
- nn.init.kaiming_uniform_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- else:
- nn.init.kaiming_normal_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-# depthwise-separable convolution (DSC)
-class DSC(nn.Module):
-
- def __init__(self, nin: int) -> None:
- super(DSC, self).__init__()
- self.conv_dws = nn.Conv2d(
- nin, nin, kernel_size=1, stride=1, padding=0, groups=nin
- )
- self.bn_dws = nn.BatchNorm2d(nin, momentum=0.9)
- self.relu_dws = nn.ReLU(inplace=False)
-
- self.maxpool = nn.MaxPool2d(kernel_size=3, stride=1, padding=1)
-
- self.conv_point = nn.Conv2d(
- nin, 1, kernel_size=1, stride=1, padding=0, groups=1
- )
- self.bn_point = nn.BatchNorm2d(1, momentum=0.9)
- self.relu_point = nn.ReLU(inplace=False)
-
- self.softmax = nn.Softmax(dim=2)
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- out = self.conv_dws(x)
- out = self.bn_dws(out)
- out = self.relu_dws(out)
-
- out = self.maxpool(out)
-
- out = self.conv_point(out)
- out = self.bn_point(out)
- out = self.relu_point(out)
-
- m, n, p, q = out.shape
- out = self.softmax(out.view(m, n, -1))
- out = out.view(m, n, p, q)
-
- out = out.expand(x.shape[0], x.shape[1], x.shape[2], x.shape[3])
-
- out = torch.mul(out, x)
-
- out = out + x
-
- return out
-
-# Efficient Feature Fusion(EFF)
-class EFF(nn.Module):
- def __init__(self, nin: int, nout: int, num_splits: int) -> None:
- super(EFF, self).__init__()
-
- assert nin % num_splits == 0
-
- self.nin = nin
- self.nout = nout
- self.num_splits = num_splits
- self.subspaces = nn.ModuleList(
- [DSC(int(self.nin / self.num_splits)) for i in range(self.num_splits)]
- )
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- sub_feat = torch.chunk(x, self.num_splits, dim=1)
- out = []
- for idx, l in enumerate(self.subspaces):
- out.append(self.subspaces[idx](sub_feat[idx]))
- out = torch.cat(out, dim=1)
-
- return out
-
-
-# spatial-spectral domain attention learning(SDL)
-class SDL_attention(nn.Module):
- def __init__(self, inplanes, planes, kernel_size=1, stride=1):
- super(SDL_attention, self).__init__()
-
- self.inplanes = inplanes
- self.inter_planes = planes // 2
- self.planes = planes
- self.kernel_size = kernel_size
- self.stride = stride
- self.padding = (kernel_size-1)//2
-
- self.conv_q_right = nn.Conv2d(self.inplanes, 1, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_v_right = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_up = nn.Conv2d(self.inter_planes, self.planes, kernel_size=1, stride=1, padding=0, bias=False)
- self.softmax_right = nn.Softmax(dim=2)
- self.sigmoid = nn.Sigmoid()
-
- self.conv_q_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #g
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.conv_v_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #theta
- self.softmax_left = nn.Softmax(dim=2)
-
- self.reset_parameters()
-
- def reset_parameters(self):
- kaiming_init(self.conv_q_right, mode='fan_in')
- kaiming_init(self.conv_v_right, mode='fan_in')
- kaiming_init(self.conv_q_left, mode='fan_in')
- kaiming_init(self.conv_v_left, mode='fan_in')
-
- self.conv_q_right.inited = True
- self.conv_v_right.inited = True
- self.conv_q_left.inited = True
- self.conv_v_left.inited = True
- # HR spatial attention
- def spatial_attention(self, x):
- input_x = self.conv_v_right(x)
- batch, channel, height, width = input_x.size()
-
- input_x = input_x.view(batch, channel, height * width)
- context_mask = self.conv_q_right(x)
- context_mask = context_mask.view(batch, 1, height * width)
- context_mask = self.softmax_right(context_mask)
-
- context = torch.matmul(input_x, context_mask.transpose(1,2))
- context = context.unsqueeze(-1)
- context = self.conv_up(context)
-
- mask_ch = self.sigmoid(context)
-
- out = x * mask_ch
-
- return out
- # HR spectral attention
- def spectral_attention(self, x):
-
- g_x = self.conv_q_left(x)
- batch, channel, height, width = g_x.size()
-
- avg_x = self.avg_pool(g_x)
- batch, channel, avg_x_h, avg_x_w = avg_x.size()
-
- avg_x = avg_x.view(batch, channel, avg_x_h * avg_x_w).permute(0, 2, 1)
- theta_x = self.conv_v_left(x).view(batch, self.inter_planes, height * width)
- context = torch.matmul(avg_x, theta_x)
- context = self.softmax_left(context)
- context = context.view(batch, 1, height, width)
-
- mask_sp = self.sigmoid(context)
-
- out = x * mask_sp
-
- return out
-
- def forward(self, x):
- context_spectral = self.spectral_attention(x)
- context_spatial = self.spatial_attention(x)
- out = context_spatial + context_spectral
- return out
-
-
-class HDNet(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28, conv=default_conv):
- super(HDNet, self).__init__()
-
- n_resblocks = 16
- n_feats = 64
- kernel_size = 3
- act = nn.ReLU(True)
-
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- # define head module
- m_head = [conv(in_ch, n_feats, kernel_size)]
-
- # define body module
- m_body = [
- ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ) for _ in range(n_resblocks)
- ]
- m_body.append(SDL_attention(inplanes = n_feats, planes = n_feats))
- m_body.append(EFF(nin=n_feats, nout=n_feats, num_splits=4))
-
- for i in range(1, n_resblocks):
- m_body.append(ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ))
-
- m_body.append(conv(n_feats, n_feats, kernel_size))
-
- m_tail = [conv(n_feats, out_ch, kernel_size)]
-
- self.head = nn.Sequential(*m_head)
- self.body = nn.Sequential(*m_body)
- self.tail = nn.Sequential(*m_tail)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
-
- x = self.initial_x(x)
-
- x = self.head(x)
-
- res = self.body(x)
- res += x
-
- x = self.tail(res)
-
- return x
-
-# frequency domain learning(FDL)
-class FDL(nn.Module):
- def __init__(self, loss_weight=1.0, alpha=1.0, patch_factor=1, ave_spectrum=False, log_matrix=False, batch_matrix=False):
- super(FDL, self).__init__()
- self.loss_weight = loss_weight
- self.alpha = alpha
- self.patch_factor = patch_factor
- self.ave_spectrum = ave_spectrum
- self.log_matrix = log_matrix
- self.batch_matrix = batch_matrix
-
- def tensor2freq(self, x):
- patch_factor = self.patch_factor
- _, _, h, w = x.shape
- assert h % patch_factor == 0 and w % patch_factor == 0, (
- 'Patch factor should be divisible by image height and width')
- patch_list = []
- patch_h = h // patch_factor
- patch_w = w // patch_factor
- for i in range(patch_factor):
- for j in range(patch_factor):
- patch_list.append(x[:, :, i * patch_h:(i + 1) * patch_h, j * patch_w:(j + 1) * patch_w])
-
- y = torch.stack(patch_list, 1)
-
- return torch.rfft(y, 2, onesided=False, normalized=True)
-
- def loss_formulation(self, recon_freq, real_freq, matrix=None):
- if matrix is not None:
- weight_matrix = matrix.detach()
- else:
- matrix_tmp = (recon_freq - real_freq) ** 2
- matrix_tmp = torch.sqrt(matrix_tmp[..., 0] + matrix_tmp[..., 1]) ** self.alpha
- if self.log_matrix:
- matrix_tmp = torch.log(matrix_tmp + 1.0)
-
- if self.batch_matrix:
- matrix_tmp = matrix_tmp / matrix_tmp.max()
- else:
- matrix_tmp = matrix_tmp / matrix_tmp.max(-1).values.max(-1).values[:, :, :, None, None]
-
- matrix_tmp[torch.isnan(matrix_tmp)] = 0.0
- matrix_tmp = torch.clamp(matrix_tmp, min=0.0, max=1.0)
- weight_matrix = matrix_tmp.clone().detach()
-
- assert weight_matrix.min().item() >= 0 and weight_matrix.max().item() <= 1, (
- 'The values of spectrum weight matrix should be in the range [0, 1], '
- 'but got Min: %.10f Max: %.10f' % (weight_matrix.min().item(), weight_matrix.max().item()))
-
- tmp = (recon_freq - real_freq) ** 2
- freq_distance = tmp[..., 0] + tmp[..., 1]
-
- loss = weight_matrix * freq_distance
- return torch.mean(loss)
-
- def forward(self, pred, target, matrix=None, **kwargs):
-
- pred_freq = self.tensor2freq(pred)
- target_freq = self.tensor2freq(target)
-
- if self.ave_spectrum:
- pred_freq = torch.mean(pred_freq, 0, keepdim=True)
- target_freq = torch.mean(target_freq, 0, keepdim=True)
-
- return self.loss_formulation(pred_freq, target_freq, matrix) * self.loss_weight
diff --git a/MST/real/test_code/architecture/Lambda_Net.py b/MST/real/test_code/architecture/Lambda_Net.py
deleted file mode 100755
index 44017bf..0000000
--- a/MST/real/test_code/architecture/Lambda_Net.py
+++ /dev/null
@@ -1,180 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-
-class LambdaNetAttention(nn.Module):
- def __init__(
- self,
- dim,
- ):
- super().__init__()
-
- self.dim = dim
- self.to_q = nn.Linear(dim, dim//8, bias=False)
- self.to_k = nn.Linear(dim, dim//8, bias=False)
- self.to_v = nn.Linear(dim, dim, bias=False)
- self.rescale = (dim//8)**-0.5
- self.gamma = nn.Parameter(torch.ones(1))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0,2,3,1)
- b, h, w, c = x.shape
-
- # Reshape to (B,N,C), where N = window_size[0]*window_size[1] is the length of sentence
- x_inp = rearrange(x, 'b h w c -> b (h w) c')
-
- # produce query, key and value
- q = self.to_q(x_inp)
- k = self.to_k(x_inp)
- v = self.to_v(x_inp)
-
- # attention
- sim = einsum('b i d, b j d -> b i j', q, k)*self.rescale
- attn = sim.softmax(dim=-1)
-
- # aggregate
- out = einsum('b i j, b j d -> b i d', attn, v)
-
- # merge blocks back to original feature map
- out = rearrange(out, 'b (h w) c -> b h w c', h=h, w=w)
- out = self.gamma*out + x
- return out.permute(0,3,1,2)
-
-class triple_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(triple_conv, self).__init__()
- self.t_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.t_conv(x)
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class Lambda_Net(nn.Module):
-
- def __init__(self, out_ch=28):
- super(Lambda_Net, self).__init__()
- self.conv_in = nn.Conv2d(1+28, 28, 3, padding=1)
-
- # encoder
- self.conv_down1 = triple_conv(28, 32)
- self.conv_down2 = triple_conv(32, 64)
- self.conv_down3 = triple_conv(64, 128)
- self.conv_down4 = triple_conv(128, 256)
- self.conv_down5 = double_conv(256, 512)
- self.conv_down6 = double_conv(512, 1024)
-
- self.maxpool = nn.MaxPool2d(2)
-
- # decoder
- self.upsample5 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
- self.upsample4 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
- self.upsample3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
- self.upsample2 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
- self.upsample1 = nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2)
-
- self.conv_up1 = triple_conv(32+32, 32)
- self.conv_up2 = triple_conv(64+64, 64)
- self.conv_up3 = triple_conv(128+128, 128)
- self.conv_up4 = triple_conv(256+256, 256)
- self.conv_up5 = double_conv(512+512, 512)
-
- # attention
- self.attention = LambdaNetAttention(dim=128)
-
- self.conv_last1 = nn.Conv2d(32, 6, 3,1,1)
- self.conv_last2 = nn.Conv2d(38, 32, 3,1,1)
- self.conv_last3 = nn.Conv2d(32, 12, 3,1,1)
- self.conv_last4 = nn.Conv2d(44, 32, 3,1,1)
- self.conv_last5 = nn.Conv2d(32, out_ch, 1)
- self.act = nn.ReLU()
-
- def forward(self, x, input_mask=None, input_mask_s=None):
- if input_mask == None:
- input_mask = torch.zeros((1,28,256,310)).cuda()
- x = x/28*2
- x = self.conv_in(torch.cat([x.unsqueeze(1), input_mask], dim=1))
- b, c, h_inp, w_inp = x.shape
- hb, wb = 32, 32
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- res0 = x
- conv1 = self.conv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.conv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.conv_down3(x)
- x = self.maxpool(conv3)
- conv4 = self.conv_down4(x)
- x = self.maxpool(conv4)
- conv5 = self.conv_down5(x)
- x = self.maxpool(conv5)
- conv6 = self.conv_down6(x)
-
- x = self.upsample5(conv6)
- x = torch.cat([x, conv5], dim=1)
- x = self.conv_up5(x)
-
- x = self.upsample4(x)
- x = torch.cat([x, conv4], dim=1)
- x = self.conv_up4(x)
-
- x = self.upsample3(x)
- x = torch.cat([x, conv3], dim=1)
- x = self.conv_up3(x)
- x = self.attention(x)
-
- x = self.upsample2(x)
- x = torch.cat([x, conv2], dim=1)
- x = self.conv_up2(x)
-
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
- x = self.conv_up1(x)
-
- res1 = x
- out1 = self.act(self.conv_last1(x))
- x = self.conv_last2(torch.cat([res1,out1],dim=1))
-
- res2 = x
- out2 = self.act(self.conv_last3(x))
- out3 = self.conv_last4(torch.cat([res2, out2], dim=1))
-
- out = self.conv_last5(out3)+res0
- out = out[:, :, :h_inp, :w_inp]
-
- return shift_back_3d(out)[:, :, :, :384]
-
diff --git a/MST/real/test_code/architecture/MST.py b/MST/real/test_code/architecture/MST.py
deleted file mode 100755
index 07f1e8e..0000000
--- a/MST/real/test_code/architecture/MST.py
+++ /dev/null
@@ -1,294 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class MST(nn.Module):
- def __init__(self, dim=28, stage=3, num_blocks=[2,2,2]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(28, self.dim, 3, 1, 1, bias=False)
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, 28, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.initial_x(x)
-
- # Embedding
- fea = self.lrelu(self.embedding(x))
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/test_code/architecture/MST_Plus_Plus.py b/MST/real/test_code/architecture/MST_Plus_Plus.py
deleted file mode 100755
index 051c737..0000000
--- a/MST/real/test_code/architecture/MST_Plus_Plus.py
+++ /dev/null
@@ -1,324 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- v = v
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class MST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-class MST_Plus_Plus(nn.Module):
- def __init__(self, in_channels=3, out_channels=28, n_feat=28, stage=3):
- super(MST_Plus_Plus, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False)
- modules_body = [MST(dim=n_feat, stage=2, num_blocks=[1,1,1]) for _ in range(stage)]
- self.fution = nn.Conv2d(28, 28, 1, padding=0, bias=True)
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- x = self.initial_x(x)
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/test_code/architecture/TSA_Net.py b/MST/real/test_code/architecture/TSA_Net.py
deleted file mode 100755
index 212595b..0000000
--- a/MST/real/test_code/architecture/TSA_Net.py
+++ /dev/null
@@ -1,350 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-import numpy as np
-_NORM_BONE = False
-
-
-def conv_block(in_planes, out_planes, the_kernel=3, the_stride=1, the_padding=1, flag_norm=False, flag_norm_act=True):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=the_kernel, stride=the_stride, padding=the_padding)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_planes)
- if flag_norm:
- return nn.Sequential(conv,norm,activation) if flag_norm_act else nn.Sequential(conv,activation,norm)
- else:
- return nn.Sequential(conv,activation)
-
-def conv1x1_block(in_planes, out_planes, flag_norm=False):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=1, stride=1, padding=0,bias=False)
- norm = nn.BatchNorm2d(out_planes)
- return nn.Sequential(conv,norm) if flag_norm else conv
-
-def fully_block(in_dim, out_dim, flag_norm=False, flag_norm_act=True):
- fc = nn.Linear(in_dim, out_dim)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_dim)
- if flag_norm:
- return nn.Sequential(fc,norm,activation) if flag_norm_act else nn.Sequential(fc,activation,norm)
- else:
- return nn.Sequential(fc,activation)
-
-class Res2Net(nn.Module):
- def __init__(self, inChannel, uPlane, scale=4):
- super(Res2Net, self).__init__()
- self.uPlane = uPlane
- self.scale = scale
-
- self.conv_init = nn.Conv2d(inChannel, uPlane * scale, kernel_size=1, bias=False)
- self.bn_init = nn.BatchNorm2d(uPlane * scale)
-
- convs = []
- bns = []
- for i in range(self.scale - 1):
- convs.append(nn.Conv2d(self.uPlane, self.uPlane, kernel_size=3, stride=1, padding=1, bias=False))
- bns.append(nn.BatchNorm2d(self.uPlane))
- self.convs = nn.ModuleList(convs)
- self.bns = nn.ModuleList(bns)
-
- self.conv_end = nn.Conv2d(uPlane * scale, inChannel, kernel_size=1, bias=False)
- self.bn_end = nn.BatchNorm2d(inChannel)
-
- self.relu = nn.ReLU(inplace=True)
-
- def forward(self, x):
-
- out = self.conv_init(x)
- out = self.bn_init(out)
- out = self.relu(out)
-
- spx = torch.split(out, self.uPlane, 1)
- for i in range(self.scale - 1):
- if i == 0:
- sp = spx[i]
- else:
- sp = sp + spx[i]
- sp = self.convs[i](sp)
- sp = self.relu(self.bns[i](sp))
- if i == 0:
- out = sp
- else:
- out = torch.cat((out, sp), 1)
- out = torch.cat((out, spx[self.scale - 1]), 1)
-
- out = self.conv_end(out)
- out = self.bn_end(out)
- return out
-
-_NORM_ATTN = True
-_NORM_FC = False
-
-
-class TSA_Transform(nn.Module):
- """ Spectral-Spatial Self-Attention """
-
- def __init__(self, uSpace, inChannel, outChannel, nHead, uAttn, mode=[0, 1], flag_mask=False, gamma_learn=False):
- super(TSA_Transform, self).__init__()
- ''' ------------------------------------------
- uSpace:
- uHeight: the [-2] dim of the 3D tensor
- uWidth: the [-1] dim of the 3D tensor
- inChannel:
- the number of Channel of the input tensor
- outChannel:
- the number of Channel of the output tensor
- nHead:
- the number of Head of the input tensor
- uAttn:
- uSpatial: the dim of the spatial features
- uSpectral: the dim of the spectral features
- mask:
- The Spectral Smoothness Mask
- {mode} and {gamma_learn} is just for variable selection
- ------------------------------------------ '''
-
- self.nHead = nHead
- self.uAttn = uAttn
- self.outChannel = outChannel
- self.uSpatial = nn.Parameter(torch.tensor(float(uAttn[0])), requires_grad=False)
- self.uSpectral = nn.Parameter(torch.tensor(float(uAttn[1])), requires_grad=False)
- self.mask = nn.Parameter(Spectral_Mask(outChannel), requires_grad=False) if flag_mask else None
- self.attn_scale = nn.Parameter(torch.tensor(1.1), requires_grad=False) if flag_mask else None
- self.gamma = nn.Parameter(torch.tensor(1.0), requires_grad=gamma_learn)
-
- if sum(mode) > 0:
- down_sample = []
- scale = 1
- cur_channel = outChannel
- for i in range(sum(mode)):
- scale *= 2
- down_sample.append(conv_block(cur_channel, 2 * cur_channel, 3, 2, 1, _NORM_ATTN))
- cur_channel = 2 * cur_channel
- self.cur_channel = cur_channel
- self.down_sample = nn.Sequential(*down_sample)
- self.up_sample = nn.ConvTranspose2d(outChannel * scale, outChannel, scale, scale)
- else:
- self.down_sample = None
- self.up_sample = None
-
- spec_dim = int(uSpace[0] / 4 - 3) * int(uSpace[1] / 4 - 3)
- self.preproc = conv1x1_block(inChannel, outChannel, _NORM_ATTN)
- self.query_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.query_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.query_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.key_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.key_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.key_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.value = conv1x1_block(outChannel, nHead * outChannel, _NORM_ATTN)
- self.aggregation = nn.Linear(nHead * outChannel, outChannel)
-
- def forward(self, image):
- feat = self.preproc(image)
- feat_qx = self.query_x(feat, 'X')
- feat_qy = self.query_y(feat, 'Y')
- feat_qlambda = self.query_lambda(feat)
- feat_kx = self.key_x(feat, 'X')
- feat_ky = self.key_y(feat, 'Y')
- feat_klambda = self.key_lambda(feat)
- feat_value = self.value(feat)
-
- feat_qx = torch.cat(torch.split(feat_qx, 1, dim=1)).squeeze(dim=1)
- feat_qy = torch.cat(torch.split(feat_qy, 1, dim=1)).squeeze(dim=1)
- feat_kx = torch.cat(torch.split(feat_kx, 1, dim=1)).squeeze(dim=1)
- feat_ky = torch.cat(torch.split(feat_ky, 1, dim=1)).squeeze(dim=1)
- feat_qlambda = torch.cat(torch.split(feat_qlambda, self.uAttn[1], dim=-1))
- feat_klambda = torch.cat(torch.split(feat_klambda, self.uAttn[1], dim=-1))
- feat_value = torch.cat(torch.split(feat_value, self.outChannel, dim=1))
-
- energy_x = torch.bmm(feat_qx, feat_kx.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_y = torch.bmm(feat_qy, feat_ky.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_lambda = torch.bmm(feat_qlambda, feat_klambda.permute(0, 2, 1)) / torch.sqrt(self.uSpectral)
-
- attn_x = F.softmax(energy_x, dim=-1)
- attn_y = F.softmax(energy_y, dim=-1)
- attn_lambda = F.softmax(energy_lambda, dim=-1)
- if self.mask is not None:
- attn_lambda = (attn_lambda + self.mask) / torch.sqrt(self.attn_scale)
-
- pro_feat = feat_value if self.down_sample is None else self.down_sample(feat_value)
- batchhead, dim_c, dim_x, dim_y = pro_feat.size()
- attn_x_repeat = attn_x.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_x, dim_x)
- attn_y_repeat = attn_y.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_y, dim_y)
- pro_feat = pro_feat.view(-1, dim_x, dim_y)
- pro_feat = torch.bmm(pro_feat, attn_y_repeat.permute(0, 2, 1))
- pro_feat = torch.bmm(pro_feat.permute(0, 2, 1), attn_x_repeat.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, dim_c, dim_x, dim_y)
-
- if self.up_sample is not None:
- pro_feat = self.up_sample(pro_feat)
- _, _, dim_x, dim_y = pro_feat.size()
- pro_feat = pro_feat.contiguous().view(batchhead, self.outChannel, -1).permute(0, 2, 1)
- pro_feat = torch.bmm(pro_feat, attn_lambda.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, self.outChannel, dim_x, dim_y)
- pro_feat = torch.cat(torch.split(pro_feat, int(batchhead / self.nHead), dim=0), dim=1).permute(0, 2, 3, 1)
- pro_feat = self.aggregation(pro_feat).permute(0, 3, 1, 2)
- out = self.gamma * pro_feat + feat
- return out, (attn_x, attn_y, attn_lambda)
-
-
-class Feature_Spatial(nn.Module):
- """ Spatial Feature Generation Component """
-
- def __init__(self, inChannel, nHead, shiftDim, outDim, mode):
- super(Feature_Spatial, self).__init__()
- kernel = [(1, 5), (3, 5)]
- stride = [(1, 2), (2, 2)]
- padding = [(0, 2), (1, 2)]
- self.conv1 = conv_block(inChannel, nHead, kernel[mode[0]], stride[mode[0]], padding[mode[0]], _NORM_ATTN)
- self.conv2 = conv_block(nHead, nHead, kernel[mode[1]], stride[mode[1]], padding[mode[1]], _NORM_ATTN)
- self.fully = fully_block(shiftDim, outDim, _NORM_FC)
-
- def forward(self, image, direction):
- if direction == 'Y':
- image = image.permute(0, 1, 3, 2)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- # import pdb; pdb.set_trace()
- feat = self.fully(feat)
- return feat
-
-
-class Feature_Spectral(nn.Module):
- """ Spectral Feature Generation Component """
-
- def __init__(self, inChannel, nHead, viewDim, outDim):
- super(Feature_Spectral, self).__init__()
- self.inChannel = inChannel
- self.conv1 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.conv2 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.fully = fully_block(viewDim, int(nHead * outDim), _NORM_FC)
-
- def forward(self, image):
- bs = image.size(0)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = feat.view(bs, self.inChannel, -1)
- feat = self.fully(feat)
- return feat
-
-
-def Spectral_Mask(dim_lambda):
- '''After put the available data into the model, we use this mask to avoid outputting the estimation of itself.'''
- orig = (np.cos(np.linspace(-1, 1, num=2 * dim_lambda - 1) * np.pi) + 1.0) / 2.0
- att = np.zeros((dim_lambda, dim_lambda))
- for i in range(dim_lambda):
- att[i, :] = orig[dim_lambda - 1 - i:2 * dim_lambda - 1 - i]
- AM_Mask = torch.from_numpy(att.astype(np.float32)).unsqueeze(0)
- return AM_Mask
-
-class TSA_Net(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28):
- super(TSA_Net, self).__init__()
-
- self.tconv_down1 = Encoder_Triblock(in_ch, 64, False)
- self.tconv_down2 = Encoder_Triblock(64, 128, False)
- self.tconv_down3 = Encoder_Triblock(128, 256)
- self.tconv_down4 = Encoder_Triblock(256, 512)
-
- self.bottom1 = conv_block(512, 1024)
- self.bottom2 = conv_block(1024, 1024)
-
- self.tconv_up4 = Decoder_Triblock(1024, 512)
- self.tconv_up3 = Decoder_Triblock(512, 256)
- self.transform3 = TSA_Transform((96, 96), 256, 256, 8, (64, 80), [0, 0])
- self.tconv_up2 = Decoder_Triblock(256, 128)
- self.transform2 = TSA_Transform((192, 192), 128, 128, 8, (64, 40), [1, 0])
- self.tconv_up1 = Decoder_Triblock(128, 64)
- self.transform1 = TSA_Transform((384, 384), 64, 28, 8, (48, 30), [1, 1], True)
-
- self.conv_last = nn.Conv2d(out_ch, out_ch, 1)
- self.afn_last = nn.Sigmoid()
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None, input_mask_s=None):
-
- x = self.initial_x(x)
- # print(x.shape)
-
- enc1, enc1_pre = self.tconv_down1(x)
- enc2, enc2_pre = self.tconv_down2(enc1)
- enc3, enc3_pre = self.tconv_down3(enc2)
- enc4, enc4_pre = self.tconv_down4(enc3)
- # enc5,enc5_pre = self.tconv_down5(enc4)
-
- bottom = self.bottom1(enc4)
- bottom = self.bottom2(bottom)
-
- # dec5 = self.tconv_up5(bottom,enc5_pre)
- dec4 = self.tconv_up4(bottom, enc4_pre)
- dec3 = self.tconv_up3(dec4, enc3_pre)
- dec3, _ = self.transform3(dec3)
- dec2 = self.tconv_up2(dec3, enc2_pre)
- dec2, _ = self.transform2(dec2)
- dec1 = self.tconv_up1(dec2, enc1_pre)
- dec1, _ = self.transform1(dec1)
-
- dec1 = self.conv_last(dec1)
- output = self.afn_last(dec1)
-
- return output
-
-
-class Encoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Encoder_Triblock, self).__init__()
-
- self.layer1 = conv_block(inChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
- if flag_res:
- self.layer2 = Res2Net(outChannel, int(outChannel / 4))
- else:
- self.layer2 = conv_block(outChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- self.pool = nn.MaxPool2d(nPool) if flag_Pool else None
-
- def forward(self, x):
- feat = self.layer1(x)
- feat = self.layer2(feat)
-
- feat_pool = self.pool(feat) if self.pool is not None else feat
- return feat_pool, feat
-
-
-class Decoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Decoder_Triblock, self).__init__()
-
- self.layer1 = nn.Sequential(
- nn.ConvTranspose2d(inChannel, outChannel, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- if flag_res:
- self.layer2 = Res2Net(int(outChannel * 2), int(outChannel / 2))
- else:
- self.layer2 = conv_block(outChannel * 2, outChannel * 2, nKernal, flag_norm=_NORM_BONE)
- self.layer3 = conv_block(outChannel * 2, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- def forward(self, feat_dec, feat_enc):
- feat_dec = self.layer1(feat_dec)
- diffY = feat_enc.size()[2] - feat_dec.size()[2]
- diffX = feat_enc.size()[3] - feat_dec.size()[3]
- if diffY != 0 or diffX != 0:
- print('Padding for size mismatch ( Enc:', feat_enc.size(), 'Dec:', feat_dec.size(), ')')
- feat_dec = F.pad(feat_dec, [diffX // 2, diffX - diffX // 2, diffY // 2, diffY - diffY // 2])
- feat = torch.cat([feat_dec, feat_enc], dim=1)
- feat = self.layer2(feat)
- feat = self.layer3(feat)
- return feat
\ No newline at end of file
diff --git a/MST/real/test_code/architecture/__init__.py b/MST/real/test_code/architecture/__init__.py
deleted file mode 100755
index a66ae98..0000000
--- a/MST/real/test_code/architecture/__init__.py
+++ /dev/null
@@ -1,70 +0,0 @@
-import torch
-from .MST import MST
-from .GAP_Net import GAP_net
-from .ADMM_Net import ADMM_net
-from .TSA_Net import TSA_Net
-from .HDNet import HDNet, FDL
-from .DGSMP import HSI_CS
-from .BIRNAT import BIRNAT
-from .MST_Plus_Plus import MST_Plus_Plus
-from .Lambda_Net import Lambda_Net
-from .CST import CST
-from .DAUHST import DAUHST
-from .BiSRNet import BiSRNet
-
-def model_generator(method, pretrained_model_path=None):
- if method == 'mst_s':
- model = MST(dim=28, stage=2, num_blocks=[2, 2, 2]).cuda()
- elif method == 'mst_m':
- model = MST(dim=28, stage=2, num_blocks=[2, 4, 4]).cuda()
- elif method == 'mst_l':
- model = MST(dim=28, stage=2, num_blocks=[4, 7, 5]).cuda()
- elif method == 'gap_net':
- model = GAP_net().cuda()
- elif method == 'admm_net':
- model = ADMM_net().cuda()
- elif method == 'tsa_net':
- model = TSA_Net().cuda()
- elif method == 'hdnet':
- model = HDNet().cuda()
- fdl_loss = FDL(loss_weight=0.7,
- alpha=2.0,
- patch_factor=4,
- ave_spectrum=True,
- log_matrix=True,
- batch_matrix=True,
- ).cuda()
- elif method == 'dgsmp':
- model = HSI_CS(Ch=28, stages=4).cuda()
- elif method == 'birnat':
- model = BIRNAT().cuda()
- elif method == 'mst_plus_plus':
- model = MST_Plus_Plus(in_channels=28, out_channels=28, n_feat=28, stage=3).cuda()
- elif method == 'lambda_net':
- model = Lambda_Net(out_ch=28).cuda()
- elif method == 'cst_s':
- model = CST(num_blocks=[1, 1, 2], sparse=True).cuda()
- elif method == 'cst_m':
- model = CST(num_blocks=[2, 2, 2], sparse=True).cuda()
- elif method == 'cst_l':
- model = CST(num_blocks=[2, 4, 6], sparse=True).cuda()
- elif method == 'cst_l_plus':
- model = CST(num_blocks=[2, 4, 6], sparse=False).cuda()
- elif method == 'bisrnet':
- model = BiSRNet(in_channels=28, out_channels=28, n_feat=28, stage=1, num_blocks=[1,1,1]).cuda()
- elif 'dauhst' in method:
- num_iterations = int(method.split('_')[1][0])
- model = DAUHST(num_iterations=num_iterations).cuda()
- else:
- print(f'Method {method} is not defined !!!!')
- if pretrained_model_path is not None:
- print(f'load model from {pretrained_model_path}')
- try:
- checkpoint = torch.load(pretrained_model_path)
- model.load_state_dict({k.replace('module.', ''): v for k, v in checkpoint.items()},
- strict=True)
- except:
- model = torch.load(pretrained_model_path)
- if method == 'hdnet':
- return model, fdl_loss
- return model
\ No newline at end of file
diff --git a/MST/real/test_code/dataset.py b/MST/real/test_code/dataset.py
deleted file mode 100755
index 50838bd..0000000
--- a/MST/real/test_code/dataset.py
+++ /dev/null
@@ -1,96 +0,0 @@
-import torch.utils.data as tud
-import random
-import torch
-import numpy as np
-import scipy.io as sio
-
-
-class dataset(tud.Dataset):
- def __init__(self, opt, CAVE, KAIST):
- super(dataset, self).__init__()
- self.isTrain = opt.isTrain
- self.size = opt.size
- # self.path = opt.data_path
- if self.isTrain == True:
- self.num = opt.trainset_num
- else:
- self.num = opt.testset_num
- self.CAVE = CAVE
- self.KAIST = KAIST
- ## load mask
- data = sio.loadmat(opt.mask_path)
- self.mask = data['mask']
- self.mask_3d = np.tile(self.mask[:, :, np.newaxis], (1, 1, 28))
-
- def __getitem__(self, index):
- if self.isTrain == True:
- # index1 = 0
- index1 = random.randint(0, 29)
- d = random.randint(0, 1)
- if d == 0:
- hsi = self.CAVE[:,:,:,index1]
- else:
- hsi = self.KAIST[:, :, :, index1]
- else:
- index1 = index
- hsi = self.HSI[:, :, :, index1]
- shape = np.shape(hsi)
-
- px = random.randint(0, shape[0] - self.size)
- py = random.randint(0, shape[1] - self.size)
- label = hsi[px:px + self.size:1, py:py + self.size:1, :]
- # while np.max(label)==0:
- # px = random.randint(0, shape[0] - self.size)
- # py = random.randint(0, shape[1] - self.size)
- # label = hsi[px:px + self.size:1, py:py + self.size:1, :]
- # print(np.min(), np.max())
-
- pxm = random.randint(0, 660 - self.size)
- pym = random.randint(0, 660 - self.size)
- mask_3d = self.mask_3d[pxm:pxm + self.size:1, pym:pym + self.size:1, :]
-
- mask_3d_shift = np.zeros((self.size, self.size + (28 - 1) * 2, 28))
- mask_3d_shift[:, 0:self.size, :] = mask_3d
- for t in range(28):
- mask_3d_shift[:, :, t] = np.roll(mask_3d_shift[:, :, t], 2 * t, axis=1)
- mask_3d_shift_s = np.sum(mask_3d_shift ** 2, axis=2, keepdims=False)
- mask_3d_shift_s[mask_3d_shift_s == 0] = 1
-
- if self.isTrain == True:
-
- rotTimes = random.randint(0, 3)
- vFlip = random.randint(0, 1)
- hFlip = random.randint(0, 1)
-
- # Random rotation
- for j in range(rotTimes):
- label = np.rot90(label)
-
- # Random vertical Flip
- for j in range(vFlip):
- label = label[:, ::-1, :].copy()
-
- # Random horizontal Flip
- for j in range(hFlip):
- label = label[::-1, :, :].copy()
-
- temp = mask_3d * label
- temp_shift = np.zeros((self.size, self.size + (28 - 1) * 2, 28))
- temp_shift[:, 0:self.size, :] = temp
- for t in range(28):
- temp_shift[:, :, t] = np.roll(temp_shift[:, :, t], 2 * t, axis=1)
- meas = np.sum(temp_shift, axis=2)
- input = meas / 28 * 2 * 1.2
-
- QE, bit = 0.4, 2048
- input = np.random.binomial((input * bit / QE).astype(int), QE)
- input = np.float32(input) / np.float32(bit)
-
- label = torch.FloatTensor(label.copy()).permute(2,0,1)
- input = torch.FloatTensor(input.copy())
- mask_3d_shift = torch.FloatTensor(mask_3d_shift.copy()).permute(2,0,1)
- mask_3d_shift_s = torch.FloatTensor(mask_3d_shift_s.copy())
- return input, label, mask_3d, mask_3d_shift, mask_3d_shift_s
-
- def __len__(self):
- return self.num
diff --git a/MST/real/test_code/option.py b/MST/real/test_code/option.py
deleted file mode 100755
index 67f1ca6..0000000
--- a/MST/real/test_code/option.py
+++ /dev/null
@@ -1,53 +0,0 @@
-import argparse
-import template
-
-parser = argparse.ArgumentParser(description="HyperSpectral Image Reconstruction Toolbox")
-parser.add_argument('--template', default='mst',
- help='You can set various templates in option.py')
-
-# Hardware specifications
-parser.add_argument("--gpu_id", type=str, default='0')
-
-# Data specifications
-parser.add_argument('--data_root', type=str, default='../../datasets/', help='dataset directory')
-parser.add_argument('--data_path_CAVE', default='../../datasets/CAVE_512_28/', type=str,
- help='path of data')
-parser.add_argument('--data_path_KAIST', default='../../datasets/KAIST_CVPR2021/', type=str,
- help='path of data')
-parser.add_argument('--mask_path', default='../../datasets/TSA_real_data/mask.mat', type=str,
- help='path of mask')
-
-# Saving specifications
-parser.add_argument('--outf', type=str, default='./exp/mst_s/', help='saving_path')
-
-# Model specifications
-parser.add_argument('--method', type=str, default='mst_s', help='method name')
-parser.add_argument('--pretrained_model_path', type=str, default=None, help='pretrained model directory')
-parser.add_argument("--input_setting", type=str, default='H',
- help='the input measurement of the network: H, HM or Y')
-parser.add_argument("--input_mask", type=str, default='Phi',
- help='the input mask of the network: Phi, Phi_PhiPhiT, Mask or None') # Phi: shift_mask Mask: mask
-
-
-# Training specifications
-parser.add_argument("--size", default=384, type=int, help='cropped patch size')
-parser.add_argument("--epoch_sam_num", default=5000, type=int, help='total number of trainset')
-parser.add_argument("--seed", default=1, type=int, help='Random_seed')
-parser.add_argument('--batch_size', type=int, default=1, help='the number of HSIs per batch')
-parser.add_argument("--isTrain", default=True, type=bool, help='train or test')
-parser.add_argument("--max_epoch", type=int, default=300, help='total epoch')
-parser.add_argument("--scheduler", type=str, default='MultiStepLR', help='MultiStepLR or CosineAnnealingLR')
-parser.add_argument("--milestones", type=int, default=[50,100,150,200,250], help='milestones for MultiStepLR')
-parser.add_argument("--gamma", type=float, default=0.5, help='learning rate decay for MultiStepLR')
-parser.add_argument("--learning_rate", type=float, default=0.0004)
-
-opt = parser.parse_args()
-template.set_template(opt)
-
-opt.trainset_num = 20000 // ((opt.size // 96) ** 2)
-
-for arg in vars(opt):
- if vars(opt)[arg] == 'True':
- vars(opt)[arg] = True
- elif vars(opt)[arg] == 'False':
- vars(opt)[arg] = False
\ No newline at end of file
diff --git a/MST/real/test_code/template.py b/MST/real/test_code/template.py
deleted file mode 100755
index cfb3891..0000000
--- a/MST/real/test_code/template.py
+++ /dev/null
@@ -1,55 +0,0 @@
-def set_template(args):
- # Set the templates here
- if args.template.find('mst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
-
- if args.template.find('cst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
-
- if args.template.find('gap_net') >= 0 or args.template.find('admm_net') >= 0 or args.template.find('dauhst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
-
- if args.template.find('tsa_net') >= 0:
- args.input_setting = 'HM'
- args.input_mask = None
-
- if args.template.find('hdnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = None
-
- if args.template.find('dgsmp') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.batch_size = 2
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1e-4
-
- if args.template.find('birnat') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.batch_size = 1
- args.max_epoch = 100
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1.5e-4
-
- if args.template.find('mst_plus_plus') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.scheduler = 'CosineAnnealingLR'
-
- if args.template.find('dnu') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.batch_size = 2
- args.max_epoch = 150
- args.milestones = range(10,args.max_epoch,10)
- args.gamma = 0.9
- args.learning_rate = 4e-4
-
- if args.template.find('lambda_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.learning_rate = 1.5e-4
\ No newline at end of file
diff --git a/MST/real/test_code/test.py b/MST/real/test_code/test.py
deleted file mode 100755
index 7c7bdd2..0000000
--- a/MST/real/test_code/test.py
+++ /dev/null
@@ -1,83 +0,0 @@
-import torch
-import os
-import argparse
-from utils import dataparallel
-import scipy.io as sio
-import numpy as np
-from torch.autograd import Variable
-from option import opt
-from architecture import *
-
-os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
-os.environ["CUDA_VISIBLE_DEVICES"] = "0"
-
-parser = argparse.ArgumentParser(description="PyTorch HSIFUSION")
-parser.add_argument('--data_path', default='../../datasets/TSA_real_data/Measurements/', type=str,help='path of data')
-parser.add_argument('--mask_path', default='../../datasets/TSA_real_data/mask.mat', type=str,help='path of mask')
-parser.add_argument("--size", default=660, type=int, help='the size of trainset image')
-parser.add_argument("--seed", default=1, type=int, help='Random_seed')
-parser.add_argument("--batch_size", default=1, type=int, help='batch_size')
-parser.add_argument("--pretrained_model_path", default=None, type=str)
-parser.add_argument("--outf", default='./exp/real_test_result/', type=str)
-parser.add_argument("--method", type=str, default='others')
-opt = parser.parse_args()
-
-def prepare_data(path, file_num):
- HR_HSI = np.zeros((((660,714,file_num))))
- for idx in range(file_num):
- #### read HrHSI
- path1 = os.path.join(path) + 'scene' + str(idx+1) + '.mat'
- data = sio.loadmat(path1)
- HR_HSI[:,:,idx] = data['meas_real']
- HR_HSI[HR_HSI < 0] = 0.0
- HR_HSI[HR_HSI > 1] = 1.0
- return HR_HSI
-
-def load_mask(path,size=660):
- ## load mask
- data = sio.loadmat(path)
- mask = data['mask']
- mask_3d = np.tile(mask[:, :, np.newaxis], (1, 1, 28))
- mask_3d_shift = np.zeros((size, size + (28 - 1) * 2, 28))
- mask_3d_shift[:, 0:size, :] = mask_3d
- for t in range(28):
- mask_3d_shift[:, :, t] = np.roll(mask_3d_shift[:, :, t], 2 * t, axis=1)
- mask_3d_shift_s = np.sum(mask_3d_shift ** 2, axis=2, keepdims=False)
- mask_3d_shift_s[mask_3d_shift_s == 0] = 1
- mask_3d_shift = torch.FloatTensor(mask_3d_shift.copy()).permute(2, 0, 1)
- mask_3d_shift_s = torch.FloatTensor(mask_3d_shift_s.copy())
- return mask_3d_shift.unsqueeze(0), mask_3d_shift_s.unsqueeze(0)
-
-HR_HSI = prepare_data(opt.data_path, 5)
-mask_3d_shift, mask_3d_shift_s = load_mask(opt.mask_path)
-
-pretrained_model_path = opt.pretrained_model_path
-save_path = opt.outf
-if opt.method=='bisrnet':
- model = model_generator(opt.method, opt.pretrained_model_path).cuda()
-else:
- model = torch.load(pretrained_model_path)
-model = model.eval()
-model = dataparallel(model, 1)
-psnr_total = 0
-k = 0
-for j in range(5):
- with torch.no_grad():
- meas = HR_HSI[:,:,j]
- meas = meas / meas.max() * 0.8
- meas = torch.FloatTensor(meas)
- # meas = torch.FloatTensor(meas).unsqueeze(2).permute(2, 0, 1)
- input = meas.unsqueeze(0)
- input = Variable(input)
- input = input.cuda()
- mask_3d_shift = mask_3d_shift.cuda()
- mask_3d_shift_s = mask_3d_shift_s.cuda()
- out = model(input, mask_3d_shift, mask_3d_shift_s)
- result = out
- result = result.clamp(min=0., max=1.)
- k = k + 1
- if not os.path.exists(save_path): # Create the model directory if it doesn't exist
- os.makedirs(save_path)
- res = result.cpu().permute(2,3,1,0).squeeze(3).numpy()
- save_file = save_path + f'{j}.mat'
- sio.savemat(save_file, {'res':res})
diff --git a/MST/real/test_code/test_s.py b/MST/real/test_code/test_s.py
deleted file mode 100755
index 911bedc..0000000
--- a/MST/real/test_code/test_s.py
+++ /dev/null
@@ -1,69 +0,0 @@
-import torch
-import os
-import argparse
-
-import scipy.io as sio
-import numpy as np
-from torch.autograd import Variable
-from architecture import *
-
-
-parser = argparse.ArgumentParser(description="PyTorch HSIFUSION")
-parser.add_argument('--data_path', default='../../datasets/TSA_real_data/Measurements/', type=str,help='path of data')
-parser.add_argument('--mask_path', default='../../datasets/TSA_real_data/mask.mat', type=str,help='path of mask')
-parser.add_argument("--size", default=660, type=int, help='the size of trainset image')
-parser.add_argument("--trainset_num", default=2000, type=int, help='total number of trainset')
-parser.add_argument("--testset_num", default=5, type=int, help='total number of testset')
-parser.add_argument("--seed", default=1, type=int, help='Random_seed')
-parser.add_argument("--batch_size", default=1, type=int, help='batch_size')
-parser.add_argument("--isTrain", default=False, type=bool, help='train or test')
-parser.add_argument("--gpu_id", type=str, default='0')
-parser.add_argument("--pretrained_model_path", type=str, default='model_zoo/bisrnet/bisrnet.pth')
-parser.add_argument("--outf", type=str, default='./exp/bisrnet/')
-parser.add_argument("--method", type=str, default='bisrnet')
-opt = parser.parse_args()
-print(opt)
-
-os.environ["CUDA_DEVICE_ORDER"] = 'PCI_BUS_ID'
-os.environ["CUDA_VISIBLE_DEVICES"] = opt.gpu_id
-
-def prepare_data(path, file_num):
- HR_HSI = np.zeros((((660,714,file_num))))
- for idx in range(file_num):
- #### read HrHSI
- path1 = os.path.join(path) + 'scene' + str(idx+1) + '.mat'
- data = sio.loadmat(path1)
- HR_HSI[:,:,idx] = data['meas_real']
- HR_HSI[HR_HSI < 0] = 0.0
- HR_HSI[HR_HSI > 1] = 1.0
- return HR_HSI
-
-
-
-HR_HSI = prepare_data(opt.data_path, 5)
-
-model = model_generator(opt.method, opt.pretrained_model_path).cuda()
-model = model.eval()
-psnr_total = 0
-k = 0
-for j in range(5):
- with torch.no_grad():
- meas = HR_HSI[:,:,j]
- meas = meas / meas.max() * 0.8
- meas = torch.FloatTensor(meas).unsqueeze(2).permute(2, 0, 1)
- input = meas.unsqueeze(0)
- input = Variable(input)
- input = input.cuda()
- out = model(input)
- result = out
- result = result.clamp(min=0., max=1.)
- k = k + 1
- model_dir = opt.outf
- if not os.path.isdir(model_dir): # Create the model directory if it doesn't exist
- os.makedirs(model_dir)
- res = result.cpu().permute(2,3,1,0).squeeze(3).numpy()
- save_path = model_dir + '/' + str(j + 1) + '.mat'
- sio.savemat(save_path, {'res':res})
-
-
-
diff --git a/MST/real/test_code/utils.py b/MST/real/test_code/utils.py
deleted file mode 100755
index 4b531a7..0000000
--- a/MST/real/test_code/utils.py
+++ /dev/null
@@ -1,184 +0,0 @@
-import numpy as np
-import scipy.io as sio
-import os
-import glob
-import re
-import torch
-import torch.nn as nn
-import math
-import random
-
-def _as_floats(im1, im2):
- float_type = np.result_type(im1.dtype, im2.dtype, np.float32)
- im1 = np.asarray(im1, dtype=float_type)
- im2 = np.asarray(im2, dtype=float_type)
- return im1, im2
-
-
-def compare_mse(im1, im2):
- im1, im2 = _as_floats(im1, im2)
- return np.mean(np.square(im1 - im2), dtype=np.float64)
-
-
-def compare_psnr(im_true, im_test, data_range=None):
- im_true, im_test = _as_floats(im_true, im_test)
-
- err = compare_mse(im_true, im_test)
- return 10 * np.log10((data_range ** 2) / err)
-
-
-def psnr(img1, img2):
- mse = np.mean((img1/255. - img2/255.) ** 2)
- if mse < 1.0e-10:
- return 100
- PIXEL_MAX = 1
- return 20 * math.log10(PIXEL_MAX / math.sqrt(mse))
-
-
-def PSNR_GPU(im_true, im_fake):
- im_true *= 255
- im_fake *= 255
- im_true = im_true.round()
- im_fake = im_fake.round()
- data_range = 255
- esp = 1e-12
- C = im_true.size()[0]
- H = im_true.size()[1]
- W = im_true.size()[2]
- Itrue = im_true.clone()
- Ifake = im_fake.clone()
- mse = nn.MSELoss(reduce=False)
- err = mse(Itrue, Ifake).sum() / (C*H*W)
- psnr = 10. * np.log((data_range**2)/(err.data + esp)) / np.log(10.)
- return psnr
-
-
-def PSNR_Nssr(im_true, im_fake):
- mse = ((im_true - im_fake)**2).mean()
- psnr = 10. * np.log10(1/mse)
- return psnr
-
-
-def dataparallel(model, ngpus, gpu0=0):
- if ngpus==0:
- assert False, "only support gpu mode"
- gpu_list = list(range(gpu0, gpu0+ngpus))
- assert torch.cuda.device_count() >= gpu0 + ngpus
- if ngpus > 1:
- if not isinstance(model, torch.nn.DataParallel):
- model = torch.nn.DataParallel(model, gpu_list).cuda()
- else:
-
- model = model.cuda()
- elif ngpus == 1:
- model = model.cuda()
- return model
-
-
-def findLastCheckpoint(save_dir):
- file_list = glob.glob(os.path.join(save_dir, 'model_*.pth'))
- if file_list:
- epochs_exist = []
- for file_ in file_list:
- result = re.findall(".*model_(.*).pth.*", file_)
- epochs_exist.append(int(result[0]))
- initial_epoch = max(epochs_exist)
- else:
- initial_epoch = 0
- return initial_epoch
-
-# load HSIs
-def prepare_data(path, file_num):
- HR_HSI = np.zeros((((512,512,28,file_num))))
- for idx in range(file_num):
- # read HrHSI
- path1 = os.path.join(path) + 'scene%02d.mat' % (idx+1)
- # path1 = os.path.join(path) + HR_code + '.mat'
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
- HR_HSI[HR_HSI < 0.] = 0.
- HR_HSI[HR_HSI > 1.] = 1.
- return HR_HSI
-
-
-def loadpath(pathlistfile):
- fp = open(pathlistfile)
- pathlist = fp.read().splitlines()
- fp.close()
- random.shuffle(pathlist)
- return pathlist
-
-def time2file_name(time):
- year = time[0:4]
- month = time[5:7]
- day = time[8:10]
- hour = time[11:13]
- minute = time[14:16]
- second = time[17:19]
- time_filename = year + '_' + month + '_' + day + '_' + hour + '_' + minute + '_' + second
- return time_filename
-
-# def prepare_data_cave(path, file_list, file_num):
-# HR_HSI = np.zeros((((512,512,28,file_num))))
-# for idx in range(file_num):
-# #### read HrHSI
-# HR_code = file_list[idx]
-# path1 = os.path.join(path) + HR_code + '.mat'
-# data = sio.loadmat(path1)
-# HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
-# HR_HSI[HR_HSI < 0] = 0
-# HR_HSI[HR_HSI > 1] = 1
-# return HR_HSI
-#
-# def prepare_data_KASIT(path, file_list, file_num):
-# HR_HSI = np.zeros((((2704,3376,28,file_num))))
-# for idx in range(file_num):
-# #### read HrHSI
-# HR_code = file_list[idx]
-# path1 = os.path.join(path) + HR_code + '.mat'
-# data = sio.loadmat(path1)
-# HR_HSI[:,:,:,idx] = data['HSI']
-# HR_HSI[HR_HSI < 0] = 0
-# HR_HSI[HR_HSI > 1] = 1
-# return HR_HSI
-
-def prepare_data_cave(path, file_num):
- HR_HSI = np.zeros((((512,512,28,file_num))))
- file_list = os.listdir(path)
- # for idx in range(1):
- for idx in range(file_num):
- print(f'loading CAVE {idx}')
- #### read HrHSI
- HR_code = file_list[idx]
- path1 = os.path.join(path) + HR_code
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
- HR_HSI[HR_HSI < 0] = 0
- HR_HSI[HR_HSI > 1] = 1
- return HR_HSI
-
-def prepare_data_KAIST(path, file_num):
- HR_HSI = np.zeros((((2704,3376,28,file_num))))
- file_list = os.listdir(path)
- # for idx in range(1):
- for idx in range(file_num):
- print(f'loading KAIST {idx}')
- #### read HrHSI
- HR_code = file_list[idx]
- path1 = os.path.join(path) + HR_code
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['HSI']
- HR_HSI[HR_HSI < 0] = 0
- HR_HSI[HR_HSI > 1] = 1
- return HR_HSI
-
-def init_mask(mask, Phi, Phi_s, mask_type):
- if mask_type == 'Phi':
- input_mask = Phi
- elif mask_type == 'Phi_PhiPhiT':
- input_mask = (Phi, Phi_s)
- elif mask_type == 'Mask':
- input_mask = mask
- elif mask_type == None:
- input_mask = None
- return input_mask
\ No newline at end of file
diff --git a/MST/real/train_code/__pycache__/dataset.cpython-36.pyc b/MST/real/train_code/__pycache__/dataset.cpython-36.pyc
deleted file mode 100755
index 23ce7d2..0000000
Binary files a/MST/real/train_code/__pycache__/dataset.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/__pycache__/option.cpython-36.pyc b/MST/real/train_code/__pycache__/option.cpython-36.pyc
deleted file mode 100755
index a15d445..0000000
Binary files a/MST/real/train_code/__pycache__/option.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/__pycache__/template.cpython-36.pyc b/MST/real/train_code/__pycache__/template.cpython-36.pyc
deleted file mode 100755
index ee57d46..0000000
Binary files a/MST/real/train_code/__pycache__/template.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/__pycache__/utils.cpython-36.pyc b/MST/real/train_code/__pycache__/utils.cpython-36.pyc
deleted file mode 100755
index 0519003..0000000
Binary files a/MST/real/train_code/__pycache__/utils.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/ADMM_Net.py b/MST/real/train_code/architecture/ADMM_Net.py
deleted file mode 100755
index bc26440..0000000
--- a/MST/real/train_code/architecture/ADMM_Net.py
+++ /dev/null
@@ -1,201 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
-
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
-
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class ADMM_net(nn.Module):
-
- def __init__(self):
- super(ADMM_net, self).__init__()
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma2 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma3 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma4 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma5 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma6 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma7 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma8 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma9 = torch.nn.Parameter(torch.Tensor([0]))
-
- def forward(self, y, input_mask=None):
- if input_mask == None:
- Phi = torch.rand((1, 28, 256, 310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- theta = At(y,Phi)
- b = torch.zeros_like(Phi)
- ### 1-3
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma1),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet1(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma2),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet2(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma3),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet3(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 4-6
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma4),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet4(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma5),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet5(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma6),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet6(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 7-9
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma7),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet7(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma8),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet8(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma9),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet9(x1)
- theta = shift_3d(theta)
- return theta[:, :, :, :384]
diff --git a/MST/real/train_code/architecture/BIRNAT.py b/MST/real/train_code/architecture/BIRNAT.py
deleted file mode 100755
index e3d8123..0000000
--- a/MST/real/train_code/architecture/BIRNAT.py
+++ /dev/null
@@ -1,365 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-
-class self_attention(nn.Module):
- def __init__(self, ch):
- super(self_attention, self).__init__()
- self.conv1 = nn.Conv2d(ch, ch // 8, 1)
- self.conv2 = nn.Conv2d(ch, ch // 8, 1)
- self.conv3 = nn.Conv2d(ch, ch, 1)
- self.conv4 = nn.Conv2d(ch, ch, 1)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.ch = ch
-
- def forward(self, x):
- batch_size = x.shape[0]
-
- f = self.conv1(x)
- g = self.conv2(x)
- h = self.conv3(x)
- ht = h.reshape([batch_size, self.ch, -1])
-
- ft = f.reshape([batch_size, self.ch // 8, -1])
- n = torch.matmul(ft.permute([0, 2, 1]), g.reshape([batch_size, self.ch // 8, -1]))
- beta = F.softmax(n, dim=1)
-
- o = torch.matmul(ht, beta)
- o = o.reshape(x.shape) # [bs, C, h, w]
-
- o = self.conv4(o)
-
- x = self.gamma1 * o + x
-
- return x
-
-
-class res_part(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(res_part, self).__init__()
- self.conv1 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv2 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv3 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
-
- def forward(self, x):
- x1 = self.conv1(x)
- x = x1 + x
- x1 = self.conv2(x)
- x = x1 + x
- x1 = self.conv3(x)
- x = x1 + x
- return x
-
-
-class down_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(down_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- # nn.Conv2d(20, 40, 5, stride=2, padding=2),
- # nn.Conv2d(40, out_ch, 5, stride=2, padding=2),
- nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 40, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(40, out_ch, 3, stride=1, padding=1),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-
-class up_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(up_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.ConvTranspose2d(in_ch, 40, 3, stride=2, padding=1, output_padding=1),
- # nn.ConvTranspose2d(40, 20, 3, stride=2, padding=1, output_padding=1),
- nn.Conv2d(in_ch, 40, 3, stride=1, padding=1),
- nn.Conv2d(40, 30, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(30, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- nn.Conv2d(20, out_ch, 1),
- # nn.Sigmoid(),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-class cnn1(nn.Module):
- # 输入meas concat mask
- # 3 下采样
-
- def __init__(self, B):
- super(cnn1, self).__init__()
- self.conv1 = nn.Conv2d(B + 1, 32, kernel_size=5, stride=1, padding=2)
- self.relu1 = nn.LeakyReLU(inplace=True)
- self.conv2 = nn.Conv2d(32, 64, kernel_size=3, stride=1, padding=1)
- self.relu2 = nn.LeakyReLU(inplace=True)
- self.conv3 = nn.Conv2d(64, 64, kernel_size=1, stride=1)
- self.relu3 = nn.LeakyReLU(inplace=True)
- self.conv4 = nn.Conv2d(64, 128, kernel_size=3, stride=2, padding=1)
- self.relu4 = nn.LeakyReLU(inplace=True)
- self.conv5 = nn.ConvTranspose2d(128, 64, kernel_size=3, stride=2, padding=1, output_padding=1)
- self.relu5 = nn.LeakyReLU(inplace=True)
- self.conv51 = nn.Conv2d(64, 32, kernel_size=3, stride=1, padding=1)
- self.relu51 = nn.LeakyReLU(inplace=True)
- self.conv52 = nn.Conv2d(32, 16, kernel_size=1, stride=1)
- self.relu52 = nn.LeakyReLU(inplace=True)
- self.conv6 = nn.Conv2d(16, 1, kernel_size=3, stride=1, padding=1)
- self.res_part1 = res_part(128, 128)
- self.res_part2 = res_part(128, 128)
- self.res_part3 = res_part(128, 128)
- self.conv7 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu7 = nn.LeakyReLU(inplace=True)
- self.conv8 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
- self.conv9 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu9 = nn.LeakyReLU(inplace=True)
- self.conv10 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
-
- self.att1 = self_attention(128)
-
- def forward(self, meas=None, nor_meas=None, PhiTy=None):
- data = torch.cat([torch.unsqueeze(nor_meas, dim=1), PhiTy], dim=1)
- out = self.conv1(data)
-
- out = self.relu1(out)
- out = self.conv2(out)
- out = self.relu2(out)
- out = self.conv3(out)
- out = self.relu3(out)
- out = self.conv4(out)
- out = self.relu4(out)
- out = self.res_part1(out)
- out = self.conv7(out)
- out = self.relu7(out)
- out = self.conv8(out)
- out = self.res_part2(out)
- out = self.conv9(out)
- out = self.relu9(out)
- out = self.conv10(out)
- out = self.res_part3(out)
-
- # out = self.att1(out)
-
- out = self.conv5(out)
- out = self.relu5(out)
- out = self.conv51(out)
- out = self.relu51(out)
- out = self.conv52(out)
- out = self.relu52(out)
- out = self.conv6(out)
-
- return out
-
-
-class forward_rnn(nn.Module):
-
- def __init__(self):
- super(forward_rnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt1, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
- xt = xt1
-
- step = 2
- [bs, nC, row, col] = xt1.shape
-
- out = xt1
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, ii, :, :], out[:, ii, :, :])
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, ii, :, :], torch.squeeze(nor_meas))
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
- out = torch.cat([out, xt], dim=1)
-
- return out, ht
-
-
-class backrnn(nn.Module):
-
- def __init__(self):
- super(backrnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt8, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
-
- step = 2
- [bs, nC, row, col] = xt8.shape
-
- xt = torch.unsqueeze(xt8[:, cs_rate - 1, :, :], 1)
-
- out = torch.zeros(bs, cs_rate, row, col).cuda()
- out[:, cs_rate - 1, :, :] = xt[:, 0, :, :]
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], out[:, cs_rate - 1 - ii, :, :].clone())
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], xt8[:, cs_rate - 1 - ii, :, :].clone())
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
-
- out[:, cs_rate - 2 - i, :, :] = xt[:, 0, :, :]
-
- return out
-
-def shift_gt_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, i, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- if inputs.is_cuda:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- else:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-class BIRNAT(nn.Module):
-
- def __init__(self):
- super(BIRNAT, self).__init__()
- self.cs_rate = 28
- self.first_frame_net = cnn1(self.cs_rate).cuda()
- self.rnn1 = forward_rnn().cuda()
- self.rnn2 = backrnn().cuda()
-
- def gen_meas_torch(self, meas, shift_mask):
- batch_size, H = meas.shape[0:2]
- mask_s = torch.sum(shift_mask, 1)
- nor_meas = torch.div(meas, mask_s)
- temp = torch.mul(torch.unsqueeze(nor_meas, dim=1).expand([batch_size, 28, H, shift_mask.shape[3]]), shift_mask)
- return nor_meas, temp
-
- def forward(self, meas, shift_mask=None):
- if shift_mask==None:
- shift_mask = torch.zeros(1, 28, 256, 310).cuda()
- H, W = meas.shape[-2:]
- nor_meas, PhiTy = self.gen_meas_torch(meas, shift_mask)
- h0 = torch.zeros(meas.shape[0], 20, H, W).cuda()
- xt1 = self.first_frame_net(meas, nor_meas, PhiTy)
- model_out1, h1 = self.rnn1(xt1, meas, nor_meas, PhiTy, shift_mask, h0, self.cs_rate)
- model_out2 = self.rnn2(model_out1, meas, nor_meas, PhiTy, shift_mask, h1, self.cs_rate)
- model_out2 = shift_gt_back(model_out2)
-
- return model_out2
diff --git a/MST/real/train_code/architecture/BiSRNet.py b/MST/real/train_code/architecture/BiSRNet.py
deleted file mode 100755
index 41c751e..0000000
--- a/MST/real/train_code/architecture/BiSRNet.py
+++ /dev/null
@@ -1,426 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-import os
-from pdb import set_trace as stx
-
-
-# --------------------------------------------- Binarized Basic Units -----------------------------------------------------------------
-
-
-class LearnableBias(nn.Module):
- def __init__(self, out_chn):
- super(LearnableBias, self).__init__()
- self.bias = nn.Parameter(torch.zeros(1, out_chn, 1, 1), requires_grad=True)
-
- def forward(self, x):
- # stx()
- out = x + self.bias.expand_as(x)
- return out
-
-
-class ReDistribution(nn.Module):
- def __init__(self, out_chn):
- super(ReDistribution, self).__init__()
- self.b = nn.Parameter(torch.zeros(1, out_chn, 1, 1), requires_grad=True)
- self.k = nn.Parameter(torch.ones(1, out_chn, 1, 1), requires_grad=True)
-
- def forward(self, x):
- out = x * self.k.expand_as(x) + self.b.expand_as(x)
- return out
-
-
-class RPReLU(nn.Module):
- def __init__(self, inplanes):
- super(RPReLU, self).__init__()
- self.pr_bias0 = LearnableBias(inplanes)
- self.pr_prelu = nn.PReLU(inplanes)
- self.pr_bias1 = LearnableBias(inplanes)
-
- def forward(self, x):
- x = self.pr_bias1(self.pr_prelu(self.pr_bias0(x)))
- return x
-
-
-class Spectral_Binary_Activation(nn.Module):
- def __init__(self):
- super(Spectral_Binary_Activation, self).__init__()
- self.beta = nn.Parameter(torch.ones(1), requires_grad=True)
-
- def forward(self, x):
- binary_activation_no_grad = torch.sign(x)
- tanh_activation = torch.tanh(x * self.beta)
-
- out = binary_activation_no_grad.detach() - tanh_activation.detach() + tanh_activation
- return out
-
-
-class HardBinaryConv(nn.Conv2d):
- def __init__(self, in_chn, out_chn, kernel_size=3, stride=1, padding=1, groups=1, bias=True):
- super(HardBinaryConv, self).__init__(
- in_chn,
- out_chn,
- kernel_size,
- stride=stride,
- padding=padding,
- groups=groups,
- bias=bias
- )
-
- def forward(self, x):
- real_weights = self.weight
- scaling_factor = torch.mean(torch.mean(torch.mean(abs(real_weights), dim=3, keepdim=True), dim=2, keepdim=True),
- dim=1, keepdim=True)
- scaling_factor = scaling_factor.detach()
- # stx()
- binary_weights_no_grad = scaling_factor * torch.sign(real_weights)
- # stx()
- cliped_weights = torch.clamp(real_weights, -1.0, 1.0)
- binary_weights = binary_weights_no_grad.detach() - cliped_weights.detach() + cliped_weights
- y = F.conv2d(x, binary_weights, self.bias, stride=self.stride, padding=self.padding, groups=self.groups)
-
- return y
-
-
-class BinaryConv2d(nn.Module):
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d, self).__init__()
-
- self.move0 = ReDistribution(in_channels)
- self.binary_activation = Spectral_Binary_Activation()
- self.binary_conv = HardBinaryConv(in_chn=in_channels,
- out_chn=in_channels,
- kernel_size=kernel_size,
- stride=stride,
- padding=padding,
- bias=bias,
- groups=groups)
- self.relu = RPReLU(in_channels)
-
- def forward(self, x):
- out = self.move0(x)
- out = self.binary_activation(out)
- out = self.binary_conv(out)
- out = self.relu(out)
- out = out + x
- return out
-
-
-class BinaryConv2d_Down(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Down, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.avg_pool = nn.AvgPool2d(kernel_size=2, stride=2, padding=0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h/2,w/2
- '''
- out = self.avg_pool(x)
- out_1 = out
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-class BinaryConv2d_Up(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Up, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,2h,2w
- '''
- b, c, h, w = x.shape
- out = F.interpolate(x, scale_factor=2, mode='bilinear')
-
- out_1 = out[:, :c // 2, :, :]
- out_2 = out[:, c // 2:, :, :]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Decrease(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,h,w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Decrease, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,h,w
- '''
- b, c, h, w = x.shape
- out = x
-
- out_1 = out[:, :c // 2, :, :]
- out_2 = out[:, c // 2:, :, :]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Increase(nn.Module):
- '''
- input: b,c,h,w
- output: b,2c,h,w
- '''
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Increase, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h,w
- '''
- # stx()
- out_1 = x
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-# ---------------------------------------------------------- Binarized UNet------------------------------------------------------
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-def shift_back(inputs, step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256 // row
- step = float(step) / float(down_sample * down_sample)
- out_col = row
- for i in range(nC):
- inputs[:, i, :, :out_col] = \
- inputs[:, i, :, int(step * i):int(step * i) + out_col]
- return inputs[:, :, :, :out_col]
-
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=2):
- super().__init__()
- self.net = nn.Sequential(
- BinaryConv2d_Fusion_Increase(dim, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Increase(dim * mult, dim * mult * mult, 1, 1, bias=False),
- RPReLU(dim * mult * mult),
- BinaryConv2d(dim * mult * mult, dim * mult * mult, 3, 1, 1, bias=False, groups=dim),
- RPReLU(dim * mult * mult),
- BinaryConv2d_Fusion_Decrease(dim * mult * mult, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-
-class BiSRNet_Block(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(
- PreNorm(dim, FeedForward(dim=dim))
- )
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for ff in self.blocks:
- # x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class BiSRNet_body(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2, 4, 4]):
- super(BiSRNet_body, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = BinaryConv2d(in_dim, self.dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- BiSRNet_Block(dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- BinaryConv2d_Down(dim_stage, dim_stage * 2, 3, 1, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = BiSRNet_Block(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- BinaryConv2d_Up(dim_stage, dim_stage // 2, 3, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim_stage, dim_stage // 2, 1, 1, bias=False),
- BiSRNet_Block(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = BinaryConv2d(self.dim, out_dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (BiSRNet_Block, FeaDownSample) in self.encoder_layers:
- # stx()
- fea = BiSRNet_Block(fea)
- fea_encoder.append(fea)
- # stx()
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, BiSRNet_Block) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage - 1 - i]], dim=1))
- fea = BiSRNet_Block(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-class BiSRNet(nn.Module):
- '''
- Only 3 layers are 32-bit conv
- '''
-
- def __init__(self, in_channels=28, out_channels=28, n_feat=28, stage=3, num_blocks=[1, 1, 1]):
- super(BiSRNet, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,
- bias=False) # 1-bit -> 32-bit
- modules_body = [BiSRNet_body(dim=n_feat, stage=2, num_blocks=num_blocks) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True) # 1-bit -> 32-bit
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,
- bias=False) # 1-bit -> 32-bit
-
- def y2x(self, y):
- ## Spilt operator
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- return x
-
- def forward(self, y, input_mask=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.y2x(y)
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
\ No newline at end of file
diff --git a/MST/real/train_code/architecture/CST.py b/MST/real/train_code/architecture/CST.py
deleted file mode 100755
index dab3f10..0000000
--- a/MST/real/train_code/architecture/CST.py
+++ /dev/null
@@ -1,600 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-from collections import defaultdict, Counter
-import numpy as np
-from tqdm import tqdm
-import random
-
-def uniform(a, b, shape, device='cuda'):
- return (b - a) * torch.rand(shape, device=device) + a
-
-class AsymmetricTransform:
-
- def Q(self, *args, **kwargs):
- raise NotImplementedError('Query transform not implemented')
-
- def K(self, *args, **kwargs):
- raise NotImplementedError('Key transform not implemented')
-
-class LSH:
- def __call__(self, *args, **kwargs):
- raise NotImplementedError('LSH scheme not implemented')
-
- def compute_hash_agreement(self, q_hash, k_hash):
- return (q_hash == k_hash).min(dim=-1)[0].sum(dim=-1)
-
-class XBOXPLUS(AsymmetricTransform):
-
- def set_norms(self, x):
- self.x_norms = x.norm(p=2, dim=-1, keepdim=True)
- self.MX = torch.amax(self.x_norms, dim=-2, keepdim=True)
-
- def X(self, x):
- device = x.device
- ext = torch.sqrt((self.MX**2).to(device) - (self.x_norms**2).to(device))
- zero = torch.tensor(0.0, device=x.device).repeat(x.shape[:-1], 1).unsqueeze(-1)
- return torch.cat((x, ext, zero), -1)
-
-def lsh_clustering(x, n_rounds, r=1):
- salsh = SALSH(n_rounds=n_rounds, dim=x.shape[-1], r=r, device=x.device)
- x_hashed = salsh(x).reshape((n_rounds,) + x.shape[:-1])
- return x_hashed.argsort(dim=-1)
-
-class SALSH(LSH):
- def __init__(self, n_rounds, dim, r, device='cuda'):
- super(SALSH, self).__init__()
- self.alpha = torch.normal(0, 1, (dim, n_rounds), device=device)
- self.beta = uniform(0, r, shape=(1, n_rounds), device=device)
- self.dim = dim
- self.r = r
-
- def __call__(self, vecs):
- projection = vecs @ self.alpha
- projection_shift = projection + self.beta
- projection_rescale = projection_shift / self.r
- return projection_rescale.permute(2, 0, 1)
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
-
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
-
- variance = scale / denom
-
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def batch_scatter(output, src, dim, index):
- """
- :param output: [b,n,c]
- :param src: [b,n,c]
- :param dim: int
- :param index: [b,n]
- :return: output: [b,n,c]
- """
- b,k,c = src.shape
- index = index[:, :, None].expand(-1, -1, c)
- output, src, index = map(lambda t: rearrange(t, 'b k c -> (b c) k'), (output, src, index))
- output.scatter_(dim,index,src)
- output = rearrange(output, '(b c) k -> b k c', b=b)
- return output
-
-def batch_gather(x, index, dim):
- """
- :param x: [b,n,c]
- :param index: [b,n//2]
- :param dim: int
- :return: output: [b,n//2,c]
- """
- b,n,c = x.shape
- index = index[:,:,None].expand(-1,-1,c)
- x, index = map(lambda t: rearrange(t, 'b n c -> (b c) n'), (x, index))
- output = torch.gather(x,dim,index)
- output = rearrange(output, '(b c) n -> b n c', b=b)
- return output
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class SAH_MSA(nn.Module):
- def __init__(self, heads=4, n_rounds=2, channels=64, patch_size=144,
- r=1):
- super(SAH_MSA, self).__init__()
- self.heads = heads
- self.n_rounds = n_rounds
- inner_dim = channels*3
- self.to_q = nn.Linear(channels, inner_dim, bias=False)
- self.to_k = nn.Linear(channels, inner_dim, bias=False)
- self.to_v = nn.Linear(channels, inner_dim, bias=False)
- self.to_out = nn.Linear(inner_dim, channels, bias=False)
-
- self.xbox_plus = XBOXPLUS()
- self.clustering_params = {
- 'r': r,
- 'n_rounds': self.n_rounds
- }
- self.q_attn_size = patch_size[0] * patch_size[1]
- self.k_attn_size = patch_size[0] * patch_size[1]
-
- def forward(self, input):
- """
- :param input: [b,n,c]
- :return: output: [b,n,c]
- """
-
- B, N, C_inp = input.shape
- query = self.to_q(input)
- key = self.to_k(input)
- value = self.to_v(input)
- input_hash = input.view(B, N, self.heads, C_inp//self.heads)
- x_hash = rearrange(input_hash, 'b t h e -> (b h) t e')
- bs, x_seqlen, dim = x_hash.shape
- with torch.no_grad():
- self.xbox_plus.set_norms(x_hash)
- Xs = self.xbox_plus.X(x_hash)
- x_positions = lsh_clustering(Xs, **self.clustering_params)
- x_positions = x_positions.reshape(self.n_rounds, bs, -1)
-
- del Xs
-
- C = query.shape[-1]
- query = query.view(B, N, self.heads, C // self.heads)
- key = key.view(B, N, self.heads, C // self.heads)
- value = value.view(B, N, self.heads, C // self.heads)
-
- query = rearrange(query, 'b t h e -> (b h) t e') # [bs, q_seqlen,c]
- key = rearrange(key, 'b t h e -> (b h) t e')
- value = rearrange(value, 'b s h d -> (b h) s d')
-
- bs, q_seqlen, dim = query.shape
- bs, k_seqlen, dim = key.shape
- v_dim = value.shape[-1]
-
- x_rev_positions = torch.argsort(x_positions, dim=-1)
- x_offset = torch.arange(bs, device=query.device).unsqueeze(-1) * x_seqlen
- x_flat = (x_positions + x_offset).reshape(-1)
-
- s_queries = query.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.q_attn_size, dim)
- s_keys = key.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, dim)
- s_values = value.reshape(-1, v_dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, v_dim)
-
- inner = s_queries @ s_keys.transpose(2, 1)
- norm_factor = 1
- inner = inner / norm_factor
-
- # free memory
- del x_positions
-
- # softmax denominator
- dots_logsumexp = torch.logsumexp(inner, dim=-1, keepdim=True)
- # softmax
- dots = torch.exp(inner - dots_logsumexp)
- # dropout
-
- # n_rounds outs
- bo = (dots @ s_values).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- # undo sort
- x_offset = torch.arange(bs * self.n_rounds, device=query.device).unsqueeze(-1) * x_seqlen
- x_rev_flat = (x_rev_positions.reshape(-1, x_seqlen) + x_offset).reshape(-1)
- o = bo.reshape(-1, v_dim).index_select(0, x_rev_flat).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- slogits = dots_logsumexp.reshape(self.n_rounds, bs, -1)
- logits = torch.gather(slogits, 2, x_rev_positions)
-
- # free memory
- del x_rev_positions
-
- # weighted sum multi-round attention
- probs = torch.exp(logits - torch.logsumexp(logits, dim=0, keepdim=True))
- out = torch.sum(o * probs.unsqueeze(-1), dim=0)
- out = rearrange(out, '(b h) t d -> b t h d', h=self.heads)
- out = out.reshape(B, N, -1)
- out = self.to_out(out)
-
- return out
-
-class SAHAB(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(16, 16),
- heads=8,
- shift_size=0,
- sparse=False
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- self.attn = PreNorm(dim, SAH_MSA(heads=heads, n_rounds=2, r=1, channels=dim, patch_size=patch_size))
- self.ffn = PreNorm(dim, FeedForward(dim=dim))
- self.shift_size = shift_size
- self.patch_size = patch_size
- self.sparse = sparse
-
- def forward(self, x, mask=None):
- """
- x: [b,h,w,c]
- mask: [b,h,w]
- return out: [b,h,w,c]
- """
- b,h,w,c = x.shape
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- mask = torch.roll(mask, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- w_size = self.patch_size
-
- # Split into large patches
- x = rearrange(x, 'b (nh hh) (nw ww) c-> b (nh nw) (hh ww c)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- mask = rearrange(mask, 'b (nh hh) (nw ww) -> b (nh nw) (hh ww)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- N = x.shape[1]
-
- mask = torch.mean(mask,dim=2,keepdim=False) # [b,nh*nw]
- if self.sparse:
- mask_select = mask.topk(mask.shape[1] // 2, dim=1)[1] # [b,nh*nw//2]
- x_select = batch_gather(x, mask_select, 1) # [b,nh*nw//2,hh*ww*c]
- x_select = x_select.reshape(b*N//2,-1,c)
- x_select = self.attn(x_select)+x_select
- x_select = x_select.view(b,N//2,-1)
- x = batch_scatter(x.clone(), x_select, 1, mask_select)
- else:
- x = x.view(b*N,-1,c)
- x = self.attn(x) + x
- x = x.view(b, N, -1)
- x = rearrange(x, 'b (nh nw) (hh ww c) -> b (nh hh) (nw ww) c', nh=h//(w_size[0] * 2), hh=w_size[0] * 2, ww=w_size[1] * 2)
-
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(self.shift_size, self.shift_size), dims=(1, 2))
-
- x = self.ffn(x) + x
-
- return x
-
-
-class SAHABs(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(8, 8),
- heads=8,
- num_blocks=2,
- sparse=False
- ):
- super().__init__()
- blocks = []
- for _ in range(num_blocks):
- blocks.append(
- SAHAB(heads=heads, dim=dim, patch_size=patch_size,sparse=sparse,
- shift_size=0 if (_ % 2 == 0) else patch_size[0]))
- self.blocks = nn.Sequential(*blocks)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,1,h,w]
- return x: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- mask = mask.squeeze(1)
- for block in self.blocks:
- x = block(x, mask)
- x = x.permute(0, 3, 1, 2)
- return x
-
-class ASPPConv(nn.Sequential):
- def __init__(self, in_channels, out_channels, dilation):
- modules = [
- nn.Conv2d(in_channels, out_channels, 3, padding=dilation, dilation=dilation, bias=False),
- nn.ReLU()
- ]
- super(ASPPConv, self).__init__(*modules)
-
-
-class ASPPPooling(nn.Sequential):
- def __init__(self, in_channels, out_channels):
- super(ASPPPooling, self).__init__(
- nn.AdaptiveAvgPool2d(1),
- nn.Conv2d(in_channels, out_channels, 1, bias=False),
- nn.ReLU())
-
- def forward(self, x):
- size = x.shape[-2:]
- for mod in self:
- x = mod(x)
- return F.interpolate(x, size=size, mode='bilinear', align_corners=False)
-
-
-class ASPP(nn.Module):
- def __init__(self, in_channels, atrous_rates, out_channels):
- super(ASPP, self).__init__()
- modules = []
-
- rates = tuple(atrous_rates)
- for rate in rates:
- modules.append(ASPPConv(in_channels, out_channels, rate))
-
- modules.append(ASPPPooling(in_channels, out_channels))
-
- self.convs = nn.ModuleList(modules)
-
- self.project = nn.Sequential(
- nn.Conv2d(len(self.convs) * out_channels, out_channels, 1, bias=False),
- nn.ReLU(),
- nn.Dropout(0.5))
-
- def forward(self, x):
- res = []
- for conv in self.convs:
- res.append(conv(x))
- res = torch.cat(res, dim=1)
- return self.project(res)
-
-class Sparsity_Estimator(nn.Module):
- def __init__(self, dim=28, expand=2, sparse=False):
- super(Sparsity_Estimator, self).__init__()
- self.dim = dim
- self.stage = 2
- self.sparse = sparse
-
- # Input projection
- self.in_proj = nn.Conv2d(28, dim, 1, 1, 0, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(2):
- self.encoder_layers.append(nn.ModuleList([
- nn.Conv2d(dim_stage, dim_stage * expand, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage * expand, dim_stage * expand, 3, 2, 1, bias=False, groups=dim_stage * expand),
- nn.Conv2d(dim_stage * expand, dim_stage*expand, 1, 1, 0, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = ASPP(dim_stage, [3,6], dim_stage)
-
- # Decoder:
- self.decoder_layers = nn.ModuleList([])
- for i in range(2):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage // 2, dim_stage, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage, dim_stage, 3, 1, 1, bias=False, groups=dim_stage),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, 0, bias=False),
- ]))
- dim_stage //= 2
-
- # Output projection
- if sparse:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim+1, 3, 1, 1, bias=False)
- else:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- # Input projection
- fea = self.lrelu(self.in_proj(x))
- # Encoder
- fea_encoder = [] # [c 2c 4c 8c]
- for (Conv1, Conv2, Conv3) in self.encoder_layers:
- fea_encoder.append(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- # Bottleneck
- fea = self.bottleneck(fea)+fea
- # Decoder
- for i, (FeaUpSample, Conv1, Conv2, Conv3) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- fea = fea + fea_encoder[self.stage-1-i]
- # Output projection
- out = self.out_conv2(fea)
- if self.sparse:
- error_map = out[:,-1:,:,:]
- return out[:,:-1], error_map
- return out
-
-class CST(nn.Module):
- def __init__(self, dim=28, stage=2, num_blocks=[2, 2, 2], sparse=False):
- super(CST, self).__init__()
- self.dim = dim
- self.stage = stage
- self.sparse = sparse
-
- # Fution physical mask and shifted measurement
- self.fution = nn.Conv2d(28, 28, 1, 1, 0, bias=False)
-
- # Sparsity Estimator
- if num_blocks==[2,4,6]:
- self.fe = nn.Sequential(Sparsity_Estimator(dim=28,expand=2,sparse=False),
- Sparsity_Estimator(dim=28, expand=2, sparse=sparse))
- else:
- self.fe = Sparsity_Estimator(dim=28, expand=2, sparse=sparse)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- SAHABs(dim=dim_stage, num_blocks=num_blocks[i], heads=dim_stage // dim, sparse=sparse),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.AvgPool2d(kernel_size=2, stride=2),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = SAHABs(
- dim=dim_stage, heads=dim_stage // dim, num_blocks=num_blocks[-1], sparse=sparse)
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- SAHABs(dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i],
- heads=(dim_stage // 2) // dim, sparse=sparse),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.out_proj = nn.Conv2d(self.dim, dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :return: x: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.initial_x(x)
-
- # Feature Extraction
- if self.sparse:
- fea,mask = self.fe(x)
- else:
- fea = self.fe(x)
- mask = torch.randn((b,1,h,w)).cuda()
-
- # Encoder
- fea_encoder = []
- masks = []
- for (Blcok, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = Blcok(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Blcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = fea + fea_encoder[self.stage - 1 - i]
- mask = masks[self.stage - 1 - i]
- fea = Blcok(fea, mask)
-
- # Output projection
- out = self.out_proj(fea) + x
- if self.sparse:
- return out, mask
- return out
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/train_code/architecture/DAUHST.py b/MST/real/train_code/architecture/DAUHST.py
deleted file mode 100755
index 1880f8e..0000000
--- a/MST/real/train_code/architecture/DAUHST.py
+++ /dev/null
@@ -1,358 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch import einsum
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-class HS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=28,
- heads=8,
- only_local_branch=False
- ):
- super().__init__()
-
- self.dim = dim
- self.heads = heads
- self.scale = dim_head ** -0.5
- self.window_size = window_size
- self.only_local_branch = only_local_branch
-
- # position embedding
- if only_local_branch:
- seq_l = window_size[0] * window_size[1]
- self.pos_emb = nn.Parameter(torch.Tensor(1, heads, seq_l, seq_l))
- trunc_normal_(self.pos_emb)
- else:
- seq_l1 = window_size[0] * window_size[1]
- self.pos_emb1 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l1, seq_l1))
- h,w = 384//self.heads, 384//self.heads
- seq_l2 = h*w//seq_l1
- self.pos_emb2 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l2, seq_l2))
- trunc_normal_(self.pos_emb1)
- trunc_normal_(self.pos_emb2)
-
- inner_dim = dim_head * heads
- self.to_q = nn.Linear(dim, inner_dim, bias=False)
- self.to_kv = nn.Linear(dim, inner_dim * 2, bias=False)
- self.to_out = nn.Linear(inner_dim, dim)
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x.shape
- w_size = self.window_size
- assert h % w_size[0] == 0 and w % w_size[1] == 0, 'fmap dimensions must be divisible by the window size'
- if self.only_local_branch:
- x_inp = rearrange(x, 'b (h b0) (w b1) c -> (b h w) (b0 b1) c', b0=w_size[0], b1=w_size[1])
- q = self.to_q(x_inp)
- k, v = self.to_kv(x_inp).chunk(2, dim=-1)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.heads), (q, k, v))
- q *= self.scale
- sim = einsum('b h i d, b h j d -> b h i j', q, k)
- sim = sim + self.pos_emb
- attn = sim.softmax(dim=-1)
- out = einsum('b h i j, b h j d -> b h i d', attn, v)
- out = rearrange(out, 'b h n d -> b n (h d)')
- out = self.to_out(out)
- out = rearrange(out, '(b h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- else:
- q = self.to_q(x)
- k, v = self.to_kv(x).chunk(2, dim=-1)
- q1, q2 = q[:,:,:,:c//2], q[:,:,:,c//2:]
- k1, k2 = k[:,:,:,:c//2], k[:,:,:,c//2:]
- v1, v2 = v[:,:,:,:c//2], v[:,:,:,c//2:]
-
- # local branch
- q1, k1, v1 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q1, k1, v1))
- q1, k1, v1 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q1, k1, v1))
- q1 *= self.scale
- sim1 = einsum('b n h i d, b n h j d -> b n h i j', q1, k1)
- sim1 = sim1 + self.pos_emb1
- attn1 = sim1.softmax(dim=-1)
- out1 = einsum('b n h i j, b n h j d -> b n h i d', attn1, v1)
- out1 = rearrange(out1, 'b n h mm d -> b n mm (h d)')
-
- # non-local branch
- q2, k2, v2 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q2, k2, v2))
- q2, k2, v2 = map(lambda t: t.permute(0, 2, 1, 3), (q2.clone(), k2.clone(), v2.clone()))
- q2, k2, v2 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q2, k2, v2))
- q2 *= self.scale
- sim2 = einsum('b n h i d, b n h j d -> b n h i j', q2, k2)
- sim2 = sim2 + self.pos_emb2
- attn2 = sim2.softmax(dim=-1)
- out2 = einsum('b n h i j, b n h j d -> b n h i d', attn2, v2)
- out2 = rearrange(out2, 'b n h mm d -> b n mm (h d)')
- out2 = out2.permute(0, 2, 1, 3)
-
- out = torch.cat([out1,out2],dim=-1).contiguous()
- out = self.to_out(out)
- out = rearrange(out, 'b (h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- return out
-
-class HSAB(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- PreNorm(dim, HS_MSA(dim=dim, window_size=window_size, dim_head=dim_head, heads=heads, only_local_branch=(heads==1))),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class HST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]):
- super(HST, self).__init__()
- self.dim = dim
- self.scales = len(num_blocks)
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_scale = dim
- for i in range(self.scales-1):
- self.encoder_layers.append(nn.ModuleList([
- HSAB(dim=dim_scale, num_blocks=num_blocks[i], dim_head=dim, heads=dim_scale // dim),
- nn.Conv2d(dim_scale, dim_scale * 2, 4, 2, 1, bias=False),
- ]))
- dim_scale *= 2
-
- # Bottleneck
- self.bottleneck = HSAB(dim=dim_scale, dim_head=dim, heads=dim_scale // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(self.scales-1):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_scale, dim_scale // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_scale, dim_scale // 2, 1, 1, bias=False),
- HSAB(dim=dim_scale // 2, num_blocks=num_blocks[self.scales - 2 - i], dim_head=dim,
- heads=(dim_scale // 2) // dim),
- ]))
- dim_scale //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 16, 16
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
-
- # Embedding
- fea = self.embedding(x)
- x = x[:,:28,:,:]
-
- # Encoder
- fea_encoder = []
- for (HSAB, FeaDownSample) in self.encoder_layers:
- fea = HSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, HSAB) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.scales-2-i]], dim=1))
- fea = HSAB(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out[:, :, :h_inp, :w_inp]
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class HyPaNet(nn.Module):
- def __init__(self, in_nc=29, out_nc=8, channel=64):
- super(HyPaNet, self).__init__()
- self.fution = nn.Conv2d(in_nc, channel, 1, 1, 0, bias=True)
- self.down_sample = nn.Conv2d(channel, channel, 3, 2, 1, bias=True)
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.mlp = nn.Sequential(
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, out_nc, 1, padding=0, bias=True),
- nn.Softplus())
- self.relu = nn.ReLU(inplace=True)
- self.out_nc = out_nc
-
- def forward(self, x):
- x = self.down_sample(self.relu(self.fution(x)))
- x = self.avg_pool(x)
- x = self.mlp(x) + 1e-6
- return x[:,:self.out_nc//2,:,:], x[:,self.out_nc//2:,:,:]
-
-class DAUHST(nn.Module):
-
- def __init__(self, num_iterations=1):
- super(DAUHST, self).__init__()
- self.para_estimator = HyPaNet(in_nc=28, out_nc=num_iterations*2)
- self.fution = nn.Conv2d(28, 28, 1, padding=0, bias=True)
- self.num_iterations = num_iterations
- self.denoisers = nn.ModuleList([])
- for _ in range(num_iterations):
- self.denoisers.append(
- HST(in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]),
- )
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :param Phi_PhiT: [b,256,310]
- :return: z_crop: [b,28,256,256]
- """
- x = self.initial_x(x)
- for i in range(self.num_iterations):
- x = self.denoisers[i](x)
- return x[:, :, :, 0:384]
-
diff --git a/MST/real/train_code/architecture/DGSMP.py b/MST/real/train_code/architecture/DGSMP.py
deleted file mode 100755
index 026fefa..0000000
--- a/MST/real/train_code/architecture/DGSMP.py
+++ /dev/null
@@ -1,322 +0,0 @@
-import torch
-import torch.nn as nn
-from torch.nn.parameter import Parameter
-import torch.nn.functional as F
-
-
-class Resblock(nn.Module):
- def __init__(self, HBW):
- super(Resblock, self).__init__()
- self.block1 = nn.Sequential(nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1))
- self.block2 = nn.Sequential(nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(HBW, HBW, kernel_size=3, stride=1, padding=1))
-
- def forward(self, x):
- tem = x
- r1 = self.block1(x)
- out = r1 + tem
- r2 = self.block2(out)
- out = r2 + out
- return out
-
-class Encoding(nn.Module):
- def __init__(self):
- super(Encoding, self).__init__()
- self.E1 = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E2 = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E3 = nn.Sequential(nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E4 = nn.Sequential(nn.Conv2d(in_channels=64, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.E5 = nn.Sequential(nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
-
- def forward(self, x):
- ## encoding blocks
- E1 = self.E1(x)
- E2 = self.E2(F.avg_pool2d(E1, kernel_size=2, stride=2))
- E3 = self.E3(F.avg_pool2d(E2, kernel_size=2, stride=2))
- E4 = self.E4(F.avg_pool2d(E3, kernel_size=2, stride=2))
- E5 = self.E5(F.avg_pool2d(E4, kernel_size=2, stride=2))
- return E1, E2, E3, E4, E5
-
-class Decoding(nn.Module):
- def __init__(self, Ch=28, kernel_size=[7,7,7]):
- super(Decoding, self).__init__()
- self.upMode = 'bilinear'
- self.Ch = Ch
- out_channel1 = Ch * kernel_size[0]
- out_channel2 = Ch * kernel_size[1]
- out_channel3 = Ch * kernel_size[2]
- self.D1 = nn.Sequential(nn.Conv2d(in_channels=128+128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=128, out_channels=128, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D2 = nn.Sequential(nn.Conv2d(in_channels=128+64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D3 = nn.Sequential(nn.Conv2d(in_channels=64+64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=64, out_channels=64, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
- self.D4 = nn.Sequential(nn.Conv2d(in_channels=64+32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU()
- )
-
- self.w_generator = nn.Sequential(nn.Conv2d(in_channels=32, out_channels=32, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=32, out_channels=self.Ch, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(in_channels=self.Ch, out_channels=self.Ch, kernel_size=1, stride=1, padding=0)
- )
-
- self.filter_g_1 = nn.Sequential(nn.Conv2d(64 + 32, out_channel1, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel1, out_channel1, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel1, out_channel1, 1, 1, 0)
- )
-
- self.filter_g_2 = nn.Sequential(nn.Conv2d(64 + 32, out_channel2, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel2, out_channel2, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel2, out_channel2, 1, 1, 0)
- )
-
- self.filter_g_3 = nn.Sequential(nn.Conv2d(64 + 32, out_channel3, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel3, out_channel3, kernel_size=3, stride=1, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channel3, out_channel3, 1, 1, 0)
- )
-
-
- def forward(self, E1, E2, E3, E4, E5):
- ## decoding blocks
- D1 = self.D1(torch.cat([E4, F.interpolate(E5, scale_factor=2, mode=self.upMode)], dim=1))
- D2 = self.D2(torch.cat([E3, F.interpolate(D1, scale_factor=2, mode=self.upMode)], dim=1))
- D3 = self.D3(torch.cat([E2, F.interpolate(D2, scale_factor=2, mode=self.upMode)], dim=1))
- D4 = self.D4(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
-
- ## estimating the regularization parameters w
- w = self.w_generator(D4)
-
- ## generate 3D filters
- f1 = self.filter_g_1(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- f2 = self.filter_g_2(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- f3 = self.filter_g_3(torch.cat([E1, F.interpolate(D3, scale_factor=2, mode=self.upMode)], dim=1))
- return w, f1, f2, f3
-
-
-class HSI_CS(nn.Module):
- def __init__(self, Ch, stages):
- super(HSI_CS, self).__init__()
- self.Ch = Ch
- self.s = stages
- self.filter_size = [7,7,7] ## 3D filter size
-
- ## The modules for learning the measurement matrix A and A^T
- self.AT = nn.Sequential(nn.Conv2d(Ch, 64, kernel_size=3, stride=1, padding=1), nn.LeakyReLU(),
- Resblock(64), Resblock(64),
- nn.Conv2d(64, Ch, kernel_size=3, stride=1, padding=1), nn.LeakyReLU())
- self.A = nn.Sequential(nn.Conv2d(Ch, 64, kernel_size=3, stride=1, padding=1), nn.LeakyReLU(),
- Resblock(64), Resblock(64),
- nn.Conv2d(64, Ch, kernel_size=3, stride=1, padding=1), nn.LeakyReLU())
-
- ## Encoding blocks
- self.Encoding = Encoding()
-
- ## Decoding blocks
- self.Decoding = Decoding(Ch=self.Ch, kernel_size=self.filter_size)
-
- ## Dense connection
- self.conv = nn.Conv2d(Ch, 32, kernel_size=3, stride=1, padding=1)
- self.Den_con1 = nn.Conv2d(32 , 32, kernel_size=1, stride=1, padding=0)
- self.Den_con2 = nn.Conv2d(32 * 2, 32, kernel_size=1, stride=1, padding=0)
- self.Den_con3 = nn.Conv2d(32 * 3, 32, kernel_size=1, stride=1, padding=0)
- self.Den_con4 = nn.Conv2d(32 * 4, 32, kernel_size=1, stride=1, padding=0)
- # self.Den_con5 = nn.Conv2d(32 * 5, 32, kernel_size=1, stride=1, padding=0)
- # self.Den_con6 = nn.Conv2d(32 * 6, 32, kernel_size=1, stride=1, padding=0)
-
-
- self.delta_0 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_1 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_2 = Parameter(torch.ones(1), requires_grad=True)
- self.delta_3 = Parameter(torch.ones(1), requires_grad=True)
- # self.delta_4 = Parameter(torch.ones(1), requires_grad=True)
- # self.delta_5 = Parameter(torch.ones(1), requires_grad=True)
-
- self._initialize_weights()
- torch.nn.init.normal_(self.delta_0, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_1, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_2, mean=0.1, std=0.01)
- torch.nn.init.normal_(self.delta_3, mean=0.1, std=0.01)
- # torch.nn.init.normal_(self.delta_4, mean=0.1, std=0.01)
- # torch.nn.init.normal_(self.delta_5, mean=0.1, std=0.01)
-
-
- def _initialize_weights(self):
- for m in self.modules():
- if isinstance(m, nn.Conv2d):
- nn.init.xavier_normal_(m.weight.data)
- nn.init.constant_(m.bias.data, 0.0)
- elif isinstance(m, nn.Linear):
- nn.init.xavier_normal_(m.weight.data)
- nn.init.constant_(m.bias.data, 0.0)
-
-
- def Filtering_1(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube, [self.filter_size[0] // 2, self.filter_size[0] // 2, 0, 0], mode='replicate')
- img_stack = []
- for i in range(self.filter_size[0]):
- img_stack.append(cube_pad[:, :, :, i:i + width])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def Filtering_2(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube, [0, 0, self.filter_size[1] // 2, self.filter_size[1] // 2], mode='replicate')
- img_stack = []
- for i in range(self.filter_size[1]):
- img_stack.append(cube_pad[:, :, i:i + height, :])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def Filtering_3(self, cube, core):
- batch_size, bandwidth, height, width = cube.size()
- cube_pad = F.pad(cube.unsqueeze(0).unsqueeze(0), pad=(0, 0, 0, 0, self.filter_size[2] // 2, self.filter_size[2] // 2)).squeeze(0).squeeze(0)
- img_stack = []
- for i in range(self.filter_size[2]):
- img_stack.append(cube_pad[:, i:i + bandwidth, :, :])
- img_stack = torch.stack(img_stack, dim=1)
- out = torch.sum(core.mul_(img_stack), dim=1, keepdim=False)
- return out
-
- def recon(self, res1, res2, Xt, i):
- if i == 0 :
- delta = self.delta_0
- elif i == 1:
- delta = self.delta_1
- elif i == 2:
- delta = self.delta_2
- elif i == 3:
- delta = self.delta_3
- # elif i == 4:
- # delta = self.delta_4
- # elif i == 5:
- # delta = self.delta_5
-
- Xt = Xt - 2 * delta * (res1 + res2)
- return Xt
-
- def y2x(self, y):
- ## Spilt operator
- sz = y.size()
- if len(sz) == 3:
- y = y.unsqueeze(1)
- bs = sz[0]
- sz = y.size()
- x = torch.zeros([bs, 28, sz[2], sz[2]]).cuda()
- for t in range(28):
- temp = y[:, :, :, 0 + 2 * t : sz[2] + 2 * t]
-
- x[:, t, :, :] = temp.squeeze(1)
- return x
-
- def x2y(self, x):
- ## Shift and Sum operator
- sz = x.size()
- if len(sz) == 3:
- x = x.unsqueeze(0).unsqueeze(0)
- bs = 1
- else:
- bs = sz[0]
- sz = x.size()
- y = torch.zeros([bs, sz[2], sz[2]+2*27]).cuda()
- for t in range(28):
- y[:, :, 0 + 2 * t : sz[2] + 2 * t] = x[:, t, :, :] + y[:, :, 0 + 2 * t : sz[2] + 2 * t]
- return y
-
- def forward(self, y, input_mask=None):
- ## The measurements y is split into a 3D data cube of size H × W × L to initialize x.
- y = y / 28 * 2
- Xt = self.y2x(y)
- feature_list = []
-
- for i in range(0, self.s):
- AXt = self.x2y(self.A(Xt)) # y = Ax
- Res1 = self.AT(self.y2x(AXt - y)) # A^T * (Ax − y)
-
- fea = self.conv(Xt)
-
- if i == 0:
- feature_list.append(fea)
- fufea = self.Den_con1(fea)
- elif i == 1:
- feature_list.append(fea)
- fufea = self.Den_con2(torch.cat(feature_list, 1))
- elif i == 2:
- feature_list.append(fea)
- fufea = self.Den_con3(torch.cat(feature_list, 1))
- elif i == 3:
- feature_list.append(fea)
- fufea = self.Den_con4(torch.cat(feature_list, 1))
- # elif i == 4:
- # feature_list.append(fea)
- # fufea = self.Den_con5(torch.cat(feature_list, 1))
- # elif i == 5:
- # feature_list.append(fea)
- # fufea = self.Den_con6(torch.cat(feature_list, 1))
-
- E1, E2, E3, E4, E5 = self.Encoding(fufea)
- W, f1, f2, f3 = self.Decoding(E1, E2, E3, E4, E5)
-
- batch_size, p, height, width = f1.size()
- f1 = F.normalize(f1.view(batch_size, self.filter_size[0], self.Ch, height, width),dim=1)
- batch_size, p, height, width = f2.size()
- f2 = F.normalize(f2.view(batch_size, self.filter_size[1], self.Ch, height, width),dim=1)
- batch_size, p, height, width = f3.size()
- f3 = F.normalize(f3.view(batch_size, self.filter_size[2], self.Ch, height, width),dim=1)
-
- ## Estimating the local means U
- u1 = self.Filtering_1(Xt, f1)
- u2 = self.Filtering_2(u1, f2)
- U = self.Filtering_3(u2, f3)
-
- ## w * (x − u)
- Res2 = (Xt - U).mul(W)
-
- ## Reconstructing HSIs
- Xt = self.recon(Res1, Res2, Xt, i)
-
- return Xt
diff --git a/MST/real/train_code/architecture/GAP_Net.py b/MST/real/train_code/architecture/GAP_Net.py
deleted file mode 100755
index 75b0b37..0000000
--- a/MST/real/train_code/architecture/GAP_Net.py
+++ /dev/null
@@ -1,189 +0,0 @@
-import torch.nn.functional as F
-import torch
-import torch.nn as nn
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- # nn.Conv2d(64, 64, (1,2), padding=(0,1)),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-
-class DoubleConv(nn.Module):
- """(convolution => [BN] => ReLU) * 2"""
-
- def __init__(self, in_channels, out_channels, mid_channels=None):
- super().__init__()
- if not mid_channels:
- mid_channels = out_channels
- self.double_conv = nn.Sequential(
- nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(mid_channels),
- nn.ReLU(inplace=True),
- nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(out_channels),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- return self.double_conv(x)
-
-class GAP_net(nn.Module):
-
- def __init__(self):
- super(GAP_net, self).__init__()
-
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
-
- def forward(self, y, input_mask=None):
- if input_mask==None:
- Phi = torch.rand((1,28,256,310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- x = At(y, Phi) # v0=H^T y
- ### 1-3
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet1(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet2(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet3(x)
- x = shift_3d(x)
- ### 4-6
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet4(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet5(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet6(x)
- x = shift_3d(x)
- # ### 7-9
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet7(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet8(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet9(x)
- x = shift_3d(x)
- return x[:, :, :, :384]
\ No newline at end of file
diff --git a/MST/real/train_code/architecture/HDNet.py b/MST/real/train_code/architecture/HDNet.py
deleted file mode 100755
index 71dce8c..0000000
--- a/MST/real/train_code/architecture/HDNet.py
+++ /dev/null
@@ -1,390 +0,0 @@
-import torch
-import torch.nn as nn
-import math
-
-def default_conv(in_channels, out_channels, kernel_size, bias=True):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias)
-
-class MeanShift(nn.Conv2d):
- def __init__(
- self, rgb_range,
- rgb_mean=(0.4488, 0.4371, 0.4040), rgb_std=(1.0, 1.0, 1.0), sign=-1):
-
- super(MeanShift, self).__init__(3, 3, kernel_size=1)
- std = torch.Tensor(rgb_std)
- self.weight.data = torch.eye(3).view(3, 3, 1, 1) / std.view(3, 1, 1, 1)
- self.bias.data = sign * rgb_range * torch.Tensor(rgb_mean) / std
- for p in self.parameters():
- p.requires_grad = False
-
-class BasicBlock(nn.Sequential):
- def __init__(
- self, conv, in_channels, out_channels, kernel_size, stride=1, bias=False,
- bn=True, act=nn.ReLU(True)):
-
- m = [conv(in_channels, out_channels, kernel_size, bias=bias)]
- if bn:
- m.append(nn.BatchNorm2d(out_channels))
- if act is not None:
- m.append(act)
-
- super(BasicBlock, self).__init__(*m)
-
-class ResBlock(nn.Module):
- def __init__(
- self, conv, n_feats, kernel_size,
- bias=True, bn=False, act=nn.ReLU(True), res_scale=1):
-
- super(ResBlock, self).__init__()
- m = []
- for i in range(2):
- m.append(conv(n_feats, n_feats, kernel_size, bias=bias))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if i == 0:
- m.append(act)
-
- self.body = nn.Sequential(*m)
- self.res_scale = res_scale
-
- def forward(self, x):
- res = self.body(x).mul(self.res_scale) # So res_scale is a scaler? just scale all elements in each feature's residual? Why?
- res += x
-
- return res
-
-class Upsampler(nn.Sequential):
- def __init__(self, conv, scale, n_feats, bn=False, act=False, bias=True):
-
- m = []
- if (scale & (scale - 1)) == 0:
- for _ in range(int(math.log(scale, 2))):
- m.append(conv(n_feats, 4 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(2))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
-
- elif scale == 3:
- m.append(conv(n_feats, 9 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(3))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
- else:
- raise NotImplementedError
-
- super(Upsampler, self).__init__(*m)
-
-_NORM_BONE = False
-
-def constant_init(module, val, bias=0):
- if hasattr(module, 'weight') and module.weight is not None:
- nn.init.constant_(module.weight, val)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-
-def kaiming_init(module,
- a=0,
- mode='fan_out',
- nonlinearity='relu',
- bias=0,
- distribution='normal'):
- assert distribution in ['uniform', 'normal']
- if distribution == 'uniform':
- nn.init.kaiming_uniform_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- else:
- nn.init.kaiming_normal_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-# depthwise-separable convolution (DSC)
-class DSC(nn.Module):
-
- def __init__(self, nin: int) -> None:
- super(DSC, self).__init__()
- self.conv_dws = nn.Conv2d(
- nin, nin, kernel_size=1, stride=1, padding=0, groups=nin
- )
- self.bn_dws = nn.BatchNorm2d(nin, momentum=0.9)
- self.relu_dws = nn.ReLU(inplace=False)
-
- self.maxpool = nn.MaxPool2d(kernel_size=3, stride=1, padding=1)
-
- self.conv_point = nn.Conv2d(
- nin, 1, kernel_size=1, stride=1, padding=0, groups=1
- )
- self.bn_point = nn.BatchNorm2d(1, momentum=0.9)
- self.relu_point = nn.ReLU(inplace=False)
-
- self.softmax = nn.Softmax(dim=2)
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- out = self.conv_dws(x)
- out = self.bn_dws(out)
- out = self.relu_dws(out)
-
- out = self.maxpool(out)
-
- out = self.conv_point(out)
- out = self.bn_point(out)
- out = self.relu_point(out)
-
- m, n, p, q = out.shape
- out = self.softmax(out.view(m, n, -1))
- out = out.view(m, n, p, q)
-
- out = out.expand(x.shape[0], x.shape[1], x.shape[2], x.shape[3])
-
- out = torch.mul(out, x)
-
- out = out + x
-
- return out
-
-# Efficient Feature Fusion(EFF)
-class EFF(nn.Module):
- def __init__(self, nin: int, nout: int, num_splits: int) -> None:
- super(EFF, self).__init__()
-
- assert nin % num_splits == 0
-
- self.nin = nin
- self.nout = nout
- self.num_splits = num_splits
- self.subspaces = nn.ModuleList(
- [DSC(int(self.nin / self.num_splits)) for i in range(self.num_splits)]
- )
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- sub_feat = torch.chunk(x, self.num_splits, dim=1)
- out = []
- for idx, l in enumerate(self.subspaces):
- out.append(self.subspaces[idx](sub_feat[idx]))
- out = torch.cat(out, dim=1)
-
- return out
-
-
-# spatial-spectral domain attention learning(SDL)
-class SDL_attention(nn.Module):
- def __init__(self, inplanes, planes, kernel_size=1, stride=1):
- super(SDL_attention, self).__init__()
-
- self.inplanes = inplanes
- self.inter_planes = planes // 2
- self.planes = planes
- self.kernel_size = kernel_size
- self.stride = stride
- self.padding = (kernel_size-1)//2
-
- self.conv_q_right = nn.Conv2d(self.inplanes, 1, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_v_right = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_up = nn.Conv2d(self.inter_planes, self.planes, kernel_size=1, stride=1, padding=0, bias=False)
- self.softmax_right = nn.Softmax(dim=2)
- self.sigmoid = nn.Sigmoid()
-
- self.conv_q_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #g
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.conv_v_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #theta
- self.softmax_left = nn.Softmax(dim=2)
-
- self.reset_parameters()
-
- def reset_parameters(self):
- kaiming_init(self.conv_q_right, mode='fan_in')
- kaiming_init(self.conv_v_right, mode='fan_in')
- kaiming_init(self.conv_q_left, mode='fan_in')
- kaiming_init(self.conv_v_left, mode='fan_in')
-
- self.conv_q_right.inited = True
- self.conv_v_right.inited = True
- self.conv_q_left.inited = True
- self.conv_v_left.inited = True
- # HR spatial attention
- def spatial_attention(self, x):
- input_x = self.conv_v_right(x)
- batch, channel, height, width = input_x.size()
-
- input_x = input_x.view(batch, channel, height * width)
- context_mask = self.conv_q_right(x)
- context_mask = context_mask.view(batch, 1, height * width)
- context_mask = self.softmax_right(context_mask)
-
- context = torch.matmul(input_x, context_mask.transpose(1,2))
- context = context.unsqueeze(-1)
- context = self.conv_up(context)
-
- mask_ch = self.sigmoid(context)
-
- out = x * mask_ch
-
- return out
- # HR spectral attention
- def spectral_attention(self, x):
-
- g_x = self.conv_q_left(x)
- batch, channel, height, width = g_x.size()
-
- avg_x = self.avg_pool(g_x)
- batch, channel, avg_x_h, avg_x_w = avg_x.size()
-
- avg_x = avg_x.view(batch, channel, avg_x_h * avg_x_w).permute(0, 2, 1)
- theta_x = self.conv_v_left(x).view(batch, self.inter_planes, height * width)
- context = torch.matmul(avg_x, theta_x)
- context = self.softmax_left(context)
- context = context.view(batch, 1, height, width)
-
- mask_sp = self.sigmoid(context)
-
- out = x * mask_sp
-
- return out
-
- def forward(self, x):
- context_spectral = self.spectral_attention(x)
- context_spatial = self.spatial_attention(x)
- out = context_spatial + context_spectral
- return out
-
-
-class HDNet(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28, conv=default_conv):
- super(HDNet, self).__init__()
-
- n_resblocks = 16
- n_feats = 64
- kernel_size = 3
- act = nn.ReLU(True)
-
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- # define head module
- m_head = [conv(in_ch, n_feats, kernel_size)]
-
- # define body module
- m_body = [
- ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ) for _ in range(n_resblocks)
- ]
- m_body.append(SDL_attention(inplanes = n_feats, planes = n_feats))
- m_body.append(EFF(nin=n_feats, nout=n_feats, num_splits=4))
-
- for i in range(1, n_resblocks):
- m_body.append(ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ))
-
- m_body.append(conv(n_feats, n_feats, kernel_size))
-
- m_tail = [conv(n_feats, out_ch, kernel_size)]
-
- self.head = nn.Sequential(*m_head)
- self.body = nn.Sequential(*m_body)
- self.tail = nn.Sequential(*m_tail)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
-
- x = self.initial_x(x)
-
- x = self.head(x)
-
- res = self.body(x)
- res += x
-
- x = self.tail(res)
-
- return x
-
-# frequency domain learning(FDL)
-class FDL(nn.Module):
- def __init__(self, loss_weight=1.0, alpha=1.0, patch_factor=1, ave_spectrum=False, log_matrix=False, batch_matrix=False):
- super(FDL, self).__init__()
- self.loss_weight = loss_weight
- self.alpha = alpha
- self.patch_factor = patch_factor
- self.ave_spectrum = ave_spectrum
- self.log_matrix = log_matrix
- self.batch_matrix = batch_matrix
-
- def tensor2freq(self, x):
- patch_factor = self.patch_factor
- _, _, h, w = x.shape
- assert h % patch_factor == 0 and w % patch_factor == 0, (
- 'Patch factor should be divisible by image height and width')
- patch_list = []
- patch_h = h // patch_factor
- patch_w = w // patch_factor
- for i in range(patch_factor):
- for j in range(patch_factor):
- patch_list.append(x[:, :, i * patch_h:(i + 1) * patch_h, j * patch_w:(j + 1) * patch_w])
-
- y = torch.stack(patch_list, 1)
-
- return torch.rfft(y, 2, onesided=False, normalized=True)
-
- def loss_formulation(self, recon_freq, real_freq, matrix=None):
- if matrix is not None:
- weight_matrix = matrix.detach()
- else:
- matrix_tmp = (recon_freq - real_freq) ** 2
- matrix_tmp = torch.sqrt(matrix_tmp[..., 0] + matrix_tmp[..., 1]) ** self.alpha
- if self.log_matrix:
- matrix_tmp = torch.log(matrix_tmp + 1.0)
-
- if self.batch_matrix:
- matrix_tmp = matrix_tmp / matrix_tmp.max()
- else:
- matrix_tmp = matrix_tmp / matrix_tmp.max(-1).values.max(-1).values[:, :, :, None, None]
-
- matrix_tmp[torch.isnan(matrix_tmp)] = 0.0
- matrix_tmp = torch.clamp(matrix_tmp, min=0.0, max=1.0)
- weight_matrix = matrix_tmp.clone().detach()
-
- assert weight_matrix.min().item() >= 0 and weight_matrix.max().item() <= 1, (
- 'The values of spectrum weight matrix should be in the range [0, 1], '
- 'but got Min: %.10f Max: %.10f' % (weight_matrix.min().item(), weight_matrix.max().item()))
-
- tmp = (recon_freq - real_freq) ** 2
- freq_distance = tmp[..., 0] + tmp[..., 1]
-
- loss = weight_matrix * freq_distance
- return torch.mean(loss)
-
- def forward(self, pred, target, matrix=None, **kwargs):
-
- pred_freq = self.tensor2freq(pred)
- target_freq = self.tensor2freq(target)
-
- if self.ave_spectrum:
- pred_freq = torch.mean(pred_freq, 0, keepdim=True)
- target_freq = torch.mean(target_freq, 0, keepdim=True)
-
- return self.loss_formulation(pred_freq, target_freq, matrix) * self.loss_weight
diff --git a/MST/real/train_code/architecture/Lambda_Net.py b/MST/real/train_code/architecture/Lambda_Net.py
deleted file mode 100755
index f878177..0000000
--- a/MST/real/train_code/architecture/Lambda_Net.py
+++ /dev/null
@@ -1,180 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-
-class LambdaNetAttention(nn.Module):
- def __init__(
- self,
- dim,
- ):
- super().__init__()
-
- self.dim = dim
- self.to_q = nn.Linear(dim, dim//8, bias=False)
- self.to_k = nn.Linear(dim, dim//8, bias=False)
- self.to_v = nn.Linear(dim, dim, bias=False)
- self.rescale = (dim//8)**-0.5
- self.gamma = nn.Parameter(torch.ones(1))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0,2,3,1)
- b, h, w, c = x.shape
-
- # Reshape to (B,N,C), where N = window_size[0]*window_size[1] is the length of sentence
- x_inp = rearrange(x, 'b h w c -> b (h w) c')
-
- # produce query, key and value
- q = self.to_q(x_inp)
- k = self.to_k(x_inp)
- v = self.to_v(x_inp)
-
- # attention
- sim = einsum('b i d, b j d -> b i j', q, k)*self.rescale
- attn = sim.softmax(dim=-1)
-
- # aggregate
- out = einsum('b i j, b j d -> b i d', attn, v)
-
- # merge blocks back to original feature map
- out = rearrange(out, 'b (h w) c -> b h w c', h=h, w=w)
- out = self.gamma*out + x
- return out.permute(0,3,1,2)
-
-class triple_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(triple_conv, self).__init__()
- self.t_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.t_conv(x)
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class Lambda_Net(nn.Module):
-
- def __init__(self, out_ch=28):
- super(Lambda_Net, self).__init__()
- self.conv_in = nn.Conv2d(1+28, 28, 3, padding=1)
-
- # encoder
- self.conv_down1 = triple_conv(28, 32)
- self.conv_down2 = triple_conv(32, 64)
- self.conv_down3 = triple_conv(64, 128)
- self.conv_down4 = triple_conv(128, 256)
- self.conv_down5 = double_conv(256, 512)
- self.conv_down6 = double_conv(512, 1024)
-
- self.maxpool = nn.MaxPool2d(2)
-
- # decoder
- self.upsample5 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
- self.upsample4 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
- self.upsample3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
- self.upsample2 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
- self.upsample1 = nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2)
-
- self.conv_up1 = triple_conv(32+32, 32)
- self.conv_up2 = triple_conv(64+64, 64)
- self.conv_up3 = triple_conv(128+128, 128)
- self.conv_up4 = triple_conv(256+256, 256)
- self.conv_up5 = double_conv(512+512, 512)
-
- # attention
- self.attention = LambdaNetAttention(dim=128)
-
- self.conv_last1 = nn.Conv2d(32, 6, 3,1,1)
- self.conv_last2 = nn.Conv2d(38, 32, 3,1,1)
- self.conv_last3 = nn.Conv2d(32, 12, 3,1,1)
- self.conv_last4 = nn.Conv2d(44, 32, 3,1,1)
- self.conv_last5 = nn.Conv2d(32, out_ch, 1)
- self.act = nn.ReLU()
-
- def forward(self, x, input_mask=None):
- if input_mask == None:
- input_mask = torch.zeros((1,28,256,310)).cuda()
- x = x/28*2
- x = self.conv_in(torch.cat([x.unsqueeze(1), input_mask], dim=1))
- b, c, h_inp, w_inp = x.shape
- hb, wb = 32, 32
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- res0 = x
- conv1 = self.conv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.conv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.conv_down3(x)
- x = self.maxpool(conv3)
- conv4 = self.conv_down4(x)
- x = self.maxpool(conv4)
- conv5 = self.conv_down5(x)
- x = self.maxpool(conv5)
- conv6 = self.conv_down6(x)
-
- x = self.upsample5(conv6)
- x = torch.cat([x, conv5], dim=1)
- x = self.conv_up5(x)
-
- x = self.upsample4(x)
- x = torch.cat([x, conv4], dim=1)
- x = self.conv_up4(x)
-
- x = self.upsample3(x)
- x = torch.cat([x, conv3], dim=1)
- x = self.conv_up3(x)
- x = self.attention(x)
-
- x = self.upsample2(x)
- x = torch.cat([x, conv2], dim=1)
- x = self.conv_up2(x)
-
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
- x = self.conv_up1(x)
-
- res1 = x
- out1 = self.act(self.conv_last1(x))
- x = self.conv_last2(torch.cat([res1,out1],dim=1))
-
- res2 = x
- out2 = self.act(self.conv_last3(x))
- out3 = self.conv_last4(torch.cat([res2, out2], dim=1))
-
- out = self.conv_last5(out3)+res0
- out = out[:, :, :h_inp, :w_inp]
-
- return shift_back_3d(out)[:, :, :, :384]
-
diff --git a/MST/real/train_code/architecture/MST.py b/MST/real/train_code/architecture/MST.py
deleted file mode 100755
index e82b77c..0000000
--- a/MST/real/train_code/architecture/MST.py
+++ /dev/null
@@ -1,294 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class MST(nn.Module):
- def __init__(self, dim=28, stage=3, num_blocks=[2,2,2]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(28, self.dim, 3, 1, 1, bias=False)
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, 28, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
- """
- x: [b,h,w]
- return out:[b,c,h,w]
- """
-
- x = self.initial_x(x)
-
- # Embedding
- fea = self.lrelu(self.embedding(x))
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/train_code/architecture/MST_Plus_Plus.py b/MST/real/train_code/architecture/MST_Plus_Plus.py
deleted file mode 100755
index 2b93eb1..0000000
--- a/MST/real/train_code/architecture/MST_Plus_Plus.py
+++ /dev/null
@@ -1,324 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- v = v
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class MST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-class MST_Plus_Plus(nn.Module):
- def __init__(self, in_channels=3, out_channels=28, n_feat=28, stage=3):
- super(MST_Plus_Plus, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False)
- modules_body = [MST(dim=n_feat, stage=2, num_blocks=[1,1,1]) for _ in range(stage)]
- self.fution = nn.Conv2d(28, 28, 1, padding=0, bias=True)
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- x = self.initial_x(x)
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/real/train_code/architecture/TSA_Net.py b/MST/real/train_code/architecture/TSA_Net.py
deleted file mode 100755
index 85a03d2..0000000
--- a/MST/real/train_code/architecture/TSA_Net.py
+++ /dev/null
@@ -1,350 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-import numpy as np
-_NORM_BONE = False
-
-
-def conv_block(in_planes, out_planes, the_kernel=3, the_stride=1, the_padding=1, flag_norm=False, flag_norm_act=True):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=the_kernel, stride=the_stride, padding=the_padding)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_planes)
- if flag_norm:
- return nn.Sequential(conv,norm,activation) if flag_norm_act else nn.Sequential(conv,activation,norm)
- else:
- return nn.Sequential(conv,activation)
-
-def conv1x1_block(in_planes, out_planes, flag_norm=False):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=1, stride=1, padding=0,bias=False)
- norm = nn.BatchNorm2d(out_planes)
- return nn.Sequential(conv,norm) if flag_norm else conv
-
-def fully_block(in_dim, out_dim, flag_norm=False, flag_norm_act=True):
- fc = nn.Linear(in_dim, out_dim)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_dim)
- if flag_norm:
- return nn.Sequential(fc,norm,activation) if flag_norm_act else nn.Sequential(fc,activation,norm)
- else:
- return nn.Sequential(fc,activation)
-
-class Res2Net(nn.Module):
- def __init__(self, inChannel, uPlane, scale=4):
- super(Res2Net, self).__init__()
- self.uPlane = uPlane
- self.scale = scale
-
- self.conv_init = nn.Conv2d(inChannel, uPlane * scale, kernel_size=1, bias=False)
- self.bn_init = nn.BatchNorm2d(uPlane * scale)
-
- convs = []
- bns = []
- for i in range(self.scale - 1):
- convs.append(nn.Conv2d(self.uPlane, self.uPlane, kernel_size=3, stride=1, padding=1, bias=False))
- bns.append(nn.BatchNorm2d(self.uPlane))
- self.convs = nn.ModuleList(convs)
- self.bns = nn.ModuleList(bns)
-
- self.conv_end = nn.Conv2d(uPlane * scale, inChannel, kernel_size=1, bias=False)
- self.bn_end = nn.BatchNorm2d(inChannel)
-
- self.relu = nn.ReLU(inplace=True)
-
- def forward(self, x):
-
- out = self.conv_init(x)
- out = self.bn_init(out)
- out = self.relu(out)
-
- spx = torch.split(out, self.uPlane, 1)
- for i in range(self.scale - 1):
- if i == 0:
- sp = spx[i]
- else:
- sp = sp + spx[i]
- sp = self.convs[i](sp)
- sp = self.relu(self.bns[i](sp))
- if i == 0:
- out = sp
- else:
- out = torch.cat((out, sp), 1)
- out = torch.cat((out, spx[self.scale - 1]), 1)
-
- out = self.conv_end(out)
- out = self.bn_end(out)
- return out
-
-_NORM_ATTN = True
-_NORM_FC = False
-
-
-class TSA_Transform(nn.Module):
- """ Spectral-Spatial Self-Attention """
-
- def __init__(self, uSpace, inChannel, outChannel, nHead, uAttn, mode=[0, 1], flag_mask=False, gamma_learn=False):
- super(TSA_Transform, self).__init__()
- ''' ------------------------------------------
- uSpace:
- uHeight: the [-2] dim of the 3D tensor
- uWidth: the [-1] dim of the 3D tensor
- inChannel:
- the number of Channel of the input tensor
- outChannel:
- the number of Channel of the output tensor
- nHead:
- the number of Head of the input tensor
- uAttn:
- uSpatial: the dim of the spatial features
- uSpectral: the dim of the spectral features
- mask:
- The Spectral Smoothness Mask
- {mode} and {gamma_learn} is just for variable selection
- ------------------------------------------ '''
-
- self.nHead = nHead
- self.uAttn = uAttn
- self.outChannel = outChannel
- self.uSpatial = nn.Parameter(torch.tensor(float(uAttn[0])), requires_grad=False)
- self.uSpectral = nn.Parameter(torch.tensor(float(uAttn[1])), requires_grad=False)
- self.mask = nn.Parameter(Spectral_Mask(outChannel), requires_grad=False) if flag_mask else None
- self.attn_scale = nn.Parameter(torch.tensor(1.1), requires_grad=False) if flag_mask else None
- self.gamma = nn.Parameter(torch.tensor(1.0), requires_grad=gamma_learn)
-
- if sum(mode) > 0:
- down_sample = []
- scale = 1
- cur_channel = outChannel
- for i in range(sum(mode)):
- scale *= 2
- down_sample.append(conv_block(cur_channel, 2 * cur_channel, 3, 2, 1, _NORM_ATTN))
- cur_channel = 2 * cur_channel
- self.cur_channel = cur_channel
- self.down_sample = nn.Sequential(*down_sample)
- self.up_sample = nn.ConvTranspose2d(outChannel * scale, outChannel, scale, scale)
- else:
- self.down_sample = None
- self.up_sample = None
-
- spec_dim = int(uSpace[0] / 4 - 3) * int(uSpace[1] / 4 - 3)
- self.preproc = conv1x1_block(inChannel, outChannel, _NORM_ATTN)
- self.query_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.query_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.query_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.key_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.key_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.key_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.value = conv1x1_block(outChannel, nHead * outChannel, _NORM_ATTN)
- self.aggregation = nn.Linear(nHead * outChannel, outChannel)
-
- def forward(self, image):
- feat = self.preproc(image)
- feat_qx = self.query_x(feat, 'X')
- feat_qy = self.query_y(feat, 'Y')
- feat_qlambda = self.query_lambda(feat)
- feat_kx = self.key_x(feat, 'X')
- feat_ky = self.key_y(feat, 'Y')
- feat_klambda = self.key_lambda(feat)
- feat_value = self.value(feat)
-
- feat_qx = torch.cat(torch.split(feat_qx, 1, dim=1)).squeeze(dim=1)
- feat_qy = torch.cat(torch.split(feat_qy, 1, dim=1)).squeeze(dim=1)
- feat_kx = torch.cat(torch.split(feat_kx, 1, dim=1)).squeeze(dim=1)
- feat_ky = torch.cat(torch.split(feat_ky, 1, dim=1)).squeeze(dim=1)
- feat_qlambda = torch.cat(torch.split(feat_qlambda, self.uAttn[1], dim=-1))
- feat_klambda = torch.cat(torch.split(feat_klambda, self.uAttn[1], dim=-1))
- feat_value = torch.cat(torch.split(feat_value, self.outChannel, dim=1))
-
- energy_x = torch.bmm(feat_qx, feat_kx.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_y = torch.bmm(feat_qy, feat_ky.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_lambda = torch.bmm(feat_qlambda, feat_klambda.permute(0, 2, 1)) / torch.sqrt(self.uSpectral)
-
- attn_x = F.softmax(energy_x, dim=-1)
- attn_y = F.softmax(energy_y, dim=-1)
- attn_lambda = F.softmax(energy_lambda, dim=-1)
- if self.mask is not None:
- attn_lambda = (attn_lambda + self.mask) / torch.sqrt(self.attn_scale)
-
- pro_feat = feat_value if self.down_sample is None else self.down_sample(feat_value)
- batchhead, dim_c, dim_x, dim_y = pro_feat.size()
- attn_x_repeat = attn_x.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_x, dim_x)
- attn_y_repeat = attn_y.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_y, dim_y)
- pro_feat = pro_feat.view(-1, dim_x, dim_y)
- pro_feat = torch.bmm(pro_feat, attn_y_repeat.permute(0, 2, 1))
- pro_feat = torch.bmm(pro_feat.permute(0, 2, 1), attn_x_repeat.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, dim_c, dim_x, dim_y)
-
- if self.up_sample is not None:
- pro_feat = self.up_sample(pro_feat)
- _, _, dim_x, dim_y = pro_feat.size()
- pro_feat = pro_feat.contiguous().view(batchhead, self.outChannel, -1).permute(0, 2, 1)
- pro_feat = torch.bmm(pro_feat, attn_lambda.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, self.outChannel, dim_x, dim_y)
- pro_feat = torch.cat(torch.split(pro_feat, int(batchhead / self.nHead), dim=0), dim=1).permute(0, 2, 3, 1)
- pro_feat = self.aggregation(pro_feat).permute(0, 3, 1, 2)
- out = self.gamma * pro_feat + feat
- return out, (attn_x, attn_y, attn_lambda)
-
-
-class Feature_Spatial(nn.Module):
- """ Spatial Feature Generation Component """
-
- def __init__(self, inChannel, nHead, shiftDim, outDim, mode):
- super(Feature_Spatial, self).__init__()
- kernel = [(1, 5), (3, 5)]
- stride = [(1, 2), (2, 2)]
- padding = [(0, 2), (1, 2)]
- self.conv1 = conv_block(inChannel, nHead, kernel[mode[0]], stride[mode[0]], padding[mode[0]], _NORM_ATTN)
- self.conv2 = conv_block(nHead, nHead, kernel[mode[1]], stride[mode[1]], padding[mode[1]], _NORM_ATTN)
- self.fully = fully_block(shiftDim, outDim, _NORM_FC)
-
- def forward(self, image, direction):
- if direction == 'Y':
- image = image.permute(0, 1, 3, 2)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- # import pdb; pdb.set_trace()
- feat = self.fully(feat)
- return feat
-
-
-class Feature_Spectral(nn.Module):
- """ Spectral Feature Generation Component """
-
- def __init__(self, inChannel, nHead, viewDim, outDim):
- super(Feature_Spectral, self).__init__()
- self.inChannel = inChannel
- self.conv1 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.conv2 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.fully = fully_block(viewDim, int(nHead * outDim), _NORM_FC)
-
- def forward(self, image):
- bs = image.size(0)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = feat.view(bs, self.inChannel, -1)
- feat = self.fully(feat)
- return feat
-
-
-def Spectral_Mask(dim_lambda):
- '''After put the available data into the model, we use this mask to avoid outputting the estimation of itself.'''
- orig = (np.cos(np.linspace(-1, 1, num=2 * dim_lambda - 1) * np.pi) + 1.0) / 2.0
- att = np.zeros((dim_lambda, dim_lambda))
- for i in range(dim_lambda):
- att[i, :] = orig[dim_lambda - 1 - i:2 * dim_lambda - 1 - i]
- AM_Mask = torch.from_numpy(att.astype(np.float32)).unsqueeze(0)
- return AM_Mask
-
-class TSA_Net(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28):
- super(TSA_Net, self).__init__()
-
- self.tconv_down1 = Encoder_Triblock(in_ch, 64, False)
- self.tconv_down2 = Encoder_Triblock(64, 128, False)
- self.tconv_down3 = Encoder_Triblock(128, 256)
- self.tconv_down4 = Encoder_Triblock(256, 512)
-
- self.bottom1 = conv_block(512, 1024)
- self.bottom2 = conv_block(1024, 1024)
-
- self.tconv_up4 = Decoder_Triblock(1024, 512)
- self.tconv_up3 = Decoder_Triblock(512, 256)
- self.transform3 = TSA_Transform((96, 96), 256, 256, 8, (64, 80), [0, 0])
- self.tconv_up2 = Decoder_Triblock(256, 128)
- self.transform2 = TSA_Transform((192, 192), 128, 128, 8, (64, 40), [1, 0])
- self.tconv_up1 = Decoder_Triblock(128, 64)
- self.transform1 = TSA_Transform((384, 384), 64, 28, 8, (48, 30), [1, 1], True)
-
- self.conv_last = nn.Conv2d(out_ch, out_ch, 1)
- self.afn_last = nn.Sigmoid()
- self.fution = nn.Conv2d(28, 28, 3, 1, 1, bias=False)
-
- def initial_x(self, y):
- """
- :param y: [b,1,256,310]
- :param Phi: [b,28,256,310]
- :return: z: [b,28,256,310]
- """
- nC, step = 28, 2
- bs, row, col = y.shape
- x = torch.zeros(bs, nC, row, row).cuda().float()
- for i in range(nC):
- x[:, i, :, :] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- x = self.fution(x)
- return x
-
- def forward(self, x, input_mask=None):
-
- x = self.initial_x(x)
- # print(x.shape)
-
- enc1, enc1_pre = self.tconv_down1(x)
- enc2, enc2_pre = self.tconv_down2(enc1)
- enc3, enc3_pre = self.tconv_down3(enc2)
- enc4, enc4_pre = self.tconv_down4(enc3)
- # enc5,enc5_pre = self.tconv_down5(enc4)
-
- bottom = self.bottom1(enc4)
- bottom = self.bottom2(bottom)
-
- # dec5 = self.tconv_up5(bottom,enc5_pre)
- dec4 = self.tconv_up4(bottom, enc4_pre)
- dec3 = self.tconv_up3(dec4, enc3_pre)
- dec3, _ = self.transform3(dec3)
- dec2 = self.tconv_up2(dec3, enc2_pre)
- dec2, _ = self.transform2(dec2)
- dec1 = self.tconv_up1(dec2, enc1_pre)
- dec1, _ = self.transform1(dec1)
-
- dec1 = self.conv_last(dec1)
- output = self.afn_last(dec1)
-
- return output
-
-
-class Encoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Encoder_Triblock, self).__init__()
-
- self.layer1 = conv_block(inChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
- if flag_res:
- self.layer2 = Res2Net(outChannel, int(outChannel / 4))
- else:
- self.layer2 = conv_block(outChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- self.pool = nn.MaxPool2d(nPool) if flag_Pool else None
-
- def forward(self, x):
- feat = self.layer1(x)
- feat = self.layer2(feat)
-
- feat_pool = self.pool(feat) if self.pool is not None else feat
- return feat_pool, feat
-
-
-class Decoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Decoder_Triblock, self).__init__()
-
- self.layer1 = nn.Sequential(
- nn.ConvTranspose2d(inChannel, outChannel, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- if flag_res:
- self.layer2 = Res2Net(int(outChannel * 2), int(outChannel / 2))
- else:
- self.layer2 = conv_block(outChannel * 2, outChannel * 2, nKernal, flag_norm=_NORM_BONE)
- self.layer3 = conv_block(outChannel * 2, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- def forward(self, feat_dec, feat_enc):
- feat_dec = self.layer1(feat_dec)
- diffY = feat_enc.size()[2] - feat_dec.size()[2]
- diffX = feat_enc.size()[3] - feat_dec.size()[3]
- if diffY != 0 or diffX != 0:
- print('Padding for size mismatch ( Enc:', feat_enc.size(), 'Dec:', feat_dec.size(), ')')
- feat_dec = F.pad(feat_dec, [diffX // 2, diffX - diffX // 2, diffY // 2, diffY - diffY // 2])
- feat = torch.cat([feat_dec, feat_enc], dim=1)
- feat = self.layer2(feat)
- feat = self.layer3(feat)
- return feat
\ No newline at end of file
diff --git a/MST/real/train_code/architecture/__init__.py b/MST/real/train_code/architecture/__init__.py
deleted file mode 100755
index b049a2b..0000000
--- a/MST/real/train_code/architecture/__init__.py
+++ /dev/null
@@ -1,67 +0,0 @@
-import torch
-from .MST import MST
-from .GAP_Net import GAP_net
-from .ADMM_Net import ADMM_net
-from .TSA_Net import TSA_Net
-from .HDNet import HDNet, FDL
-from .DGSMP import HSI_CS
-from .BIRNAT import BIRNAT
-from .MST_Plus_Plus import MST_Plus_Plus
-from .Lambda_Net import Lambda_Net
-from .CST import CST
-from .DAUHST import DAUHST
-from .BiSRNet import BiSRNet
-
-def model_generator(method, pretrained_model_path=None):
- if method == 'mst_s':
- model = MST(dim=28, stage=2, num_blocks=[2, 2, 2]).cuda()
- elif method == 'mst_m':
- model = MST(dim=28, stage=2, num_blocks=[2, 4, 4]).cuda()
- elif method == 'mst_l':
- model = MST(dim=28, stage=2, num_blocks=[4, 7, 5]).cuda()
- elif method == 'gap_net':
- model = GAP_net().cuda()
- elif method == 'admm_net':
- model = ADMM_net().cuda()
- elif method == 'tsa_net':
- model = TSA_Net().cuda()
- elif method == 'hdnet':
- model = HDNet().cuda()
- fdl_loss = FDL(loss_weight=0.7,
- alpha=2.0,
- patch_factor=4,
- ave_spectrum=True,
- log_matrix=True,
- batch_matrix=True,
- ).cuda()
- elif method == 'dgsmp':
- model = HSI_CS(Ch=28, stages=4).cuda()
- elif method == 'birnat':
- model = BIRNAT().cuda()
- elif method == 'mst_plus_plus':
- model = MST_Plus_Plus(in_channels=28, out_channels=28, n_feat=28, stage=3).cuda()
- elif method == 'lambda_net':
- model = Lambda_Net(out_ch=28).cuda()
- elif method == 'cst_s':
- model = CST(num_blocks=[1, 1, 2], sparse=True).cuda()
- elif method == 'cst_m':
- model = CST(num_blocks=[2, 2, 2], sparse=True).cuda()
- elif method == 'cst_l':
- model = CST(num_blocks=[2, 4, 6], sparse=True).cuda()
- elif method == 'cst_l_plus':
- model = CST(num_blocks=[2, 4, 6], sparse=False).cuda()
- elif method == 'bisrnet':
- model = BiSRNet(in_channels=28, out_channels=28, n_feat=28, stage=1, num_blocks=[1,1,1]).cuda()
- elif 'dauhst' in method:
- num_iterations = int(method.split('_')[1][0])
- model = DAUHST(num_iterations=num_iterations).cuda()
- else:
- print(f'Method {method} is not defined !!!!')
- if pretrained_model_path is not None:
- print(f'load model from {pretrained_model_path}')
- checkpoint = torch.load(pretrained_model_path)
- model.load_state_dict({k.replace('module.', ''): v for k, v in checkpoint.items()},
- strict=True)
- if method == 'hdnet':
- return model, fdl_loss
- return model
\ No newline at end of file
diff --git a/MST/real/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc
deleted file mode 100755
index fb6b7c1..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc
deleted file mode 100755
index 3f04a00..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/CST.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/CST.cpython-36.pyc
deleted file mode 100755
index fde5864..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/CST.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc
deleted file mode 100755
index 1482c06..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc
deleted file mode 100755
index 00f967b..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/HDNet.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/HDNet.cpython-36.pyc
deleted file mode 100755
index 04b112e..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/HDNet.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc
deleted file mode 100755
index d2f89f6..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/MST.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/MST.cpython-36.pyc
deleted file mode 100755
index cb2944e..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/MST.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc
deleted file mode 100755
index fcff4f8..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc
deleted file mode 100755
index d2b85f3..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/architecture/__pycache__/__init__.cpython-36.pyc b/MST/real/train_code/architecture/__pycache__/__init__.cpython-36.pyc
deleted file mode 100755
index c2f4d73..0000000
Binary files a/MST/real/train_code/architecture/__pycache__/__init__.cpython-36.pyc and /dev/null differ
diff --git a/MST/real/train_code/dataset.py b/MST/real/train_code/dataset.py
deleted file mode 100755
index 284b29d..0000000
--- a/MST/real/train_code/dataset.py
+++ /dev/null
@@ -1,96 +0,0 @@
-import torch.utils.data as tud
-import random
-import torch
-import numpy as np
-import scipy.io as sio
-
-
-class dataset(tud.Dataset):
- def __init__(self, opt, CAVE, KAIST):
- super(dataset, self).__init__()
- self.isTrain = opt.isTrain
- self.size = opt.size
- # self.path = opt.data_path
- if self.isTrain == True:
- self.num = opt.trainset_num
- else:
- self.num = opt.testset_num
- self.CAVE = CAVE
- self.KAIST = KAIST
- ## load mask
- data = sio.loadmat(opt.mask_path)
- self.mask = data['mask']
- self.mask_3d = np.tile(self.mask[:, :, np.newaxis], (1, 1, 28))
-
- def __getitem__(self, index):
- if self.isTrain == True:
- # index1 = 0; d=0
- index1 = random.randint(0, 29)
- d = random.randint(0, 1)
- if d == 0:
- hsi = self.CAVE[:,:,:,index1]
- else:
- hsi = self.KAIST[:, :, :, index1]
- else:
- index1 = index
- hsi = self.HSI[:, :, :, index1]
- shape = np.shape(hsi)
-
- px = random.randint(0, shape[0] - self.size)
- py = random.randint(0, shape[1] - self.size)
- label = hsi[px:px + self.size:1, py:py + self.size:1, :]
- # while np.max(label)==0:
- # px = random.randint(0, shape[0] - self.size)
- # py = random.randint(0, shape[1] - self.size)
- # label = hsi[px:px + self.size:1, py:py + self.size:1, :]
- # print(np.min(), np.max())
-
- pxm = random.randint(0, 660 - self.size)
- pym = random.randint(0, 660 - self.size)
- mask_3d = self.mask_3d[pxm:pxm + self.size:1, pym:pym + self.size:1, :]
-
- mask_3d_shift = np.zeros((self.size, self.size + (28 - 1) * 2, 28))
- mask_3d_shift[:, 0:self.size, :] = mask_3d
- for t in range(28):
- mask_3d_shift[:, :, t] = np.roll(mask_3d_shift[:, :, t], 2 * t, axis=1)
- mask_3d_shift_s = np.sum(mask_3d_shift ** 2, axis=2, keepdims=False)
- mask_3d_shift_s[mask_3d_shift_s == 0] = 1
-
- if self.isTrain == True:
-
- rotTimes = random.randint(0, 3)
- vFlip = random.randint(0, 1)
- hFlip = random.randint(0, 1)
-
- # Random rotation
- for j in range(rotTimes):
- label = np.rot90(label)
-
- # Random vertical Flip
- for j in range(vFlip):
- label = label[:, ::-1, :].copy()
-
- # Random horizontal Flip
- for j in range(hFlip):
- label = label[::-1, :, :].copy()
-
- temp = mask_3d * label
- temp_shift = np.zeros((self.size, self.size + (28 - 1) * 2, 28))
- temp_shift[:, 0:self.size, :] = temp
- for t in range(28):
- temp_shift[:, :, t] = np.roll(temp_shift[:, :, t], 2 * t, axis=1)
- meas = np.sum(temp_shift, axis=2)
- input = meas / 28 * 2 * 1.2
-
- QE, bit = 0.4, 2048
- input = np.random.binomial((input * bit / QE).astype(int), QE)
- input = np.float32(input) / np.float32(bit)
-
- label = torch.FloatTensor(label.copy()).permute(2,0,1)
- input = torch.FloatTensor(input.copy())
- mask_3d_shift = torch.FloatTensor(mask_3d_shift.copy()).permute(2,0,1)
- mask_3d_shift_s = torch.FloatTensor(mask_3d_shift_s.copy())
- return input, label, mask_3d, mask_3d_shift, mask_3d_shift_s
-
- def __len__(self):
- return self.num
diff --git a/MST/real/train_code/option.py b/MST/real/train_code/option.py
deleted file mode 100755
index 67f1ca6..0000000
--- a/MST/real/train_code/option.py
+++ /dev/null
@@ -1,53 +0,0 @@
-import argparse
-import template
-
-parser = argparse.ArgumentParser(description="HyperSpectral Image Reconstruction Toolbox")
-parser.add_argument('--template', default='mst',
- help='You can set various templates in option.py')
-
-# Hardware specifications
-parser.add_argument("--gpu_id", type=str, default='0')
-
-# Data specifications
-parser.add_argument('--data_root', type=str, default='../../datasets/', help='dataset directory')
-parser.add_argument('--data_path_CAVE', default='../../datasets/CAVE_512_28/', type=str,
- help='path of data')
-parser.add_argument('--data_path_KAIST', default='../../datasets/KAIST_CVPR2021/', type=str,
- help='path of data')
-parser.add_argument('--mask_path', default='../../datasets/TSA_real_data/mask.mat', type=str,
- help='path of mask')
-
-# Saving specifications
-parser.add_argument('--outf', type=str, default='./exp/mst_s/', help='saving_path')
-
-# Model specifications
-parser.add_argument('--method', type=str, default='mst_s', help='method name')
-parser.add_argument('--pretrained_model_path', type=str, default=None, help='pretrained model directory')
-parser.add_argument("--input_setting", type=str, default='H',
- help='the input measurement of the network: H, HM or Y')
-parser.add_argument("--input_mask", type=str, default='Phi',
- help='the input mask of the network: Phi, Phi_PhiPhiT, Mask or None') # Phi: shift_mask Mask: mask
-
-
-# Training specifications
-parser.add_argument("--size", default=384, type=int, help='cropped patch size')
-parser.add_argument("--epoch_sam_num", default=5000, type=int, help='total number of trainset')
-parser.add_argument("--seed", default=1, type=int, help='Random_seed')
-parser.add_argument('--batch_size', type=int, default=1, help='the number of HSIs per batch')
-parser.add_argument("--isTrain", default=True, type=bool, help='train or test')
-parser.add_argument("--max_epoch", type=int, default=300, help='total epoch')
-parser.add_argument("--scheduler", type=str, default='MultiStepLR', help='MultiStepLR or CosineAnnealingLR')
-parser.add_argument("--milestones", type=int, default=[50,100,150,200,250], help='milestones for MultiStepLR')
-parser.add_argument("--gamma", type=float, default=0.5, help='learning rate decay for MultiStepLR')
-parser.add_argument("--learning_rate", type=float, default=0.0004)
-
-opt = parser.parse_args()
-template.set_template(opt)
-
-opt.trainset_num = 20000 // ((opt.size // 96) ** 2)
-
-for arg in vars(opt):
- if vars(opt)[arg] == 'True':
- vars(opt)[arg] = True
- elif vars(opt)[arg] == 'False':
- vars(opt)[arg] = False
\ No newline at end of file
diff --git a/MST/real/train_code/option_s.py b/MST/real/train_code/option_s.py
deleted file mode 100755
index c2532aa..0000000
--- a/MST/real/train_code/option_s.py
+++ /dev/null
@@ -1,52 +0,0 @@
-import argparse
-
-parser = argparse.ArgumentParser(description="HyperSpectral Image Reconstruction Toolbox")
-
-# Hardware specifications
-parser.add_argument("--gpu_id", type=str, default='0')
-
-# Data specifications
-parser.add_argument('--data_root', type=str, default='../../datasets/', help='dataset directory')
-parser.add_argument('--data_path_CAVE', default='../../datasets/CAVE_512_28/', type=str,
- help='path of data')
-parser.add_argument('--data_path_KAIST', default='../../datasets/KAIST_CVPR2021/', type=str,
- help='path of data')
-parser.add_argument('--mask_path', default='../../datasets/TSA_real_data/mask.mat', type=str,
- help='path of mask')
-
-# Saving specifications
-parser.add_argument('--outf', type=str, default='./exp/bisrnet/', help='saving_path')
-
-# Model specifications
-parser.add_argument('--method', type=str, default='bisrnet', help='method name')
-parser.add_argument('--pretrained_model_path', type=str, default=None, help='pretrained model directory')
-parser.add_argument("--input_setting", type=str, default='H',
- help='the input measurement of the network: H, HM or Y')
-parser.add_argument("--input_mask", type=str, default='Phi',
- help='the input mask of the network: Phi, Phi_PhiPhiT, Mask or None') # Phi: shift_mask Mask: mask
-
-
-# Training specifications
-parser.add_argument("--size", default=96, type=int, help='cropped patch size')
-parser.add_argument("--epoch_sam_num", default=5000, type=int, help='total number of trainset')
-parser.add_argument("--seed", default=1, type=int, help='Random_seed')
-parser.add_argument('--batch_size', type=int, default=8, help='the number of HSIs per batch')
-parser.add_argument("--isTrain", default=True, type=bool, help='train or test')
-parser.add_argument("--max_epoch", type=int, default=500, help='total epoch')
-parser.add_argument("--scheduler", type=str, default='MultiStepLR', help='MultiStepLR or CosineAnnealingLR')
-parser.add_argument("--milestones", type=int, default=[50,100,150,200,250], help='milestones for MultiStepLR')
-parser.add_argument("--gamma", type=float, default=0.1, help='learning rate decay for MultiStepLR')
-parser.add_argument("--learning_rate", type=float, default=0.0001)
-
-opt = parser.parse_args()
-opt.input_setting = 'H'
-opt.input_mask = 'Mask'
-opt.scheduler = 'CosineAnnealingLR'
-
-opt.trainset_num = 20000 // ((opt.size // 96) ** 2)
-
-for arg in vars(opt):
- if vars(opt)[arg] == 'True':
- vars(opt)[arg] = True
- elif vars(opt)[arg] == 'False':
- vars(opt)[arg] = False
diff --git a/MST/real/train_code/template.py b/MST/real/train_code/template.py
deleted file mode 100755
index 0b9ffef..0000000
--- a/MST/real/train_code/template.py
+++ /dev/null
@@ -1,66 +0,0 @@
-def set_template(args):
- # Set the templates here
- if args.template.find('mst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
-
- if args.template.find('gap_net') >= 0 or args.template.find('admm_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.milestones = range(30,args.max_epoch,30)
- args.gamma = 0.9
- args.learning_rate = 1e-3
-
- if args.template.find('dauhst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.scheduler = 'CosineAnnealingLR'
- args.max_epoch = 300
-
- if args.template.find('tsa_net') >= 0:
- args.input_setting = 'HM'
- args.input_mask = None
-
- if args.template.find('hdnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = None
-
- if args.template.find('dgsmp') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.batch_size = 2
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1e-4
-
- if args.template.find('birnat') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.batch_size = 1
- args.max_epoch = 100
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1.5e-4
-
- if args.template.find('mst_plus_plus') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.scheduler = 'CosineAnnealingLR'
-
- if args.template.find('cst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.scheduler = 'CosineAnnealingLR'
- args.max_epoch = 500
-
- if args.template.find('dnu') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.batch_size = 2
- args.max_epoch = 150
- args.milestones = range(10,args.max_epoch,10)
- args.gamma = 0.9
- args.learning_rate = 4e-4
-
- if args.template.find('lambda_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.learning_rate = 1.5e-4
\ No newline at end of file
diff --git a/MST/real/train_code/train.py b/MST/real/train_code/train.py
deleted file mode 100755
index e4c4f8a..0000000
--- a/MST/real/train_code/train.py
+++ /dev/null
@@ -1,96 +0,0 @@
-from architecture import *
-from utils import *
-from dataset import dataset
-import torch.utils.data as tud
-import torch
-import torch.nn.functional as F
-import time
-import datetime
-from torch.autograd import Variable
-import os
-from option import opt
-
-os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
-os.environ["CUDA_VISIBLE_DEVICES"] = opt.gpu_id
-torch.backends.cudnn.enabled = True
-torch.backends.cudnn.benchmark = True
-if not torch.cuda.is_available():
- raise Exception('NO GPU!')
-
-# load training data
-CAVE = prepare_data_cave(opt.data_path_CAVE, 30)
-KAIST = prepare_data_KAIST(opt.data_path_KAIST, 30)
-
-# saving path
-date_time = str(datetime.datetime.now())
-date_time = time2file_name(date_time)
-opt.outf = os.path.join(opt.outf, date_time)
-if not os.path.exists(opt.outf):
- os.makedirs(opt.outf)
-
-# model
-if opt.method == 'hdnet':
- model, FDL_loss = model_generator(opt.method, opt.pretrained_model_path)
- model = model.cuda()
- FDL_loss = FDL_loss.cuda()
-else:
- model = model_generator(opt.method, opt.pretrained_model_path).cuda()
-
-# optimizing
-optimizer = torch.optim.Adam(model.parameters(), lr=opt.learning_rate, betas=(0.9, 0.999))
-if opt.scheduler == 'MultiStepLR':
- scheduler = torch.optim.lr_scheduler.MultiStepLR(optimizer, milestones=opt.milestones, gamma=opt.gamma)
-elif opt.scheduler == 'CosineAnnealingLR':
- scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, opt.max_epoch, eta_min=1e-6)
-criterion = nn.L1Loss()
-
-if __name__ == "__main__":
-
- print("Random Seed: ", opt.seed)
- torch.manual_seed(opt.seed)
- torch.cuda.manual_seed(opt.seed)
-
- ## pipline of training
- for epoch in range(1, opt.max_epoch):
- model.train()
- Dataset = dataset(opt, CAVE, KAIST)
- loader_train = tud.DataLoader(Dataset, num_workers=8, batch_size=opt.batch_size, shuffle=True)
-
- scheduler.step(epoch)
- epoch_loss = 0
-
- start_time = time.time()
- for i, (input, label, Mask, Phi, Phi_s) in enumerate(loader_train):
- input, label, Phi, Phi_s = Variable(input), Variable(label), Variable(Phi), Variable(Phi_s)
- input, label, Phi, Phi_s = input.cuda(), label.cuda(), Phi.cuda(), Phi_s.cuda()
-
- input_mask = init_mask(Mask, Phi, Phi_s, opt.input_mask)
-
- if opt.method in ['cst_s', 'cst_m', 'cst_l']:
- out, diff_pred = model(input, input_mask)
- loss = criterion(out, label)
- diff_gt = torch.mean(torch.abs(out.detach() - label),dim=1, keepdim=True) # [b,1,h,w]
- loss_sparsity = F.mse_loss(diff_gt, diff_pred)
- loss = loss + 2 * loss_sparsity
- else:
- out = model(input, input_mask)
- # import pdb; pdb.set_trace()
- # print(out.shape, label.shape)
- loss = criterion(out, label)
-
- epoch_loss += loss.item()
-
- optimizer.zero_grad()
- loss.backward()
-
- optimizer.step()
-
- if i % (1000) == 0:
- print('%4d %4d / %4d loss = %.10f time = %s' % (
- epoch + 1, i, len(Dataset) // opt.batch_size, epoch_loss / ((i + 1) * opt.batch_size),
- datetime.datetime.now()))
-
-
- elapsed_time = time.time() - start_time
- print('epcoh = %4d , loss = %.10f , time = %4.2f s' % (epoch + 1, epoch_loss / len(Dataset), elapsed_time))
- torch.save(model, os.path.join(opt.outf, 'model_%03d.pth' % (epoch + 1)))
diff --git a/MST/real/train_code/train_s.py b/MST/real/train_code/train_s.py
deleted file mode 100755
index 9215354..0000000
--- a/MST/real/train_code/train_s.py
+++ /dev/null
@@ -1,106 +0,0 @@
-from architecture import *
-from utils import *
-from dataset import dataset
-import torch.utils.data as tud
-import torch
-import torch.nn.functional as F
-import time
-import datetime
-from torch.autograd import Variable
-import os
-from option_s import opt
-
-from torch import optim
-from torch.optim.lr_scheduler import MultiStepLR
-from pdb import set_trace as stx
-
-os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
-os.environ["CUDA_VISIBLE_DEVICES"] = opt.gpu_id
-
-if not torch.cuda.is_available():
- raise Exception('NO GPU!')
-
-# load training data
-CAVE = prepare_data_cave(opt.data_path_CAVE, 30)
-KAIST = prepare_data_KAIST(opt.data_path_KAIST, 30)
-# KAIST = None
-
-# saving path
-date_time = str(datetime.datetime.now())
-date_time = time2file_name(date_time)
-opt.outf = os.path.join(opt.outf, date_time)
-if not os.path.exists(opt.outf):
- os.makedirs(opt.outf)
-
-model_path = opt.outf
-# model
-model = model_generator(opt.method, opt.pretrained_model_path).cuda()
-
-#optimizing
-optimizer = torch.optim.Adam(model.parameters(), lr=opt.learning_rate, betas=(0.9, 0.999))
-if opt.scheduler == 'MultiStepLR':
- scheduler = torch.optim.lr_scheduler.MultiStepLR(optimizer, milestones=opt.milestones, gamma=opt.gamma)
-elif opt.scheduler == 'CosineAnnealingLR':
- scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, opt.max_epoch, eta_min=1e-6)
-
-criterion = nn.L1Loss()
-
-
-if __name__ == "__main__":
-
- print("Random Seed: ", opt.seed)
- torch.manual_seed(opt.seed)
- torch.cuda.manual_seed(opt.seed)
-
- ## Initialize weight
- for layer in model.modules():
- if isinstance(layer, nn.Conv2d):
- nn.init.xavier_uniform_(layer.weight)
- # nn.init.constant_(layer.bias, 0.0)
- if isinstance(layer, nn.ConvTranspose2d):
- nn.init.xavier_uniform_(layer.weight)
- # nn.init.constant_(layer.bias, 0.0)
-
- logger = gen_log(model_path)
- logger.info("Learning rate:{}, batch_size:{}.\n".format(opt.learning_rate, opt.batch_size))
-
- ## pipline of training
- for epoch in range(0, opt.max_epoch):
- model.train()
-
- Dataset = dataset(opt, CAVE, KAIST)
- # Dataset = dataset(opt, CAVE)
- loader_train = tud.DataLoader(Dataset, num_workers=8, batch_size=opt.batch_size, shuffle=True)
-
- scheduler.step(epoch)
- epoch_loss = 0
-
- start_time = time.time()
- for i, (input, label, Mask, Phi, Phi_s) in enumerate(loader_train):
- input, label = Variable(input), Variable(label)
- input, label = input.cuda(), label.cuda()
- out = model(input)
-
- loss = criterion(out, label)
- epoch_loss += loss.item()
- optimizer.zero_grad()
- loss.backward()
-
- optimizer.step()
-
- if i % (1000) == 0:
- print('%4d %4d / %4d loss = %.10f time = %s' % (
- epoch + 1, i, len(Dataset) // opt.batch_size, epoch_loss / ((i + 1) * opt.batch_size),
- datetime.datetime.now()))
-
- elapsed_time = time.time() - start_time
-
- logger.info("===> Epoch {} Complete: Avg. Loss: {:.6f} time: {:.2f} s".
- format(epoch+1 , epoch_loss / len(Dataset), elapsed_time))
-
- print('epcoh = %4d , loss = %.10f , time = %4.2f s' % (epoch + 1, epoch_loss / len(Dataset), elapsed_time))
-
-
- torch.save(model, os.path.join(opt.outf, 'model_%03d.pth' % (epoch + 1)))
-
-
diff --git a/MST/real/train_code/utils.py b/MST/real/train_code/utils.py
deleted file mode 100755
index 0bd9a60..0000000
--- a/MST/real/train_code/utils.py
+++ /dev/null
@@ -1,203 +0,0 @@
-import numpy as np
-import scipy.io as sio
-import os
-import glob
-import re
-import torch
-import torch.nn as nn
-import math
-import random
-import logging
-
-def _as_floats(im1, im2):
- float_type = np.result_type(im1.dtype, im2.dtype, np.float32)
- im1 = np.asarray(im1, dtype=float_type)
- im2 = np.asarray(im2, dtype=float_type)
- return im1, im2
-
-
-def compare_mse(im1, im2):
- im1, im2 = _as_floats(im1, im2)
- return np.mean(np.square(im1 - im2), dtype=np.float64)
-
-
-def compare_psnr(im_true, im_test, data_range=None):
- im_true, im_test = _as_floats(im_true, im_test)
-
- err = compare_mse(im_true, im_test)
- return 10 * np.log10((data_range ** 2) / err)
-
-
-def psnr(img1, img2):
- mse = np.mean((img1/255. - img2/255.) ** 2)
- if mse < 1.0e-10:
- return 100
- PIXEL_MAX = 1
- return 20 * math.log10(PIXEL_MAX / math.sqrt(mse))
-
-
-def PSNR_GPU(im_true, im_fake):
- im_true *= 255
- im_fake *= 255
- im_true = im_true.round()
- im_fake = im_fake.round()
- data_range = 255
- esp = 1e-12
- C = im_true.size()[0]
- H = im_true.size()[1]
- W = im_true.size()[2]
- Itrue = im_true.clone()
- Ifake = im_fake.clone()
- mse = nn.MSELoss(reduce=False)
- err = mse(Itrue, Ifake).sum() / (C*H*W)
- psnr = 10. * np.log((data_range**2)/(err.data + esp)) / np.log(10.)
- return psnr
-
-
-def PSNR_Nssr(im_true, im_fake):
- mse = ((im_true - im_fake)**2).mean()
- psnr = 10. * np.log10(1/mse)
- return psnr
-
-
-def dataparallel(model, ngpus, gpu0=0):
- if ngpus==0:
- assert False, "only support gpu mode"
- gpu_list = list(range(gpu0, gpu0+ngpus))
- assert torch.cuda.device_count() >= gpu0 + ngpus
- if ngpus > 1:
- if not isinstance(model, torch.nn.DataParallel):
- model = torch.nn.DataParallel(model, gpu_list).cuda()
- else:
-
- model = model.cuda()
- elif ngpus == 1:
- model = model.cuda()
- return model
-
-
-def findLastCheckpoint(save_dir):
- file_list = glob.glob(os.path.join(save_dir, 'model_*.pth'))
- if file_list:
- epochs_exist = []
- for file_ in file_list:
- result = re.findall(".*model_(.*).pth.*", file_)
- epochs_exist.append(int(result[0]))
- initial_epoch = max(epochs_exist)
- else:
- initial_epoch = 0
- return initial_epoch
-
-# load HSIs
-def prepare_data(path, file_num):
- HR_HSI = np.zeros((((512,512,28,file_num))))
- for idx in range(file_num):
- # read HrHSI
- path1 = os.path.join(path) + 'scene%02d.mat' % (idx+1)
- # path1 = os.path.join(path) + HR_code + '.mat'
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
- HR_HSI[HR_HSI < 0.] = 0.
- HR_HSI[HR_HSI > 1.] = 1.
- return HR_HSI
-
-
-def loadpath(pathlistfile):
- fp = open(pathlistfile)
- pathlist = fp.read().splitlines()
- fp.close()
- random.shuffle(pathlist)
- return pathlist
-
-def time2file_name(time):
- year = time[0:4]
- month = time[5:7]
- day = time[8:10]
- hour = time[11:13]
- minute = time[14:16]
- second = time[17:19]
- time_filename = year + '_' + month + '_' + day + '_' + hour + '_' + minute + '_' + second
- return time_filename
-
-# def prepare_data_cave(path, file_list, file_num):
-# HR_HSI = np.zeros((((512,512,28,file_num))))
-# for idx in range(file_num):
-# #### read HrHSI
-# HR_code = file_list[idx]
-# path1 = os.path.join(path) + HR_code + '.mat'
-# data = sio.loadmat(path1)
-# HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
-# HR_HSI[HR_HSI < 0] = 0
-# HR_HSI[HR_HSI > 1] = 1
-# return HR_HSI
-#
-# def prepare_data_KASIT(path, file_list, file_num):
-# HR_HSI = np.zeros((((2704,3376,28,file_num))))
-# for idx in range(file_num):
-# #### read HrHSI
-# HR_code = file_list[idx]
-# path1 = os.path.join(path) + HR_code + '.mat'
-# data = sio.loadmat(path1)
-# HR_HSI[:,:,:,idx] = data['HSI']
-# HR_HSI[HR_HSI < 0] = 0
-# HR_HSI[HR_HSI > 1] = 1
-# return HR_HSI
-
-def prepare_data_cave(path, file_num):
- HR_HSI = np.zeros((((512,512,28,file_num))))
- file_list = os.listdir(path)
- # for idx in range(1):
- for idx in range(file_num):
- print(f'loading CAVE {idx}')
- #### read HrHSI
- HR_code = file_list[idx]
- path1 = os.path.join(path) + HR_code
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['data_slice'] / 65535.0
- HR_HSI[HR_HSI < 0] = 0
- HR_HSI[HR_HSI > 1] = 1
- return HR_HSI
-
-def prepare_data_KAIST(path, file_num):
- HR_HSI = np.zeros((((2704,3376,28,file_num))))
- file_list = os.listdir(path)
- # for idx in range(1):
- for idx in range(file_num):
- print(f'loading KAIST {idx}')
- #### read HrHSI
- HR_code = file_list[idx]
- path1 = os.path.join(path) + HR_code
- data = sio.loadmat(path1)
- HR_HSI[:,:,:,idx] = data['HSI']
- HR_HSI[HR_HSI < 0] = 0
- HR_HSI[HR_HSI > 1] = 1
- return HR_HSI
-
-def init_mask(mask, Phi, Phi_s, mask_type):
- if mask_type == 'Phi':
- input_mask = Phi
- elif mask_type == 'Phi_PhiPhiT':
- input_mask = (Phi, Phi_s)
- elif mask_type == 'Mask':
- input_mask = mask
- elif mask_type == None:
- input_mask = None
- return input_mask
-
-def gen_log(model_path):
- logger = logging.getLogger()
- logger.setLevel(logging.INFO)
- formatter = logging.Formatter("%(asctime)s - %(levelname)s: %(message)s")
-
- log_file = model_path + '/log.txt'
- fh = logging.FileHandler(log_file, mode='a')
- fh.setLevel(logging.INFO)
- fh.setFormatter(formatter)
-
- ch = logging.StreamHandler()
- ch.setLevel(logging.INFO)
- ch.setFormatter(formatter)
-
- logger.addHandler(fh)
- logger.addHandler(ch)
- return logger
diff --git a/MST/requirements.txt b/MST/requirements.txt
deleted file mode 100755
index b5086d0..0000000
--- a/MST/requirements.txt
+++ /dev/null
@@ -1,6 +0,0 @@
-opencv-python==4.4.0.46
-einops
-torchvision==0.7.0
-torch==1.6.0
-scipy==1.0.0
-fvcore
diff --git a/MST/simulation/test_code/Quality_Metrics/CC.m b/MST/simulation/test_code/Quality_Metrics/CC.m
deleted file mode 100755
index eee4d50..0000000
--- a/MST/simulation/test_code/Quality_Metrics/CC.m
+++ /dev/null
@@ -1,41 +0,0 @@
-function out = CC(ref,tar,mask)
-%--------------------------------------------------------------------------
-% Cross Correlation
-%
-% USAGE
-% out = CC(ref,tar,mask)
-%
-% INPUT
-% ref : reference HS data (rows,cols,bands)
-% tar : target HS data (rows,cols,bands)
-% mask: binary mask (rows,cols) (optional)
-%
-% OUTPUT
-% out : cross correlations (bands)
-%
-%--------------------------------------------------------------------------
-
-if nargin==2
- [rows,cols,bands] = size(tar);
-
- out = zeros(1,bands);
- for i = 1:bands
- tar_tmp = tar(:,:,i);
- ref_tmp = ref(:,:,i);
- cc = corrcoef(tar_tmp(:),ref_tmp(:));
- out(1,i) = cc(1,2);
- end
-
-else
- [rows,cols,bands] = size(tar);
-
- out = zeros(1,bands);
- mask = find(mask~=0);
- for i = 1:bands
- tar_tmp = tar(:,:,i);
- ref_tmp = ref(:,:,i);
- cc = corrcoef(tar_tmp(mask),ref_tmp(mask));
- out(1,i) = cc(1,2);
- end
-end
- out=mean(out);
diff --git a/MST/simulation/test_code/Quality_Metrics/Cal_quality_assessment.m b/MST/simulation/test_code/Quality_Metrics/Cal_quality_assessment.m
deleted file mode 100755
index bb2aca7..0000000
--- a/MST/simulation/test_code/Quality_Metrics/Cal_quality_assessment.m
+++ /dev/null
@@ -1,36 +0,0 @@
-clear;clc;
-res_path = 'results/Test_result.mat';
-load(res_path);
-
-psnr_total=0.0;
-ssim_total=0.0;
-psnr_list = zeros(10,1);
-ssim_list = zeros(10,1);
-for i=1:10
- Z = squeeze(pred(i,:,:,:));
- Z = double(Z);
- S = squeeze(truth(i,:,:,:));
- S = double(S);
-
- Z(Z>1.0) = 1.0;
- Z(Z<0.0) = 0.0;
-
- [psnr, rmse, ergas, sam, uiqi, ssim] = quality_assessment(double(im2uint8(S)), double(im2uint8(Z)), 0, 1);
-
- pred(1,i) = psnr;
- pred(2,i) = rmse;
- pred(3,i) = ergas;
- pred(4,i) = sam;
- pred(5,i) = uiqi;
- pred(6,i) = ssim;
- psnr_list(i,1) = psnr;
- ssim_list(i,1) = ssim;
-
- psnr_total = psnr_total+psnr;
- ssim_total = ssim_total+ssim;
-end
-psnr = mean(psnr_list);
-ssim = mean(ssim_list);
-fprintf('The PNSR=%f\n',psnr);
-fprintf('The SSIM=%f\n',ssim);
-
diff --git a/MST/simulation/test_code/Quality_Metrics/SpectAngMapper.m b/MST/simulation/test_code/Quality_Metrics/SpectAngMapper.m
deleted file mode 100755
index e440f25..0000000
--- a/MST/simulation/test_code/Quality_Metrics/SpectAngMapper.m
+++ /dev/null
@@ -1,29 +0,0 @@
-function sam = SpectAngMapper(imagery1, imagery2)
-
-%==========================================================================
-% Evaluates the mean Spectral Angle Mapper (SAM)[1] for two MSIs.
-%
-% Syntax:
-% [psnr, ssim, fsim, ergas, msam ] = MSIQA(imagery1, imagery2)
-%
-% Input:
-% imagery1 - the reference MSI data array
-% imagery2 - the target MSI data array
-% NOTE: MSI data array is a M*N*K array for imagery with M*N spatial
-% pixels, K bands and DYNAMIC RANGE [0, 255]. If imagery1 and imagery2
-% have different size, the larger one will be truncated to fit the
-% smaller one.
-%
-% [1] R. YUHAS, J. BOARDMAN, and A. GOETZ, "Determination of semi-arid
-% landscape endmembers and seasonal trends using convex geometry
-% spectral unmixing techniques", JPL, Summaries of the 4 th Annual JPL
-% Airborne Geoscience Workshop. 1993.
-%
-% See also StructureSIM, FeatureSIM and ErrRelGlobAdimSyn
-%
-% by Yi Peng
-%==========================================================================
-
-tmp = (sum(imagery1.*imagery2, 3) + eps) ...
- ./ (sqrt(sum(imagery1.^2, 3)) + eps) ./ (sqrt(sum(imagery2.^2, 3)) + eps);
-sam = mean2(real(acos(tmp)));
\ No newline at end of file
diff --git a/MST/simulation/test_code/Quality_Metrics/cal_ssim.m b/MST/simulation/test_code/Quality_Metrics/cal_ssim.m
deleted file mode 100755
index 8d844b7..0000000
--- a/MST/simulation/test_code/Quality_Metrics/cal_ssim.m
+++ /dev/null
@@ -1,213 +0,0 @@
-function ssim = cal_ssim( im1, im2, b_row, b_col )
-
-[h w ch] = size( im1 );
-ssim = 0;
-if ch==1
- ssim = ssim_index( im1(b_row+1:h-b_row, b_col+1:w-b_col), im2( b_row+1:h-b_row, b_col+1:w-b_col) );
-else
- for i = 1:ch
- ssim = ssim + ssim_index( im1(b_row+1:h-b_row, b_col+1:w-b_col, i), im2( b_row+1:h-b_row, b_col+1:w-b_col, i) );
- end
- ssim = ssim/ch;
-end
-return;
-
-
-
-
-function [mssim, ssim_map] = ssim_index(img1, img2, K, window, L)
-
-%========================================================================
-%SSIM Index, Version 1.0
-%Copyright(c) 2003 Zhou Wang
-%All Rights Reserved.
-%
-%The author was with Howard Hughes Medical Institute, and Laboratory
-%for Computational Vision at Center for Neural Science and Courant
-%Institute of Mathematical Sciences, New York University, USA. He is
-%currently with Department of Electrical and Computer Engineering,
-%University of Waterloo, Canada.
-%
-%----------------------------------------------------------------------
-%Permission to use, copy, or modify this software and its documentation
-%for educational and research purposes only and without fee is hereby
-%granted, provided that this copyright notice and the original authors'
-%names appear on all copies and supporting documentation. This program
-%shall not be used, rewritten, or adapted as the basis of a commercial
-%software or hardware product without first obtaining permission of the
-%authors. The authors make no representations about the suitability of
-%this software for any purpose. It is provided "as is" without express
-%or implied warranty.
-%----------------------------------------------------------------------
-%
-%This is an implementation of the algorithm for calculating the
-%Structural SIMilarity (SSIM) index between two images. Please refer
-%to the following paper:
-%
-%Z. Wang, A. C. Bovik, H. R. Sheikh, and E. P. Simoncelli, "Image
-%quality assessment: From error measurement to structural similarity"
-%IEEE Transactios on Image Processing, vol. 13, no. 4, Apr. 2004.
-%
-%Kindly report any suggestions or corrections to zhouwang@ieee.org
-%
-%----------------------------------------------------------------------
-%
-%Input : (1) img1: the first image being compared
-% (2) img2: the second image being compared
-% (3) K: constants in the SSIM index formula (see the above
-% reference). defualt value: K = [0.01 0.03]
-% (4) window: local window for statistics (see the above
-% reference). default widnow is Gaussian given by
-% window = fspecial('gaussian', 11, 1.5);
-% (5) L: dynamic range of the images. default: L = 255
-%
-%Output: (1) mssim: the mean SSIM index value between 2 images.
-% If one of the images being compared is regarded as
-% perfect quality, then mssim can be considered as the
-% quality measure of the other image.
-% If img1 = img2, then mssim = 1.
-% (2) ssim_map: the SSIM index map of the test image. The map
-% has a smaller size than the input images. The actual size:
-% size(img1) - size(window) + 1.
-%
-%Default Usage:
-% Given 2 test images img1 and img2, whose dynamic range is 0-255
-%
-% [mssim ssim_map] = ssim_index(img1, img2);
-%
-%Advanced Usage:
-% User defined parameters. For example
-%
-% K = [0.05 0.05];
-% window = ones(8);
-% L = 100;
-% [mssim ssim_map] = ssim_index(img1, img2, K, window, L);
-%
-%See the results:
-%
-% mssim %Gives the mssim value
-% imshow(max(0, ssim_map).^4) %Shows the SSIM index map
-%
-%========================================================================
-
-
-if (nargin < 2 | nargin > 5)
- mssim = -Inf;
- ssim_map = -Inf;
- return;
-end
-
-if (size(img1) ~= size(img2))
- mssim = -Inf;
- ssim_map = -Inf;
- return;
-end
-
-[M N] = size(img1);
-
-if (nargin == 2)
- if ((M < 11) | (N < 11))
- mssim = -Inf;
- ssim_map = -Inf;
- return
- end
- window = fspecial('gaussian', 11, 1.5); %
- K(1) = 0.01; % default settings
- K(2) = 0.03; %
- L = 255; %
-end
-
-if (nargin == 3)
- if ((M < 11) | (N < 11))
- mssim = -Inf;
- ssim_map = -Inf;
- return
- end
- window = fspecial('gaussian', 11, 1.5);
- L = 255;
- if (length(K) == 2)
- if (K(1) < 0 | K(2) < 0)
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
- else
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
-end
-
-if (nargin == 4)
- [H W] = size(window);
- if ((H*W) < 4 | (H > M) | (W > N))
- mssim = -Inf;
- ssim_map = -Inf;
- return
- end
- L = 255;
- if (length(K) == 2)
- if (K(1) < 0 | K(2) < 0)
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
- else
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
-end
-
-if (nargin == 5)
- [H W] = size(window);
- if ((H*W) < 4 | (H > M) | (W > N))
- mssim = -Inf;
- ssim_map = -Inf;
- return
- end
- if (length(K) == 2)
- if (K(1) < 0 | K(2) < 0)
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
- else
- mssim = -Inf;
- ssim_map = -Inf;
- return;
- end
-end
-
-C1 = (K(1)*L)^2;
-C2 = (K(2)*L)^2;
-window = window/sum(sum(window));
-img1 = double(img1);
-img2 = double(img2);
-
-mu1 = filter2(window, img1, 'valid');
-mu2 = filter2(window, img2, 'valid');
-mu1_sq = mu1.*mu1;
-mu2_sq = mu2.*mu2;
-mu1_mu2 = mu1.*mu2;
-sigma1_sq = filter2(window, img1.*img1, 'valid') - mu1_sq;
-sigma2_sq = filter2(window, img2.*img2, 'valid') - mu2_sq;
-sigma12 = filter2(window, img1.*img2, 'valid') - mu1_mu2;
-
-if (C1 > 0 & C2 > 0)
- ssim_map = ((2*mu1_mu2 + C1).*(2*sigma12 + C2))./((mu1_sq + mu2_sq + C1).*(sigma1_sq + sigma2_sq + C2));
-else
- numerator1 = 2*mu1_mu2 + C1;
- numerator2 = 2*sigma12 + C2;
- denominator1 = mu1_sq + mu2_sq + C1;
- denominator2 = sigma1_sq + sigma2_sq + C2;
- ssim_map = ones(size(mu1));
- index = (denominator1.*denominator2 > 0);
- ssim_map(index) = (numerator1(index).*numerator2(index))./(denominator1(index).*denominator2(index));
- index = (denominator1 ~= 0) & (denominator2 == 0);
- ssim_map(index) = numerator1(index)./denominator1(index);
-end
-
-mssim = mean2(ssim_map);
-
-return
\ No newline at end of file
diff --git a/MST/simulation/test_code/Quality_Metrics/csnr.m b/MST/simulation/test_code/Quality_Metrics/csnr.m
deleted file mode 100755
index 65ffe01..0000000
--- a/MST/simulation/test_code/Quality_Metrics/csnr.m
+++ /dev/null
@@ -1,22 +0,0 @@
-function s=csnr(A,B,row,col)
-
-[n,m,ch]=size(A);
-summa = 0;
-if ch==1
- e=A-B;
- e=e(row+1:n-row,col+1:m-col);
- me=mean(mean(e.^2));
- s=10*log10(255^2/me);
-else
- for i=1:ch
- e=A-B;
- e=e(row+1:n-row,col+1:m-col,i);
- mse = mean(mean(e.^2));
- s = 10*log10(255^2/mse);
- summa = summa + s;
- end
- s = summa/ch;
-end
-
-return;
-
diff --git a/MST/simulation/test_code/Quality_Metrics/img_qi.m b/MST/simulation/test_code/Quality_Metrics/img_qi.m
deleted file mode 100755
index 73eb0ec..0000000
--- a/MST/simulation/test_code/Quality_Metrics/img_qi.m
+++ /dev/null
@@ -1,118 +0,0 @@
-function [quality, quality_map] = img_qi(img1, img2, block_size)
-
-%========================================================================
-%
-%Copyright (c) 2001 The University of Texas at Austin
-%All Rights Reserved.
-%
-%This program is free software; you can redistribute it and/or modify
-%it under the terms of the GNU General Public License as published by
-%the Free Software Foundation; either version 2 of the License, or
-%(at your option) any later version.
-%
-%This program is distributed in the hope that it will be useful,
-%but WITHOUT ANY WARRANTY; without even the implied warranty of
-%MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-%GNU General Public License for more details.
-%
-%The GNU Public License is available in the file LICENSE, or you
-%can write to the Free Software Foundation, Inc., 59 Temple Place -
-%Suite 330, Boston, MA 02111-1307, USA, or you can find it on the
-%World Wide Web at http://www.fsf.org.
-%
-%Author : Zhou Wang
-%Version : 1.0
-%
-%The authors are with the Laboratory for Image and Video Engineering
-%(LIVE), Department of Electrical and Computer Engineering, The
-%University of Texas at Austin, Austin, TX.
-%
-%Kindly report any suggestions or corrections to zwang@ece.utexas.edu
-%
-%Acknowledgement:
-%The author would like to thank Mr. Umesh Rajashekar, the Matlab master
-%in our lab, for spending his precious time and giving his kind help
-%on writing this program. Without his help, this program would not
-%achieve its current efficiency.
-%
-%========================================================================
-%
-%This is an efficient implementation of the algorithm for calculating
-%the universal image quality index proposed by Zhou Wang and Alan C.
-%Bovik. Please refer to the paper "A Universal Image Quality Index"
-%by Zhou Wang and Alan C. Bovik, published in IEEE Signal Processing
-%Letters, 2001. In order to run this function, you must have Matlab's
-%Image Processing Toobox.
-%
-%Input : an original image and a test image of the same size
-%Output: (1) an overall quality index of the test image, with a value
-% range of [-1, 1].
-% (2) a quality map of the test image. The map has a smaller
-% size than the input images. The actual size is
-% img_size - BLOCK_SIZE + 1.
-%
-%Usage:
-%
-%1. Load the original and the test images into two matrices
-% (say img1 and img2)
-%
-%2. Run this function in one of the two ways:
-%
-% % Choice 1 (suggested):
-% [qi qi_map] = img_qi(img1, img2);
-%
-% % Choice 2:
-% [qi qi_map] = img_qi(img1, img2, BLOCK_SIZE);
-%
-% The default BLOCK_SIZE is 8 (Choice 1). Otherwise, you can specify
-% it by yourself (Choice 2).
-%
-%3. See the results:
-%
-% qi %Gives the over quality index.
-% imshow((qi_map+1)/2) %Shows the quality map as an image.
-%
-%========================================================================
-
-if (nargin == 1 | nargin > 3)
- quality = -Inf;
- quality_map = -1*ones(size(img1));
- return;
-end
-
-if (size(img1) ~= size(img2))
- quality = -Inf;
- quality_map = -1*ones(size(img1));
- return;
-end
-
-if (nargin == 2)
- block_size = 8;
-end
-
-N = block_size.^2;
-sum2_filter = ones(block_size);
-
-img1_sq = img1.*img1;
-img2_sq = img2.*img2;
-img12 = img1.*img2;
-
-img1_sum = filter2(sum2_filter, img1, 'valid');
-img2_sum = filter2(sum2_filter, img2, 'valid');
-img1_sq_sum = filter2(sum2_filter, img1_sq, 'valid');
-img2_sq_sum = filter2(sum2_filter, img2_sq, 'valid');
-img12_sum = filter2(sum2_filter, img12, 'valid');
-
-img12_sum_mul = img1_sum.*img2_sum;
-img12_sq_sum_mul = img1_sum.*img1_sum + img2_sum.*img2_sum;
-numerator = 4*(N*img12_sum - img12_sum_mul).*img12_sum_mul;
-denominator1 = N*(img1_sq_sum + img2_sq_sum) - img12_sq_sum_mul;
-denominator = denominator1.*img12_sq_sum_mul;
-
-quality_map = ones(size(denominator));
-index = (denominator1 == 0) & (img12_sq_sum_mul ~= 0);
-quality_map(index) = 2*img12_sum_mul(index)./img12_sq_sum_mul(index);
-index = (denominator ~= 0);
-quality_map(index) = numerator(index)./denominator(index);
-
-quality = mean2(quality_map);
\ No newline at end of file
diff --git a/MST/simulation/test_code/Quality_Metrics/quality_assessment.m b/MST/simulation/test_code/Quality_Metrics/quality_assessment.m
deleted file mode 100755
index bf157a9..0000000
--- a/MST/simulation/test_code/Quality_Metrics/quality_assessment.m
+++ /dev/null
@@ -1,39 +0,0 @@
-function [psnr,rmse, ergas, sam, uiqi,ssim,DD,CCS] = quality_assessment(ground_truth, estimated, ignore_edges, ratio_ergas)
-
-% Ignore borders
-y = ground_truth(ignore_edges+1:end-ignore_edges, ignore_edges+1:end-ignore_edges, :);
-x = estimated(ignore_edges+1:end-ignore_edges, ignore_edges+1:end-ignore_edges, :);
-
-% Size, bands, samples
-sz_x = size(x);
-n_bands = sz_x(3);
-n_samples = sz_x(1)*sz_x(2);
-
-% RMSE
-aux = sum(sum((x - y).^2, 1), 2)/n_samples;
-rmse_per_band = sqrt(aux);
-rmse = sqrt(sum(aux, 3)/n_bands);
-
-% ERGAS
-mean_y = sum(sum(y, 1), 2)/n_samples;
-ergas = 100*ratio_ergas*sqrt(sum((rmse_per_band ./ mean_y).^2)/n_bands);
-
-% SAM
-sam= SpectAngMapper( ground_truth, estimated );
-sam=sam*180/pi;
-% num = sum(x .* y, 3);
-% den = sqrt(sum(x.^2, 3) .* sum(y.^2, 3));
-% sam = sum(sum(acosd(num ./ den)))/(n_samples);
-
-% UIQI - calls the method described in "A Universal Image Quality Index"
-% by Zhou Wang and Alan C. Bovik
-q_band = zeros(1, n_bands);
-for idx1=1:n_bands
- q_band(idx1)=img_qi(ground_truth(:,:,idx1), estimated(:,:,idx1), 32);
-end
-uiqi = mean(q_band);
-ssim=cal_ssim(ground_truth, estimated,0,0);
-DD=norm(ground_truth(:)-estimated(:),1)/numel(ground_truth);
-CCS = CC(ground_truth,estimated);
-CCS=mean(CCS);
-psnr=csnr(ground_truth, estimated,0,0);
\ No newline at end of file
diff --git a/MST/simulation/test_code/Quality_Metrics/results/README.md b/MST/simulation/test_code/Quality_Metrics/results/README.md
deleted file mode 100755
index e36c521..0000000
--- a/MST/simulation/test_code/Quality_Metrics/results/README.md
+++ /dev/null
@@ -1 +0,0 @@
-Please put the reconstructed HSI in this folder.
\ No newline at end of file
diff --git a/MST/simulation/test_code/__pycache__/option.cpython-36.pyc b/MST/simulation/test_code/__pycache__/option.cpython-36.pyc
deleted file mode 100755
index e948007..0000000
Binary files a/MST/simulation/test_code/__pycache__/option.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/__pycache__/option.cpython-39.pyc b/MST/simulation/test_code/__pycache__/option.cpython-39.pyc
deleted file mode 100644
index 8d186ca..0000000
Binary files a/MST/simulation/test_code/__pycache__/option.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/__pycache__/template.cpython-36.pyc b/MST/simulation/test_code/__pycache__/template.cpython-36.pyc
deleted file mode 100755
index 73dfaec..0000000
Binary files a/MST/simulation/test_code/__pycache__/template.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/__pycache__/template.cpython-39.pyc b/MST/simulation/test_code/__pycache__/template.cpython-39.pyc
deleted file mode 100644
index d36559e..0000000
Binary files a/MST/simulation/test_code/__pycache__/template.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/__pycache__/utils.cpython-36.pyc b/MST/simulation/test_code/__pycache__/utils.cpython-36.pyc
deleted file mode 100755
index a27b6e0..0000000
Binary files a/MST/simulation/test_code/__pycache__/utils.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/__pycache__/utils.cpython-39.pyc b/MST/simulation/test_code/__pycache__/utils.cpython-39.pyc
deleted file mode 100644
index 668f55b..0000000
Binary files a/MST/simulation/test_code/__pycache__/utils.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/ADMM_Net.py b/MST/simulation/test_code/architecture/ADMM_Net.py
deleted file mode 100755
index 7fc4180..0000000
--- a/MST/simulation/test_code/architecture/ADMM_Net.py
+++ /dev/null
@@ -1,201 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
-
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
-
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class ADMM_net(nn.Module):
-
- def __init__(self):
- super(ADMM_net, self).__init__()
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma2 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma3 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma4 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma5 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma6 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma7 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma8 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma9 = torch.nn.Parameter(torch.Tensor([0]))
-
- def forward(self, y, input_mask=None):
- if input_mask == None:
- Phi = torch.rand((1, 28, 256, 310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- theta = At(y,Phi)
- b = torch.zeros_like(Phi)
- ### 1-3
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma1),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet1(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma2),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet2(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma3),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet3(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 4-6
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma4),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet4(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma5),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet5(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma6),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet6(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 7-9
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma7),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet7(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma8),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet8(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma9),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet9(x1)
- theta = shift_3d(theta)
- return theta[:, :, :, 0:256]
diff --git a/MST/simulation/test_code/architecture/BIRNAT.py b/MST/simulation/test_code/architecture/BIRNAT.py
deleted file mode 100755
index e3d8123..0000000
--- a/MST/simulation/test_code/architecture/BIRNAT.py
+++ /dev/null
@@ -1,365 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-
-class self_attention(nn.Module):
- def __init__(self, ch):
- super(self_attention, self).__init__()
- self.conv1 = nn.Conv2d(ch, ch // 8, 1)
- self.conv2 = nn.Conv2d(ch, ch // 8, 1)
- self.conv3 = nn.Conv2d(ch, ch, 1)
- self.conv4 = nn.Conv2d(ch, ch, 1)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.ch = ch
-
- def forward(self, x):
- batch_size = x.shape[0]
-
- f = self.conv1(x)
- g = self.conv2(x)
- h = self.conv3(x)
- ht = h.reshape([batch_size, self.ch, -1])
-
- ft = f.reshape([batch_size, self.ch // 8, -1])
- n = torch.matmul(ft.permute([0, 2, 1]), g.reshape([batch_size, self.ch // 8, -1]))
- beta = F.softmax(n, dim=1)
-
- o = torch.matmul(ht, beta)
- o = o.reshape(x.shape) # [bs, C, h, w]
-
- o = self.conv4(o)
-
- x = self.gamma1 * o + x
-
- return x
-
-
-class res_part(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(res_part, self).__init__()
- self.conv1 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv2 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv3 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
-
- def forward(self, x):
- x1 = self.conv1(x)
- x = x1 + x
- x1 = self.conv2(x)
- x = x1 + x
- x1 = self.conv3(x)
- x = x1 + x
- return x
-
-
-class down_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(down_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- # nn.Conv2d(20, 40, 5, stride=2, padding=2),
- # nn.Conv2d(40, out_ch, 5, stride=2, padding=2),
- nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 40, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(40, out_ch, 3, stride=1, padding=1),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-
-class up_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(up_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.ConvTranspose2d(in_ch, 40, 3, stride=2, padding=1, output_padding=1),
- # nn.ConvTranspose2d(40, 20, 3, stride=2, padding=1, output_padding=1),
- nn.Conv2d(in_ch, 40, 3, stride=1, padding=1),
- nn.Conv2d(40, 30, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(30, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- nn.Conv2d(20, out_ch, 1),
- # nn.Sigmoid(),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-class cnn1(nn.Module):
- # 输入meas concat mask
- # 3 下采样
-
- def __init__(self, B):
- super(cnn1, self).__init__()
- self.conv1 = nn.Conv2d(B + 1, 32, kernel_size=5, stride=1, padding=2)
- self.relu1 = nn.LeakyReLU(inplace=True)
- self.conv2 = nn.Conv2d(32, 64, kernel_size=3, stride=1, padding=1)
- self.relu2 = nn.LeakyReLU(inplace=True)
- self.conv3 = nn.Conv2d(64, 64, kernel_size=1, stride=1)
- self.relu3 = nn.LeakyReLU(inplace=True)
- self.conv4 = nn.Conv2d(64, 128, kernel_size=3, stride=2, padding=1)
- self.relu4 = nn.LeakyReLU(inplace=True)
- self.conv5 = nn.ConvTranspose2d(128, 64, kernel_size=3, stride=2, padding=1, output_padding=1)
- self.relu5 = nn.LeakyReLU(inplace=True)
- self.conv51 = nn.Conv2d(64, 32, kernel_size=3, stride=1, padding=1)
- self.relu51 = nn.LeakyReLU(inplace=True)
- self.conv52 = nn.Conv2d(32, 16, kernel_size=1, stride=1)
- self.relu52 = nn.LeakyReLU(inplace=True)
- self.conv6 = nn.Conv2d(16, 1, kernel_size=3, stride=1, padding=1)
- self.res_part1 = res_part(128, 128)
- self.res_part2 = res_part(128, 128)
- self.res_part3 = res_part(128, 128)
- self.conv7 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu7 = nn.LeakyReLU(inplace=True)
- self.conv8 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
- self.conv9 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu9 = nn.LeakyReLU(inplace=True)
- self.conv10 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
-
- self.att1 = self_attention(128)
-
- def forward(self, meas=None, nor_meas=None, PhiTy=None):
- data = torch.cat([torch.unsqueeze(nor_meas, dim=1), PhiTy], dim=1)
- out = self.conv1(data)
-
- out = self.relu1(out)
- out = self.conv2(out)
- out = self.relu2(out)
- out = self.conv3(out)
- out = self.relu3(out)
- out = self.conv4(out)
- out = self.relu4(out)
- out = self.res_part1(out)
- out = self.conv7(out)
- out = self.relu7(out)
- out = self.conv8(out)
- out = self.res_part2(out)
- out = self.conv9(out)
- out = self.relu9(out)
- out = self.conv10(out)
- out = self.res_part3(out)
-
- # out = self.att1(out)
-
- out = self.conv5(out)
- out = self.relu5(out)
- out = self.conv51(out)
- out = self.relu51(out)
- out = self.conv52(out)
- out = self.relu52(out)
- out = self.conv6(out)
-
- return out
-
-
-class forward_rnn(nn.Module):
-
- def __init__(self):
- super(forward_rnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt1, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
- xt = xt1
-
- step = 2
- [bs, nC, row, col] = xt1.shape
-
- out = xt1
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, ii, :, :], out[:, ii, :, :])
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, ii, :, :], torch.squeeze(nor_meas))
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
- out = torch.cat([out, xt], dim=1)
-
- return out, ht
-
-
-class backrnn(nn.Module):
-
- def __init__(self):
- super(backrnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt8, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
-
- step = 2
- [bs, nC, row, col] = xt8.shape
-
- xt = torch.unsqueeze(xt8[:, cs_rate - 1, :, :], 1)
-
- out = torch.zeros(bs, cs_rate, row, col).cuda()
- out[:, cs_rate - 1, :, :] = xt[:, 0, :, :]
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], out[:, cs_rate - 1 - ii, :, :].clone())
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], xt8[:, cs_rate - 1 - ii, :, :].clone())
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
-
- out[:, cs_rate - 2 - i, :, :] = xt[:, 0, :, :]
-
- return out
-
-def shift_gt_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, i, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- if inputs.is_cuda:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- else:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-class BIRNAT(nn.Module):
-
- def __init__(self):
- super(BIRNAT, self).__init__()
- self.cs_rate = 28
- self.first_frame_net = cnn1(self.cs_rate).cuda()
- self.rnn1 = forward_rnn().cuda()
- self.rnn2 = backrnn().cuda()
-
- def gen_meas_torch(self, meas, shift_mask):
- batch_size, H = meas.shape[0:2]
- mask_s = torch.sum(shift_mask, 1)
- nor_meas = torch.div(meas, mask_s)
- temp = torch.mul(torch.unsqueeze(nor_meas, dim=1).expand([batch_size, 28, H, shift_mask.shape[3]]), shift_mask)
- return nor_meas, temp
-
- def forward(self, meas, shift_mask=None):
- if shift_mask==None:
- shift_mask = torch.zeros(1, 28, 256, 310).cuda()
- H, W = meas.shape[-2:]
- nor_meas, PhiTy = self.gen_meas_torch(meas, shift_mask)
- h0 = torch.zeros(meas.shape[0], 20, H, W).cuda()
- xt1 = self.first_frame_net(meas, nor_meas, PhiTy)
- model_out1, h1 = self.rnn1(xt1, meas, nor_meas, PhiTy, shift_mask, h0, self.cs_rate)
- model_out2 = self.rnn2(model_out1, meas, nor_meas, PhiTy, shift_mask, h1, self.cs_rate)
- model_out2 = shift_gt_back(model_out2)
-
- return model_out2
diff --git a/MST/simulation/test_code/architecture/BiSRNet.py b/MST/simulation/test_code/architecture/BiSRNet.py
deleted file mode 100755
index 08014a0..0000000
--- a/MST/simulation/test_code/architecture/BiSRNet.py
+++ /dev/null
@@ -1,422 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-import os
-from pdb import set_trace as stx
-
-# --------------------------------------------- Binarized Basic Units -----------------------------------------------------------------
-
-
-class LearnableBias(nn.Module):
- def __init__(self, out_chn):
- super(LearnableBias, self).__init__()
- self.bias = nn.Parameter(torch.zeros(1,out_chn,1,1), requires_grad=True)
-
- def forward(self, x):
- # stx()
- out = x + self.bias.expand_as(x)
- return out
-
-class ReDistribution(nn.Module):
- def __init__(self, out_chn):
- super(ReDistribution, self).__init__()
- self.b = nn.Parameter(torch.zeros(1,out_chn,1,1), requires_grad=True)
- self.k = nn.Parameter(torch.ones(1,out_chn,1,1), requires_grad=True)
-
- def forward(self, x):
- out = x * self.k.expand_as(x) + self.b.expand_as(x)
- return out
-
-class RPReLU(nn.Module):
- def __init__(self, inplanes):
- super(RPReLU, self).__init__()
- self.pr_bias0 = LearnableBias(inplanes)
- self.pr_prelu = nn.PReLU(inplanes)
- self.pr_bias1 = LearnableBias(inplanes)
-
- def forward(self, x):
- x = self.pr_bias1(self.pr_prelu(self.pr_bias0(x)))
- return x
-
-class Spectral_Binary_Activation(nn.Module):
- def __init__(self):
- super(Spectral_Binary_Activation, self).__init__()
- self.beta = nn.Parameter(torch.ones(1), requires_grad=True)
-
- def forward(self, x):
-
- binary_activation_no_grad = torch.sign(x)
- tanh_activation = torch.tanh(x*self.beta)
-
- out = binary_activation_no_grad.detach() - tanh_activation.detach() + tanh_activation
- return out
-
-
-class HardBinaryConv(nn.Conv2d):
- def __init__(self, in_chn, out_chn, kernel_size=3, stride=1, padding=1, groups=1, bias=True):
- super(HardBinaryConv, self).__init__(
- in_chn,
- out_chn,
- kernel_size,
- stride=stride,
- padding=padding,
- groups=groups,
- bias=bias
- )
-
- def forward(self, x):
- real_weights = self.weight
- scaling_factor = torch.mean(torch.mean(torch.mean(abs(real_weights),dim=3,keepdim=True),dim=2,keepdim=True),dim=1,keepdim=True)
- scaling_factor = scaling_factor.detach()
- # stx()
- binary_weights_no_grad = scaling_factor * torch.sign(real_weights)
- # stx()
- cliped_weights = torch.clamp(real_weights, -1.0, 1.0)
- binary_weights = binary_weights_no_grad.detach() - cliped_weights.detach() + cliped_weights
- y = F.conv2d(x, binary_weights,self.bias, stride=self.stride, padding=self.padding, groups=self.groups)
-
- return y
-
-class BinaryConv2d(nn.Module):
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d, self).__init__()
-
- self.move0 = ReDistribution(in_channels)
- self.binary_activation = Spectral_Binary_Activation()
- self.binary_conv = HardBinaryConv(in_chn=in_channels,
- out_chn=in_channels,
- kernel_size=kernel_size,
- stride = stride,
- padding=padding,
- bias=bias,
- groups=groups)
- self.relu=RPReLU(in_channels)
-
-
- def forward(self, x):
- out = self.move0(x)
- out = self.binary_activation(out)
- out = self.binary_conv(out)
- out =self.relu(out)
- out = out + x
- return out
-
-
-class BinaryConv2d_Down(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Down, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h/2,w/2
- '''
- out = self.avg_pool(x)
- out_1 = out
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-
-class BinaryConv2d_Up(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Up, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,2h,2w
- '''
- b,c,h,w = x.shape
- out = F.interpolate(x, scale_factor=2, mode='bilinear')
-
- out_1 = out[:,:c//2,:,:]
- out_2 = out[:,c//2:,:,:]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Decrease(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,h,w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Decrease, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,h,w
- '''
- b,c,h,w = x.shape
- out = x
-
- out_1 = out[:,:c//2,:,:]
- out_2 = out[:,c//2:,:,:]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Increase(nn.Module):
- '''
- input: b,c,h,w
- output: b,2c,h,w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Increase, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h,w
- '''
- # stx()
- out_1 = x
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-# ---------------------------------------------------------- Binarized UNet------------------------------------------------------
-
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=2):
- super().__init__()
- self.net = nn.Sequential(
- BinaryConv2d_Fusion_Increase(dim, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Increase(dim * mult, dim * mult * mult, 1, 1, bias=False),
- RPReLU(dim * mult * mult),
- BinaryConv2d(dim * mult * mult, dim * mult * mult, 3, 1, 1, bias=False, groups=dim),
- RPReLU(dim * mult * mult),
- BinaryConv2d_Fusion_Decrease(dim * mult * mult, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-
-
-class BiSRNet_Block(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(
- PreNorm(dim, FeedForward(dim=dim))
- )
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for ff in self.blocks:
- # x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-
-class BiSRNet_body(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(BiSRNet_body, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = BinaryConv2d(in_dim, self.dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- BiSRNet_Block(dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- BinaryConv2d_Down(dim_stage, dim_stage * 2, 3, 1, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = BiSRNet_Block(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- BinaryConv2d_Up(dim_stage, dim_stage // 2, 3, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim_stage, dim_stage // 2, 1, 1, bias=False),
- BiSRNet_Block(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = BinaryConv2d(self.dim, out_dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (BiSRNet_Block, FeaDownSample) in self.encoder_layers:
- # stx()
- fea = BiSRNet_Block(fea)
- fea_encoder.append(fea)
- # stx()
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, BiSRNet_Block) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = BiSRNet_Block(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-
-class BiSRNet(nn.Module):
- '''
- Only 3 layers are 32-bit conv
- '''
- def __init__(self, in_channels=28, out_channels=28, n_feat=28, stage=3, num_blocks=[1,1,1]):
- super(BiSRNet, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False) # 1-bit -> 32-bit
- modules_body = [BiSRNet_body(dim=n_feat, stage=2, num_blocks=num_blocks) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True) # 1-bit -> 32-bit
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False) # 1-bit -> 32-bit
-
- def initial_x(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,256]
- :return: z: [b,28,256,256]
- """
- x = self.fution(torch.cat([y, Phi], dim=1))
- return x
-
- def forward(self, y, Phi=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if Phi==None:
- Phi = torch.rand((1,28,256,256)).cuda()
- # Phi = torch.rand((1,28,256,256)).to(device)
- x = self.initial_x(y, Phi)
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
\ No newline at end of file
diff --git a/MST/simulation/test_code/architecture/CST.py b/MST/simulation/test_code/architecture/CST.py
deleted file mode 100755
index ff5aa53..0000000
--- a/MST/simulation/test_code/architecture/CST.py
+++ /dev/null
@@ -1,588 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-from collections import defaultdict, Counter
-import numpy as np
-from tqdm import tqdm
-import random
-
-def uniform(a, b, shape, device='cuda'):
- return (b - a) * torch.rand(shape, device=device) + a
-
-class AsymmetricTransform:
-
- def Q(self, *args, **kwargs):
- raise NotImplementedError('Query transform not implemented')
-
- def K(self, *args, **kwargs):
- raise NotImplementedError('Key transform not implemented')
-
-class LSH:
- def __call__(self, *args, **kwargs):
- raise NotImplementedError('LSH scheme not implemented')
-
- def compute_hash_agreement(self, q_hash, k_hash):
- return (q_hash == k_hash).min(dim=-1)[0].sum(dim=-1)
-
-class XBOXPLUS(AsymmetricTransform):
-
- def set_norms(self, x):
- self.x_norms = x.norm(p=2, dim=-1, keepdim=True)
- self.MX = torch.amax(self.x_norms, dim=-2, keepdim=True)
-
- def X(self, x):
- device = x.device
- ext = torch.sqrt((self.MX**2).to(device) - (self.x_norms**2).to(device))
- zero = torch.tensor(0.0, device=x.device).repeat(x.shape[:-1], 1).unsqueeze(-1)
- return torch.cat((x, ext, zero), -1)
-
-def lsh_clustering(x, n_rounds, r=1):
- salsh = SALSH(n_rounds=n_rounds, dim=x.shape[-1], r=r, device=x.device)
- x_hashed = salsh(x).reshape((n_rounds,) + x.shape[:-1])
- return x_hashed.argsort(dim=-1)
-
-class SALSH(LSH):
- def __init__(self, n_rounds, dim, r, device='cuda'):
- super(SALSH, self).__init__()
- self.alpha = torch.normal(0, 1, (dim, n_rounds), device=device)
- self.beta = uniform(0, r, shape=(1, n_rounds), device=device)
- self.dim = dim
- self.r = r
-
- def __call__(self, vecs):
- projection = vecs @ self.alpha
- projection_shift = projection + self.beta
- projection_rescale = projection_shift / self.r
- return projection_rescale.permute(2, 0, 1)
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
-
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
-
- variance = scale / denom
-
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def batch_scatter(output, src, dim, index):
- """
- :param output: [b,n,c]
- :param src: [b,n,c]
- :param dim: int
- :param index: [b,n]
- :return: output: [b,n,c]
- """
- b,k,c = src.shape
- index = index[:, :, None].expand(-1, -1, c)
- output, src, index = map(lambda t: rearrange(t, 'b k c -> (b c) k'), (output, src, index))
- output.scatter_(dim,index,src)
- output = rearrange(output, '(b c) k -> b k c', b=b)
- return output
-
-def batch_gather(x, index, dim):
- """
- :param x: [b,n,c]
- :param index: [b,n//2]
- :param dim: int
- :return: output: [b,n//2,c]
- """
- b,n,c = x.shape
- index = index[:,:,None].expand(-1,-1,c)
- x, index = map(lambda t: rearrange(t, 'b n c -> (b c) n'), (x, index))
- output = torch.gather(x,dim,index)
- output = rearrange(output, '(b c) n -> b n c', b=b)
- return output
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class SAH_MSA(nn.Module):
- def __init__(self, heads=4, n_rounds=2, channels=64, patch_size=144,
- r=1):
- super(SAH_MSA, self).__init__()
- self.heads = heads
- self.n_rounds = n_rounds
- inner_dim = channels*3
- self.to_q = nn.Linear(channels, inner_dim, bias=False)
- self.to_k = nn.Linear(channels, inner_dim, bias=False)
- self.to_v = nn.Linear(channels, inner_dim, bias=False)
- self.to_out = nn.Linear(inner_dim, channels, bias=False)
-
- self.xbox_plus = XBOXPLUS()
- self.clustering_params = {
- 'r': r,
- 'n_rounds': self.n_rounds
- }
- self.q_attn_size = patch_size[0] * patch_size[1]
- self.k_attn_size = patch_size[0] * patch_size[1]
-
- def forward(self, input):
- """
- :param input: [b,n,c]
- :return: output: [b,n,c]
- """
-
- B, N, C_inp = input.shape
- query = self.to_q(input)
- key = self.to_k(input)
- value = self.to_v(input)
- input_hash = input.view(B, N, self.heads, C_inp//self.heads)
- x_hash = rearrange(input_hash, 'b t h e -> (b h) t e')
- bs, x_seqlen, dim = x_hash.shape
- with torch.no_grad():
- self.xbox_plus.set_norms(x_hash)
- Xs = self.xbox_plus.X(x_hash)
- x_positions = lsh_clustering(Xs, **self.clustering_params)
- x_positions = x_positions.reshape(self.n_rounds, bs, -1)
-
- del Xs
-
- C = query.shape[-1]
- query = query.view(B, N, self.heads, C // self.heads)
- key = key.view(B, N, self.heads, C // self.heads)
- value = value.view(B, N, self.heads, C // self.heads)
-
- query = rearrange(query, 'b t h e -> (b h) t e') # [bs, q_seqlen,c]
- key = rearrange(key, 'b t h e -> (b h) t e')
- value = rearrange(value, 'b s h d -> (b h) s d')
-
- bs, q_seqlen, dim = query.shape
- bs, k_seqlen, dim = key.shape
- v_dim = value.shape[-1]
-
- x_rev_positions = torch.argsort(x_positions, dim=-1)
- x_offset = torch.arange(bs, device=query.device).unsqueeze(-1) * x_seqlen
- x_flat = (x_positions + x_offset).reshape(-1)
-
- s_queries = query.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.q_attn_size, dim)
- s_keys = key.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, dim)
- s_values = value.reshape(-1, v_dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, v_dim)
-
- inner = s_queries @ s_keys.transpose(2, 1)
- norm_factor = 1
- inner = inner / norm_factor
-
- # free memory
- del x_positions
-
- # softmax denominator
- dots_logsumexp = torch.logsumexp(inner, dim=-1, keepdim=True)
- # softmax
- dots = torch.exp(inner - dots_logsumexp)
- # dropout
-
- # n_rounds outs
- bo = (dots @ s_values).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- # undo sort
- x_offset = torch.arange(bs * self.n_rounds, device=query.device).unsqueeze(-1) * x_seqlen
- x_rev_flat = (x_rev_positions.reshape(-1, x_seqlen) + x_offset).reshape(-1)
- o = bo.reshape(-1, v_dim).index_select(0, x_rev_flat).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- slogits = dots_logsumexp.reshape(self.n_rounds, bs, -1)
- logits = torch.gather(slogits, 2, x_rev_positions)
-
- # free memory
- del x_rev_positions
-
- # weighted sum multi-round attention
- probs = torch.exp(logits - torch.logsumexp(logits, dim=0, keepdim=True))
- out = torch.sum(o * probs.unsqueeze(-1), dim=0)
- out = rearrange(out, '(b h) t d -> b t h d', h=self.heads)
- out = out.reshape(B, N, -1)
- out = self.to_out(out)
-
- return out
-
-class SAHAB(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(16, 16),
- heads=8,
- shift_size=0,
- sparse=False
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- self.attn = PreNorm(dim, SAH_MSA(heads=heads, n_rounds=2, r=1, channels=dim, patch_size=patch_size))
- self.ffn = PreNorm(dim, FeedForward(dim=dim))
- self.shift_size = shift_size
- self.patch_size = patch_size
- self.sparse = sparse
-
- def forward(self, x, mask=None):
- """
- x: [b,h,w,c]
- mask: [b,h,w]
- return out: [b,h,w,c]
- """
- b,h,w,c = x.shape
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- mask = torch.roll(mask, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- w_size = self.patch_size
-
- # Split into large patches
- x = rearrange(x, 'b (nh hh) (nw ww) c-> b (nh nw) (hh ww c)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- mask = rearrange(mask, 'b (nh hh) (nw ww) -> b (nh nw) (hh ww)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- N = x.shape[1]
-
- mask = torch.mean(mask,dim=2,keepdim=False) # [b,nh*nw]
- if self.sparse:
- mask_select = mask.topk(mask.shape[1] // 2, dim=1)[1] # [b,nh*nw//2]
- x_select = batch_gather(x, mask_select, 1) # [b,nh*nw//2,hh*ww*c]
- x_select = x_select.reshape(b*N//2,-1,c)
- x_select = self.attn(x_select)+x_select
- x_select = x_select.view(b,N//2,-1)
- x = batch_scatter(x.clone(), x_select, 1, mask_select)
- else:
- x = x.view(b*N,-1,c)
- x = self.attn(x) + x
- x = x.view(b, N, -1)
- x = rearrange(x, 'b (nh nw) (hh ww c) -> b (nh hh) (nw ww) c', nh=h//(w_size[0] * 2), hh=w_size[0] * 2, ww=w_size[1] * 2)
-
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(self.shift_size, self.shift_size), dims=(1, 2))
-
- x = self.ffn(x) + x
-
- return x
-
-
-class SAHABs(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(8, 8),
- heads=8,
- num_blocks=2,
- sparse=False
- ):
- super().__init__()
- blocks = []
- for _ in range(num_blocks):
- blocks.append(
- SAHAB(heads=heads, dim=dim, patch_size=patch_size,sparse=sparse,
- shift_size=0 if (_ % 2 == 0) else patch_size[0]))
- self.blocks = nn.Sequential(*blocks)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,1,h,w]
- return x: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- mask = mask.squeeze(1)
- for block in self.blocks:
- x = block(x, mask)
- x = x.permute(0, 3, 1, 2)
- return x
-
-class ASPPConv(nn.Sequential):
- def __init__(self, in_channels, out_channels, dilation):
- modules = [
- nn.Conv2d(in_channels, out_channels, 3, padding=dilation, dilation=dilation, bias=False),
- nn.ReLU()
- ]
- super(ASPPConv, self).__init__(*modules)
-
-
-class ASPPPooling(nn.Sequential):
- def __init__(self, in_channels, out_channels):
- super(ASPPPooling, self).__init__(
- nn.AdaptiveAvgPool2d(1),
- nn.Conv2d(in_channels, out_channels, 1, bias=False),
- nn.ReLU())
-
- def forward(self, x):
- size = x.shape[-2:]
- for mod in self:
- x = mod(x)
- return F.interpolate(x, size=size, mode='bilinear', align_corners=False)
-
-
-class ASPP(nn.Module):
- def __init__(self, in_channels, atrous_rates, out_channels):
- super(ASPP, self).__init__()
- modules = []
-
- rates = tuple(atrous_rates)
- for rate in rates:
- modules.append(ASPPConv(in_channels, out_channels, rate))
-
- modules.append(ASPPPooling(in_channels, out_channels))
-
- self.convs = nn.ModuleList(modules)
-
- self.project = nn.Sequential(
- nn.Conv2d(len(self.convs) * out_channels, out_channels, 1, bias=False),
- nn.ReLU(),
- nn.Dropout(0.5))
-
- def forward(self, x):
- res = []
- for conv in self.convs:
- res.append(conv(x))
- res = torch.cat(res, dim=1)
- return self.project(res)
-
-class Sparsity_Estimator(nn.Module):
- def __init__(self, dim=28, expand=2, sparse=False):
- super(Sparsity_Estimator, self).__init__()
- self.dim = dim
- self.stage = 2
- self.sparse = sparse
-
- # Input projection
- self.in_proj = nn.Conv2d(28, dim, 1, 1, 0, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(2):
- self.encoder_layers.append(nn.ModuleList([
- nn.Conv2d(dim_stage, dim_stage * expand, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage * expand, dim_stage * expand, 3, 2, 1, bias=False, groups=dim_stage * expand),
- nn.Conv2d(dim_stage * expand, dim_stage*expand, 1, 1, 0, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = ASPP(dim_stage, [3,6], dim_stage)
-
- # Decoder:
- self.decoder_layers = nn.ModuleList([])
- for i in range(2):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage // 2, dim_stage, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage, dim_stage, 3, 1, 1, bias=False, groups=dim_stage),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, 0, bias=False),
- ]))
- dim_stage //= 2
-
- # Output projection
- if sparse:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim+1, 3, 1, 1, bias=False)
- else:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- # Input projection
- fea = self.lrelu(self.in_proj(x))
- # Encoder
- fea_encoder = [] # [c 2c 4c 8c]
- for (Conv1, Conv2, Conv3) in self.encoder_layers:
- fea_encoder.append(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- # Bottleneck
- fea = self.bottleneck(fea)+fea
- # Decoder
- for i, (FeaUpSample, Conv1, Conv2, Conv3) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- fea = fea + fea_encoder[self.stage-1-i]
- # Output projection
- out = self.out_conv2(fea)
- if self.sparse:
- error_map = out[:,-1:,:,:]
- return out[:,:-1], error_map
- return out
-
-class CST(nn.Module):
- def __init__(self, dim=28, stage=2, num_blocks=[2, 2, 2], sparse=False):
- super(CST, self).__init__()
- self.dim = dim
- self.stage = stage
- self.sparse = sparse
-
- # Fution physical mask and shifted measurement
- self.fution = nn.Conv2d(56, 28, 1, 1, 0, bias=False)
-
- # Sparsity Estimator
- if num_blocks==[2,4,6]:
- self.fe = nn.Sequential(Sparsity_Estimator(dim=28,expand=2,sparse=False),
- Sparsity_Estimator(dim=28, expand=2, sparse=sparse))
- else:
- self.fe = Sparsity_Estimator(dim=28, expand=2, sparse=sparse)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- SAHABs(dim=dim_stage, num_blocks=num_blocks[i], heads=dim_stage // dim, sparse=sparse),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.AvgPool2d(kernel_size=2, stride=2),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = SAHABs(
- dim=dim_stage, heads=dim_stage // dim, num_blocks=num_blocks[-1], sparse=sparse)
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- SAHABs(dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i],
- heads=(dim_stage // 2) // dim, sparse=sparse),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.out_proj = nn.Conv2d(self.dim, dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,c,h,w]
- return out:[b,c,h,w]
- """
- b, c, h, w = x.shape
-
- # Fution
- x = self.fution(torch.cat([x,mask],dim=1))
-
- # Feature Extraction
- if self.sparse:
- fea,mask = self.fe(x)
- else:
- fea = self.fe(x)
- mask = torch.randn((b,1,h,w)).cuda()
-
- # Encoder
- fea_encoder = []
- masks = []
- for (Blcok, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = Blcok(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Blcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = fea + fea_encoder[self.stage - 1 - i]
- mask = masks[self.stage - 1 - i]
- fea = Blcok(fea, mask)
-
- # Output projection
- out = self.out_proj(fea) + x
- return out
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/test_code/architecture/DAUHST.py b/MST/simulation/test_code/architecture/DAUHST.py
deleted file mode 100755
index 07f8461..0000000
--- a/MST/simulation/test_code/architecture/DAUHST.py
+++ /dev/null
@@ -1,367 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch import einsum
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-class HS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=28,
- heads=8,
- only_local_branch=False
- ):
- super().__init__()
-
- self.dim = dim
- self.heads = heads
- self.scale = dim_head ** -0.5
- self.window_size = window_size
- self.only_local_branch = only_local_branch
-
- # position embedding
- if only_local_branch:
- seq_l = window_size[0] * window_size[1]
- self.pos_emb = nn.Parameter(torch.Tensor(1, heads, seq_l, seq_l))
- trunc_normal_(self.pos_emb)
- else:
- seq_l1 = window_size[0] * window_size[1]
- self.pos_emb1 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l1, seq_l1))
- h,w = 256//self.heads,320//self.heads
- seq_l2 = h*w//seq_l1
- self.pos_emb2 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l2, seq_l2))
- trunc_normal_(self.pos_emb1)
- trunc_normal_(self.pos_emb2)
-
- inner_dim = dim_head * heads
- self.to_q = nn.Linear(dim, inner_dim, bias=False)
- self.to_kv = nn.Linear(dim, inner_dim * 2, bias=False)
- self.to_out = nn.Linear(inner_dim, dim)
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x.shape
- w_size = self.window_size
- assert h % w_size[0] == 0 and w % w_size[1] == 0, 'fmap dimensions must be divisible by the window size'
- if self.only_local_branch:
- x_inp = rearrange(x, 'b (h b0) (w b1) c -> (b h w) (b0 b1) c', b0=w_size[0], b1=w_size[1])
- q = self.to_q(x_inp)
- k, v = self.to_kv(x_inp).chunk(2, dim=-1)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.heads), (q, k, v))
- q *= self.scale
- sim = einsum('b h i d, b h j d -> b h i j', q, k)
- sim = sim + self.pos_emb
- attn = sim.softmax(dim=-1)
- out = einsum('b h i j, b h j d -> b h i d', attn, v)
- out = rearrange(out, 'b h n d -> b n (h d)')
- out = self.to_out(out)
- out = rearrange(out, '(b h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- else:
- q = self.to_q(x)
- k, v = self.to_kv(x).chunk(2, dim=-1)
- q1, q2 = q[:,:,:,:c//2], q[:,:,:,c//2:]
- k1, k2 = k[:,:,:,:c//2], k[:,:,:,c//2:]
- v1, v2 = v[:,:,:,:c//2], v[:,:,:,c//2:]
-
- # local branch
- q1, k1, v1 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q1, k1, v1))
- q1, k1, v1 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q1, k1, v1))
- q1 *= self.scale
- sim1 = einsum('b n h i d, b n h j d -> b n h i j', q1, k1)
- sim1 = sim1 + self.pos_emb1
- attn1 = sim1.softmax(dim=-1)
- out1 = einsum('b n h i j, b n h j d -> b n h i d', attn1, v1)
- out1 = rearrange(out1, 'b n h mm d -> b n mm (h d)')
-
- # non-local branch
- q2, k2, v2 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q2, k2, v2))
- q2, k2, v2 = map(lambda t: t.permute(0, 2, 1, 3), (q2.clone(), k2.clone(), v2.clone()))
- q2, k2, v2 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q2, k2, v2))
- q2 *= self.scale
- sim2 = einsum('b n h i d, b n h j d -> b n h i j', q2, k2)
- sim2 = sim2 + self.pos_emb2
- attn2 = sim2.softmax(dim=-1)
- out2 = einsum('b n h i j, b n h j d -> b n h i d', attn2, v2)
- out2 = rearrange(out2, 'b n h mm d -> b n mm (h d)')
- out2 = out2.permute(0, 2, 1, 3)
-
- out = torch.cat([out1,out2],dim=-1).contiguous()
- out = self.to_out(out)
- out = rearrange(out, 'b (h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- return out
-
-class HSAB(nn.Module):
- def __init__(
- self,
- dim,
- window_size=(8, 8),
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- PreNorm(dim, HS_MSA(dim=dim, window_size=window_size, dim_head=dim_head, heads=heads, only_local_branch=(heads==1))),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class HST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]):
- super(HST, self).__init__()
- self.dim = dim
- self.scales = len(num_blocks)
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_scale = dim
- for i in range(self.scales-1):
- self.encoder_layers.append(nn.ModuleList([
- HSAB(dim=dim_scale, num_blocks=num_blocks[i], dim_head=dim, heads=dim_scale // dim),
- nn.Conv2d(dim_scale, dim_scale * 2, 4, 2, 1, bias=False),
- ]))
- dim_scale *= 2
-
- # Bottleneck
- self.bottleneck = HSAB(dim=dim_scale, dim_head=dim, heads=dim_scale // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(self.scales-1):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_scale, dim_scale // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_scale, dim_scale // 2, 1, 1, bias=False),
- HSAB(dim=dim_scale // 2, num_blocks=num_blocks[self.scales - 2 - i], dim_head=dim,
- heads=(dim_scale // 2) // dim),
- ]))
- dim_scale //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 16, 16
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
-
- # Embedding
- fea = self.embedding(x)
- x = x[:,:28,:,:]
-
- # Encoder
- fea_encoder = []
- for (HSAB, FeaDownSample) in self.encoder_layers:
- fea = HSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, HSAB) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.scales-2-i]], dim=1))
- fea = HSAB(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out[:, :, :h_inp, :w_inp]
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class HyPaNet(nn.Module):
- def __init__(self, in_nc=29, out_nc=8, channel=64):
- super(HyPaNet, self).__init__()
- self.fution = nn.Conv2d(in_nc, channel, 1, 1, 0, bias=True)
- self.down_sample = nn.Conv2d(channel, channel, 3, 2, 1, bias=True)
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.mlp = nn.Sequential(
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, out_nc, 1, padding=0, bias=True),
- nn.Softplus())
- self.relu = nn.ReLU(inplace=True)
- self.out_nc = out_nc
-
- def forward(self, x):
- x = self.down_sample(self.relu(self.fution(x)))
- x = self.avg_pool(x)
- x = self.mlp(x) + 1e-6
- return x[:,:self.out_nc//2,:,:], x[:,self.out_nc//2:,:,:]
-
-class DAUHST(nn.Module):
-
- def __init__(self, num_iterations=1):
- super(DAUHST, self).__init__()
- self.para_estimator = HyPaNet(in_nc=28, out_nc=num_iterations*2)
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True)
- self.num_iterations = num_iterations
- self.denoisers = nn.ModuleList([])
- for _ in range(num_iterations):
- self.denoisers.append(
- HST(in_dim=29, out_dim=28, dim=28, num_blocks=[1,1,1]),
- )
- def initial(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :return: temp: [b,28,256,310]; alpha: [b, num_iterations]; beta: [b, num_iterations]
- """
- nC, step = 28, 2
- y = y / nC * 2
- bs,row,col = y.shape
- y_shift = torch.zeros(bs, nC, row, col).cuda().float()
- for i in range(nC):
- y_shift[:, i, :, step * i:step * i + col - (nC - 1) * step] = y[:, :, step * i:step * i + col - (nC - 1) * step]
- z = self.fution(torch.cat([y_shift, Phi], dim=1))
- alpha, beta = self.para_estimator(self.fution(torch.cat([y_shift, Phi], dim=1)))
- return z, alpha, beta
-
- def forward(self, y, input_mask=None):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :param Phi_PhiT: [b,256,310]
- :return: z_crop: [b,28,256,256]
- """
- Phi, Phi_s = input_mask
- z, alphas, betas = self.initial(y, Phi)
- for i in range(self.num_iterations):
- alpha, beta = alphas[:,i,:,:], betas[:,i:i+1,:,:]
- Phi_z = A(z, Phi)
- x = z + At(torch.div(y-Phi_z,alpha+Phi_s), Phi)
- x = shift_back_3d(x)
- beta_repeat = beta.repeat(1,1,x.shape[2], x.shape[3])
- z = self.denoisers[i](torch.cat([x, beta_repeat],dim=1))
- if i [BN] => ReLU) * 2"""
-
- def __init__(self, in_channels, out_channels, mid_channels=None):
- super().__init__()
- if not mid_channels:
- mid_channels = out_channels
- self.double_conv = nn.Sequential(
- nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(mid_channels),
- nn.ReLU(inplace=True),
- nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(out_channels),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- return self.double_conv(x)
-
-class GAP_net(nn.Module):
-
- def __init__(self):
- super(GAP_net, self).__init__()
-
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
-
- def forward(self, y, input_mask=None):
- if input_mask==None:
- Phi = torch.rand((1,28,256,310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- x = At(y, Phi) # v0=H^T y
- ### 1-3
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet1(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet2(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet3(x)
- x = shift_3d(x)
- ### 4-6
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet4(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet5(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet6(x)
- x = shift_3d(x)
- # ### 7-9
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet7(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet8(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet9(x)
- x = shift_3d(x)
- return x[:, :, :, 0:256]
diff --git a/MST/simulation/test_code/architecture/HDNet.py b/MST/simulation/test_code/architecture/HDNet.py
deleted file mode 100755
index 442acc8..0000000
--- a/MST/simulation/test_code/architecture/HDNet.py
+++ /dev/null
@@ -1,371 +0,0 @@
-import torch
-import torch.nn as nn
-import math
-
-def default_conv(in_channels, out_channels, kernel_size, bias=True):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias)
-
-class MeanShift(nn.Conv2d):
- def __init__(
- self, rgb_range,
- rgb_mean=(0.4488, 0.4371, 0.4040), rgb_std=(1.0, 1.0, 1.0), sign=-1):
-
- super(MeanShift, self).__init__(3, 3, kernel_size=1)
- std = torch.Tensor(rgb_std)
- self.weight.data = torch.eye(3).view(3, 3, 1, 1) / std.view(3, 1, 1, 1)
- self.bias.data = sign * rgb_range * torch.Tensor(rgb_mean) / std
- for p in self.parameters():
- p.requires_grad = False
-
-class BasicBlock(nn.Sequential):
- def __init__(
- self, conv, in_channels, out_channels, kernel_size, stride=1, bias=False,
- bn=True, act=nn.ReLU(True)):
-
- m = [conv(in_channels, out_channels, kernel_size, bias=bias)]
- if bn:
- m.append(nn.BatchNorm2d(out_channels))
- if act is not None:
- m.append(act)
-
- super(BasicBlock, self).__init__(*m)
-
-class ResBlock(nn.Module):
- def __init__(
- self, conv, n_feats, kernel_size,
- bias=True, bn=False, act=nn.ReLU(True), res_scale=1):
-
- super(ResBlock, self).__init__()
- m = []
- for i in range(2):
- m.append(conv(n_feats, n_feats, kernel_size, bias=bias))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if i == 0:
- m.append(act)
-
- self.body = nn.Sequential(*m)
- self.res_scale = res_scale
-
- def forward(self, x):
- res = self.body(x).mul(self.res_scale) # So res_scale is a scaler? just scale all elements in each feature's residual? Why?
- res += x
-
- return res
-
-class Upsampler(nn.Sequential):
- def __init__(self, conv, scale, n_feats, bn=False, act=False, bias=True):
-
- m = []
- if (scale & (scale - 1)) == 0:
- for _ in range(int(math.log(scale, 2))):
- m.append(conv(n_feats, 4 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(2))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
-
- elif scale == 3:
- m.append(conv(n_feats, 9 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(3))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
- else:
- raise NotImplementedError
-
- super(Upsampler, self).__init__(*m)
-
-_NORM_BONE = False
-
-def constant_init(module, val, bias=0):
- if hasattr(module, 'weight') and module.weight is not None:
- nn.init.constant_(module.weight, val)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-
-def kaiming_init(module,
- a=0,
- mode='fan_out',
- nonlinearity='relu',
- bias=0,
- distribution='normal'):
- assert distribution in ['uniform', 'normal']
- if distribution == 'uniform':
- nn.init.kaiming_uniform_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- else:
- nn.init.kaiming_normal_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-# depthwise-separable convolution (DSC)
-class DSC(nn.Module):
-
- def __init__(self, nin: int) -> None:
- super(DSC, self).__init__()
- self.conv_dws = nn.Conv2d(
- nin, nin, kernel_size=1, stride=1, padding=0, groups=nin
- )
- self.bn_dws = nn.BatchNorm2d(nin, momentum=0.9)
- self.relu_dws = nn.ReLU(inplace=False)
-
- self.maxpool = nn.MaxPool2d(kernel_size=3, stride=1, padding=1)
-
- self.conv_point = nn.Conv2d(
- nin, 1, kernel_size=1, stride=1, padding=0, groups=1
- )
- self.bn_point = nn.BatchNorm2d(1, momentum=0.9)
- self.relu_point = nn.ReLU(inplace=False)
-
- self.softmax = nn.Softmax(dim=2)
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- out = self.conv_dws(x)
- out = self.bn_dws(out)
- out = self.relu_dws(out)
-
- out = self.maxpool(out)
-
- out = self.conv_point(out)
- out = self.bn_point(out)
- out = self.relu_point(out)
-
- m, n, p, q = out.shape
- out = self.softmax(out.view(m, n, -1))
- out = out.view(m, n, p, q)
-
- out = out.expand(x.shape[0], x.shape[1], x.shape[2], x.shape[3])
-
- out = torch.mul(out, x)
-
- out = out + x
-
- return out
-
-# Efficient Feature Fusion(EFF)
-class EFF(nn.Module):
- def __init__(self, nin: int, nout: int, num_splits: int) -> None:
- super(EFF, self).__init__()
-
- assert nin % num_splits == 0
-
- self.nin = nin
- self.nout = nout
- self.num_splits = num_splits
- self.subspaces = nn.ModuleList(
- [DSC(int(self.nin / self.num_splits)) for i in range(self.num_splits)]
- )
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- sub_feat = torch.chunk(x, self.num_splits, dim=1)
- out = []
- for idx, l in enumerate(self.subspaces):
- out.append(self.subspaces[idx](sub_feat[idx]))
- out = torch.cat(out, dim=1)
-
- return out
-
-
-# spatial-spectral domain attention learning(SDL)
-class SDL_attention(nn.Module):
- def __init__(self, inplanes, planes, kernel_size=1, stride=1):
- super(SDL_attention, self).__init__()
-
- self.inplanes = inplanes
- self.inter_planes = planes // 2
- self.planes = planes
- self.kernel_size = kernel_size
- self.stride = stride
- self.padding = (kernel_size-1)//2
-
- self.conv_q_right = nn.Conv2d(self.inplanes, 1, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_v_right = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_up = nn.Conv2d(self.inter_planes, self.planes, kernel_size=1, stride=1, padding=0, bias=False)
- self.softmax_right = nn.Softmax(dim=2)
- self.sigmoid = nn.Sigmoid()
-
- self.conv_q_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #g
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.conv_v_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #theta
- self.softmax_left = nn.Softmax(dim=2)
-
- self.reset_parameters()
-
- def reset_parameters(self):
- kaiming_init(self.conv_q_right, mode='fan_in')
- kaiming_init(self.conv_v_right, mode='fan_in')
- kaiming_init(self.conv_q_left, mode='fan_in')
- kaiming_init(self.conv_v_left, mode='fan_in')
-
- self.conv_q_right.inited = True
- self.conv_v_right.inited = True
- self.conv_q_left.inited = True
- self.conv_v_left.inited = True
- # HR spatial attention
- def spatial_attention(self, x):
- input_x = self.conv_v_right(x)
- batch, channel, height, width = input_x.size()
-
- input_x = input_x.view(batch, channel, height * width)
- context_mask = self.conv_q_right(x)
- context_mask = context_mask.view(batch, 1, height * width)
- context_mask = self.softmax_right(context_mask)
-
- context = torch.matmul(input_x, context_mask.transpose(1,2))
- context = context.unsqueeze(-1)
- context = self.conv_up(context)
-
- mask_ch = self.sigmoid(context)
-
- out = x * mask_ch
-
- return out
- # HR spectral attention
- def spectral_attention(self, x):
-
- g_x = self.conv_q_left(x)
- batch, channel, height, width = g_x.size()
-
- avg_x = self.avg_pool(g_x)
- batch, channel, avg_x_h, avg_x_w = avg_x.size()
-
- avg_x = avg_x.view(batch, channel, avg_x_h * avg_x_w).permute(0, 2, 1)
- theta_x = self.conv_v_left(x).view(batch, self.inter_planes, height * width)
- context = torch.matmul(avg_x, theta_x)
- context = self.softmax_left(context)
- context = context.view(batch, 1, height, width)
-
- mask_sp = self.sigmoid(context)
-
- out = x * mask_sp
-
- return out
-
- def forward(self, x):
- context_spectral = self.spectral_attention(x)
- context_spatial = self.spatial_attention(x)
- out = context_spatial + context_spectral
- return out
-
-
-class HDNet(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28, conv=default_conv):
- super(HDNet, self).__init__()
-
- n_resblocks = 16
- n_feats = 64
- kernel_size = 3
- act = nn.ReLU(True)
-
- # define head module
- m_head = [conv(in_ch, n_feats, kernel_size)]
-
- # define body module
- m_body = [
- ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ) for _ in range(n_resblocks)
- ]
- m_body.append(SDL_attention(inplanes = n_feats, planes = n_feats))
- m_body.append(EFF(nin=n_feats, nout=n_feats, num_splits=4))
-
- for i in range(1, n_resblocks):
- m_body.append(ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ))
-
- m_body.append(conv(n_feats, n_feats, kernel_size))
-
- m_tail = [conv(n_feats, out_ch, kernel_size)]
-
- self.head = nn.Sequential(*m_head)
- self.body = nn.Sequential(*m_body)
- self.tail = nn.Sequential(*m_tail)
-
- def forward(self, x, input_mask=None):
- x = self.head(x)
-
- res = self.body(x)
- res += x
-
- x = self.tail(res)
-
- return x
-
-# frequency domain learning(FDL)
-class FDL(nn.Module):
- def __init__(self, loss_weight=1.0, alpha=1.0, patch_factor=1, ave_spectrum=False, log_matrix=False, batch_matrix=False):
- super(FDL, self).__init__()
- self.loss_weight = loss_weight
- self.alpha = alpha
- self.patch_factor = patch_factor
- self.ave_spectrum = ave_spectrum
- self.log_matrix = log_matrix
- self.batch_matrix = batch_matrix
-
- def tensor2freq(self, x):
- patch_factor = self.patch_factor
- _, _, h, w = x.shape
- assert h % patch_factor == 0 and w % patch_factor == 0, (
- 'Patch factor should be divisible by image height and width')
- patch_list = []
- patch_h = h // patch_factor
- patch_w = w // patch_factor
- for i in range(patch_factor):
- for j in range(patch_factor):
- patch_list.append(x[:, :, i * patch_h:(i + 1) * patch_h, j * patch_w:(j + 1) * patch_w])
-
- y = torch.stack(patch_list, 1)
-
- return torch.rfft(y, 2, onesided=False, normalized=True)
-
- def loss_formulation(self, recon_freq, real_freq, matrix=None):
- if matrix is not None:
- weight_matrix = matrix.detach()
- else:
- matrix_tmp = (recon_freq - real_freq) ** 2
- matrix_tmp = torch.sqrt(matrix_tmp[..., 0] + matrix_tmp[..., 1]) ** self.alpha
- if self.log_matrix:
- matrix_tmp = torch.log(matrix_tmp + 1.0)
-
- if self.batch_matrix:
- matrix_tmp = matrix_tmp / matrix_tmp.max()
- else:
- matrix_tmp = matrix_tmp / matrix_tmp.max(-1).values.max(-1).values[:, :, :, None, None]
-
- matrix_tmp[torch.isnan(matrix_tmp)] = 0.0
- matrix_tmp = torch.clamp(matrix_tmp, min=0.0, max=1.0)
- weight_matrix = matrix_tmp.clone().detach()
-
- assert weight_matrix.min().item() >= 0 and weight_matrix.max().item() <= 1, (
- 'The values of spectrum weight matrix should be in the range [0, 1], '
- 'but got Min: %.10f Max: %.10f' % (weight_matrix.min().item(), weight_matrix.max().item()))
-
- tmp = (recon_freq - real_freq) ** 2
- freq_distance = tmp[..., 0] + tmp[..., 1]
-
- loss = weight_matrix * freq_distance
- return torch.mean(loss)
-
- def forward(self, pred, target, matrix=None, **kwargs):
-
- pred_freq = self.tensor2freq(pred)
- target_freq = self.tensor2freq(target)
-
- if self.ave_spectrum:
- pred_freq = torch.mean(pred_freq, 0, keepdim=True)
- target_freq = torch.mean(target_freq, 0, keepdim=True)
-
- return self.loss_formulation(pred_freq, target_freq, matrix) * self.loss_weight
diff --git a/MST/simulation/test_code/architecture/Lambda_Net.py b/MST/simulation/test_code/architecture/Lambda_Net.py
deleted file mode 100755
index ddac0aa..0000000
--- a/MST/simulation/test_code/architecture/Lambda_Net.py
+++ /dev/null
@@ -1,179 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-
-class LambdaNetAttention(nn.Module):
- def __init__(
- self,
- dim,
- ):
- super().__init__()
-
- self.dim = dim
- self.to_q = nn.Linear(dim, dim//8, bias=False)
- self.to_k = nn.Linear(dim, dim//8, bias=False)
- self.to_v = nn.Linear(dim, dim, bias=False)
- self.rescale = (dim//8)**-0.5
- self.gamma = nn.Parameter(torch.ones(1))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0,2,3,1)
- b, h, w, c = x.shape
-
- # Reshape to (B,N,C), where N = window_size[0]*window_size[1] is the length of sentence
- x_inp = rearrange(x, 'b h w c -> b (h w) c')
-
- # produce query, key and value
- q = self.to_q(x_inp)
- k = self.to_k(x_inp)
- v = self.to_v(x_inp)
-
- # attention
- sim = einsum('b i d, b j d -> b i j', q, k)*self.rescale
- attn = sim.softmax(dim=-1)
-
- # aggregate
- out = einsum('b i j, b j d -> b i d', attn, v)
-
- # merge blocks back to original feature map
- out = rearrange(out, 'b (h w) c -> b h w c', h=h, w=w)
- out = self.gamma*out + x
- return out.permute(0,3,1,2)
-
-class triple_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(triple_conv, self).__init__()
- self.t_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.t_conv(x)
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class Lambda_Net(nn.Module):
-
- def __init__(self, out_ch=28):
- super(Lambda_Net, self).__init__()
- self.conv_in = nn.Conv2d(1+28, 28, 3, padding=1)
-
- # encoder
- self.conv_down1 = triple_conv(28, 32)
- self.conv_down2 = triple_conv(32, 64)
- self.conv_down3 = triple_conv(64, 128)
- self.conv_down4 = triple_conv(128, 256)
- self.conv_down5 = double_conv(256, 512)
- self.conv_down6 = double_conv(512, 1024)
-
- self.maxpool = nn.MaxPool2d(2)
-
- # decoder
- self.upsample5 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
- self.upsample4 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
- self.upsample3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
- self.upsample2 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
- self.upsample1 = nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2)
-
- self.conv_up1 = triple_conv(32+32, 32)
- self.conv_up2 = triple_conv(64+64, 64)
- self.conv_up3 = triple_conv(128+128, 128)
- self.conv_up4 = triple_conv(256+256, 256)
- self.conv_up5 = double_conv(512+512, 512)
-
- # attention
- self.attention = LambdaNetAttention(dim=128)
-
- self.conv_last1 = nn.Conv2d(32, 6, 3,1,1)
- self.conv_last2 = nn.Conv2d(38, 32, 3,1,1)
- self.conv_last3 = nn.Conv2d(32, 12, 3,1,1)
- self.conv_last4 = nn.Conv2d(44, 32, 3,1,1)
- self.conv_last5 = nn.Conv2d(32, out_ch, 1)
- self.act = nn.ReLU()
-
- def forward(self, x, input_mask=None):
- if input_mask == None:
- input_mask = torch.zeros((1,28,256,310)).cuda()
- x = x/28*2
- x = self.conv_in(torch.cat([x.unsqueeze(1), input_mask], dim=1))
- b, c, h_inp, w_inp = x.shape
- hb, wb = 32, 32
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- res0 = x
- conv1 = self.conv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.conv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.conv_down3(x)
- x = self.maxpool(conv3)
- conv4 = self.conv_down4(x)
- x = self.maxpool(conv4)
- conv5 = self.conv_down5(x)
- x = self.maxpool(conv5)
- conv6 = self.conv_down6(x)
-
- x = self.upsample5(conv6)
- x = torch.cat([x, conv5], dim=1)
- x = self.conv_up5(x)
-
- x = self.upsample4(x)
- x = torch.cat([x, conv4], dim=1)
- x = self.conv_up4(x)
-
- x = self.upsample3(x)
- x = torch.cat([x, conv3], dim=1)
- x = self.conv_up3(x)
- x = self.attention(x)
-
- x = self.upsample2(x)
- x = torch.cat([x, conv2], dim=1)
- x = self.conv_up2(x)
-
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
- x = self.conv_up1(x)
-
- res1 = x
- out1 = self.act(self.conv_last1(x))
- x = self.conv_last2(torch.cat([res1,out1],dim=1))
-
- res2 = x
- out2 = self.act(self.conv_last3(x))
- out3 = self.conv_last4(torch.cat([res2, out2], dim=1))
-
- out = self.conv_last5(out3)+res0
- out = out[:, :, :h_inp, :w_inp]
-
- return shift_back_3d(out)[:, :, :, :256]
diff --git a/MST/simulation/test_code/architecture/MST.py b/MST/simulation/test_code/architecture/MST.py
deleted file mode 100755
index 3686dfc..0000000
--- a/MST/simulation/test_code/architecture/MST.py
+++ /dev/null
@@ -1,311 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MaskGuidedMechanism(nn.Module):
- def __init__(
- self, n_feat):
- super(MaskGuidedMechanism, self).__init__()
-
- self.conv1 = nn.Conv2d(n_feat, n_feat, kernel_size=1, bias=True)
- self.conv2 = nn.Conv2d(n_feat, n_feat, kernel_size=1, bias=True)
- self.depth_conv = nn.Conv2d(n_feat, n_feat, kernel_size=5, padding=2, bias=True, groups=n_feat)
-
- def forward(self, mask_shift):
- # x: b,c,h,w
- [bs, nC, row, col] = mask_shift.shape
- mask_shift = self.conv1(mask_shift)
- attn_map = torch.sigmoid(self.depth_conv(self.conv2(mask_shift)))
- res = mask_shift * attn_map
- mask_shift = res + mask_shift
- mask_emb = shift_back(mask_shift)
- return mask_emb
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.mm = MaskGuidedMechanism(dim)
- self.dim = dim
-
- def forward(self, x_in, mask=None):
- """
- x_in: [b,h,w,c]
- mask: [1,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- mask_attn = self.mm(mask.permute(0,3,1,2)).permute(0,2,3,1)
- if b != 0:
- mask_attn = (mask_attn[0, :, :, :]).expand([b, h, w, c])
- q, k, v, mask_attn = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp, mask_attn.flatten(1, 2)))
- v = v * mask_attn
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x, mask):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x, mask=mask.permute(0, 2, 3, 1)) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class MST(nn.Module):
- def __init__(self, dim=28, stage=3, num_blocks=[2,2,2]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(28, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False)
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, 28, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if mask == None:
- mask = torch.zeros((1,28,256,310)).cuda()
-
- # Embedding
- fea = self.lrelu(self.embedding(x))
-
- # Encoder
- fea_encoder = []
- masks = []
- for (MSAB, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = MSAB(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- mask = masks[self.stage - 1 - i]
- fea = LeWinBlcok(fea, mask)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/test_code/architecture/MST_Plus_Plus.py b/MST/simulation/test_code/architecture/MST_Plus_Plus.py
deleted file mode 100755
index e7a4826..0000000
--- a/MST/simulation/test_code/architecture/MST_Plus_Plus.py
+++ /dev/null
@@ -1,320 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- v = v
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class MST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-class MST_Plus_Plus(nn.Module):
- def __init__(self, in_channels=3, out_channels=28, n_feat=28, stage=3):
- super(MST_Plus_Plus, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False)
- modules_body = [MST(dim=n_feat, stage=2, num_blocks=[1,1,1]) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True)
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False)
-
- def initial_x(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,256]
- :return: z: [b,28,256,256]
- """
- x = self.fution(torch.cat([y, Phi], dim=1))
- return x
-
- def forward(self, y, Phi=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if Phi==None:
- Phi = torch.rand((1,28,256,256)).cuda()
- x = self.initial_x(y, Phi)
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/test_code/architecture/TSA_Net.py b/MST/simulation/test_code/architecture/TSA_Net.py
deleted file mode 100755
index 1c9dc42..0000000
--- a/MST/simulation/test_code/architecture/TSA_Net.py
+++ /dev/null
@@ -1,330 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-import numpy as np
-_NORM_BONE = False
-
-
-def conv_block(in_planes, out_planes, the_kernel=3, the_stride=1, the_padding=1, flag_norm=False, flag_norm_act=True):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=the_kernel, stride=the_stride, padding=the_padding)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_planes)
- if flag_norm:
- return nn.Sequential(conv,norm,activation) if flag_norm_act else nn.Sequential(conv,activation,norm)
- else:
- return nn.Sequential(conv,activation)
-
-def conv1x1_block(in_planes, out_planes, flag_norm=False):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=1, stride=1, padding=0,bias=False)
- norm = nn.BatchNorm2d(out_planes)
- return nn.Sequential(conv,norm) if flag_norm else conv
-
-def fully_block(in_dim, out_dim, flag_norm=False, flag_norm_act=True):
- fc = nn.Linear(in_dim, out_dim)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_dim)
- if flag_norm:
- return nn.Sequential(fc,norm,activation) if flag_norm_act else nn.Sequential(fc,activation,norm)
- else:
- return nn.Sequential(fc,activation)
-
-class Res2Net(nn.Module):
- def __init__(self, inChannel, uPlane, scale=4):
- super(Res2Net, self).__init__()
- self.uPlane = uPlane
- self.scale = scale
-
- self.conv_init = nn.Conv2d(inChannel, uPlane * scale, kernel_size=1, bias=False)
- self.bn_init = nn.BatchNorm2d(uPlane * scale)
-
- convs = []
- bns = []
- for i in range(self.scale - 1):
- convs.append(nn.Conv2d(self.uPlane, self.uPlane, kernel_size=3, stride=1, padding=1, bias=False))
- bns.append(nn.BatchNorm2d(self.uPlane))
- self.convs = nn.ModuleList(convs)
- self.bns = nn.ModuleList(bns)
-
- self.conv_end = nn.Conv2d(uPlane * scale, inChannel, kernel_size=1, bias=False)
- self.bn_end = nn.BatchNorm2d(inChannel)
-
- self.relu = nn.ReLU(inplace=True)
-
- def forward(self, x):
-
- out = self.conv_init(x)
- out = self.bn_init(out)
- out = self.relu(out)
-
- spx = torch.split(out, self.uPlane, 1)
- for i in range(self.scale - 1):
- if i == 0:
- sp = spx[i]
- else:
- sp = sp + spx[i]
- sp = self.convs[i](sp)
- sp = self.relu(self.bns[i](sp))
- if i == 0:
- out = sp
- else:
- out = torch.cat((out, sp), 1)
- out = torch.cat((out, spx[self.scale - 1]), 1)
-
- out = self.conv_end(out)
- out = self.bn_end(out)
- return out
-
-_NORM_ATTN = True
-_NORM_FC = False
-
-
-class TSA_Transform(nn.Module):
- """ Spectral-Spatial Self-Attention """
-
- def __init__(self, uSpace, inChannel, outChannel, nHead, uAttn, mode=[0, 1], flag_mask=False, gamma_learn=False):
- super(TSA_Transform, self).__init__()
- ''' ------------------------------------------
- uSpace:
- uHeight: the [-2] dim of the 3D tensor
- uWidth: the [-1] dim of the 3D tensor
- inChannel:
- the number of Channel of the input tensor
- outChannel:
- the number of Channel of the output tensor
- nHead:
- the number of Head of the input tensor
- uAttn:
- uSpatial: the dim of the spatial features
- uSpectral: the dim of the spectral features
- mask:
- The Spectral Smoothness Mask
- {mode} and {gamma_learn} is just for variable selection
- ------------------------------------------ '''
-
- self.nHead = nHead
- self.uAttn = uAttn
- self.outChannel = outChannel
- self.uSpatial = nn.Parameter(torch.tensor(float(uAttn[0])), requires_grad=False)
- self.uSpectral = nn.Parameter(torch.tensor(float(uAttn[1])), requires_grad=False)
- self.mask = nn.Parameter(Spectral_Mask(outChannel), requires_grad=False) if flag_mask else None
- self.attn_scale = nn.Parameter(torch.tensor(1.1), requires_grad=False) if flag_mask else None
- self.gamma = nn.Parameter(torch.tensor(1.0), requires_grad=gamma_learn)
-
- if sum(mode) > 0:
- down_sample = []
- scale = 1
- cur_channel = outChannel
- for i in range(sum(mode)):
- scale *= 2
- down_sample.append(conv_block(cur_channel, 2 * cur_channel, 3, 2, 1, _NORM_ATTN))
- cur_channel = 2 * cur_channel
- self.cur_channel = cur_channel
- self.down_sample = nn.Sequential(*down_sample)
- self.up_sample = nn.ConvTranspose2d(outChannel * scale, outChannel, scale, scale)
- else:
- self.down_sample = None
- self.up_sample = None
-
- spec_dim = int(uSpace[0] / 4 - 3) * int(uSpace[1] / 4 - 3)
- self.preproc = conv1x1_block(inChannel, outChannel, _NORM_ATTN)
- self.query_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.query_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.query_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.key_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.key_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.key_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.value = conv1x1_block(outChannel, nHead * outChannel, _NORM_ATTN)
- self.aggregation = nn.Linear(nHead * outChannel, outChannel)
-
- def forward(self, image):
- feat = self.preproc(image)
- feat_qx = self.query_x(feat, 'X')
- feat_qy = self.query_y(feat, 'Y')
- feat_qlambda = self.query_lambda(feat)
- feat_kx = self.key_x(feat, 'X')
- feat_ky = self.key_y(feat, 'Y')
- feat_klambda = self.key_lambda(feat)
- feat_value = self.value(feat)
-
- feat_qx = torch.cat(torch.split(feat_qx, 1, dim=1)).squeeze(dim=1)
- feat_qy = torch.cat(torch.split(feat_qy, 1, dim=1)).squeeze(dim=1)
- feat_kx = torch.cat(torch.split(feat_kx, 1, dim=1)).squeeze(dim=1)
- feat_ky = torch.cat(torch.split(feat_ky, 1, dim=1)).squeeze(dim=1)
- feat_qlambda = torch.cat(torch.split(feat_qlambda, self.uAttn[1], dim=-1))
- feat_klambda = torch.cat(torch.split(feat_klambda, self.uAttn[1], dim=-1))
- feat_value = torch.cat(torch.split(feat_value, self.outChannel, dim=1))
-
- energy_x = torch.bmm(feat_qx, feat_kx.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_y = torch.bmm(feat_qy, feat_ky.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_lambda = torch.bmm(feat_qlambda, feat_klambda.permute(0, 2, 1)) / torch.sqrt(self.uSpectral)
-
- attn_x = F.softmax(energy_x, dim=-1)
- attn_y = F.softmax(energy_y, dim=-1)
- attn_lambda = F.softmax(energy_lambda, dim=-1)
- if self.mask is not None:
- attn_lambda = (attn_lambda + self.mask) / torch.sqrt(self.attn_scale)
-
- pro_feat = feat_value if self.down_sample is None else self.down_sample(feat_value)
- batchhead, dim_c, dim_x, dim_y = pro_feat.size()
- attn_x_repeat = attn_x.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_x, dim_x)
- attn_y_repeat = attn_y.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_y, dim_y)
- pro_feat = pro_feat.view(-1, dim_x, dim_y)
- pro_feat = torch.bmm(pro_feat, attn_y_repeat.permute(0, 2, 1))
- pro_feat = torch.bmm(pro_feat.permute(0, 2, 1), attn_x_repeat.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, dim_c, dim_x, dim_y)
-
- if self.up_sample is not None:
- pro_feat = self.up_sample(pro_feat)
- _, _, dim_x, dim_y = pro_feat.size()
- pro_feat = pro_feat.contiguous().view(batchhead, self.outChannel, -1).permute(0, 2, 1)
- pro_feat = torch.bmm(pro_feat, attn_lambda.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, self.outChannel, dim_x, dim_y)
- pro_feat = torch.cat(torch.split(pro_feat, int(batchhead / self.nHead), dim=0), dim=1).permute(0, 2, 3, 1)
- pro_feat = self.aggregation(pro_feat).permute(0, 3, 1, 2)
- out = self.gamma * pro_feat + feat
- return out, (attn_x, attn_y, attn_lambda)
-
-
-class Feature_Spatial(nn.Module):
- """ Spatial Feature Generation Component """
-
- def __init__(self, inChannel, nHead, shiftDim, outDim, mode):
- super(Feature_Spatial, self).__init__()
- kernel = [(1, 5), (3, 5)]
- stride = [(1, 2), (2, 2)]
- padding = [(0, 2), (1, 2)]
- self.conv1 = conv_block(inChannel, nHead, kernel[mode[0]], stride[mode[0]], padding[mode[0]], _NORM_ATTN)
- self.conv2 = conv_block(nHead, nHead, kernel[mode[1]], stride[mode[1]], padding[mode[1]], _NORM_ATTN)
- self.fully = fully_block(shiftDim, outDim, _NORM_FC)
-
- def forward(self, image, direction):
- if direction == 'Y':
- image = image.permute(0, 1, 3, 2)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = self.fully(feat)
- return feat
-
-
-class Feature_Spectral(nn.Module):
- """ Spectral Feature Generation Component """
-
- def __init__(self, inChannel, nHead, viewDim, outDim):
- super(Feature_Spectral, self).__init__()
- self.inChannel = inChannel
- self.conv1 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.conv2 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.fully = fully_block(viewDim, int(nHead * outDim), _NORM_FC)
-
- def forward(self, image):
- bs = image.size(0)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = feat.view(bs, self.inChannel, -1)
- feat = self.fully(feat)
- return feat
-
-
-def Spectral_Mask(dim_lambda):
- '''After put the available data into the model, we use this mask to avoid outputting the estimation of itself.'''
- orig = (np.cos(np.linspace(-1, 1, num=2 * dim_lambda - 1) * np.pi) + 1.0) / 2.0
- att = np.zeros((dim_lambda, dim_lambda))
- for i in range(dim_lambda):
- att[i, :] = orig[dim_lambda - 1 - i:2 * dim_lambda - 1 - i]
- AM_Mask = torch.from_numpy(att.astype(np.float32)).unsqueeze(0)
- return AM_Mask
-
-class TSA_Net(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28):
- super(TSA_Net, self).__init__()
-
- self.tconv_down1 = Encoder_Triblock(in_ch, 64, False)
- self.tconv_down2 = Encoder_Triblock(64, 128, False)
- self.tconv_down3 = Encoder_Triblock(128, 256)
- self.tconv_down4 = Encoder_Triblock(256, 512)
-
- self.bottom1 = conv_block(512, 1024)
- self.bottom2 = conv_block(1024, 1024)
-
- self.tconv_up4 = Decoder_Triblock(1024, 512)
- self.tconv_up3 = Decoder_Triblock(512, 256)
- self.transform3 = TSA_Transform((64, 64), 256, 256, 8, (64, 80), [0, 0])
- self.tconv_up2 = Decoder_Triblock(256, 128)
- self.transform2 = TSA_Transform((128, 128), 128, 128, 8, (64, 40), [1, 0])
- self.tconv_up1 = Decoder_Triblock(128, 64)
- self.transform1 = TSA_Transform((256, 256), 64, 28, 8, (48, 30), [1, 1], True)
-
- self.conv_last = nn.Conv2d(out_ch, out_ch, 1)
- self.afn_last = nn.Sigmoid()
-
- def forward(self, x, input_mask=None):
- enc1, enc1_pre = self.tconv_down1(x)
- enc2, enc2_pre = self.tconv_down2(enc1)
- enc3, enc3_pre = self.tconv_down3(enc2)
- enc4, enc4_pre = self.tconv_down4(enc3)
- # enc5,enc5_pre = self.tconv_down5(enc4)
-
- bottom = self.bottom1(enc4)
- bottom = self.bottom2(bottom)
-
- # dec5 = self.tconv_up5(bottom,enc5_pre)
- dec4 = self.tconv_up4(bottom, enc4_pre)
- dec3 = self.tconv_up3(dec4, enc3_pre)
- dec3, _ = self.transform3(dec3)
- dec2 = self.tconv_up2(dec3, enc2_pre)
- dec2, _ = self.transform2(dec2)
- dec1 = self.tconv_up1(dec2, enc1_pre)
- dec1, _ = self.transform1(dec1)
-
- dec1 = self.conv_last(dec1)
- output = self.afn_last(dec1)
-
- return output
-
-
-class Encoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Encoder_Triblock, self).__init__()
-
- self.layer1 = conv_block(inChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
- if flag_res:
- self.layer2 = Res2Net(outChannel, int(outChannel / 4))
- else:
- self.layer2 = conv_block(outChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- self.pool = nn.MaxPool2d(nPool) if flag_Pool else None
-
- def forward(self, x):
- feat = self.layer1(x)
- feat = self.layer2(feat)
-
- feat_pool = self.pool(feat) if self.pool is not None else feat
- return feat_pool, feat
-
-
-class Decoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Decoder_Triblock, self).__init__()
-
- self.layer1 = nn.Sequential(
- nn.ConvTranspose2d(inChannel, outChannel, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- if flag_res:
- self.layer2 = Res2Net(int(outChannel * 2), int(outChannel / 2))
- else:
- self.layer2 = conv_block(outChannel * 2, outChannel * 2, nKernal, flag_norm=_NORM_BONE)
- self.layer3 = conv_block(outChannel * 2, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- def forward(self, feat_dec, feat_enc):
- feat_dec = self.layer1(feat_dec)
- diffY = feat_enc.size()[2] - feat_dec.size()[2]
- diffX = feat_enc.size()[3] - feat_dec.size()[3]
- if diffY != 0 or diffX != 0:
- print('Padding for size mismatch ( Enc:', feat_enc.size(), 'Dec:', feat_dec.size(), ')')
- feat_dec = F.pad(feat_dec, [diffX // 2, diffX - diffX // 2, diffY // 2, diffY - diffY // 2])
- feat = torch.cat([feat_dec, feat_enc], dim=1)
- feat = self.layer2(feat)
- feat = self.layer3(feat)
- return feat
\ No newline at end of file
diff --git a/MST/simulation/test_code/architecture/__init__.py b/MST/simulation/test_code/architecture/__init__.py
deleted file mode 100755
index fdb77ea..0000000
--- a/MST/simulation/test_code/architecture/__init__.py
+++ /dev/null
@@ -1,67 +0,0 @@
-import torch
-from .MST import MST
-from .GAP_Net import GAP_net
-from .ADMM_Net import ADMM_net
-from .TSA_Net import TSA_Net
-from .HDNet import HDNet, FDL
-from .DGSMP import HSI_CS
-from .BIRNAT import BIRNAT
-from .MST_Plus_Plus import MST_Plus_Plus
-from .Lambda_Net import Lambda_Net
-from .CST import CST
-from .DAUHST import DAUHST
-from .BiSRNet import BiSRNet
-
-def model_generator(method, pretrained_model_path=None):
- if method == 'mst_s':
- model = MST(dim=28, stage=2, num_blocks=[2, 2, 2]).cuda()
- elif method == 'mst_m':
- model = MST(dim=28, stage=2, num_blocks=[2, 4, 4]).cuda()
- elif method == 'mst_l':
- model = MST(dim=28, stage=2, num_blocks=[4, 7, 5]).cuda()
- elif method == 'gap_net':
- model = GAP_net().cuda()
- elif method == 'admm_net':
- model = ADMM_net().cuda()
- elif method == 'tsa_net':
- model = TSA_Net().cuda()
- elif method == 'hdnet':
- model = HDNet().cuda()
- fdl_loss = FDL(loss_weight=0.7,
- alpha=2.0,
- patch_factor=4,
- ave_spectrum=True,
- log_matrix=True,
- batch_matrix=True,
- ).cuda()
- elif method == 'dgsmp':
- model = HSI_CS(Ch=28, stages=4).cuda()
- elif method == 'birnat':
- model = BIRNAT().cuda()
- elif method == 'mst_plus_plus':
- model = MST_Plus_Plus(in_channels=28, out_channels=28, n_feat=28, stage=3).cuda()
- elif method == 'lambda_net':
- model = Lambda_Net(out_ch=28).cuda()
- elif method == 'cst_s':
- model = CST(num_blocks=[1, 1, 2], sparse=True).cuda()
- elif method == 'cst_m':
- model = CST(num_blocks=[2, 2, 2], sparse=True).cuda()
- elif method == 'cst_l':
- model = CST(num_blocks=[2, 4, 6], sparse=True).cuda()
- elif method == 'cst_l_plus':
- model = CST(num_blocks=[2, 4, 6], sparse=False).cuda()
- elif 'dauhst' in method:
- num_iterations = int(method.split('_')[1][0])
- model = DAUHST(num_iterations=num_iterations).cuda()
- elif method == 'bisrnet':
- model = BiSRNet(in_channels=28, out_channels=28, n_feat=28, stage=1, num_blocks=[1,1,1]).cuda()
- else:
- print(f'Method {method} is not defined !!!!')
- if pretrained_model_path is not None:
- print(f'load model from {pretrained_model_path}')
- checkpoint = torch.load(pretrained_model_path)
- model.load_state_dict({k.replace('module.', ''): v for k, v in checkpoint.items()},
- strict=True)
- if method == 'hdnet':
- return model,fdl_loss
- return model
\ No newline at end of file
diff --git a/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc
deleted file mode 100755
index a9b0fea..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc
deleted file mode 100644
index 84e0a08..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-36.pyc
deleted file mode 100755
index d955531..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-39.pyc
deleted file mode 100644
index d1aa583..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/BIRNAT.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/BiSRNet.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/BiSRNet.cpython-39.pyc
deleted file mode 100644
index 1e2dc45..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/BiSRNet.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/CST.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/CST.cpython-36.pyc
deleted file mode 100755
index 489b99e..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/CST.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/CST.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/CST.cpython-39.pyc
deleted file mode 100644
index 522ba14..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/CST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/DAUHST.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/DAUHST.cpython-39.pyc
deleted file mode 100644
index 41485fe..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/DAUHST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-36.pyc
deleted file mode 100755
index 40a9e0d..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-39.pyc
deleted file mode 100644
index cb358ee..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/DGSMP.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-36.pyc
deleted file mode 100755
index 5460466..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-39.pyc
deleted file mode 100644
index 3be4d9d..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/GAP_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-36.pyc
deleted file mode 100755
index 4ca0e72..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-39.pyc
deleted file mode 100644
index f599d37..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/HDNet.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc
deleted file mode 100755
index 4fb4e38..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc
deleted file mode 100644
index e422c06..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/MST.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/MST.cpython-36.pyc
deleted file mode 100755
index c941b2d..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/MST.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/MST.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/MST.cpython-39.pyc
deleted file mode 100644
index 8e67bb8..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/MST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc
deleted file mode 100755
index 757069a..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc
deleted file mode 100644
index 4ff4add..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-36.pyc
deleted file mode 100755
index 990b7e7..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-39.pyc
deleted file mode 100644
index 559477f..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/TSA_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-36.pyc b/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-36.pyc
deleted file mode 100755
index b94e802..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-39.pyc b/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-39.pyc
deleted file mode 100644
index 7f506f0..0000000
Binary files a/MST/simulation/test_code/architecture/__pycache__/__init__.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/test_code/option.py b/MST/simulation/test_code/option.py
deleted file mode 100755
index 7b2e71d..0000000
--- a/MST/simulation/test_code/option.py
+++ /dev/null
@@ -1,35 +0,0 @@
-import argparse
-import template
-
-parser = argparse.ArgumentParser(description="HyperSpectral Image Reconstruction Toolbox")
-parser.add_argument('--template', default='mst',
- help='You can set various templates in option.py')
-
-# Hardware specifications
-parser.add_argument("--gpu_id", type=str, default='0')
-
-# Data specifications
-parser.add_argument('--data_root', type=str, default='../../datasets/', help='dataset directory')
-
-# Saving specifications
-parser.add_argument('--outf', type=str, default='./exp/mst_s/', help='saving_path')
-
-# Model specifications
-parser.add_argument('--method', type=str, default='mst_s', help='method name')
-parser.add_argument('--pretrained_model_path', type=str, default=None, help='pretrained model directory')
-parser.add_argument("--input_setting", type=str, default='H',
- help='the input measurement of the network: H, HM or Y')
-parser.add_argument("--input_mask", type=str, default='Phi',
- help='the input mask of the network: Phi, Phi_PhiPhiT or None')
-
-opt = parser.parse_args()
-template.set_template(opt)
-
-opt.mask_path = f"{opt.data_root}/TSA_simu_data/"
-opt.test_path = f"{opt.data_root}/TSA_simu_data/Truth/"
-
-for arg in vars(opt):
- if vars(opt)[arg] == 'True':
- vars(opt)[arg] = True
- elif vars(opt)[arg] == 'False':
- vars(opt)[arg] = False
diff --git a/MST/simulation/test_code/template.py b/MST/simulation/test_code/template.py
deleted file mode 100755
index 7559ca4..0000000
--- a/MST/simulation/test_code/template.py
+++ /dev/null
@@ -1,42 +0,0 @@
-def set_template(args):
- # Set the templates here
- if args.template.find('mst') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Phi'
-
- if args.template.find('gap_net') >= 0 or args.template.find('admm_net') >= 0 or args.template.find('dnu')>= 0 \
- or args.template.find('dauhst')>= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
-
- if args.template.find('tsa_net') >= 0:
- args.input_setting = 'HM'
- args.input_mask = None
-
- if args.template.find('hdnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = None
-
- if args.template.find('dgsmp') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
-
- if args.template.find('birnat') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
-
- if args.template.find('mst_plus_plus') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
-
- if args.template.find('bisrnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
-
- if args.template.find('cst') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
-
- if args.template.find('lambda_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
diff --git a/MST/simulation/test_code/test.py b/MST/simulation/test_code/test.py
deleted file mode 100755
index 46267be..0000000
--- a/MST/simulation/test_code/test.py
+++ /dev/null
@@ -1,47 +0,0 @@
-from architecture import *
-from utils import *
-import scipy.io as scio
-import torch
-import os
-import numpy as np
-from option import opt
-
-os.environ["CUDA_DEVICE_ORDER"] = 'PCI_BUS_ID'
-os.environ["CUDA_VISIBLE_DEVICES"] = opt.gpu_id
-torch.backends.cudnn.enabled = True
-torch.backends.cudnn.benchmark = True
-if not torch.cuda.is_available():
- raise Exception('NO GPU!')
-
-# Intialize mask
-mask3d_batch, input_mask = init_mask(opt.mask_path, opt.input_mask, 10)
-
-if not os.path.exists(opt.outf):
- os.makedirs(opt.outf)
-
-def test(model):
- test_data = LoadTest(opt.test_path)
- test_gt = test_data.cuda().float()
- input_meas = init_meas(test_gt, mask3d_batch, opt.input_setting)
- model.eval()
- with torch.no_grad():
- model_out = model(input_meas, input_mask)
- pred = np.transpose(model_out.detach().cpu().numpy(), (0, 2, 3, 1)).astype(np.float32)
- truth = np.transpose(test_gt.cpu().numpy(), (0, 2, 3, 1)).astype(np.float32)
- model.train()
- return pred, truth
-
-def main():
- # model
- if opt.method == 'hdnet':
- model, FDL_loss = model_generator(opt.method, opt.pretrained_model_path)
- model = model.cuda()
- else:
- model = model_generator(opt.method, opt.pretrained_model_path).cuda()
- pred, truth = test(model)
- name = opt.outf + 'Test_result.mat'
- print(f'Save reconstructed HSIs as {name}.')
- scio.savemat(name, {'truth': truth, 'pred': pred})
-
-if __name__ == '__main__':
- main()
\ No newline at end of file
diff --git a/MST/simulation/test_code/utils.py b/MST/simulation/test_code/utils.py
deleted file mode 100755
index 329fb92..0000000
--- a/MST/simulation/test_code/utils.py
+++ /dev/null
@@ -1,155 +0,0 @@
-import scipy.io as sio
-import os
-import numpy as np
-import torch
-import logging
-from fvcore.nn import FlopCountAnalysis
-
-
-def generate_masks(mask_path, batch_size):
- mask = sio.loadmat(mask_path + '/mask.mat')
- mask = mask['mask']
- mask3d = np.tile(mask[:, :, np.newaxis], (1, 1, 28))
- mask3d = np.transpose(mask3d, [2, 0, 1])
- mask3d = torch.from_numpy(mask3d)
- [nC, H, W] = mask3d.shape
- mask3d_batch = mask3d.expand([batch_size, nC, H, W]).cuda().float()
- return mask3d_batch
-
-def generate_shift_masks(mask_path, batch_size):
- mask = sio.loadmat(mask_path + '/mask_3d_shift.mat')
- mask_3d_shift = mask['mask_3d_shift']
- mask_3d_shift = np.transpose(mask_3d_shift, [2, 0, 1])
- mask_3d_shift = torch.from_numpy(mask_3d_shift)
- [nC, H, W] = mask_3d_shift.shape
- Phi_batch = mask_3d_shift.expand([batch_size, nC, H, W]).cuda().float()
- Phi_s_batch = torch.sum(Phi_batch**2,1)
- Phi_s_batch[Phi_s_batch==0] = 1
- # print(Phi_batch.shape, Phi_s_batch.shape)
- return Phi_batch, Phi_s_batch
-
-def LoadTest(path_test):
- scene_list = os.listdir(path_test)
- scene_list.sort()
- test_data = np.zeros((len(scene_list), 256, 256, 28))
- for i in range(len(scene_list)):
- scene_path = path_test + scene_list[i]
- img = sio.loadmat(scene_path)['img']
- test_data[i, :, :, :] = img
- test_data = torch.from_numpy(np.transpose(test_data, (0, 3, 1, 2)))
- return test_data
-
-def LoadMeasurement(path_test_meas):
- img = sio.loadmat(path_test_meas)['simulation_test']
- test_data = img
- test_data = torch.from_numpy(test_data)
- return test_data
-
-def time2file_name(time):
- year = time[0:4]
- month = time[5:7]
- day = time[8:10]
- hour = time[11:13]
- minute = time[14:16]
- second = time[17:19]
- time_filename = year + '_' + month + '_' + day + '_' + hour + '_' + minute + '_' + second
- return time_filename
-
-def shuffle_crop(train_data, batch_size, crop_size=256):
- index = np.random.choice(range(len(train_data)), batch_size)
- processed_data = np.zeros((batch_size, crop_size, crop_size, 28), dtype=np.float32)
- for i in range(batch_size):
- h, w, _ = train_data[index[i]].shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data[i, :, :, :] = train_data[index[i]][x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- gt_batch = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2)))
- return gt_batch
-
-def gen_meas_torch(data_batch, mask3d_batch, Y2H=True, mul_mask=False):
- [batch_size, nC, H, W] = data_batch.shape
- mask3d_batch = (mask3d_batch[0, :, :, :]).expand([batch_size, nC, H, W]).cuda().float() # [10,28,256,256]
- temp = shift(mask3d_batch * data_batch, 2)
- meas = torch.sum(temp, 1)
- if Y2H:
- meas = meas / nC * 2
- H = shift_back(meas)
- if mul_mask:
- HM = torch.mul(H, mask3d_batch)
- return HM
- return H
- return meas
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-def shift_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, row, col] = inputs.shape
- nC = 28
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def gen_log(model_path):
- logger = logging.getLogger()
- logger.setLevel(logging.INFO)
- formatter = logging.Formatter("%(asctime)s - %(levelname)s: %(message)s")
-
- log_file = model_path + '/log.txt'
- fh = logging.FileHandler(log_file, mode='a')
- fh.setLevel(logging.INFO)
- fh.setFormatter(formatter)
-
- ch = logging.StreamHandler()
- ch.setLevel(logging.INFO)
- ch.setFormatter(formatter)
-
- logger.addHandler(fh)
- logger.addHandler(ch)
- return logger
-
-def init_mask(mask_path, mask_type, batch_size):
- mask3d_batch = generate_masks(mask_path, batch_size)
- if mask_type == 'Phi':
- shift_mask3d_batch = shift(mask3d_batch)
- input_mask = shift_mask3d_batch
- elif mask_type == 'Phi_PhiPhiT':
- Phi_batch, Phi_s_batch = generate_shift_masks(mask_path, batch_size)
- input_mask = (Phi_batch, Phi_s_batch)
- elif mask_type == 'Mask':
- input_mask = mask3d_batch
- elif mask_type == None:
- input_mask = None
- return mask3d_batch, input_mask
-
-def init_meas(gt, mask, input_setting):
- if input_setting == 'H':
- input_meas = gen_meas_torch(gt, mask, Y2H=True, mul_mask=False)
- elif input_setting == 'HM':
- input_meas = gen_meas_torch(gt, mask, Y2H=True, mul_mask=True)
- elif input_setting == 'Y':
- input_meas = gen_meas_torch(gt, mask, Y2H=False, mul_mask=True)
- return input_meas
-
-def my_summary(test_model, H = 256, W = 256, C = 28, N = 1):
- model = test_model.cuda()
- print(model)
- inputs = torch.randn((N, C, H, W)).cuda()
- flops = FlopCountAnalysis(model,inputs)
- n_param = sum([p.nelement() for p in model.parameters()])
- print(f'GMac:{flops.total()/(1024*1024*1024)}')
- print(f'Params:{n_param}')
-
-def my_summary_bnn(test_model, H = 256, W = 256, C = 28, N = 1):
- model = test_model.cuda()
- print(model)
- inputs = torch.randn((N, C, H, W)).cuda()
- flops = FlopCountAnalysis(model,inputs)
- n_param = sum([p.nelement() for p in model.parameters()])
- print(f'GMac:{flops.total()/(1024*1024*1024*58)}')
- print(f'Params:{n_param / 32}')
\ No newline at end of file
diff --git a/MST/simulation/train_code/__pycache__/option.cpython-36.pyc b/MST/simulation/train_code/__pycache__/option.cpython-36.pyc
deleted file mode 100755
index f7d8518..0000000
Binary files a/MST/simulation/train_code/__pycache__/option.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/__pycache__/ssim_torch.cpython-36.pyc b/MST/simulation/train_code/__pycache__/ssim_torch.cpython-36.pyc
deleted file mode 100755
index 1f18256..0000000
Binary files a/MST/simulation/train_code/__pycache__/ssim_torch.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/__pycache__/template.cpython-36.pyc b/MST/simulation/train_code/__pycache__/template.cpython-36.pyc
deleted file mode 100755
index a55fd6a..0000000
Binary files a/MST/simulation/train_code/__pycache__/template.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/__pycache__/utils.cpython-36.pyc b/MST/simulation/train_code/__pycache__/utils.cpython-36.pyc
deleted file mode 100755
index 9cf90c7..0000000
Binary files a/MST/simulation/train_code/__pycache__/utils.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/__pycache__/utils.cpython-39.pyc b/MST/simulation/train_code/__pycache__/utils.cpython-39.pyc
deleted file mode 100644
index 8a91e56..0000000
Binary files a/MST/simulation/train_code/__pycache__/utils.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/ADMM_Net.py b/MST/simulation/train_code/architecture/ADMM_Net.py
deleted file mode 100755
index 7fc4180..0000000
--- a/MST/simulation/train_code/architecture/ADMM_Net.py
+++ /dev/null
@@ -1,201 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-
-class Unet(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(Unet, self).__init__()
-
- self.dconv_down1 = double_conv(in_ch, 32)
- self.dconv_down2 = double_conv(32, 64)
- self.dconv_down3 = double_conv(64, 128)
-
- self.maxpool = nn.MaxPool2d(2)
- self.upsample2 = nn.Sequential(
- nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.upsample1 = nn.Sequential(
- nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- self.dconv_up2 = double_conv(64 + 64, 64)
- self.dconv_up1 = double_conv(32 + 32, 32)
-
- self.conv_last = nn.Conv2d(32, out_ch, 1)
- self.afn_last = nn.Tanh()
-
- def forward(self, x):
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- inputs = x
- conv1 = self.dconv_down1(x)
- x = self.maxpool(conv1)
-
- conv2 = self.dconv_down2(x)
- x = self.maxpool(conv2)
-
- conv3 = self.dconv_down3(x)
-
- x = self.upsample2(conv3)
- x = torch.cat([x, conv2], dim=1)
-
- x = self.dconv_up2(x)
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
-
- x = self.dconv_up1(x)
-
- x = self.conv_last(x)
- x = self.afn_last(x)
- out = x + inputs
-
- return out[:, :, :h_inp, :w_inp]
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class ADMM_net(nn.Module):
-
- def __init__(self):
- super(ADMM_net, self).__init__()
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma2 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma3 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma4 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma5 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma6 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma7 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma8 = torch.nn.Parameter(torch.Tensor([0]))
- self.gamma9 = torch.nn.Parameter(torch.Tensor([0]))
-
- def forward(self, y, input_mask=None):
- if input_mask == None:
- Phi = torch.rand((1, 28, 256, 310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- theta = At(y,Phi)
- b = torch.zeros_like(Phi)
- ### 1-3
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma1),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet1(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma2),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet2(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma3),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet3(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 4-6
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma4),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet4(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma5),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet5(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma6),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet6(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- ### 7-9
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma7),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet7(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma8),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet8(x1)
- theta = shift_3d(theta)
- b = b- (x-theta)
- x_list.append(theta)
- yb = A(theta+b,Phi)
- x = theta+b + At(torch.div(y-yb,Phi_s+self.gamma9),Phi)
- x1 = x-b
- x1 = shift_back_3d(x1)
- theta = self.unet9(x1)
- theta = shift_3d(theta)
- return theta[:, :, :, 0:256]
diff --git a/MST/simulation/train_code/architecture/BIRNAT.py b/MST/simulation/train_code/architecture/BIRNAT.py
deleted file mode 100755
index e3d8123..0000000
--- a/MST/simulation/train_code/architecture/BIRNAT.py
+++ /dev/null
@@ -1,365 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-
-class self_attention(nn.Module):
- def __init__(self, ch):
- super(self_attention, self).__init__()
- self.conv1 = nn.Conv2d(ch, ch // 8, 1)
- self.conv2 = nn.Conv2d(ch, ch // 8, 1)
- self.conv3 = nn.Conv2d(ch, ch, 1)
- self.conv4 = nn.Conv2d(ch, ch, 1)
- self.gamma1 = torch.nn.Parameter(torch.Tensor([0]))
- self.ch = ch
-
- def forward(self, x):
- batch_size = x.shape[0]
-
- f = self.conv1(x)
- g = self.conv2(x)
- h = self.conv3(x)
- ht = h.reshape([batch_size, self.ch, -1])
-
- ft = f.reshape([batch_size, self.ch // 8, -1])
- n = torch.matmul(ft.permute([0, 2, 1]), g.reshape([batch_size, self.ch // 8, -1]))
- beta = F.softmax(n, dim=1)
-
- o = torch.matmul(ht, beta)
- o = o.reshape(x.shape) # [bs, C, h, w]
-
- o = self.conv4(o)
-
- x = self.gamma1 * o + x
-
- return x
-
-
-class res_part(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(res_part, self).__init__()
- self.conv1 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv2 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
- self.conv3 = nn.Sequential(
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- # nn.BatchNorm2d(out_ch),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, out_ch, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(in_ch, in_ch, 3, padding=1),
- )
-
- def forward(self, x):
- x1 = self.conv1(x)
- x = x1 + x
- x1 = self.conv2(x)
- x = x1 + x
- x1 = self.conv3(x)
- x = x1 + x
- return x
-
-
-class down_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(down_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- # nn.Conv2d(20, 40, 5, stride=2, padding=2),
- # nn.Conv2d(40, out_ch, 5, stride=2, padding=2),
- nn.Conv2d(in_ch, 20, 5, stride=1, padding=2),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 40, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(40, out_ch, 3, stride=1, padding=1),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-
-class up_feature(nn.Module):
-
- def __init__(self, in_ch, out_ch):
- super(up_feature, self).__init__()
- self.conv = nn.Sequential(
- # nn.ConvTranspose2d(in_ch, 40, 3, stride=2, padding=1, output_padding=1),
- # nn.ConvTranspose2d(40, 20, 3, stride=2, padding=1, output_padding=1),
- nn.Conv2d(in_ch, 40, 3, stride=1, padding=1),
- nn.Conv2d(40, 30, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(30, 20, 3, stride=1, padding=1),
- nn.Conv2d(20, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- nn.Conv2d(20, out_ch, 1),
- # nn.Sigmoid(),
- )
-
- def forward(self, x):
- x = self.conv(x)
- return x
-
-class cnn1(nn.Module):
- # 输入meas concat mask
- # 3 下采样
-
- def __init__(self, B):
- super(cnn1, self).__init__()
- self.conv1 = nn.Conv2d(B + 1, 32, kernel_size=5, stride=1, padding=2)
- self.relu1 = nn.LeakyReLU(inplace=True)
- self.conv2 = nn.Conv2d(32, 64, kernel_size=3, stride=1, padding=1)
- self.relu2 = nn.LeakyReLU(inplace=True)
- self.conv3 = nn.Conv2d(64, 64, kernel_size=1, stride=1)
- self.relu3 = nn.LeakyReLU(inplace=True)
- self.conv4 = nn.Conv2d(64, 128, kernel_size=3, stride=2, padding=1)
- self.relu4 = nn.LeakyReLU(inplace=True)
- self.conv5 = nn.ConvTranspose2d(128, 64, kernel_size=3, stride=2, padding=1, output_padding=1)
- self.relu5 = nn.LeakyReLU(inplace=True)
- self.conv51 = nn.Conv2d(64, 32, kernel_size=3, stride=1, padding=1)
- self.relu51 = nn.LeakyReLU(inplace=True)
- self.conv52 = nn.Conv2d(32, 16, kernel_size=1, stride=1)
- self.relu52 = nn.LeakyReLU(inplace=True)
- self.conv6 = nn.Conv2d(16, 1, kernel_size=3, stride=1, padding=1)
- self.res_part1 = res_part(128, 128)
- self.res_part2 = res_part(128, 128)
- self.res_part3 = res_part(128, 128)
- self.conv7 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu7 = nn.LeakyReLU(inplace=True)
- self.conv8 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
- self.conv9 = nn.Conv2d(128, 128, kernel_size=3, stride=1, padding=1)
- self.relu9 = nn.LeakyReLU(inplace=True)
- self.conv10 = nn.Conv2d(128, 128, kernel_size=1, stride=1)
-
- self.att1 = self_attention(128)
-
- def forward(self, meas=None, nor_meas=None, PhiTy=None):
- data = torch.cat([torch.unsqueeze(nor_meas, dim=1), PhiTy], dim=1)
- out = self.conv1(data)
-
- out = self.relu1(out)
- out = self.conv2(out)
- out = self.relu2(out)
- out = self.conv3(out)
- out = self.relu3(out)
- out = self.conv4(out)
- out = self.relu4(out)
- out = self.res_part1(out)
- out = self.conv7(out)
- out = self.relu7(out)
- out = self.conv8(out)
- out = self.res_part2(out)
- out = self.conv9(out)
- out = self.relu9(out)
- out = self.conv10(out)
- out = self.res_part3(out)
-
- # out = self.att1(out)
-
- out = self.conv5(out)
- out = self.relu5(out)
- out = self.conv51(out)
- out = self.relu51(out)
- out = self.conv52(out)
- out = self.relu52(out)
- out = self.conv6(out)
-
- return out
-
-
-class forward_rnn(nn.Module):
-
- def __init__(self):
- super(forward_rnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt1, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
- xt = xt1
-
- step = 2
- [bs, nC, row, col] = xt1.shape
-
- out = xt1
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, ii, :, :], out[:, ii, :, :])
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, ii, :, :], torch.squeeze(nor_meas))
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
- out = torch.cat([out, xt], dim=1)
-
- return out, ht
-
-
-class backrnn(nn.Module):
-
- def __init__(self):
- super(backrnn, self).__init__()
- self.extract_feature1 = down_feature(1, 20)
- self.up_feature1 = up_feature(60, 1)
- self.conv_x1 = nn.Sequential(
- nn.Conv2d(1, 16, 5, stride=1, padding=2),
- nn.Conv2d(16, 32, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(32, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.conv_x2 = nn.Sequential(
- nn.Conv2d(1, 10, 5, stride=1, padding=2),
- nn.Conv2d(10, 10, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(10, 40, 3, stride=2, padding=1),
- nn.Conv2d(40, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, stride=1, padding=1),
- nn.LeakyReLU(inplace=True),
- nn.ConvTranspose2d(20, 10, kernel_size=3, stride=2, padding=1, output_padding=1),
- )
- self.h_h = nn.Sequential(
- nn.Conv2d(60, 30, 3, padding=1),
- nn.Conv2d(30, 20, 1),
- nn.LeakyReLU(inplace=True),
- nn.Conv2d(20, 20, 3, padding=1),
- )
- self.res_part1 = res_part(60, 60)
- self.res_part2 = res_part(60, 60)
-
- def forward(self, xt8, meas=None, nor_meas=None, PhiTy=None, mask3d_batch=None, h=None, cs_rate=28):
- ht = h
-
- step = 2
- [bs, nC, row, col] = xt8.shape
-
- xt = torch.unsqueeze(xt8[:, cs_rate - 1, :, :], 1)
-
- out = torch.zeros(bs, cs_rate, row, col).cuda()
- out[:, cs_rate - 1, :, :] = xt[:, 0, :, :]
- x11 = self.conv_x1(torch.unsqueeze(nor_meas, 1))
- for i in range(cs_rate - 1):
- d1 = torch.zeros(bs, row, col).cuda()
- d2 = torch.zeros(bs, row, col).cuda()
- for ii in range(i + 1):
- d1 = d1 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], out[:, cs_rate - 1 - ii, :, :].clone())
- for ii in range(i + 2, cs_rate):
- d2 = d2 + torch.mul(mask3d_batch[:, cs_rate - 1 - ii, :, :], xt8[:, cs_rate - 1 - ii, :, :].clone())
- x12 = self.conv_x2(torch.unsqueeze(meas - d1 - d2, 1))
-
- x2 = self.extract_feature1(xt)
- h = torch.cat([ht, x11, x12, x2], dim=1)
- h = self.res_part1(h)
- h = self.res_part2(h)
- ht = self.h_h(h)
- xt = self.up_feature1(h)
-
- out[:, cs_rate - 2 - i, :, :] = xt[:, 0, :, :]
-
- return out
-
-def shift_gt_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, i, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- if inputs.is_cuda:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- else:
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-class BIRNAT(nn.Module):
-
- def __init__(self):
- super(BIRNAT, self).__init__()
- self.cs_rate = 28
- self.first_frame_net = cnn1(self.cs_rate).cuda()
- self.rnn1 = forward_rnn().cuda()
- self.rnn2 = backrnn().cuda()
-
- def gen_meas_torch(self, meas, shift_mask):
- batch_size, H = meas.shape[0:2]
- mask_s = torch.sum(shift_mask, 1)
- nor_meas = torch.div(meas, mask_s)
- temp = torch.mul(torch.unsqueeze(nor_meas, dim=1).expand([batch_size, 28, H, shift_mask.shape[3]]), shift_mask)
- return nor_meas, temp
-
- def forward(self, meas, shift_mask=None):
- if shift_mask==None:
- shift_mask = torch.zeros(1, 28, 256, 310).cuda()
- H, W = meas.shape[-2:]
- nor_meas, PhiTy = self.gen_meas_torch(meas, shift_mask)
- h0 = torch.zeros(meas.shape[0], 20, H, W).cuda()
- xt1 = self.first_frame_net(meas, nor_meas, PhiTy)
- model_out1, h1 = self.rnn1(xt1, meas, nor_meas, PhiTy, shift_mask, h0, self.cs_rate)
- model_out2 = self.rnn2(model_out1, meas, nor_meas, PhiTy, shift_mask, h1, self.cs_rate)
- model_out2 = shift_gt_back(model_out2)
-
- return model_out2
diff --git a/MST/simulation/train_code/architecture/BiSRNet.py b/MST/simulation/train_code/architecture/BiSRNet.py
deleted file mode 100755
index 08014a0..0000000
--- a/MST/simulation/train_code/architecture/BiSRNet.py
+++ /dev/null
@@ -1,422 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-import os
-from pdb import set_trace as stx
-
-# --------------------------------------------- Binarized Basic Units -----------------------------------------------------------------
-
-
-class LearnableBias(nn.Module):
- def __init__(self, out_chn):
- super(LearnableBias, self).__init__()
- self.bias = nn.Parameter(torch.zeros(1,out_chn,1,1), requires_grad=True)
-
- def forward(self, x):
- # stx()
- out = x + self.bias.expand_as(x)
- return out
-
-class ReDistribution(nn.Module):
- def __init__(self, out_chn):
- super(ReDistribution, self).__init__()
- self.b = nn.Parameter(torch.zeros(1,out_chn,1,1), requires_grad=True)
- self.k = nn.Parameter(torch.ones(1,out_chn,1,1), requires_grad=True)
-
- def forward(self, x):
- out = x * self.k.expand_as(x) + self.b.expand_as(x)
- return out
-
-class RPReLU(nn.Module):
- def __init__(self, inplanes):
- super(RPReLU, self).__init__()
- self.pr_bias0 = LearnableBias(inplanes)
- self.pr_prelu = nn.PReLU(inplanes)
- self.pr_bias1 = LearnableBias(inplanes)
-
- def forward(self, x):
- x = self.pr_bias1(self.pr_prelu(self.pr_bias0(x)))
- return x
-
-class Spectral_Binary_Activation(nn.Module):
- def __init__(self):
- super(Spectral_Binary_Activation, self).__init__()
- self.beta = nn.Parameter(torch.ones(1), requires_grad=True)
-
- def forward(self, x):
-
- binary_activation_no_grad = torch.sign(x)
- tanh_activation = torch.tanh(x*self.beta)
-
- out = binary_activation_no_grad.detach() - tanh_activation.detach() + tanh_activation
- return out
-
-
-class HardBinaryConv(nn.Conv2d):
- def __init__(self, in_chn, out_chn, kernel_size=3, stride=1, padding=1, groups=1, bias=True):
- super(HardBinaryConv, self).__init__(
- in_chn,
- out_chn,
- kernel_size,
- stride=stride,
- padding=padding,
- groups=groups,
- bias=bias
- )
-
- def forward(self, x):
- real_weights = self.weight
- scaling_factor = torch.mean(torch.mean(torch.mean(abs(real_weights),dim=3,keepdim=True),dim=2,keepdim=True),dim=1,keepdim=True)
- scaling_factor = scaling_factor.detach()
- # stx()
- binary_weights_no_grad = scaling_factor * torch.sign(real_weights)
- # stx()
- cliped_weights = torch.clamp(real_weights, -1.0, 1.0)
- binary_weights = binary_weights_no_grad.detach() - cliped_weights.detach() + cliped_weights
- y = F.conv2d(x, binary_weights,self.bias, stride=self.stride, padding=self.padding, groups=self.groups)
-
- return y
-
-class BinaryConv2d(nn.Module):
-
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d, self).__init__()
-
- self.move0 = ReDistribution(in_channels)
- self.binary_activation = Spectral_Binary_Activation()
- self.binary_conv = HardBinaryConv(in_chn=in_channels,
- out_chn=in_channels,
- kernel_size=kernel_size,
- stride = stride,
- padding=padding,
- bias=bias,
- groups=groups)
- self.relu=RPReLU(in_channels)
-
-
- def forward(self, x):
- out = self.move0(x)
- out = self.binary_activation(out)
- out = self.binary_conv(out)
- out =self.relu(out)
- out = out + x
- return out
-
-
-class BinaryConv2d_Down(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Down, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h/2,w/2
- '''
- out = self.avg_pool(x)
- out_1 = out
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-
-
-class BinaryConv2d_Up(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,2h,2w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Up, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,2h,2w
- '''
- b,c,h,w = x.shape
- out = F.interpolate(x, scale_factor=2, mode='bilinear')
-
- out_1 = out[:,:c//2,:,:]
- out_2 = out[:,c//2:,:,:]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Decrease(nn.Module):
- '''
- input: b,c,h,w
- output: b,c/2,h,w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Decrease, self).__init__()
-
- self.biconv_1 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(out_channels, out_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,c/2,h,w
- '''
- b,c,h,w = x.shape
- out = x
-
- out_1 = out[:,:c//2,:,:]
- out_2 = out[:,c//2:,:,:]
-
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
-
- out = (out_1 + out_2) / 2
-
- return out
-
-
-class BinaryConv2d_Fusion_Increase(nn.Module):
- '''
- input: b,c,h,w
- output: b,2c,h,w
- '''
- def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, bias=False, groups=1):
- super(BinaryConv2d_Fusion_Increase, self).__init__()
-
- self.biconv_1 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- self.biconv_2 = BinaryConv2d(in_channels, in_channels, kernel_size, stride, padding, bias, groups)
- # self.avg_pool = nn.AvgPool2d(kernel_size = 2, stride = 2, padding = 0)
-
- def forward(self, x):
- '''
- x: b,c,h,w
- out: b,2c,h,w
- '''
- # stx()
- out_1 = x
- out_2 = out_1.clone()
- out_1 = self.biconv_1(out_1)
- out_2 = self.biconv_2(out_2)
- out = torch.cat([out_1, out_2], dim=1)
-
- return out
-
-# ---------------------------------------------------------- Binarized UNet------------------------------------------------------
-
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=2):
- super().__init__()
- self.net = nn.Sequential(
- BinaryConv2d_Fusion_Increase(dim, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Increase(dim * mult, dim * mult * mult, 1, 1, bias=False),
- RPReLU(dim * mult * mult),
- BinaryConv2d(dim * mult * mult, dim * mult * mult, 3, 1, 1, bias=False, groups=dim),
- RPReLU(dim * mult * mult),
- BinaryConv2d_Fusion_Decrease(dim * mult * mult, dim * mult, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-
-
-class BiSRNet_Block(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(
- PreNorm(dim, FeedForward(dim=dim))
- )
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for ff in self.blocks:
- # x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-
-class BiSRNet_body(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(BiSRNet_body, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = BinaryConv2d(in_dim, self.dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- BiSRNet_Block(dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- BinaryConv2d_Down(dim_stage, dim_stage * 2, 3, 1, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = BiSRNet_Block(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- BinaryConv2d_Up(dim_stage, dim_stage // 2, 3, 1, 1, bias=False),
- BinaryConv2d_Fusion_Decrease(dim_stage, dim_stage // 2, 1, 1, bias=False),
- BiSRNet_Block(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = BinaryConv2d(self.dim, out_dim, 3, 1, 1, bias=False) # 1-bit -> 32-bit
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (BiSRNet_Block, FeaDownSample) in self.encoder_layers:
- # stx()
- fea = BiSRNet_Block(fea)
- fea_encoder.append(fea)
- # stx()
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, BiSRNet_Block) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = BiSRNet_Block(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-
-class BiSRNet(nn.Module):
- '''
- Only 3 layers are 32-bit conv
- '''
- def __init__(self, in_channels=28, out_channels=28, n_feat=28, stage=3, num_blocks=[1,1,1]):
- super(BiSRNet, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False) # 1-bit -> 32-bit
- modules_body = [BiSRNet_body(dim=n_feat, stage=2, num_blocks=num_blocks) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True) # 1-bit -> 32-bit
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False) # 1-bit -> 32-bit
-
- def initial_x(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,256]
- :return: z: [b,28,256,256]
- """
- x = self.fution(torch.cat([y, Phi], dim=1))
- return x
-
- def forward(self, y, Phi=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if Phi==None:
- Phi = torch.rand((1,28,256,256)).cuda()
- # Phi = torch.rand((1,28,256,256)).to(device)
- x = self.initial_x(y, Phi)
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
\ No newline at end of file
diff --git a/MST/simulation/train_code/architecture/CST.py b/MST/simulation/train_code/architecture/CST.py
deleted file mode 100755
index 8e58c50..0000000
--- a/MST/simulation/train_code/architecture/CST.py
+++ /dev/null
@@ -1,591 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-from collections import defaultdict, Counter
-import numpy as np
-from tqdm import tqdm
-import random
-
-def uniform(a, b, shape, device='cuda'):
- return (b - a) * torch.rand(shape, device=device) + a
-
-class AsymmetricTransform:
-
- def Q(self, *args, **kwargs):
- raise NotImplementedError('Query transform not implemented')
-
- def K(self, *args, **kwargs):
- raise NotImplementedError('Key transform not implemented')
-
-class LSH:
- def __call__(self, *args, **kwargs):
- raise NotImplementedError('LSH scheme not implemented')
-
- def compute_hash_agreement(self, q_hash, k_hash):
- return (q_hash == k_hash).min(dim=-1)[0].sum(dim=-1)
-
-class XBOXPLUS(AsymmetricTransform):
-
- def set_norms(self, x):
- self.x_norms = x.norm(p=2, dim=-1, keepdim=True)
- self.MX = torch.amax(self.x_norms, dim=-2, keepdim=True)
-
- def X(self, x):
- device = x.device
- ext = torch.sqrt((self.MX**2).to(device) - (self.x_norms**2).to(device))
- zero = torch.tensor(0.0, device=x.device).repeat(x.shape[:-1], 1).unsqueeze(-1)
- return torch.cat((x, ext, zero), -1)
-
-def lsh_clustering(x, n_rounds, r=1):
- salsh = SALSH(n_rounds=n_rounds, dim=x.shape[-1], r=r, device=x.device)
- x_hashed = salsh(x).reshape((n_rounds,) + x.shape[:-1])
- return x_hashed.argsort(dim=-1)
-
-class SALSH(LSH):
- def __init__(self, n_rounds, dim, r, device='cuda'):
- super(SALSH, self).__init__()
- self.alpha = torch.normal(0, 1, (dim, n_rounds), device=device)
- self.beta = uniform(0, r, shape=(1, n_rounds), device=device)
- self.dim = dim
- self.r = r
-
- def __call__(self, vecs):
- projection = vecs @ self.alpha
- projection_shift = projection + self.beta
- projection_rescale = projection_shift / self.r
- return projection_rescale.permute(2, 0, 1)
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
-
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
-
- variance = scale / denom
-
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def batch_scatter(output, src, dim, index):
- """
- :param output: [b,n,c]
- :param src: [b,n,c]
- :param dim: int
- :param index: [b,n]
- :return: output: [b,n,c]
- """
- b,k,c = src.shape
- index = index[:, :, None].expand(-1, -1, c)
- output, src, index = map(lambda t: rearrange(t, 'b k c -> (b c) k'), (output, src, index))
- output.scatter_(dim,index,src)
- output = rearrange(output, '(b c) k -> b k c', b=b)
- return output
-
-def batch_gather(x, index, dim):
- """
- :param x: [b,n,c]
- :param index: [b,n//2]
- :param dim: int
- :return: output: [b,n//2,c]
- """
- b,n,c = x.shape
- index = index[:,:,None].expand(-1,-1,c)
- x, index = map(lambda t: rearrange(t, 'b n c -> (b c) n'), (x, index))
- output = torch.gather(x,dim,index)
- output = rearrange(output, '(b c) n -> b n c', b=b)
- return output
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class SAH_MSA(nn.Module):
- def __init__(self, heads=4, n_rounds=2, channels=64, patch_size=144,
- r=1):
- super(SAH_MSA, self).__init__()
- self.heads = heads
- self.n_rounds = n_rounds
- inner_dim = channels*3
- self.to_q = nn.Linear(channels, inner_dim, bias=False)
- self.to_k = nn.Linear(channels, inner_dim, bias=False)
- self.to_v = nn.Linear(channels, inner_dim, bias=False)
- self.to_out = nn.Linear(inner_dim, channels, bias=False)
-
- self.xbox_plus = XBOXPLUS()
- self.clustering_params = {
- 'r': r,
- 'n_rounds': self.n_rounds
- }
- self.q_attn_size = patch_size[0] * patch_size[1]
- self.k_attn_size = patch_size[0] * patch_size[1]
-
- def forward(self, input):
- """
- :param input: [b,n,c]
- :return: output: [b,n,c]
- """
-
- B, N, C_inp = input.shape
- query = self.to_q(input)
- key = self.to_k(input)
- value = self.to_v(input)
- input_hash = input.view(B, N, self.heads, C_inp//self.heads)
- x_hash = rearrange(input_hash, 'b t h e -> (b h) t e')
- bs, x_seqlen, dim = x_hash.shape
- with torch.no_grad():
- self.xbox_plus.set_norms(x_hash)
- Xs = self.xbox_plus.X(x_hash)
- x_positions = lsh_clustering(Xs, **self.clustering_params)
- x_positions = x_positions.reshape(self.n_rounds, bs, -1)
-
- del Xs
-
- C = query.shape[-1]
- query = query.view(B, N, self.heads, C // self.heads)
- key = key.view(B, N, self.heads, C // self.heads)
- value = value.view(B, N, self.heads, C // self.heads)
-
- query = rearrange(query, 'b t h e -> (b h) t e') # [bs, q_seqlen,c]
- key = rearrange(key, 'b t h e -> (b h) t e')
- value = rearrange(value, 'b s h d -> (b h) s d')
-
- bs, q_seqlen, dim = query.shape
- bs, k_seqlen, dim = key.shape
- v_dim = value.shape[-1]
-
- x_rev_positions = torch.argsort(x_positions, dim=-1)
- x_offset = torch.arange(bs, device=query.device).unsqueeze(-1) * x_seqlen
- x_flat = (x_positions + x_offset).reshape(-1)
-
- s_queries = query.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.q_attn_size, dim)
- s_keys = key.reshape(-1, dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, dim)
- s_values = value.reshape(-1, v_dim).index_select(0, x_flat).reshape(-1, self.k_attn_size, v_dim)
-
- inner = s_queries @ s_keys.transpose(2, 1)
- norm_factor = 1
- inner = inner / norm_factor
-
- # free memory
- del x_positions
-
- # softmax denominator
- dots_logsumexp = torch.logsumexp(inner, dim=-1, keepdim=True)
- # softmax
- dots = torch.exp(inner - dots_logsumexp)
- # dropout
-
- # n_rounds outs
- bo = (dots @ s_values).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- # undo sort
- x_offset = torch.arange(bs * self.n_rounds, device=query.device).unsqueeze(-1) * x_seqlen
- x_rev_flat = (x_rev_positions.reshape(-1, x_seqlen) + x_offset).reshape(-1)
- o = bo.reshape(-1, v_dim).index_select(0, x_rev_flat).reshape(self.n_rounds, bs, q_seqlen, -1)
-
- slogits = dots_logsumexp.reshape(self.n_rounds, bs, -1)
- logits = torch.gather(slogits, 2, x_rev_positions)
-
- # free memory
- del x_rev_positions
-
- # weighted sum multi-round attention
- probs = torch.exp(logits - torch.logsumexp(logits, dim=0, keepdim=True))
- out = torch.sum(o * probs.unsqueeze(-1), dim=0)
- out = rearrange(out, '(b h) t d -> b t h d', h=self.heads)
- out = out.reshape(B, N, -1)
- out = self.to_out(out)
-
- return out
-
-class SAHAB(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(16, 16),
- heads=8,
- shift_size=0,
- sparse=False
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- self.attn = PreNorm(dim, SAH_MSA(heads=heads, n_rounds=2, r=1, channels=dim, patch_size=patch_size))
- self.ffn = PreNorm(dim, FeedForward(dim=dim))
- self.shift_size = shift_size
- self.patch_size = patch_size
- self.sparse = sparse
-
- def forward(self, x, mask=None):
- """
- x: [b,h,w,c]
- mask: [b,h,w]
- return out: [b,h,w,c]
- """
- b,h,w,c = x.shape
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- mask = torch.roll(mask, shifts=(-self.shift_size, -self.shift_size), dims=(1, 2))
- w_size = self.patch_size
-
- # Split into large patches
- x = rearrange(x, 'b (nh hh) (nw ww) c-> b (nh nw) (hh ww c)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- mask = rearrange(mask, 'b (nh hh) (nw ww) -> b (nh nw) (hh ww)', hh=w_size[0] * 2, ww=w_size[1] * 2)
- N = x.shape[1]
-
- mask = torch.mean(mask,dim=2,keepdim=False) # [b,nh*nw]
- if self.sparse:
- mask_select = mask.topk(mask.shape[1] // 2, dim=1)[1] # [b,nh*nw//2]
- x_select = batch_gather(x, mask_select, 1) # [b,nh*nw//2,hh*ww*c]
- x_select = x_select.reshape(b*N//2,-1,c)
- x_select = self.attn(x_select)+x_select
- x_select = x_select.view(b,N//2,-1)
- x = batch_scatter(x.clone(), x_select, 1, mask_select)
- else:
- x = x.view(b*N,-1,c)
- x = self.attn(x) + x
- x = x.view(b, N, -1)
- x = rearrange(x, 'b (nh nw) (hh ww c) -> b (nh hh) (nw ww) c', nh=h//(w_size[0] * 2), hh=w_size[0] * 2, ww=w_size[1] * 2)
-
- if self.shift_size > 0:
- x = torch.roll(x, shifts=(self.shift_size, self.shift_size), dims=(1, 2))
-
- x = self.ffn(x) + x
-
- return x
-
-
-class SAHABs(nn.Module):
- def __init__(
- self,
- dim,
- patch_size=(8, 8),
- heads=8,
- num_blocks=2,
- sparse=False
- ):
- super().__init__()
- blocks = []
- for _ in range(num_blocks):
- blocks.append(
- SAHAB(heads=heads, dim=dim, patch_size=patch_size,sparse=sparse,
- shift_size=0 if (_ % 2 == 0) else patch_size[0]))
- self.blocks = nn.Sequential(*blocks)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,1,h,w]
- return x: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- mask = mask.squeeze(1)
- for block in self.blocks:
- x = block(x, mask)
- x = x.permute(0, 3, 1, 2)
- return x
-
-class ASPPConv(nn.Sequential):
- def __init__(self, in_channels, out_channels, dilation):
- modules = [
- nn.Conv2d(in_channels, out_channels, 3, padding=dilation, dilation=dilation, bias=False),
- nn.ReLU()
- ]
- super(ASPPConv, self).__init__(*modules)
-
-
-class ASPPPooling(nn.Sequential):
- def __init__(self, in_channels, out_channels):
- super(ASPPPooling, self).__init__(
- nn.AdaptiveAvgPool2d(1),
- nn.Conv2d(in_channels, out_channels, 1, bias=False),
- nn.ReLU())
-
- def forward(self, x):
- size = x.shape[-2:]
- for mod in self:
- x = mod(x)
- return F.interpolate(x, size=size, mode='bilinear', align_corners=False)
-
-
-class ASPP(nn.Module):
- def __init__(self, in_channels, atrous_rates, out_channels):
- super(ASPP, self).__init__()
- modules = []
-
- rates = tuple(atrous_rates)
- for rate in rates:
- modules.append(ASPPConv(in_channels, out_channels, rate))
-
- modules.append(ASPPPooling(in_channels, out_channels))
-
- self.convs = nn.ModuleList(modules)
-
- self.project = nn.Sequential(
- nn.Conv2d(len(self.convs) * out_channels, out_channels, 1, bias=False),
- nn.ReLU(),
- nn.Dropout(0.5))
-
- def forward(self, x):
- res = []
- for conv in self.convs:
- res.append(conv(x))
- res = torch.cat(res, dim=1)
- return self.project(res)
-
-class Sparsity_Estimator(nn.Module):
- def __init__(self, dim=28, expand=2, sparse=False):
- super(Sparsity_Estimator, self).__init__()
- self.dim = dim
- self.stage = 2
- self.sparse = sparse
-
- # Input projection
- self.in_proj = nn.Conv2d(28, dim, 1, 1, 0, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(2):
- self.encoder_layers.append(nn.ModuleList([
- nn.Conv2d(dim_stage, dim_stage * expand, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage * expand, dim_stage * expand, 3, 2, 1, bias=False, groups=dim_stage * expand),
- nn.Conv2d(dim_stage * expand, dim_stage*expand, 1, 1, 0, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = ASPP(dim_stage, [3,6], dim_stage)
-
- # Decoder:
- self.decoder_layers = nn.ModuleList([])
- for i in range(2):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage // 2, dim_stage, 1, 1, 0, bias=False),
- nn.Conv2d(dim_stage, dim_stage, 3, 1, 1, bias=False, groups=dim_stage),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, 0, bias=False),
- ]))
- dim_stage //= 2
-
- # Output projection
- if sparse:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim+1, 3, 1, 1, bias=False)
- else:
- self.out_conv2 = nn.Conv2d(self.dim, self.dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- # Input projection
- fea = self.lrelu(self.in_proj(x))
- # Encoder
- fea_encoder = [] # [c 2c 4c 8c]
- for (Conv1, Conv2, Conv3) in self.encoder_layers:
- fea_encoder.append(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- # Bottleneck
- fea = self.bottleneck(fea)+fea
- # Decoder
- for i, (FeaUpSample, Conv1, Conv2, Conv3) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Conv3(self.lrelu(Conv2(self.lrelu(Conv1(fea)))))
- fea = fea + fea_encoder[self.stage-1-i]
- # Output projection
- out = self.out_conv2(fea)
- if self.sparse:
- error_map = out[:,-1:,:,:]
- return out[:,:-1], error_map
- return out
-
-class CST(nn.Module):
- def __init__(self, dim=28, stage=2, num_blocks=[2, 2, 2], sparse=False):
- super(CST, self).__init__()
- self.dim = dim
- self.stage = stage
- self.sparse = sparse
-
- # Fution physical mask and shifted measurement
- self.fution = nn.Conv2d(56, 28, 1, 1, 0, bias=False)
-
- # Sparsity Estimator
- if num_blocks==[2,4,6]:
- self.fe = nn.Sequential(Sparsity_Estimator(dim=28,expand=2,sparse=False),
- Sparsity_Estimator(dim=28, expand=2, sparse=sparse))
- else:
- self.fe = Sparsity_Estimator(dim=28, expand=2, sparse=sparse)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- SAHABs(dim=dim_stage, num_blocks=num_blocks[i], heads=dim_stage // dim, sparse=sparse),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.AvgPool2d(kernel_size=2, stride=2),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = SAHABs(
- dim=dim_stage, heads=dim_stage // dim, num_blocks=num_blocks[-1], sparse=sparse)
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- SAHABs(dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i],
- heads=(dim_stage // 2) // dim, sparse=sparse),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.out_proj = nn.Conv2d(self.dim, dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- mask: [b,c,h,w]
- return out:[b,c,h,w]
- """
- b, c, h, w = x.shape
-
- # Fution
- x = self.fution(torch.cat([x,mask],dim=1))
-
- # Feature Extraction
- if self.sparse:
- fea,mask = self.fe(x)
- else:
- fea = self.fe(x)
- mask = torch.randn((b,1,h,w)).cuda()
-
- # Encoder
- fea_encoder = []
- masks = []
- for (Blcok, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = Blcok(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Blcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = fea + fea_encoder[self.stage - 1 - i]
- mask = masks[self.stage - 1 - i]
- fea = Blcok(fea, mask)
-
- # Output projection
- out = self.out_proj(fea) + x
- if self.sparse:
- return out, mask
- else:
- return out
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/train_code/architecture/DAUHST.py b/MST/simulation/train_code/architecture/DAUHST.py
deleted file mode 100755
index d7c9bf3..0000000
--- a/MST/simulation/train_code/architecture/DAUHST.py
+++ /dev/null
@@ -1,372 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch import einsum
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-
-class HS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- #window_size=(8, 8),
- window_size=(7, 7),
- dim_head=28,
- heads=8,
- only_local_branch=False
- ):
- super().__init__()
-
- self.dim = dim
- self.heads = heads
- self.scale = dim_head ** -0.5
- self.window_size = window_size
- self.only_local_branch = only_local_branch
-
- # position embedding
- if only_local_branch:
- seq_l = window_size[0] * window_size[1]
- self.pos_emb = nn.Parameter(torch.Tensor(1, heads, seq_l, seq_l))
- trunc_normal_(self.pos_emb)
- else:
- seq_l1 = window_size[0] * window_size[1]
- self.pos_emb1 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l1, seq_l1))
- #h,w = 256//self.heads,320//self.heads
- h,w = 112//self.heads,112//self.heads
- seq_l2 = h*w//seq_l1
- self.pos_emb2 = nn.Parameter(torch.Tensor(1, 1, heads//2, seq_l2, seq_l2))
- trunc_normal_(self.pos_emb1)
- trunc_normal_(self.pos_emb2)
-
- inner_dim = dim_head * heads
- self.to_q = nn.Linear(dim, inner_dim, bias=False)
- self.to_kv = nn.Linear(dim, inner_dim * 2, bias=False)
- self.to_out = nn.Linear(inner_dim, dim)
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x.shape
- w_size = self.window_size
-
- assert h % w_size[0] == 0 and w % w_size[1] == 0, 'fmap dimensions must be divisible by the window size'
- if self.only_local_branch:
- x_inp = rearrange(x, 'b (h b0) (w b1) c -> (b h w) (b0 b1) c', b0=w_size[0], b1=w_size[1])
- q = self.to_q(x_inp)
- k, v = self.to_kv(x_inp).chunk(2, dim=-1)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.heads), (q, k, v))
- q *= self.scale
- sim = einsum('b h i d, b h j d -> b h i j', q, k)
- sim = sim + self.pos_emb
- attn = sim.softmax(dim=-1)
- out = einsum('b h i j, b h j d -> b h i d', attn, v)
- out = rearrange(out, 'b h n d -> b n (h d)')
- out = self.to_out(out)
- out = rearrange(out, '(b h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- else:
- q = self.to_q(x)
- k, v = self.to_kv(x).chunk(2, dim=-1)
- q1, q2 = q[:,:,:,:c//2], q[:,:,:,c//2:]
- k1, k2 = k[:,:,:,:c//2], k[:,:,:,c//2:]
- v1, v2 = v[:,:,:,:c//2], v[:,:,:,c//2:]
-
- # local branch
- q1, k1, v1 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q1, k1, v1))
- q1, k1, v1 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q1, k1, v1))
- q1 *= self.scale
- sim1 = einsum('b n h i d, b n h j d -> b n h i j', q1, k1)
- sim1 = sim1 + self.pos_emb1
- attn1 = sim1.softmax(dim=-1)
- out1 = einsum('b n h i j, b n h j d -> b n h i d', attn1, v1)
- out1 = rearrange(out1, 'b n h mm d -> b n mm (h d)')
-
- # non-local branch
- q2, k2, v2 = map(lambda t: rearrange(t, 'b (h b0) (w b1) c -> b (h w) (b0 b1) c',
- b0=w_size[0], b1=w_size[1]), (q2, k2, v2))
- q2, k2, v2 = map(lambda t: t.permute(0, 2, 1, 3), (q2.clone(), k2.clone(), v2.clone()))
- q2, k2, v2 = map(lambda t: rearrange(t, 'b n mm (h d) -> b n h mm d', h=self.heads//2), (q2, k2, v2))
- q2 *= self.scale
- sim2 = einsum('b n h i d, b n h j d -> b n h i j', q2, k2)
- sim2 = sim2 + self.pos_emb2
- attn2 = sim2.softmax(dim=-1)
- out2 = einsum('b n h i j, b n h j d -> b n h i d', attn2, v2)
- out2 = rearrange(out2, 'b n h mm d -> b n mm (h d)')
- out2 = out2.permute(0, 2, 1, 3)
-
- out = torch.cat([out1,out2],dim=-1).contiguous()
- out = self.to_out(out)
- out = rearrange(out, 'b (h w) (b0 b1) c -> b (h b0) (w b1) c', h=h // w_size[0], w=w // w_size[1],
- b0=w_size[0])
- return out
-
-class HSAB(nn.Module):
- def __init__(
- self,
- dim,
- #window_size=(8, 8),
- window_size=(7, 7),
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- PreNorm(dim, HS_MSA(dim=dim, window_size=window_size, dim_head=dim_head, heads=heads, only_local_branch=(heads==1))),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class HST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, num_blocks=[1,1,1]):
- super(HST, self).__init__()
- self.dim = dim
- self.scales = len(num_blocks)
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_scale = dim
- for i in range(self.scales-1):
- self.encoder_layers.append(nn.ModuleList([
- HSAB(dim=dim_scale, num_blocks=num_blocks[i], dim_head=dim, heads=dim_scale // dim),
- nn.Conv2d(dim_scale, dim_scale * 2, 4, 2, 1, bias=False),
- ]))
- dim_scale *= 2
-
- # Bottleneck
- self.bottleneck = HSAB(dim=dim_scale, dim_head=dim, heads=dim_scale // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(self.scales-1):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_scale, dim_scale // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_scale, dim_scale // 2, 1, 1, bias=False),
- HSAB(dim=dim_scale // 2, num_blocks=num_blocks[self.scales - 2 - i], dim_head=dim,
- heads=(dim_scale // 2) // dim),
- ]))
- dim_scale //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- b, c, h_inp, w_inp = x.shape
- hb, wb = 16, 16
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
-
- # Embedding
- fea = self.embedding(x)
- x = x[:,:28,:,:]
-
- # Encoder
- fea_encoder = []
- for (HSAB, FeaDownSample) in self.encoder_layers:
- fea = HSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, HSAB) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.scales-2-i]], dim=1))
- fea = HSAB(fea)
-
- # Mapping
- out = self.mapping(fea) + x
- return out[:, :, :h_inp, :w_inp]
-
-def A(x,Phi):
- temp = x*Phi
- y = torch.sum(temp,1)
- return y
-
-def At(y,Phi):
- temp = torch.unsqueeze(y, 1).repeat(1,Phi.shape[1],1,1)
- x = temp*Phi
- return x
-
-def shift_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=step*i, dims=2)
- return inputs
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class HyPaNet(nn.Module):
- def __init__(self, in_nc=29, out_nc=8, channel=64):
- super(HyPaNet, self).__init__()
- self.fution = nn.Conv2d(in_nc, channel, 1, 1, 0, bias=True)
- self.down_sample = nn.Conv2d(channel, channel, 3, 2, 1, bias=True)
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.mlp = nn.Sequential(
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, channel, 1, padding=0, bias=True),
- nn.ReLU(inplace=True),
- nn.Conv2d(channel, out_nc, 1, padding=0, bias=True),
- nn.Softplus())
- self.relu = nn.ReLU(inplace=True)
- self.out_nc = out_nc
-
- def forward(self, x):
- x = self.down_sample(self.relu(self.fution(x)))
- x = self.avg_pool(x)
- x = self.mlp(x) + 1e-6
- return x[:,:self.out_nc//2,:,:], x[:,self.out_nc//2:,:,:]
-
-class DAUHST(nn.Module):
-
- def __init__(self, num_iterations=1):
- super(DAUHST, self).__init__()
- self.para_estimator = HyPaNet(in_nc=28, out_nc=num_iterations*2)
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True)
- self.num_iterations = num_iterations
- self.denoisers = nn.ModuleList([])
- for _ in range(num_iterations):
- self.denoisers.append(
- HST(in_dim=29, out_dim=28, dim=28, num_blocks=[1,1,1]),
- )
- def initial(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :return: temp: [b,28,256,310]; alpha: [b, num_iterations]; beta: [b, num_iterations]
- """
- nC, step = 28, 2
- y = y / nC * 2
- bs,row,col = y.shape
- """ y_shift = torch.zeros(bs, nC, row, col).cuda().float()
- for i in range(nC):
- y_shift[:, i, :, step * i:step * i + col - (nC - 1) * step] = y[:, :, step * i:step * i + col - (nC - 1) * step] """
- y_shift = y.unsqueeze(1).repeat((1, 28, 1, 1)).float()
- z = self.fution(torch.cat([y_shift, Phi], dim=1))
- alpha, beta = self.para_estimator(self.fution(torch.cat([y_shift, Phi], dim=1)))
- return z, alpha, beta
-
- def forward(self, y, input_mask=None):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,310]
- :param Phi_PhiT: [b,256,310]
- :return: z_crop: [b,28,256,256]
- """
- Phi, Phi_s = input_mask
- z, alphas, betas = self.initial(y, Phi)
- for i in range(self.num_iterations):
- alpha, beta = alphas[:,i,:,:], betas[:,i:i+1,:,:]
- Phi_z = A(z, Phi)
- x = z + At(torch.div(y-Phi_z,alpha+Phi_s), Phi)
- x = shift_back_3d(x)
- beta_repeat = beta.repeat(1,1,x.shape[2], x.shape[3])
- z = self.denoisers[i](torch.cat([x, beta_repeat],dim=1))
- if i [BN] => ReLU) * 2"""
-
- def __init__(self, in_channels, out_channels, mid_channels=None):
- super().__init__()
- if not mid_channels:
- mid_channels = out_channels
- self.double_conv = nn.Sequential(
- nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(mid_channels),
- nn.ReLU(inplace=True),
- nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
- nn.BatchNorm2d(out_channels),
- nn.ReLU(inplace=True)
- )
-
- def forward(self, x):
- return self.double_conv(x)
-
-class GAP_net(nn.Module):
-
- def __init__(self):
- super(GAP_net, self).__init__()
-
- self.unet1 = Unet(28, 28)
- self.unet2 = Unet(28, 28)
- self.unet3 = Unet(28, 28)
- self.unet4 = Unet(28, 28)
- self.unet5 = Unet(28, 28)
- self.unet6 = Unet(28, 28)
- self.unet7 = Unet(28, 28)
- self.unet8 = Unet(28, 28)
- self.unet9 = Unet(28, 28)
-
- def forward(self, y, input_mask=None):
- if input_mask==None:
- Phi = torch.rand((1,28,256,310)).cuda()
- Phi_s = torch.rand((1, 256, 310)).cuda()
- else:
- Phi, Phi_s = input_mask
- x_list = []
- x = At(y, Phi) # v0=H^T y
- ### 1-3
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet1(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet2(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet3(x)
- x = shift_3d(x)
- ### 4-6
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet4(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet5(x)
- x = shift_3d(x)
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet6(x)
- x = shift_3d(x)
- # ### 7-9
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet7(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet8(x)
- x = shift_3d(x)
- x_list.append(x[:, :, :, 0:256])
- yb = A(x, Phi)
- x = x + At(torch.div(y - yb, Phi_s), Phi)
- x = shift_back_3d(x)
- x = self.unet9(x)
- x = shift_3d(x)
- return x[:, :, :, 0:256]
diff --git a/MST/simulation/train_code/architecture/HDNet.py b/MST/simulation/train_code/architecture/HDNet.py
deleted file mode 100755
index 442acc8..0000000
--- a/MST/simulation/train_code/architecture/HDNet.py
+++ /dev/null
@@ -1,371 +0,0 @@
-import torch
-import torch.nn as nn
-import math
-
-def default_conv(in_channels, out_channels, kernel_size, bias=True):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias)
-
-class MeanShift(nn.Conv2d):
- def __init__(
- self, rgb_range,
- rgb_mean=(0.4488, 0.4371, 0.4040), rgb_std=(1.0, 1.0, 1.0), sign=-1):
-
- super(MeanShift, self).__init__(3, 3, kernel_size=1)
- std = torch.Tensor(rgb_std)
- self.weight.data = torch.eye(3).view(3, 3, 1, 1) / std.view(3, 1, 1, 1)
- self.bias.data = sign * rgb_range * torch.Tensor(rgb_mean) / std
- for p in self.parameters():
- p.requires_grad = False
-
-class BasicBlock(nn.Sequential):
- def __init__(
- self, conv, in_channels, out_channels, kernel_size, stride=1, bias=False,
- bn=True, act=nn.ReLU(True)):
-
- m = [conv(in_channels, out_channels, kernel_size, bias=bias)]
- if bn:
- m.append(nn.BatchNorm2d(out_channels))
- if act is not None:
- m.append(act)
-
- super(BasicBlock, self).__init__(*m)
-
-class ResBlock(nn.Module):
- def __init__(
- self, conv, n_feats, kernel_size,
- bias=True, bn=False, act=nn.ReLU(True), res_scale=1):
-
- super(ResBlock, self).__init__()
- m = []
- for i in range(2):
- m.append(conv(n_feats, n_feats, kernel_size, bias=bias))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if i == 0:
- m.append(act)
-
- self.body = nn.Sequential(*m)
- self.res_scale = res_scale
-
- def forward(self, x):
- res = self.body(x).mul(self.res_scale) # So res_scale is a scaler? just scale all elements in each feature's residual? Why?
- res += x
-
- return res
-
-class Upsampler(nn.Sequential):
- def __init__(self, conv, scale, n_feats, bn=False, act=False, bias=True):
-
- m = []
- if (scale & (scale - 1)) == 0:
- for _ in range(int(math.log(scale, 2))):
- m.append(conv(n_feats, 4 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(2))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
-
- elif scale == 3:
- m.append(conv(n_feats, 9 * n_feats, 3, bias))
- m.append(nn.PixelShuffle(3))
- if bn:
- m.append(nn.BatchNorm2d(n_feats))
- if act == 'relu':
- m.append(nn.ReLU(True))
- elif act == 'prelu':
- m.append(nn.PReLU(n_feats))
- else:
- raise NotImplementedError
-
- super(Upsampler, self).__init__(*m)
-
-_NORM_BONE = False
-
-def constant_init(module, val, bias=0):
- if hasattr(module, 'weight') and module.weight is not None:
- nn.init.constant_(module.weight, val)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-
-def kaiming_init(module,
- a=0,
- mode='fan_out',
- nonlinearity='relu',
- bias=0,
- distribution='normal'):
- assert distribution in ['uniform', 'normal']
- if distribution == 'uniform':
- nn.init.kaiming_uniform_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- else:
- nn.init.kaiming_normal_(
- module.weight, a=a, mode=mode, nonlinearity=nonlinearity)
- if hasattr(module, 'bias') and module.bias is not None:
- nn.init.constant_(module.bias, bias)
-
-# depthwise-separable convolution (DSC)
-class DSC(nn.Module):
-
- def __init__(self, nin: int) -> None:
- super(DSC, self).__init__()
- self.conv_dws = nn.Conv2d(
- nin, nin, kernel_size=1, stride=1, padding=0, groups=nin
- )
- self.bn_dws = nn.BatchNorm2d(nin, momentum=0.9)
- self.relu_dws = nn.ReLU(inplace=False)
-
- self.maxpool = nn.MaxPool2d(kernel_size=3, stride=1, padding=1)
-
- self.conv_point = nn.Conv2d(
- nin, 1, kernel_size=1, stride=1, padding=0, groups=1
- )
- self.bn_point = nn.BatchNorm2d(1, momentum=0.9)
- self.relu_point = nn.ReLU(inplace=False)
-
- self.softmax = nn.Softmax(dim=2)
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- out = self.conv_dws(x)
- out = self.bn_dws(out)
- out = self.relu_dws(out)
-
- out = self.maxpool(out)
-
- out = self.conv_point(out)
- out = self.bn_point(out)
- out = self.relu_point(out)
-
- m, n, p, q = out.shape
- out = self.softmax(out.view(m, n, -1))
- out = out.view(m, n, p, q)
-
- out = out.expand(x.shape[0], x.shape[1], x.shape[2], x.shape[3])
-
- out = torch.mul(out, x)
-
- out = out + x
-
- return out
-
-# Efficient Feature Fusion(EFF)
-class EFF(nn.Module):
- def __init__(self, nin: int, nout: int, num_splits: int) -> None:
- super(EFF, self).__init__()
-
- assert nin % num_splits == 0
-
- self.nin = nin
- self.nout = nout
- self.num_splits = num_splits
- self.subspaces = nn.ModuleList(
- [DSC(int(self.nin / self.num_splits)) for i in range(self.num_splits)]
- )
-
- def forward(self, x: torch.Tensor) -> torch.Tensor:
- sub_feat = torch.chunk(x, self.num_splits, dim=1)
- out = []
- for idx, l in enumerate(self.subspaces):
- out.append(self.subspaces[idx](sub_feat[idx]))
- out = torch.cat(out, dim=1)
-
- return out
-
-
-# spatial-spectral domain attention learning(SDL)
-class SDL_attention(nn.Module):
- def __init__(self, inplanes, planes, kernel_size=1, stride=1):
- super(SDL_attention, self).__init__()
-
- self.inplanes = inplanes
- self.inter_planes = planes // 2
- self.planes = planes
- self.kernel_size = kernel_size
- self.stride = stride
- self.padding = (kernel_size-1)//2
-
- self.conv_q_right = nn.Conv2d(self.inplanes, 1, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_v_right = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False)
- self.conv_up = nn.Conv2d(self.inter_planes, self.planes, kernel_size=1, stride=1, padding=0, bias=False)
- self.softmax_right = nn.Softmax(dim=2)
- self.sigmoid = nn.Sigmoid()
-
- self.conv_q_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #g
- self.avg_pool = nn.AdaptiveAvgPool2d(1)
- self.conv_v_left = nn.Conv2d(self.inplanes, self.inter_planes, kernel_size=1, stride=stride, padding=0, bias=False) #theta
- self.softmax_left = nn.Softmax(dim=2)
-
- self.reset_parameters()
-
- def reset_parameters(self):
- kaiming_init(self.conv_q_right, mode='fan_in')
- kaiming_init(self.conv_v_right, mode='fan_in')
- kaiming_init(self.conv_q_left, mode='fan_in')
- kaiming_init(self.conv_v_left, mode='fan_in')
-
- self.conv_q_right.inited = True
- self.conv_v_right.inited = True
- self.conv_q_left.inited = True
- self.conv_v_left.inited = True
- # HR spatial attention
- def spatial_attention(self, x):
- input_x = self.conv_v_right(x)
- batch, channel, height, width = input_x.size()
-
- input_x = input_x.view(batch, channel, height * width)
- context_mask = self.conv_q_right(x)
- context_mask = context_mask.view(batch, 1, height * width)
- context_mask = self.softmax_right(context_mask)
-
- context = torch.matmul(input_x, context_mask.transpose(1,2))
- context = context.unsqueeze(-1)
- context = self.conv_up(context)
-
- mask_ch = self.sigmoid(context)
-
- out = x * mask_ch
-
- return out
- # HR spectral attention
- def spectral_attention(self, x):
-
- g_x = self.conv_q_left(x)
- batch, channel, height, width = g_x.size()
-
- avg_x = self.avg_pool(g_x)
- batch, channel, avg_x_h, avg_x_w = avg_x.size()
-
- avg_x = avg_x.view(batch, channel, avg_x_h * avg_x_w).permute(0, 2, 1)
- theta_x = self.conv_v_left(x).view(batch, self.inter_planes, height * width)
- context = torch.matmul(avg_x, theta_x)
- context = self.softmax_left(context)
- context = context.view(batch, 1, height, width)
-
- mask_sp = self.sigmoid(context)
-
- out = x * mask_sp
-
- return out
-
- def forward(self, x):
- context_spectral = self.spectral_attention(x)
- context_spatial = self.spatial_attention(x)
- out = context_spatial + context_spectral
- return out
-
-
-class HDNet(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28, conv=default_conv):
- super(HDNet, self).__init__()
-
- n_resblocks = 16
- n_feats = 64
- kernel_size = 3
- act = nn.ReLU(True)
-
- # define head module
- m_head = [conv(in_ch, n_feats, kernel_size)]
-
- # define body module
- m_body = [
- ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ) for _ in range(n_resblocks)
- ]
- m_body.append(SDL_attention(inplanes = n_feats, planes = n_feats))
- m_body.append(EFF(nin=n_feats, nout=n_feats, num_splits=4))
-
- for i in range(1, n_resblocks):
- m_body.append(ResBlock(
- conv, n_feats, kernel_size, act=act, res_scale= 1
- ))
-
- m_body.append(conv(n_feats, n_feats, kernel_size))
-
- m_tail = [conv(n_feats, out_ch, kernel_size)]
-
- self.head = nn.Sequential(*m_head)
- self.body = nn.Sequential(*m_body)
- self.tail = nn.Sequential(*m_tail)
-
- def forward(self, x, input_mask=None):
- x = self.head(x)
-
- res = self.body(x)
- res += x
-
- x = self.tail(res)
-
- return x
-
-# frequency domain learning(FDL)
-class FDL(nn.Module):
- def __init__(self, loss_weight=1.0, alpha=1.0, patch_factor=1, ave_spectrum=False, log_matrix=False, batch_matrix=False):
- super(FDL, self).__init__()
- self.loss_weight = loss_weight
- self.alpha = alpha
- self.patch_factor = patch_factor
- self.ave_spectrum = ave_spectrum
- self.log_matrix = log_matrix
- self.batch_matrix = batch_matrix
-
- def tensor2freq(self, x):
- patch_factor = self.patch_factor
- _, _, h, w = x.shape
- assert h % patch_factor == 0 and w % patch_factor == 0, (
- 'Patch factor should be divisible by image height and width')
- patch_list = []
- patch_h = h // patch_factor
- patch_w = w // patch_factor
- for i in range(patch_factor):
- for j in range(patch_factor):
- patch_list.append(x[:, :, i * patch_h:(i + 1) * patch_h, j * patch_w:(j + 1) * patch_w])
-
- y = torch.stack(patch_list, 1)
-
- return torch.rfft(y, 2, onesided=False, normalized=True)
-
- def loss_formulation(self, recon_freq, real_freq, matrix=None):
- if matrix is not None:
- weight_matrix = matrix.detach()
- else:
- matrix_tmp = (recon_freq - real_freq) ** 2
- matrix_tmp = torch.sqrt(matrix_tmp[..., 0] + matrix_tmp[..., 1]) ** self.alpha
- if self.log_matrix:
- matrix_tmp = torch.log(matrix_tmp + 1.0)
-
- if self.batch_matrix:
- matrix_tmp = matrix_tmp / matrix_tmp.max()
- else:
- matrix_tmp = matrix_tmp / matrix_tmp.max(-1).values.max(-1).values[:, :, :, None, None]
-
- matrix_tmp[torch.isnan(matrix_tmp)] = 0.0
- matrix_tmp = torch.clamp(matrix_tmp, min=0.0, max=1.0)
- weight_matrix = matrix_tmp.clone().detach()
-
- assert weight_matrix.min().item() >= 0 and weight_matrix.max().item() <= 1, (
- 'The values of spectrum weight matrix should be in the range [0, 1], '
- 'but got Min: %.10f Max: %.10f' % (weight_matrix.min().item(), weight_matrix.max().item()))
-
- tmp = (recon_freq - real_freq) ** 2
- freq_distance = tmp[..., 0] + tmp[..., 1]
-
- loss = weight_matrix * freq_distance
- return torch.mean(loss)
-
- def forward(self, pred, target, matrix=None, **kwargs):
-
- pred_freq = self.tensor2freq(pred)
- target_freq = self.tensor2freq(target)
-
- if self.ave_spectrum:
- pred_freq = torch.mean(pred_freq, 0, keepdim=True)
- target_freq = torch.mean(target_freq, 0, keepdim=True)
-
- return self.loss_formulation(pred_freq, target_freq, matrix) * self.loss_weight
diff --git a/MST/simulation/train_code/architecture/Lambda_Net.py b/MST/simulation/train_code/architecture/Lambda_Net.py
deleted file mode 100755
index ddac0aa..0000000
--- a/MST/simulation/train_code/architecture/Lambda_Net.py
+++ /dev/null
@@ -1,179 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-from torch import einsum
-
-class LambdaNetAttention(nn.Module):
- def __init__(
- self,
- dim,
- ):
- super().__init__()
-
- self.dim = dim
- self.to_q = nn.Linear(dim, dim//8, bias=False)
- self.to_k = nn.Linear(dim, dim//8, bias=False)
- self.to_v = nn.Linear(dim, dim, bias=False)
- self.rescale = (dim//8)**-0.5
- self.gamma = nn.Parameter(torch.ones(1))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0,2,3,1)
- b, h, w, c = x.shape
-
- # Reshape to (B,N,C), where N = window_size[0]*window_size[1] is the length of sentence
- x_inp = rearrange(x, 'b h w c -> b (h w) c')
-
- # produce query, key and value
- q = self.to_q(x_inp)
- k = self.to_k(x_inp)
- v = self.to_v(x_inp)
-
- # attention
- sim = einsum('b i d, b j d -> b i j', q, k)*self.rescale
- attn = sim.softmax(dim=-1)
-
- # aggregate
- out = einsum('b i j, b j d -> b i d', attn, v)
-
- # merge blocks back to original feature map
- out = rearrange(out, 'b (h w) c -> b h w c', h=h, w=w)
- out = self.gamma*out + x
- return out.permute(0,3,1,2)
-
-class triple_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(triple_conv, self).__init__()
- self.t_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.t_conv(x)
- return x
-
-class double_conv(nn.Module):
-
- def __init__(self, in_channels, out_channels):
- super(double_conv, self).__init__()
- self.d_conv = nn.Sequential(
- nn.Conv2d(in_channels, out_channels, 3, padding=1),
- nn.ReLU(),
- nn.Conv2d(out_channels, out_channels, 3, padding=1),
- )
-
- def forward(self, x):
- x = self.d_conv(x)
- return x
-
-def shift_back_3d(inputs,step=2):
- [bs, nC, row, col] = inputs.shape
- for i in range(nC):
- inputs[:,i,:,:] = torch.roll(inputs[:,i,:,:], shifts=(-1)*step*i, dims=2)
- return inputs
-
-class Lambda_Net(nn.Module):
-
- def __init__(self, out_ch=28):
- super(Lambda_Net, self).__init__()
- self.conv_in = nn.Conv2d(1+28, 28, 3, padding=1)
-
- # encoder
- self.conv_down1 = triple_conv(28, 32)
- self.conv_down2 = triple_conv(32, 64)
- self.conv_down3 = triple_conv(64, 128)
- self.conv_down4 = triple_conv(128, 256)
- self.conv_down5 = double_conv(256, 512)
- self.conv_down6 = double_conv(512, 1024)
-
- self.maxpool = nn.MaxPool2d(2)
-
- # decoder
- self.upsample5 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
- self.upsample4 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
- self.upsample3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
- self.upsample2 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
- self.upsample1 = nn.ConvTranspose2d(64, 32, kernel_size=2, stride=2)
-
- self.conv_up1 = triple_conv(32+32, 32)
- self.conv_up2 = triple_conv(64+64, 64)
- self.conv_up3 = triple_conv(128+128, 128)
- self.conv_up4 = triple_conv(256+256, 256)
- self.conv_up5 = double_conv(512+512, 512)
-
- # attention
- self.attention = LambdaNetAttention(dim=128)
-
- self.conv_last1 = nn.Conv2d(32, 6, 3,1,1)
- self.conv_last2 = nn.Conv2d(38, 32, 3,1,1)
- self.conv_last3 = nn.Conv2d(32, 12, 3,1,1)
- self.conv_last4 = nn.Conv2d(44, 32, 3,1,1)
- self.conv_last5 = nn.Conv2d(32, out_ch, 1)
- self.act = nn.ReLU()
-
- def forward(self, x, input_mask=None):
- if input_mask == None:
- input_mask = torch.zeros((1,28,256,310)).cuda()
- x = x/28*2
- x = self.conv_in(torch.cat([x.unsqueeze(1), input_mask], dim=1))
- b, c, h_inp, w_inp = x.shape
- hb, wb = 32, 32
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- res0 = x
- conv1 = self.conv_down1(x)
- x = self.maxpool(conv1)
- conv2 = self.conv_down2(x)
- x = self.maxpool(conv2)
- conv3 = self.conv_down3(x)
- x = self.maxpool(conv3)
- conv4 = self.conv_down4(x)
- x = self.maxpool(conv4)
- conv5 = self.conv_down5(x)
- x = self.maxpool(conv5)
- conv6 = self.conv_down6(x)
-
- x = self.upsample5(conv6)
- x = torch.cat([x, conv5], dim=1)
- x = self.conv_up5(x)
-
- x = self.upsample4(x)
- x = torch.cat([x, conv4], dim=1)
- x = self.conv_up4(x)
-
- x = self.upsample3(x)
- x = torch.cat([x, conv3], dim=1)
- x = self.conv_up3(x)
- x = self.attention(x)
-
- x = self.upsample2(x)
- x = torch.cat([x, conv2], dim=1)
- x = self.conv_up2(x)
-
- x = self.upsample1(x)
- x = torch.cat([x, conv1], dim=1)
- x = self.conv_up1(x)
-
- res1 = x
- out1 = self.act(self.conv_last1(x))
- x = self.conv_last2(torch.cat([res1,out1],dim=1))
-
- res2 = x
- out2 = self.act(self.conv_last3(x))
- out3 = self.conv_last4(torch.cat([res2, out2], dim=1))
-
- out = self.conv_last5(out3)+res0
- out = out[:, :, :h_inp, :w_inp]
-
- return shift_back_3d(out)[:, :, :, :256]
diff --git a/MST/simulation/train_code/architecture/MST.py b/MST/simulation/train_code/architecture/MST.py
deleted file mode 100755
index 3686dfc..0000000
--- a/MST/simulation/train_code/architecture/MST.py
+++ /dev/null
@@ -1,311 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MaskGuidedMechanism(nn.Module):
- def __init__(
- self, n_feat):
- super(MaskGuidedMechanism, self).__init__()
-
- self.conv1 = nn.Conv2d(n_feat, n_feat, kernel_size=1, bias=True)
- self.conv2 = nn.Conv2d(n_feat, n_feat, kernel_size=1, bias=True)
- self.depth_conv = nn.Conv2d(n_feat, n_feat, kernel_size=5, padding=2, bias=True, groups=n_feat)
-
- def forward(self, mask_shift):
- # x: b,c,h,w
- [bs, nC, row, col] = mask_shift.shape
- mask_shift = self.conv1(mask_shift)
- attn_map = torch.sigmoid(self.depth_conv(self.conv2(mask_shift)))
- res = mask_shift * attn_map
- mask_shift = res + mask_shift
- mask_emb = shift_back(mask_shift)
- return mask_emb
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.mm = MaskGuidedMechanism(dim)
- self.dim = dim
-
- def forward(self, x_in, mask=None):
- """
- x_in: [b,h,w,c]
- mask: [1,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- mask_attn = self.mm(mask.permute(0,3,1,2)).permute(0,2,3,1)
- if b != 0:
- mask_attn = (mask_attn[0, :, :, :]).expand([b, h, w, c])
- q, k, v, mask_attn = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp, mask_attn.flatten(1, 2)))
- v = v * mask_attn
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head=64,
- heads=8,
- num_blocks=2,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x, mask):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x, mask=mask.permute(0, 2, 3, 1)) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-
-class MST(nn.Module):
- def __init__(self, dim=28, stage=3, num_blocks=[2,2,2]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(28, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False)
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, 28, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
-
- def forward(self, x, mask=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if mask == None:
- mask = torch.zeros((1,28,256,310)).cuda()
-
- # Embedding
- fea = self.lrelu(self.embedding(x))
-
- # Encoder
- fea_encoder = []
- masks = []
- for (MSAB, FeaDownSample, MaskDownSample) in self.encoder_layers:
- fea = MSAB(fea, mask)
- masks.append(mask)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
- mask = MaskDownSample(mask)
-
- # Bottleneck
- fea = self.bottleneck(fea, mask)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- mask = masks[self.stage - 1 - i]
- fea = LeWinBlcok(fea, mask)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/train_code/architecture/MST_Plus_Plus.py b/MST/simulation/train_code/architecture/MST_Plus_Plus.py
deleted file mode 100755
index a5bdc8a..0000000
--- a/MST/simulation/train_code/architecture/MST_Plus_Plus.py
+++ /dev/null
@@ -1,321 +0,0 @@
-import torch.nn as nn
-import torch
-import torch.nn.functional as F
-from einops import rearrange
-import math
-import warnings
-from torch.nn.init import _calculate_fan_in_and_fan_out
-
-def _no_grad_trunc_normal_(tensor, mean, std, a, b):
- def norm_cdf(x):
- return (1. + math.erf(x / math.sqrt(2.))) / 2.
-
- if (mean < a - 2 * std) or (mean > b + 2 * std):
- warnings.warn("mean is more than 2 std from [a, b] in nn.init.trunc_normal_. "
- "The distribution of values may be incorrect.",
- stacklevel=2)
- with torch.no_grad():
- l = norm_cdf((a - mean) / std)
- u = norm_cdf((b - mean) / std)
- tensor.uniform_(2 * l - 1, 2 * u - 1)
- tensor.erfinv_()
- tensor.mul_(std * math.sqrt(2.))
- tensor.add_(mean)
- tensor.clamp_(min=a, max=b)
- return tensor
-
-
-def trunc_normal_(tensor, mean=0., std=1., a=-2., b=2.):
- # type: (Tensor, float, float, float, float) -> Tensor
- return _no_grad_trunc_normal_(tensor, mean, std, a, b)
-
-
-def variance_scaling_(tensor, scale=1.0, mode='fan_in', distribution='normal'):
- fan_in, fan_out = _calculate_fan_in_and_fan_out(tensor)
- if mode == 'fan_in':
- denom = fan_in
- elif mode == 'fan_out':
- denom = fan_out
- elif mode == 'fan_avg':
- denom = (fan_in + fan_out) / 2
- variance = scale / denom
- if distribution == "truncated_normal":
- trunc_normal_(tensor, std=math.sqrt(variance) / .87962566103423978)
- elif distribution == "normal":
- tensor.normal_(std=math.sqrt(variance))
- elif distribution == "uniform":
- bound = math.sqrt(3 * variance)
- tensor.uniform_(-bound, bound)
- else:
- raise ValueError(f"invalid distribution {distribution}")
-
-
-def lecun_normal_(tensor):
- variance_scaling_(tensor, mode='fan_in', distribution='truncated_normal')
-
-
-class PreNorm(nn.Module):
- def __init__(self, dim, fn):
- super().__init__()
- self.fn = fn
- self.norm = nn.LayerNorm(dim)
-
- def forward(self, x, *args, **kwargs):
- x = self.norm(x)
- return self.fn(x, *args, **kwargs)
-
-
-class GELU(nn.Module):
- def forward(self, x):
- return F.gelu(x)
-
-def conv(in_channels, out_channels, kernel_size, bias=False, padding = 1, stride = 1):
- return nn.Conv2d(
- in_channels, out_channels, kernel_size,
- padding=(kernel_size//2), bias=bias, stride=stride)
-
-
-def shift_back(inputs,step=2): # input [bs,28,256,310] output [bs, 28, 256, 256]
- [bs, nC, row, col] = inputs.shape
- down_sample = 256//row
- step = float(step)/float(down_sample*down_sample)
- out_col = row
- for i in range(nC):
- inputs[:,i,:,:out_col] = \
- inputs[:,i,:,int(step*i):int(step*i)+out_col]
- return inputs[:, :, :, :out_col]
-
-class MS_MSA(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- ):
- super().__init__()
- self.num_heads = heads
- self.dim_head = dim_head
- self.to_q = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_k = nn.Linear(dim, dim_head * heads, bias=False)
- self.to_v = nn.Linear(dim, dim_head * heads, bias=False)
- self.rescale = nn.Parameter(torch.ones(heads, 1, 1))
- self.proj = nn.Linear(dim_head * heads, dim, bias=True)
- self.pos_emb = nn.Sequential(
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- GELU(),
- nn.Conv2d(dim, dim, 3, 1, 1, bias=False, groups=dim),
- )
- self.dim = dim
-
- def forward(self, x_in):
- """
- x_in: [b,h,w,c]
- return out: [b,h,w,c]
- """
- b, h, w, c = x_in.shape
- x = x_in.reshape(b,h*w,c)
- q_inp = self.to_q(x)
- k_inp = self.to_k(x)
- v_inp = self.to_v(x)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> b h n d', h=self.num_heads),
- (q_inp, k_inp, v_inp))
- v = v
- # q: b,heads,hw,c
- q = q.transpose(-2, -1)
- k = k.transpose(-2, -1)
- v = v.transpose(-2, -1)
- q = F.normalize(q, dim=-1, p=2)
- k = F.normalize(k, dim=-1, p=2)
- attn = (k @ q.transpose(-2, -1)) # A = K^T*Q
- attn = attn * self.rescale
- attn = attn.softmax(dim=-1)
- x = attn @ v # b,heads,d,hw
- x = x.permute(0, 3, 1, 2) # Transpose
- x = x.reshape(b, h * w, self.num_heads * self.dim_head)
- out_c = self.proj(x).view(b, h, w, c)
- out_p = self.pos_emb(v_inp.reshape(b,h,w,c).permute(0, 3, 1, 2)).permute(0, 2, 3, 1)
- out = out_c + out_p
-
- return out
-
-class FeedForward(nn.Module):
- def __init__(self, dim, mult=4):
- super().__init__()
- self.net = nn.Sequential(
- nn.Conv2d(dim, dim * mult, 1, 1, bias=False),
- GELU(),
- nn.Conv2d(dim * mult, dim * mult, 3, 1, 1, bias=False, groups=dim * mult),
- GELU(),
- nn.Conv2d(dim * mult, dim, 1, 1, bias=False),
- )
-
- def forward(self, x):
- """
- x: [b,h,w,c]
- return out: [b,h,w,c]
- """
- out = self.net(x.permute(0, 3, 1, 2))
- return out.permute(0, 2, 3, 1)
-
-class MSAB(nn.Module):
- def __init__(
- self,
- dim,
- dim_head,
- heads,
- num_blocks,
- ):
- super().__init__()
- self.blocks = nn.ModuleList([])
- for _ in range(num_blocks):
- self.blocks.append(nn.ModuleList([
- MS_MSA(dim=dim, dim_head=dim_head, heads=heads),
- PreNorm(dim, FeedForward(dim=dim))
- ]))
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out: [b,c,h,w]
- """
- x = x.permute(0, 2, 3, 1)
- for (attn, ff) in self.blocks:
- x = attn(x) + x
- x = ff(x) + x
- out = x.permute(0, 3, 1, 2)
- return out
-
-class MST(nn.Module):
- def __init__(self, in_dim=28, out_dim=28, dim=28, stage=2, num_blocks=[2,4,4]):
- super(MST, self).__init__()
- self.dim = dim
- self.stage = stage
-
- # Input projection
- self.embedding = nn.Conv2d(in_dim, self.dim, 3, 1, 1, bias=False)
-
- # Encoder
- self.encoder_layers = nn.ModuleList([])
- dim_stage = dim
- for i in range(stage):
- self.encoder_layers.append(nn.ModuleList([
- MSAB(
- dim=dim_stage, num_blocks=num_blocks[i], dim_head=dim, heads=dim_stage // dim),
- nn.Conv2d(dim_stage, dim_stage * 2, 4, 2, 1, bias=False),
- ]))
- dim_stage *= 2
-
- # Bottleneck
- self.bottleneck = MSAB(
- dim=dim_stage, dim_head=dim, heads=dim_stage // dim, num_blocks=num_blocks[-1])
-
- # Decoder
- self.decoder_layers = nn.ModuleList([])
- for i in range(stage):
- self.decoder_layers.append(nn.ModuleList([
- nn.ConvTranspose2d(dim_stage, dim_stage // 2, stride=2, kernel_size=2, padding=0, output_padding=0),
- nn.Conv2d(dim_stage, dim_stage // 2, 1, 1, bias=False),
- MSAB(
- dim=dim_stage // 2, num_blocks=num_blocks[stage - 1 - i], dim_head=dim,
- heads=(dim_stage // 2) // dim),
- ]))
- dim_stage //= 2
-
- # Output projection
- self.mapping = nn.Conv2d(self.dim, out_dim, 3, 1, 1, bias=False)
-
- #### activation function
- self.lrelu = nn.LeakyReLU(negative_slope=0.1, inplace=True)
- self.apply(self._init_weights)
-
- def _init_weights(self, m):
- if isinstance(m, nn.Linear):
- trunc_normal_(m.weight, std=.02)
- if isinstance(m, nn.Linear) and m.bias is not None:
- nn.init.constant_(m.bias, 0)
- elif isinstance(m, nn.LayerNorm):
- nn.init.constant_(m.bias, 0)
- nn.init.constant_(m.weight, 1.0)
-
- def forward(self, x):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
-
- # Embedding
- fea = self.embedding(x)
-
- # Encoder
- fea_encoder = []
- for (MSAB, FeaDownSample) in self.encoder_layers:
- fea = MSAB(fea)
- fea_encoder.append(fea)
- fea = FeaDownSample(fea)
-
- # Bottleneck
- fea = self.bottleneck(fea)
-
- # Decoder
- for i, (FeaUpSample, Fution, LeWinBlcok) in enumerate(self.decoder_layers):
- fea = FeaUpSample(fea)
- fea = Fution(torch.cat([fea, fea_encoder[self.stage-1-i]], dim=1))
- fea = LeWinBlcok(fea)
-
- # Mapping
- out = self.mapping(fea) + x
-
- return out
-
-class MST_Plus_Plus(nn.Module):
- def __init__(self, in_channels=3, out_channels=28, n_feat=28, stage=3):
- super(MST_Plus_Plus, self).__init__()
- self.stage = stage
- self.conv_in = nn.Conv2d(in_channels, n_feat, kernel_size=3, padding=(3 - 1) // 2,bias=False)
- modules_body = [MST(dim=n_feat, stage=2, num_blocks=[1,1,1]) for _ in range(stage)]
- self.fution = nn.Conv2d(56, 28, 1, padding=0, bias=True)
- self.body = nn.Sequential(*modules_body)
- self.conv_out = nn.Conv2d(n_feat, out_channels, kernel_size=3, padding=(3 - 1) // 2,bias=False)
-
- def initial_x(self, y, Phi):
- """
- :param y: [b,256,310]
- :param Phi: [b,28,256,256]
- :return: z: [b,28,256,256]
- """
- x = self.fution(torch.cat([y, Phi], dim=1))
- return x
-
- def forward(self, y, Phi=None):
- """
- x: [b,c,h,w]
- return out:[b,c,h,w]
- """
- if Phi==None:
- #Phi = torch.rand((1,28,256,256))#.cuda()
- Phi = torch.rand((1,28,256,256))
- x = self.initial_x(y, Phi)
- b, c, h_inp, w_inp = x.shape
- hb, wb = 8, 8
- pad_h = (hb - h_inp % hb) % hb
- pad_w = (wb - w_inp % wb) % wb
- x = F.pad(x, [0, pad_w, 0, pad_h], mode='reflect')
- x = self.conv_in(x)
- h = self.body(x)
- h = self.conv_out(h)
- h += x
- return h[:, :, :h_inp, :w_inp]
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/MST/simulation/train_code/architecture/TSA_Net.py b/MST/simulation/train_code/architecture/TSA_Net.py
deleted file mode 100755
index bb7a77e..0000000
--- a/MST/simulation/train_code/architecture/TSA_Net.py
+++ /dev/null
@@ -1,331 +0,0 @@
-import torch
-import torch.nn as nn
-import torch.nn.functional as F
-import numpy as np
-_NORM_BONE = False
-
-
-def conv_block(in_planes, out_planes, the_kernel=3, the_stride=1, the_padding=1, flag_norm=False, flag_norm_act=True):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=the_kernel, stride=the_stride, padding=the_padding)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_planes)
- if flag_norm:
- return nn.Sequential(conv,norm,activation) if flag_norm_act else nn.Sequential(conv,activation,norm)
- else:
- return nn.Sequential(conv,activation)
-
-def conv1x1_block(in_planes, out_planes, flag_norm=False):
- conv = nn.Conv2d(in_planes, out_planes, kernel_size=1, stride=1, padding=0,bias=False)
- norm = nn.BatchNorm2d(out_planes)
- return nn.Sequential(conv,norm) if flag_norm else conv
-
-def fully_block(in_dim, out_dim, flag_norm=False, flag_norm_act=True):
- fc = nn.Linear(in_dim, out_dim)
- activation = nn.ReLU(inplace=True)
- norm = nn.BatchNorm2d(out_dim)
- if flag_norm:
- return nn.Sequential(fc,norm,activation) if flag_norm_act else nn.Sequential(fc,activation,norm)
- else:
- return nn.Sequential(fc,activation)
-
-class Res2Net(nn.Module):
- def __init__(self, inChannel, uPlane, scale=4):
- super(Res2Net, self).__init__()
- self.uPlane = uPlane
- self.scale = scale
-
- self.conv_init = nn.Conv2d(inChannel, uPlane * scale, kernel_size=1, bias=False)
- self.bn_init = nn.BatchNorm2d(uPlane * scale)
-
- convs = []
- bns = []
- for i in range(self.scale - 1):
- convs.append(nn.Conv2d(self.uPlane, self.uPlane, kernel_size=3, stride=1, padding=1, bias=False))
- bns.append(nn.BatchNorm2d(self.uPlane))
- self.convs = nn.ModuleList(convs)
- self.bns = nn.ModuleList(bns)
-
- self.conv_end = nn.Conv2d(uPlane * scale, inChannel, kernel_size=1, bias=False)
- self.bn_end = nn.BatchNorm2d(inChannel)
-
- self.relu = nn.ReLU(inplace=True)
-
- def forward(self, x):
-
- out = self.conv_init(x)
- out = self.bn_init(out)
- out = self.relu(out)
-
- spx = torch.split(out, self.uPlane, 1)
- for i in range(self.scale - 1):
- if i == 0:
- sp = spx[i]
- else:
- sp = sp + spx[i]
- sp = self.convs[i](sp)
- sp = self.relu(self.bns[i](sp))
- if i == 0:
- out = sp
- else:
- out = torch.cat((out, sp), 1)
- out = torch.cat((out, spx[self.scale - 1]), 1)
-
- out = self.conv_end(out)
- out = self.bn_end(out)
- return out
-
-_NORM_ATTN = True
-_NORM_FC = False
-
-
-class TSA_Transform(nn.Module):
- """ Spectral-Spatial Self-Attention """
-
- def __init__(self, uSpace, inChannel, outChannel, nHead, uAttn, mode=[0, 1], flag_mask=False, gamma_learn=False):
- super(TSA_Transform, self).__init__()
- ''' ------------------------------------------
- uSpace:
- uHeight: the [-2] dim of the 3D tensor
- uWidth: the [-1] dim of the 3D tensor
- inChannel:
- the number of Channel of the input tensor
- outChannel:
- the number of Channel of the output tensor
- nHead:
- the number of Head of the input tensor
- uAttn:
- uSpatial: the dim of the spatial features
- uSpectral: the dim of the spectral features
- mask:
- The Spectral Smoothness Mask
- {mode} and {gamma_learn} is just for variable selection
- ------------------------------------------ '''
-
- self.nHead = nHead
- self.uAttn = uAttn
- self.outChannel = outChannel
- self.uSpatial = nn.Parameter(torch.tensor(float(uAttn[0])), requires_grad=False)
- self.uSpectral = nn.Parameter(torch.tensor(float(uAttn[1])), requires_grad=False)
- self.mask = nn.Parameter(Spectral_Mask(outChannel), requires_grad=False) if flag_mask else None
- self.attn_scale = nn.Parameter(torch.tensor(1.1), requires_grad=False) if flag_mask else None
- self.gamma = nn.Parameter(torch.tensor(1.0), requires_grad=gamma_learn)
-
- if sum(mode) > 0:
- down_sample = []
- scale = 1
- cur_channel = outChannel
- for i in range(sum(mode)):
- scale *= 2
- down_sample.append(conv_block(cur_channel, 2 * cur_channel, 3, 2, 1, _NORM_ATTN))
- cur_channel = 2 * cur_channel
- self.cur_channel = cur_channel
- self.down_sample = nn.Sequential(*down_sample)
- self.up_sample = nn.ConvTranspose2d(outChannel * scale, outChannel, scale, scale)
- else:
- self.down_sample = None
- self.up_sample = None
-
- spec_dim = int(uSpace[0] / 4 - 3) * int(uSpace[1] / 4 - 3)
- self.preproc = conv1x1_block(inChannel, outChannel, _NORM_ATTN)
- self.query_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.query_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.query_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.key_x = Feature_Spatial(outChannel, nHead, int(uSpace[1] / 4), uAttn[0], mode)
- self.key_y = Feature_Spatial(outChannel, nHead, int(uSpace[0] / 4), uAttn[0], mode)
- self.key_lambda = Feature_Spectral(outChannel, nHead, spec_dim, uAttn[1])
- self.value = conv1x1_block(outChannel, nHead * outChannel, _NORM_ATTN)
- self.aggregation = nn.Linear(nHead * outChannel, outChannel)
-
- def forward(self, image):
- feat = self.preproc(image)
- feat_qx = self.query_x(feat, 'X')
- feat_qy = self.query_y(feat, 'Y')
- feat_qlambda = self.query_lambda(feat)
- feat_kx = self.key_x(feat, 'X')
- feat_ky = self.key_y(feat, 'Y')
- feat_klambda = self.key_lambda(feat)
- feat_value = self.value(feat)
-
- feat_qx = torch.cat(torch.split(feat_qx, 1, dim=1)).squeeze(dim=1)
- feat_qy = torch.cat(torch.split(feat_qy, 1, dim=1)).squeeze(dim=1)
- feat_kx = torch.cat(torch.split(feat_kx, 1, dim=1)).squeeze(dim=1)
- feat_ky = torch.cat(torch.split(feat_ky, 1, dim=1)).squeeze(dim=1)
- feat_qlambda = torch.cat(torch.split(feat_qlambda, self.uAttn[1], dim=-1))
- feat_klambda = torch.cat(torch.split(feat_klambda, self.uAttn[1], dim=-1))
- feat_value = torch.cat(torch.split(feat_value, self.outChannel, dim=1))
-
- energy_x = torch.bmm(feat_qx, feat_kx.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_y = torch.bmm(feat_qy, feat_ky.permute(0, 2, 1)) / torch.sqrt(self.uSpatial)
- energy_lambda = torch.bmm(feat_qlambda, feat_klambda.permute(0, 2, 1)) / torch.sqrt(self.uSpectral)
-
- attn_x = F.softmax(energy_x, dim=-1)
- attn_y = F.softmax(energy_y, dim=-1)
- attn_lambda = F.softmax(energy_lambda, dim=-1)
- if self.mask is not None:
- attn_lambda = (attn_lambda + self.mask) / torch.sqrt(self.attn_scale)
-
- pro_feat = feat_value if self.down_sample is None else self.down_sample(feat_value)
- batchhead, dim_c, dim_x, dim_y = pro_feat.size()
- attn_x_repeat = attn_x.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_x, dim_x)
- attn_y_repeat = attn_y.unsqueeze(dim=1).repeat(1, dim_c, 1, 1).view(-1, dim_y, dim_y)
- pro_feat = pro_feat.view(-1, dim_x, dim_y)
- pro_feat = torch.bmm(pro_feat, attn_y_repeat.permute(0, 2, 1))
- pro_feat = torch.bmm(pro_feat.permute(0, 2, 1), attn_x_repeat.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, dim_c, dim_x, dim_y)
-
- if self.up_sample is not None:
- pro_feat = self.up_sample(pro_feat)
- _, _, dim_x, dim_y = pro_feat.size()
- pro_feat = pro_feat.contiguous().view(batchhead, self.outChannel, -1).permute(0, 2, 1)
- pro_feat = torch.bmm(pro_feat, attn_lambda.permute(0, 2, 1)).permute(0, 2, 1)
- pro_feat = pro_feat.view(batchhead, self.outChannel, dim_x, dim_y)
- pro_feat = torch.cat(torch.split(pro_feat, int(batchhead / self.nHead), dim=0), dim=1).permute(0, 2, 3, 1)
- pro_feat = self.aggregation(pro_feat).permute(0, 3, 1, 2)
- out = self.gamma * pro_feat + feat
- return out, (attn_x, attn_y, attn_lambda)
-
-
-class Feature_Spatial(nn.Module):
- """ Spatial Feature Generation Component """
-
- def __init__(self, inChannel, nHead, shiftDim, outDim, mode):
- super(Feature_Spatial, self).__init__()
- kernel = [(1, 5), (3, 5)]
- stride = [(1, 2), (2, 2)]
- padding = [(0, 2), (1, 2)]
- self.conv1 = conv_block(inChannel, nHead, kernel[mode[0]], stride[mode[0]], padding[mode[0]], _NORM_ATTN)
- self.conv2 = conv_block(nHead, nHead, kernel[mode[1]], stride[mode[1]], padding[mode[1]], _NORM_ATTN)
- self.fully = fully_block(shiftDim, outDim, _NORM_FC)
-
- def forward(self, image, direction):
- if direction == 'Y':
- image = image.permute(0, 1, 3, 2)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = self.fully(feat)
- return feat
-
-
-class Feature_Spectral(nn.Module):
- """ Spectral Feature Generation Component """
-
- def __init__(self, inChannel, nHead, viewDim, outDim):
- super(Feature_Spectral, self).__init__()
- self.inChannel = inChannel
- self.conv1 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.conv2 = conv_block(inChannel, inChannel, 5, 2, 0, _NORM_ATTN)
- self.fully = fully_block(viewDim, int(nHead * outDim), _NORM_FC)
-
- def forward(self, image):
- bs = image.size(0)
- feat = self.conv1(image)
- feat = self.conv2(feat)
- feat = feat.view(bs, self.inChannel, -1)
- feat = self.fully(feat)
- return feat
-
-
-def Spectral_Mask(dim_lambda):
- '''After put the available data into the model, we use this mask to avoid outputting the estimation of itself.'''
- orig = (np.cos(np.linspace(-1, 1, num=2 * dim_lambda - 1) * np.pi) + 1.0) / 2.0
- att = np.zeros((dim_lambda, dim_lambda))
- for i in range(dim_lambda):
- att[i, :] = orig[dim_lambda - 1 - i:2 * dim_lambda - 1 - i]
- AM_Mask = torch.from_numpy(att.astype(np.float32)).unsqueeze(0)
- return AM_Mask
-
-class TSA_Net(nn.Module):
-
- def __init__(self, in_ch=28, out_ch=28):
- super(TSA_Net, self).__init__()
-
- self.tconv_down1 = Encoder_Triblock(in_ch, 64, False)
- self.tconv_down2 = Encoder_Triblock(64, 128, False)
- self.tconv_down3 = Encoder_Triblock(128, 256)
- self.tconv_down4 = Encoder_Triblock(256, 512)
-
- self.bottom1 = conv_block(512, 1024)
- self.bottom2 = conv_block(1024, 1024)
-
- self.tconv_up4 = Decoder_Triblock(1024, 512)
- self.tconv_up3 = Decoder_Triblock(512, 256)
- self.transform3 = TSA_Transform((64, 64), 256, 256, 8, (64, 80), [0, 0])
- self.tconv_up2 = Decoder_Triblock(256, 128)
- self.transform2 = TSA_Transform((128, 128), 128, 128, 8, (64, 40), [1, 0])
- self.tconv_up1 = Decoder_Triblock(128, 64)
- self.transform1 = TSA_Transform((256, 256), 64, 28, 8, (48, 30), [1, 1], True)
-
- self.conv_last = nn.Conv2d(out_ch, out_ch, 1)
- self.afn_last = nn.Sigmoid()
-
- def forward(self, x, input_mask=None):
-
- enc1, enc1_pre = self.tconv_down1(x)
- enc2, enc2_pre = self.tconv_down2(enc1)
- enc3, enc3_pre = self.tconv_down3(enc2)
- enc4, enc4_pre = self.tconv_down4(enc3)
- # enc5,enc5_pre = self.tconv_down5(enc4)
-
- bottom = self.bottom1(enc4)
- bottom = self.bottom2(bottom)
-
- # dec5 = self.tconv_up5(bottom,enc5_pre)
- dec4 = self.tconv_up4(bottom, enc4_pre)
- dec3 = self.tconv_up3(dec4, enc3_pre)
- dec3, _ = self.transform3(dec3)
- dec2 = self.tconv_up2(dec3, enc2_pre)
- dec2, _ = self.transform2(dec2)
- dec1 = self.tconv_up1(dec2, enc1_pre)
- dec1, _ = self.transform1(dec1)
-
- dec1 = self.conv_last(dec1)
- output = self.afn_last(dec1)
-
- return output
-
-
-class Encoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Encoder_Triblock, self).__init__()
-
- self.layer1 = conv_block(inChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
- if flag_res:
- self.layer2 = Res2Net(outChannel, int(outChannel / 4))
- else:
- self.layer2 = conv_block(outChannel, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- self.pool = nn.MaxPool2d(nPool) if flag_Pool else None
-
- def forward(self, x):
- feat = self.layer1(x)
- feat = self.layer2(feat)
-
- feat_pool = self.pool(feat) if self.pool is not None else feat
- return feat_pool, feat
-
-
-class Decoder_Triblock(nn.Module):
- def __init__(self, inChannel, outChannel, flag_res=True, nKernal=3, nPool=2, flag_Pool=True):
- super(Decoder_Triblock, self).__init__()
-
- self.layer1 = nn.Sequential(
- nn.ConvTranspose2d(inChannel, outChannel, kernel_size=2, stride=2),
- nn.ReLU(inplace=True)
- )
- if flag_res:
- self.layer2 = Res2Net(int(outChannel * 2), int(outChannel / 2))
- else:
- self.layer2 = conv_block(outChannel * 2, outChannel * 2, nKernal, flag_norm=_NORM_BONE)
- self.layer3 = conv_block(outChannel * 2, outChannel, nKernal, flag_norm=_NORM_BONE)
-
- def forward(self, feat_dec, feat_enc):
- feat_dec = self.layer1(feat_dec)
- diffY = feat_enc.size()[2] - feat_dec.size()[2]
- diffX = feat_enc.size()[3] - feat_dec.size()[3]
- if diffY != 0 or diffX != 0:
- print('Padding for size mismatch ( Enc:', feat_enc.size(), 'Dec:', feat_dec.size(), ')')
- feat_dec = F.pad(feat_dec, [diffX // 2, diffX - diffX // 2, diffY // 2, diffY - diffY // 2])
- feat = torch.cat([feat_dec, feat_enc], dim=1)
- feat = self.layer2(feat)
- feat = self.layer3(feat)
- return feat
\ No newline at end of file
diff --git a/MST/simulation/train_code/architecture/__init__.py b/MST/simulation/train_code/architecture/__init__.py
deleted file mode 100755
index 3fa9eb2..0000000
--- a/MST/simulation/train_code/architecture/__init__.py
+++ /dev/null
@@ -1,67 +0,0 @@
-import torch
-from .MST import MST
-from .GAP_Net import GAP_net
-from .ADMM_Net import ADMM_net
-from .TSA_Net import TSA_Net
-from .HDNet import HDNet, FDL
-from .DGSMP import HSI_CS
-from .BIRNAT import BIRNAT
-from .MST_Plus_Plus import MST_Plus_Plus
-from .Lambda_Net import Lambda_Net
-from .CST import CST
-from .DAUHST import DAUHST
-from .BiSRNet import BiSRNet
-
-def model_generator(method, pretrained_model_path=None):
- if method == 'mst_s':
- model = MST(dim=28, stage=2, num_blocks=[2, 2, 2]).cuda()
- elif method == 'mst_m':
- model = MST(dim=28, stage=2, num_blocks=[2, 4, 4]).cuda()
- elif method == 'mst_l':
- model = MST(dim=28, stage=2, num_blocks=[4, 7, 5]).cuda()
- elif method == 'gap_net':
- model = GAP_net().cuda()
- elif method == 'admm_net':
- model = ADMM_net().cuda()
- elif method == 'tsa_net':
- model = TSA_Net().cuda()
- elif method == 'hdnet':
- model = HDNet().cuda()
- fdl_loss = FDL(loss_weight=0.7,
- alpha=2.0,
- patch_factor=4,
- ave_spectrum=True,
- log_matrix=True,
- batch_matrix=True,
- ).cuda()
- elif method == 'dgsmp':
- model = HSI_CS(Ch=28, stages=4).cuda()
- elif method == 'birnat':
- model = BIRNAT().cuda()
- elif method == 'mst_plus_plus':
- model = MST_Plus_Plus(in_channels=28, out_channels=28, n_feat=28, stage=3)
- elif method == 'lambda_net':
- model = Lambda_Net(out_ch=28).cuda()
- elif method == 'cst_s':
- model = CST(num_blocks=[1, 1, 2], sparse=True).cuda()
- elif method == 'cst_m':
- model = CST(num_blocks=[2, 2, 2], sparse=True).cuda()
- elif method == 'cst_l':
- model = CST(num_blocks=[2, 4, 6], sparse=True).cuda()
- elif method == 'cst_l_plus':
- model = CST(num_blocks=[2, 4, 6], sparse=False).cuda()
- elif 'dauhst' in method:
- num_iterations = int(method.split('_')[1][0])
- model = DAUHST(num_iterations=num_iterations).cuda()
- elif method == 'bisrnet':
- model = BiSRNet(in_channels=28, out_channels=28, n_feat=28, stage=1, num_blocks=[1,1,1]).cuda()
- else:
- print(f'Method {method} is not defined !!!!')
- if pretrained_model_path is not None:
- print(f'load model from {pretrained_model_path}')
- checkpoint = torch.load(pretrained_model_path)
- model.load_state_dict({k.replace('module.', ''): v for k, v in checkpoint.items()},
- strict=False)
- if method == 'hdnet':
- return model,fdl_loss
- return model
\ No newline at end of file
diff --git a/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc
deleted file mode 100755
index 7823a54..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc
deleted file mode 100644
index 9606853..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/ADMM_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc
deleted file mode 100755
index 8f8a96c..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-39.pyc
deleted file mode 100644
index 39ac929..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/BIRNAT.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/BiSRNet.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/BiSRNet.cpython-39.pyc
deleted file mode 100644
index 2a3be85..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/BiSRNet.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/CST.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/CST.cpython-36.pyc
deleted file mode 100755
index abb638b..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/CST.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/CST.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/CST.cpython-39.pyc
deleted file mode 100644
index d4e2492..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/CST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/DAUHST.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/DAUHST.cpython-39.pyc
deleted file mode 100644
index ecee790..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/DAUHST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc
deleted file mode 100755
index 162adcd..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-39.pyc
deleted file mode 100644
index b5ae100..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/DGSMP.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc
deleted file mode 100755
index 70cb319..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-39.pyc
deleted file mode 100644
index bd2d0a6..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/GAP_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-36.pyc
deleted file mode 100755
index 9fdc498..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-39.pyc
deleted file mode 100644
index 8e22f70..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/HDNet.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc
deleted file mode 100755
index 32b5ca1..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc
deleted file mode 100644
index 0fad479..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/Lambda_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/MST.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/MST.cpython-36.pyc
deleted file mode 100755
index 13ac392..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/MST.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/MST.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/MST.cpython-39.pyc
deleted file mode 100644
index 4319526..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/MST.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc
deleted file mode 100755
index 0db28c5..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc
deleted file mode 100644
index f1bbc1f..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/MST_Plus_Plus.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc
deleted file mode 100755
index 0a3f58c..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-39.pyc
deleted file mode 100644
index aacff40..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/TSA_Net.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-36.pyc b/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-36.pyc
deleted file mode 100755
index 5f56441..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-36.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-39.pyc b/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-39.pyc
deleted file mode 100644
index e821b7c..0000000
Binary files a/MST/simulation/train_code/architecture/__pycache__/__init__.cpython-39.pyc and /dev/null differ
diff --git a/MST/simulation/train_code/option.py b/MST/simulation/train_code/option.py
deleted file mode 100755
index 20c36e1..0000000
--- a/MST/simulation/train_code/option.py
+++ /dev/null
@@ -1,46 +0,0 @@
-import argparse
-import template
-
-parser = argparse.ArgumentParser(description="HyperSpectral Image Reconstruction Toolbox")
-parser.add_argument('--template', default='mst',
- help='You can set various templates in option.py')
-
-# Hardware specifications
-parser.add_argument("--gpu_id", type=str, default='0')
-
-# Data specifications
-parser.add_argument('--data_root', type=str, default='../../datasets/', help='dataset directory')
-
-# Saving specifications
-parser.add_argument('--outf', type=str, default='./exp/mst_s/', help='saving_path')
-
-# Model specifications
-parser.add_argument('--method', type=str, default='mst_s', help='method name')
-parser.add_argument('--pretrained_model_path', type=str, default=None, help='pretrained model directory')
-parser.add_argument("--input_setting", type=str, default='H',
- help='the input measurement of the network: H, HM or Y')
-parser.add_argument("--input_mask", type=str, default='Phi',
- help='the input mask of the network: Phi, Phi_PhiPhiT, Mask or None') # Phi: shift_mask Mask: mask
-
-# Training specifications
-parser.add_argument('--batch_size', type=int, default=5, help='the number of HSIs per batch')
-parser.add_argument("--max_epoch", type=int, default=300, help='total epoch')
-parser.add_argument("--scheduler", type=str, default='MultiStepLR', help='MultiStepLR or CosineAnnealingLR')
-parser.add_argument("--milestones", type=int, default=[50,100,150,200,250], help='milestones for MultiStepLR')
-parser.add_argument("--gamma", type=float, default=0.5, help='learning rate decay for MultiStepLR')
-parser.add_argument("--epoch_sam_num", type=int, default=5000, help='the number of samples per epoch')
-parser.add_argument("--learning_rate", type=float, default=0.0004)
-
-opt = parser.parse_args()
-template.set_template(opt)
-
-# dataset
-opt.data_path = f"{opt.data_root}/cave_1024_28/"
-opt.mask_path = f"{opt.data_root}/TSA_simu_data/"
-opt.test_path = f"{opt.data_root}/TSA_simu_data/Truth/"
-
-for arg in vars(opt):
- if vars(opt)[arg] == 'True':
- vars(opt)[arg] = True
- elif vars(opt)[arg] == 'False':
- vars(opt)[arg] = False
\ No newline at end of file
diff --git a/MST/simulation/train_code/ssim_torch.py b/MST/simulation/train_code/ssim_torch.py
deleted file mode 100755
index 0787fa2..0000000
--- a/MST/simulation/train_code/ssim_torch.py
+++ /dev/null
@@ -1,77 +0,0 @@
-import torch
-import torch.nn.functional as F
-from torch.autograd import Variable
-import numpy as np
-from math import exp
-
-
-def gaussian(window_size, sigma):
- gauss = torch.Tensor([exp(-(x - window_size // 2) ** 2 / float(2 * sigma ** 2)) for x in range(window_size)])
- return gauss / gauss.sum()
-
-
-def create_window(window_size, channel):
- _1D_window = gaussian(window_size, 1.5).unsqueeze(1)
- _2D_window = _1D_window.mm(_1D_window.t()).float().unsqueeze(0).unsqueeze(0)
- window = Variable(_2D_window.expand(channel, 1, window_size, window_size).contiguous())
- return window
-
-
-def _ssim(img1, img2, window, window_size, channel, size_average=True):
- mu1 = F.conv2d(img1, window, padding=window_size // 2, groups=channel)
- mu2 = F.conv2d(img2, window, padding=window_size // 2, groups=channel)
-
- mu1_sq = mu1.pow(2)
- mu2_sq = mu2.pow(2)
- mu1_mu2 = mu1 * mu2
-
- sigma1_sq = F.conv2d(img1 * img1, window, padding=window_size // 2, groups=channel) - mu1_sq
- sigma2_sq = F.conv2d(img2 * img2, window, padding=window_size // 2, groups=channel) - mu2_sq
- sigma12 = F.conv2d(img1 * img2, window, padding=window_size // 2, groups=channel) - mu1_mu2
-
- C1 = 0.01 ** 2
- C2 = 0.03 ** 2
-
- ssim_map = ((2 * mu1_mu2 + C1) * (2 * sigma12 + C2)) / ((mu1_sq + mu2_sq + C1) * (sigma1_sq + sigma2_sq + C2))
-
- if size_average:
- return ssim_map.mean()
- else:
- return ssim_map.mean(1).mean(1).mean(1)
-
-
-class SSIM(torch.nn.Module):
- def __init__(self, window_size=11, size_average=True):
- super(SSIM, self).__init__()
- self.window_size = window_size
- self.size_average = size_average
- self.channel = 1
- self.window = create_window(window_size, self.channel)
-
- def forward(self, img1, img2):
- (_, channel, _, _) = img1.size()
-
- if channel == self.channel and self.window.data.type() == img1.data.type():
- window = self.window
- else:
- window = create_window(self.window_size, channel)
-
- if img1.is_cuda:
- window = window.cuda(img1.get_device())
- window = window.type_as(img1)
-
- self.window = window
- self.channel = channel
-
- return _ssim(img1, img2, window, self.window_size, channel, self.size_average)
-
-
-def ssim(img1, img2, window_size=11, size_average=True):
- (_, channel, _, _) = img1.size()
- window = create_window(window_size, channel)
-
- if img1.is_cuda:
- window = window.cuda(img1.get_device())
- window = window.type_as(img1)
-
- return _ssim(img1, img2, window, window_size, channel, size_average)
diff --git a/MST/simulation/train_code/template.py b/MST/simulation/train_code/template.py
deleted file mode 100755
index 6104ef2..0000000
--- a/MST/simulation/train_code/template.py
+++ /dev/null
@@ -1,71 +0,0 @@
-def set_template(args):
- # Set the templates here
- if args.template.find('mst') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Phi'
-
- if args.template.find('gap_net') >= 0 or args.template.find('admm_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.milestones = range(30,args.max_epoch,30)
- args.gamma = 0.9
- args.learning_rate = 1e-3
-
- if args.template.find('dauhst') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.scheduler = 'CosineAnnealingLR'
- args.max_epoch = 300
-
- if args.template.find('tsa_net') >= 0:
- args.input_setting = 'HM'
- args.input_mask = None
-
- if args.template.find('hdnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = None
-
- if args.template.find('dgsmp') >= 0:
- args.input_setting = 'Y'
- args.input_mask = None
- args.batch_size = 2
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1e-4
-
- if args.template.find('birnat') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.batch_size = 1
- args.max_epoch = 100
- args.milestones = [args.max_epoch] # fix the learning rate during training, following the official implementation
- args.learning_rate = 1.5e-4
-
- if args.template.find('mst_plus_plus') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
- args.scheduler = 'CosineAnnealingLR'
-
- if args.template.find('bisrnet') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
- args.scheduler = 'CosineAnnealingLR'
-
- if args.template.find('cst') >= 0:
- args.input_setting = 'H'
- args.input_mask = 'Mask'
- args.scheduler = 'CosineAnnealingLR'
- args.max_epoch = 500
-
- if args.template.find('dnu') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi_PhiPhiT'
- args.batch_size = 2
- args.max_epoch = 150
- args.milestones = range(10,args.max_epoch,10)
- args.gamma = 0.9
- args.learning_rate = 4e-4
-
- if args.template.find('lambda_net') >= 0:
- args.input_setting = 'Y'
- args.input_mask = 'Phi'
- args.learning_rate = 1.5e-4
\ No newline at end of file
diff --git a/MST/simulation/train_code/train.py b/MST/simulation/train_code/train.py
deleted file mode 100755
index 3f27c59..0000000
--- a/MST/simulation/train_code/train.py
+++ /dev/null
@@ -1,130 +0,0 @@
-from architecture import *
-from utils import *
-import torch
-import scipy.io as scio
-import time
-import os
-import numpy as np
-from torch.autograd import Variable
-import datetime
-from option import opt
-import torch.nn.functional as F
-
-os.environ["CUDA_DEVICE_ORDER"] = 'PCI_BUS_ID'
-os.environ["CUDA_VISIBLE_DEVICES"] = opt.gpu_id
-torch.backends.cudnn.enabled = True
-torch.backends.cudnn.benchmark = True
-if not torch.cuda.is_available():
- raise Exception('NO GPU!')
-
-# init mask
-mask3d_batch_train, input_mask_train = init_mask(opt.mask_path, opt.input_mask, opt.batch_size)
-mask3d_batch_test, input_mask_test = init_mask(opt.mask_path, opt.input_mask, 10)
-
-# dataset
-train_set = LoadTraining(opt.data_path)
-test_data = LoadTest(opt.test_path)
-
-# saving path
-date_time = str(datetime.datetime.now())
-date_time = time2file_name(date_time)
-result_path = opt.outf + date_time + '/result/'
-model_path = opt.outf + date_time + '/model/'
-if not os.path.exists(result_path):
- os.makedirs(result_path)
-if not os.path.exists(model_path):
- os.makedirs(model_path)
-
-# model
-if opt.method=='hdnet':
- model, FDL_loss = model_generator(opt.method, opt.pretrained_model_path).cuda()
-else:
- model = model_generator(opt.method, opt.pretrained_model_path).cuda()
-
-# optimizing
-optimizer = torch.optim.Adam(model.parameters(), lr=opt.learning_rate, betas=(0.9, 0.999))
-if opt.scheduler=='MultiStepLR':
- scheduler = torch.optim.lr_scheduler.MultiStepLR(optimizer, milestones=opt.milestones, gamma=opt.gamma)
-elif opt.scheduler=='CosineAnnealingLR':
- scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, opt.max_epoch, eta_min=1e-6)
-mse = torch.nn.MSELoss().cuda()
-
-def train(epoch, logger):
- epoch_loss = 0
- begin = time.time()
- batch_num = int(np.floor(opt.epoch_sam_num / opt.batch_size))
- for i in range(batch_num):
- gt_batch = shuffle_crop(train_set, opt.batch_size)
- gt = Variable(gt_batch).cuda().float()
- input_meas = init_meas(gt, mask3d_batch_train, opt.input_setting)
- optimizer.zero_grad()
-
- if opt.method in ['cst_s', 'cst_m', 'cst_l']:
- model_out, diff_pred = model(input_meas, input_mask_train)
- loss = torch.sqrt(mse(model_out, gt))
- diff_gt = torch.mean(torch.abs(model_out.detach() - gt),dim=1, keepdim=True) # [b,1,h,w]
- loss_sparsity = F.mse_loss(diff_gt, diff_pred)
- loss = loss + 2 * loss_sparsity
- else:
- model_out = model(input_meas, input_mask_train)
- loss = torch.sqrt(mse(model_out, gt))
-
- if opt.method=='hdnet':
- fdl_loss = FDL_loss(model_out, gt)
- loss = loss + 0.7 * fdl_loss
- epoch_loss += loss.data
- loss.backward()
- optimizer.step()
- end = time.time()
- logger.info("===> Epoch {} Complete: Avg. Loss: {:.6f} time: {:.2f}".
- format(epoch, epoch_loss / batch_num, (end - begin)))
- return 0
-
-def test(epoch, logger):
- psnr_list, ssim_list = [], []
- test_gt = test_data.cuda().float()
- input_meas = init_meas(test_gt, mask3d_batch_test, opt.input_setting)
- model.eval()
- begin = time.time()
- with torch.no_grad():
- if opt.method in ['cst_s', 'cst_m', 'cst_l']:
- model_out, _ = model(input_meas, input_mask_test)
- else:
- model_out = model(input_meas, input_mask_test)
-
- end = time.time()
- for k in range(test_gt.shape[0]):
- psnr_val = torch_psnr(model_out[k, :, :, :], test_gt[k, :, :, :])
- ssim_val = torch_ssim(model_out[k, :, :, :], test_gt[k, :, :, :])
- psnr_list.append(psnr_val.detach().cpu().numpy())
- ssim_list.append(ssim_val.detach().cpu().numpy())
- pred = np.transpose(model_out.detach().cpu().numpy(), (0, 2, 3, 1)).astype(np.float32)
- truth = np.transpose(test_gt.cpu().numpy(), (0, 2, 3, 1)).astype(np.float32)
- psnr_mean = np.mean(np.asarray(psnr_list))
- ssim_mean = np.mean(np.asarray(ssim_list))
- logger.info('===> Epoch {}: testing psnr = {:.2f}, ssim = {:.3f}, time: {:.2f}'
- .format(epoch, psnr_mean, ssim_mean,(end - begin)))
- model.train()
- return pred, truth, psnr_list, ssim_list, psnr_mean, ssim_mean
-
-def main():
- logger = gen_log(model_path)
- logger.info("Learning rate:{}, batch_size:{}.\n".format(opt.learning_rate, opt.batch_size))
- psnr_max = 0
- for epoch in range(1, opt.max_epoch + 1):
- train(epoch, logger)
- (pred, truth, psnr_all, ssim_all, psnr_mean, ssim_mean) = test(epoch, logger)
- scheduler.step()
- if psnr_mean > psnr_max:
- psnr_max = psnr_mean
- if psnr_mean > 28:
- name = result_path + '/' + 'Test_{}_{:.2f}_{:.3f}'.format(epoch, psnr_max, ssim_mean) + '.mat'
- scio.savemat(name, {'truth': truth, 'pred': pred, 'psnr_list': psnr_all, 'ssim_list': ssim_all})
- checkpoint(model, epoch, model_path, logger)
-
-if __name__ == '__main__':
- torch.backends.cudnn.enabled = True
- torch.backends.cudnn.benchmark = True
- main()
-
-
diff --git a/MST/simulation/train_code/utils.py b/MST/simulation/train_code/utils.py
deleted file mode 100755
index 477a3eb..0000000
--- a/MST/simulation/train_code/utils.py
+++ /dev/null
@@ -1,235 +0,0 @@
-import scipy.io as sio
-import os
-import numpy as np
-import torch
-import logging
-import random
-from ssim_torch import ssim
-
-def generate_masks(mask_path, batch_size):
- mask = sio.loadmat(mask_path + '/mask.mat')
- mask = mask['mask']
- mask3d = np.tile(mask[:, :, np.newaxis], (1, 1, 28))
- mask3d = np.transpose(mask3d, [2, 0, 1])
- mask3d = torch.from_numpy(mask3d)
- [nC, H, W] = mask3d.shape
- mask3d_batch = mask3d.expand([batch_size, nC, H, W]).cuda().float()
- return mask3d_batch
-
-def generate_shift_masks(mask_path, batch_size):
- mask = sio.loadmat(mask_path + '/mask_3d_shift.mat')
- mask_3d_shift = mask['mask_3d_shift']
- mask_3d_shift = np.transpose(mask_3d_shift, [2, 0, 1])
- mask_3d_shift = torch.from_numpy(mask_3d_shift)
- [nC, H, W] = mask_3d_shift.shape
- Phi_batch = mask_3d_shift.expand([batch_size, nC, H, W]).cuda().float()
- Phi_s_batch = torch.sum(Phi_batch**2,1)
- Phi_s_batch[Phi_s_batch==0] = 1
- return Phi_batch, Phi_s_batch
-
-def LoadTraining(path):
- imgs = []
- scene_list = os.listdir(path)
- scene_list.sort()
- print('training sences:', len(scene_list))
- for i in range(len(scene_list)):
- # for i in range(5):
- scene_path = path + scene_list[i]
- scene_num = int(scene_list[i].split('.')[0][5:])
- if scene_num<=205:
- if 'mat' not in scene_path:
- continue
- img_dict = sio.loadmat(scene_path)
- if "img_expand" in img_dict:
- img = img_dict['img_expand'] / 65536.
- elif "img" in img_dict:
- img = img_dict['img'] / 65536.
- img = img.astype(np.float32)
- imgs.append(img)
- print('Sence {} is loaded. {}'.format(i, scene_list[i]))
- return imgs
-
-def LoadTest(path_test):
- scene_list = os.listdir(path_test)
- scene_list.sort()
- test_data = np.zeros((len(scene_list), 256, 256, 28))
- for i in range(len(scene_list)):
- scene_path = path_test + scene_list[i]
- img = sio.loadmat(scene_path)['img']
- test_data[i, :, :, :] = img
- test_data = torch.from_numpy(np.transpose(test_data, (0, 3, 1, 2)))
- return test_data
-
-def LoadMeasurement(path_test_meas):
- img = sio.loadmat(path_test_meas)['simulation_test']
- test_data = img
- test_data = torch.from_numpy(test_data)
- return test_data
-
-# We find that this calculation method is more close to DGSMP's.
-def torch_psnr(img, ref): # input [28,256,256]
- img = (img*256).round()
- ref = (ref*256).round()
- nC = img.shape[0]
- psnr = 0
- for i in range(nC):
- mse = torch.mean((img[i, :, :] - ref[i, :, :]) ** 2)
- psnr += 10 * torch.log10((255*255)/mse)
- return psnr / nC
-
-def torch_ssim(img, ref): # input [28,256,256]
- return ssim(torch.unsqueeze(img, 0), torch.unsqueeze(ref, 0))
-
-def time2file_name(time):
- year = time[0:4]
- month = time[5:7]
- day = time[8:10]
- hour = time[11:13]
- minute = time[14:16]
- second = time[17:19]
- time_filename = year + '_' + month + '_' + day + '_' + hour + '_' + minute + '_' + second
- return time_filename
-
-def shuffle_crop(train_data, batch_size, crop_size=256, argument=True):
- if argument:
- gt_batch = []
- # The first half data use the original data.
- index = np.random.choice(range(len(train_data)), batch_size//2)
- processed_data = np.zeros((batch_size//2, crop_size, crop_size, 28), dtype=np.float32)
- for i in range(batch_size//2):
- img = train_data[index[i]]
- h, w, _ = img.shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data[i, :, :, :] = img[x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- processed_data = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2))).cuda().float()
- for i in range(processed_data.shape[0]):
- gt_batch.append(arguement_1(processed_data[i]))
-
- # The other half data use splicing.
- processed_data = np.zeros((4, 128, 128, 28), dtype=np.float32)
- for i in range(batch_size - batch_size // 2):
- sample_list = np.random.randint(0, len(train_data), 4)
- for j in range(4):
- x_index = np.random.randint(0, h-crop_size//2)
- y_index = np.random.randint(0, w-crop_size//2)
- processed_data[j] = train_data[sample_list[j]][x_index:x_index+crop_size//2,y_index:y_index+crop_size//2,:]
- gt_batch_2 = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2))).cuda() # [4,28,128,128]
- gt_batch.append(arguement_2(gt_batch_2))
- gt_batch = torch.stack(gt_batch, dim=0)
- return gt_batch
- else:
- index = np.random.choice(range(len(train_data)), batch_size)
- processed_data = np.zeros((batch_size, crop_size, crop_size, 28), dtype=np.float32)
- for i in range(batch_size):
- h, w, _ = train_data[index[i]].shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data[i, :, :, :] = train_data[index[i]][x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- gt_batch = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2)))
- return gt_batch
-
-def arguement_1(x):
- """
- :param x: c,h,w
- :return: c,h,w
- """
- rotTimes = random.randint(0, 3)
- vFlip = random.randint(0, 1)
- hFlip = random.randint(0, 1)
- # Random rotation
- for j in range(rotTimes):
- x = torch.rot90(x, dims=(1, 2))
- # Random vertical Flip
- for j in range(vFlip):
- x = torch.flip(x, dims=(2,))
- # Random horizontal Flip
- for j in range(hFlip):
- x = torch.flip(x, dims=(1,))
- return x
-
-def arguement_2(generate_gt):
- c, h, w = generate_gt.shape[1],256,256
- divid_point_h = 128
- divid_point_w = 128
- output_img = torch.zeros(c,h,w).cuda()
- output_img[:, :divid_point_h, :divid_point_w] = generate_gt[0]
- output_img[:, :divid_point_h, divid_point_w:] = generate_gt[1]
- output_img[:, divid_point_h:, :divid_point_w] = generate_gt[2]
- output_img[:, divid_point_h:, divid_point_w:] = generate_gt[3]
- return output_img
-
-
-def gen_meas_torch(data_batch, mask3d_batch, Y2H=True, mul_mask=False):
- nC = data_batch.shape[1]
- temp = shift(mask3d_batch * data_batch, 2)
- meas = torch.sum(temp, 1)
- if Y2H:
- meas = meas / nC * 2
- H = shift_back(meas)
- if mul_mask:
- HM = torch.mul(H, mask3d_batch)
- return HM
- return H
- return meas
-
-def shift(inputs, step=2):
- [bs, nC, row, col] = inputs.shape
- output = torch.zeros(bs, nC, row, col + (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, step * i:step * i + col] = inputs[:, i, :, :]
- return output
-
-def shift_back(inputs, step=2): # input [bs,256,310] output [bs, 28, 256, 256]
- [bs, row, col] = inputs.shape
- nC = 28
- output = torch.zeros(bs, nC, row, col - (nC - 1) * step).cuda().float()
- for i in range(nC):
- output[:, i, :, :] = inputs[:, :, step * i:step * i + col - (nC - 1) * step]
- return output
-
-def gen_log(model_path):
- logger = logging.getLogger()
- logger.setLevel(logging.INFO)
- formatter = logging.Formatter("%(asctime)s - %(levelname)s: %(message)s")
-
- log_file = model_path + '/log.txt'
- fh = logging.FileHandler(log_file, mode='a')
- fh.setLevel(logging.INFO)
- fh.setFormatter(formatter)
-
- ch = logging.StreamHandler()
- ch.setLevel(logging.INFO)
- ch.setFormatter(formatter)
-
- logger.addHandler(fh)
- logger.addHandler(ch)
- return logger
-
-def init_mask(mask_path, mask_type, batch_size):
- mask3d_batch = generate_masks(mask_path, batch_size)
- if mask_type == 'Phi':
- shift_mask3d_batch = shift(mask3d_batch)
- input_mask = shift_mask3d_batch
- elif mask_type == 'Phi_PhiPhiT':
- Phi_batch, Phi_s_batch = generate_shift_masks(mask_path, batch_size)
- input_mask = (Phi_batch, Phi_s_batch)
- elif mask_type == 'Mask':
- input_mask = mask3d_batch
- elif mask_type == None:
- input_mask = None
- return mask3d_batch, input_mask
-
-def init_meas(gt, mask, input_setting):
- if input_setting == 'H':
- input_meas = gen_meas_torch(gt, mask, Y2H=True, mul_mask=False)
- elif input_setting == 'HM':
- input_meas = gen_meas_torch(gt, mask, Y2H=True, mul_mask=True)
- elif input_setting == 'Y':
- input_meas = gen_meas_torch(gt, mask, Y2H=False, mul_mask=True)
- return input_meas
-
-def checkpoint(model, epoch, model_path, logger):
- model_out_path = model_path + "/model_epoch_{}.pth".format(epoch)
- torch.save(model.state_dict(), model_out_path)
- logger.info("Checkpoint saved to {}".format(model_out_path))
diff --git a/MST/visualization/createfigure.m b/MST/visualization/createfigure.m
deleted file mode 100755
index 15ea8af..0000000
--- a/MST/visualization/createfigure.m
+++ /dev/null
@@ -1,47 +0,0 @@
-function createfigure(X1, YMatrix1, Corr)
-%CREATEFIGURE(X1, YMatrix1)
-% X1: x 数据的向量
-% YMATRIX1: y 数据的矩阵
-
-% 由 MATLAB 于 19-Feb-2022 11:12:35 自动生成
-
-% 创建 figure
-figure1 = figure('PaperOrientation','landscape',...
- 'PaperSize',[29.69999902 20.99999864]);
-
-% 创建 axes
-axes1 = axes('Parent',figure1,'Position',[0.13 0.11 0.385625 0.815]);
-hold(axes1,'on');
-
-% 使用 plot 的矩阵输入创建多行
-plot1 = plot(X1,YMatrix1,'MarkerSize',16,'Marker','.','LineWidth',2.5,...
- 'Parent',axes1);
-set(plot1(1),'DisplayName',' Ground Truth','Color',[1 0 0]);
-set(plot1(2),'DisplayName',' HDNet, corr: '+string(roundn(Corr(1),-4)),'Color',[0.01 0.66 0.62]);
-set(plot1(3),'DisplayName',' MST-S, corr: '+string(roundn(Corr(2),-4)),'Color',[0.66 0.01 0.62]);
-set(plot1(4),'DisplayName',' MST-M, corr: '+string(roundn(Corr(3),-4)),'Color',[1 1 0]);
-set(plot1(5),'DisplayName',' MST-L, corr: '+string(roundn(Corr(4),-4)),'Color',[0 0.5 0.5]);
-set(plot1(6),'DisplayName',' MST++, corr: '+string(roundn(Corr(5),-4)),'Color',[0 1 0]);
-
-
-
-
-% 取消以下行的注释以保留坐标区的 Y 范围
-ylim(axes1,[0 1]);
-box(axes1,'on');
-hold(axes1,'off');
-% 设置其余坐标区属性
-set(axes1,'FontName','Arial','FontSize',22,'LineWidth',3.5);
-
-% 创建 ylabel
-ylabel('Density','FontSize',28,'FontName','Arial');
-
-% 创建 xlabel
-xlabel('Wavelength (nm)','FontSize',28,'FontName','Arial');
-% 创建 legend
-legend1 = legend(axes1,'show');
-set(legend1,...
- 'Position',[0.320670220276361 0.124725505873052 0.187369795342287 0.36915888702758],...
- 'FontSize',22,...
- 'EdgeColor',[1 1 1]);
-
diff --git a/MST/visualization/dispCubeAshwin.m b/MST/visualization/dispCubeAshwin.m
deleted file mode 100755
index 8b65196..0000000
--- a/MST/visualization/dispCubeAshwin.m
+++ /dev/null
@@ -1,2124 +0,0 @@
-function [] = dispCubeAshwin(datacube,brightness,mywl,labelss,cols,rows,writefile,grayc,resultname)
-%dispCubeAshwin(x_twist16,80,linspace(450,650,23),[],4,6,0,0)
-h = figure;
-set(gcf,'color','white');
-% fig_xpos = 10; % 50
-% fig_ypos = -30; % 50
-% fig_width = 820; % 820
-% fig_height = 860; % 860
-% set(gcf,'position',[fig_xpos fig_ypos fig_width fig_height]);
-
-% wltextposition = [0 size(datacube,2)-0];
-wltextposition = [12 12]; %[12 40];
-m=size(datacube,3);
-for ind=1:m
- datacube(:,:,ind)=flipud(datacube(:,:,ind)); % up side dowm
-end
-imagedatacube2(h,double(datacube),brightness,mywl,labelss,wltextposition,cols,rows,writefile,grayc,resultname);
-
-
-
-
-function imagedatacube2(h, data,mymax,wavelengths,labelss,textposition,cols,rows,writefile,grayc,resultname)
-%data = datacube to plot
-%mymax = scaling factor to increase brightness of each slice
-%wavelengths = wavelengths of each spectral slice in nm
-%textposition = where the wavelengths text will be placed
-
-n = size(data,1);
-% data=mymax*data;
-temp=sort(data(:));
-temp=mean(temp(end-50:end));
-data=data*(50/temp);
-if mymax > 1
- data=data*mymax;
-end
-
-totalfigs = size(data,3);
-
-% cols = ceil(sqrt(totalfigs));
-% rows = ceil(totalfigs/cols);
-
-figscount = 1;
-set(gcf,'color','white');
-
-subplot1(rows,cols,'Gap',[0.005 0.005]);
-for r = 1:rows
- for c = 1:cols
- if figscount>totalfigs
- subplot1(figscount);axis off;
- else
- currentwl = wavelengths(figscount);
-
- cmM=(gray*kron(ones(3,1),spectrumRGB(wavelengths(figscount))));
- cmM=cmM/max(max(cmM));
-
- if figscount<=totalfigs
- subplot1((r-1)*cols+c);
- if isempty(labelss)
- subimage2(squeeze(data(:,:,figscount)),colormap(cmM));
- %text(textposition(1),textposition(2),['\bf' num2str(currentwl,4) ' nm'],'color','w')
- else
- if grayc==1
- subimage2(make01(squeeze(data(:,:,figscount))));
- else
- subimage2(squeeze(data(:,:,figscount)),colormap(cmM));
- end
- if r*c==1
- text(textposition(1),textposition(2),['\bf' num2str(labelss(r*c),4) ' frame'],'color','w')
- else
- text(textposition(1),textposition(2),['\bf' num2str(labelss((r-1)*cols+c),4) ' frames'],'color','w')
- end
- end
- if writefile
- imwrite(squeeze(rot90(rot90(data(:,:,figscount)))),colormap(cmM),['file' num2str(figscount) '.png'])
- end
- axis off;
- end
- end
- figscount = figscount+1;
- end
-end
-% h
-% rect1 = [181 37 553 553];
-% h_crop = imcrop(h,rect1);
-% saveas(h_crop, [resultname '.png']);
-saveas(h, [resultname, '.png']);
-% print(gcf,'-dpng',resultname);
-
-
-function sRGB = spectrumRGB(lambdaIn, varargin)
-%spectrumRGB Converts a spectral wavelength to RGB.
-%
-% sRGB = spectrumRGB(LAMBDA) converts the spectral color with wavelength
-% LAMBDA in the visible light spectrum to its RGB values in the sRGB
-% color space.
-%
-% sRGB = spectrumRGB(LAMBDA, MATCH) converts LAMBDA to sRGB using the
-% color matching function MATCH, a string. See colorMatchFcn for a list
-% of supported matching functions.
-%
-% Note: LAMBDA must be a scalar value or a vector of wavelengths.
-%
-% See also colorMatchFcn, createSpectrum, spectrumLabel.
-
-% Copyright 1993-2005 The MathWorks, Inc.
-
-if (numel(lambdaIn) ~= length(lambdaIn))
-
- error('spectrumRGB:unsupportedDimension', ...
- 'Input must be a scalar or vector of wavelengths.')
-
-end
-
-% Get the color matching functions.
-if (nargin == 1)
-
- matchingFcn = '1964_full';
-
-elseif (nargin == 2)
-
- matchingFcn = varargin{1};
-
-else
-
- error(nargchk(1, 2, nargin, 'struct'))
-
-end
-
-[lambdaMatch, xFcn, yFcn, zFcn] = colorMatchFcn(matchingFcn);
-
-% Interpolate the input wavelength in the color matching functions.
-XYZ = interp1(lambdaMatch', [xFcn; yFcn; zFcn]', lambdaIn, 'pchip', 0);
-
-% Reshape interpolated values to match standard image representation.
-if (numel(lambdaIn) > 1)
-
- XYZ = permute(XYZ', [3 2 1]);
-
-end
-
-% Convert the XYZ values to sRGB.
-XYZ2sRGB = makecform('xyz2srgb');
-sRGB = applycform(XYZ, XYZ2sRGB);
-
-
-function hout = subimage2(varargin)
-%SUBIMAGE Display multiple images in single figure.
-% You can use SUBIMAGE in conjunction with SUBPLOT to create
-% figures with multiple images, even if the images have
-% different colormaps. SUBIMAGE works by converting images to
-% truecolor for display purposes, thus avoiding colormap
-% conflicts.
-%
-% SUBIMAGE(X,MAP) displays the indexed image X with colormap
-% MAP in the current axes.
-%
-% SUBIMAGE(I) displays the intensity image I in the current
-% axes.
-%
-% SUBIMAGE(BW) displays the binary image BW in the current
-% axes.
-%
-% SUBIMAGE(RGB) displays the truecolor image RGB in the current
-% axes.
-%
-% SUBIMAGE(x,y,...) displays an image with nondefault spatial
-% coordinates.
-%
-% H = SUBIMAGE(...) returns a handle to the image object.
-%
-% Class Support
-% -------------
-% The input image can be of class logical, uint8, uint16,
-% or double.
-%
-% Example
-% -------
-% load trees
-% [X2,map2] = imread('forest.tif');
-% subplot(1,2,1), subimage(X,map)
-% subplot(1,2,2), subimage(X2,map2)
-%
-% See also IMSHOW, SUBPLOT.
-
-% Copyright 1993-2005 The MathWorks, Inc.
-% $Revision: 1.1.8.3 $ $Date: 2005/05/27 14:07:39 $
-
-[x,y,cdata] = parse_inputs(varargin{:});
-
-ax = newplot;
-fig = ancestor(ax,'figure');
-cm = get(fig,'Colormap');
-
-% Go change all the existing image and texture-mapped surface
-% objects to truecolor.
-h = [findobj(fig,'Type','image') ;
- findobj(fig,'Type','surface','FaceColor','texturemap')];
-for k = 1:length(h)
- if (ndims(get(h(k), 'CData')) < 3)
- if (isequal(get(h(k), 'CDataMapping'), 'direct'))
- if (strcmp(get(h(k),'Type'),'image'))
- set(h(k), 'CData', ...
- iptgate('ind2rgb8',get(h(k),'CData'), cm));
- else
- set(h(k), 'CData', ind2rgb(get(h(k),'CData'), cm));
- end
- else
- clim = get(ancestor(h(k),'axes'), 'CLim');
- data = get(h(k), 'CData');
- if (isa(data,'uint8'))
- data = double(data) / 255;
- clim = clim / 255;
- elseif (isa(data,'uint16'))
- data = double(data) / 65535;
- clim = clim / 65535;
- end
- data = (data - clim(1)) / (clim(2) - clim(1));
- if (strcmp(get(h(k),'Type'),'image'))
- data = im2uint8(data);
- set(h(k), 'CData', cat(3, data, data, data));
- else
- data = min(max(data,0),1);
- set(h(k), 'CData', cat(3, data, data, data));
- end
- end
- end
-end
-
-h = image(x, y, cdata);
-axis image;
-
-if nargout==1,
- hout = h;
-end
-
-%--------------------------------------------------------
-% Subfunction PARSE_INPUTS
-%--------------------------------------------------------
-function [x,y,cdata] = parse_inputs(varargin)
-
-x = [];
-y = [];
-cdata = [];
-msg = ''; % empty string if no error encountered
-
-scaled = 0;
-binary = 0;
-
-msg_aEqualsb = 'a cannot equal b in subimage(I,[a b])';
-eid_aEqualsb = sprintf('Images:%s:aEqualsB',mfilename);
-
-switch nargin
-case 0
- msg = 'Not enough input arguments.';
- eid = sprintf('Images:%s:notEnoughInputs',mfilename);
- error(eid,'%s',msg);
-
-case 1
- % subimage(I)
- % subimage(RGB)
-
- if ((ndims(varargin{1}) == 3) && (size(varargin{1},3) == 3))
- % subimage(RGB)
- cdata = varargin{1};
-
- else
- % subimage(I)
- binary = islogical(varargin{1});
- cdata = cat(3, varargin{1}, varargin{1}, varargin{1});
-
- end
-
-case 2
- % subimage(I,[a b])
- % subimage(I,N)
- % subimage(X,map)
-
- if (numel(varargin{2}) == 1)
- % subimage(I,N)
- binary = islogical(varargin{1});
- cdata = cat(3, varargin{1}, varargin{1}, varargin{1});
-
- elseif (isequal(size(varargin{2}), [1 2]))
- % subimage(I,[a b])
- clim = varargin{2};
- if (clim(1) == clim(2))
- error(eid_aEqualsb,'%s',msg_aEqualsb);
-
- else
- cdata = cat(3, varargin{1}, varargin{1}, varargin{1});
- end
- scaled = 1;
-
- elseif (size(varargin{2},2) == 3)
- % subimage(X,map);
- cdata = iptgate('ind2rgb8',varargin{1},varargin{2});
-
- else
- msg = 'Invalid input arguments.';
- eid = sprintf('Images:%s:invalidInputs',mfilename);
- error(eid,'%s',msg);
-
- end
-
-case 3
- % subimage(x,y,I)
- % subimage(x,y,RGB)
-
- if ((ndims(varargin{3}) == 3) && (size(varargin{3},3) == 3))
- % subimage(x,y,RGB)
- x = varargin{1};
- y = varargin{2};
- cdata = varargin{3};
-
- else
- % subimage(x,y,I)
- x = varargin{1};
- y = varargin{2};
- binary = islogical(varargin{3});
- cdata = cat(3, varargin{3}, varargin{3}, varargin{3});
-
- end
-
-case 4
- % subimage(x,y,I,[a b])
- % subimage(x,y,I,N)
- % subimage(x,y,X,map)
-
- if (numel(varargin{4}) == 1)
- % subimage(x,y,I,N)
- x = varargin{1};
- y = varargin{2};
- binary = islogical(varargin{3});
- cdata = cat(3, varargin{3}, varargin{3}, varargin{3});
-
- elseif (isequal(size(varargin{4}), [1 2]))
- % subimage(x,y,I,[a b])
- scaled = 1;
- clim = varargin{4};
- if (clim(1) == clim(2))
- error(eid_aEqualsb,'%s',msg_aEqualsb);
- else
- x = varargin{1};
- y = varargin{2};
- cdata = cat(3, varargin{3}, varargin{3}, varargin{3});
- end
-
- elseif (size(varargin{4},2) == 3)
- % subimage(x,y,X,map);
- x = varargin{1};
- y = varargin{2};
- cdata = iptgate('ind2rgb8',varargin{3},varargin{4});
-
- else
- msg = 'Invalid input arguments';
- eid = sprintf('Images:%s:invalidInputs',mfilename);
- error(eid,'%s',msg);
-
- end
-
-otherwise
- msg = 'Too many input arguments';
- eid = sprintf('Images:%s:tooManyInputs',mfilename);
- error(eid,'%s',msg);
-
-end
-
-if (isempty(msg))
- if (scaled)
- if (isa(cdata,'double'))
- cdata = (cdata - clim(1)) / (clim(2) - clim(1));
- cdata = min(max(cdata,0),1);
-
- elseif (isa(cdata,'uint8'))
- cdata = im2double(cdata);
- clim = clim / 255;
- cdata = (cdata - clim(1)) / (clim(2) - clim(1));
- cdata = im2uint8(cdata);
-
- elseif (isa(cdata,'uint16'))
- cdata = im2double(cdata);
- clim = clim / 65535;
- cdata = (cdata - clim(1)) / (clim(2) - clim(1));
- cdata = im2uint8(cdata);
-
- else
- msg = 'Class of input image must be uint8, uint16, or double.';
- eid = sprintf('Images:%s:invalidClass',mfilename);
- error(eid,'%s',msg);
-
- end
-
- elseif (binary)
- cdata = uint8(cdata);
- cdata(cdata ~= 0) = 255;
- end
-
- if (isempty(x))
- x = [1 size(cdata,2)];
- y = [1 size(cdata,1)];
- end
-end
-
-% Regardless of the input type, at this point in the code,
-% cdata represents an RGB image; atomatically clip double RGB images
-% to [0 1] range
-if isa(cdata, 'double')
-
- cdata(cdata > 1) = 1;
- cdata(cdata < 0) = 0;
-end
-
-
-function subplot1(M,N,varargin);
-%-------------------------------------------------------------------------
-% subplot1 function An mproved subplot function
-% Input : - If more than one input argumenst are given,
-% then the first parameter is the number of rows.
-% If single input argument is given, then this is the
-% subplot-number for which to set focus.
-% This could a scalar or two element vector (I,J).
-% - Number of columns.
-% * variable number of parameters
-% (in pairs: ...,Keywoard, Value,...)
-% - 'Min' : X, Y lower position of lowest subplot,
-% default is [0.10 0.10].
-% - 'Max' : X, Y largest position of highest subplot,
-% default is [0.95 0.95].
-% - 'Gap' : X,Y gaps between subplots,
-% default is [0.01 0.01].
-% - 'XTickL' : x ticks labels option,
-% 'Margin' : plot only XTickLabels in the
-% subplot of the lowest row (default).
-% 'All' : plot XTickLabels in all subplots.
-% 'None' : don't plot XTickLabels in subplots.
-% - 'YTickL' : y ticks labels option,
-% 'Margin' : plot only YTickLabels in the
-% subplot of the lowest row (defailt).
-% 'All' : plot YTickLabels in all subplots.
-% 'None' : don't plot YTickLabels in subplots.
-% - 'FontS' : axis font size, default is 10.
-% 'XScale' : scale of x axis:
-% 'linear', default.
-% 'log'
-% - 'YScale' : scale of y axis:
-% 'linear', default.
-% 'log'
-% Example: subplot1(2,2,'Gap',[0.02 0.02]);
-% subplot1(2,3,'Gap',[0.02 0.02],'XTickL','None','YTickL','All','FontS',16);
-% See also : subplot1c.m
-% Tested : Matlab 5.3
-% By : Eran O. Ofek June 2002
-% URL : http://wise-obs.tau.ac.il/~eran/matlab.html
-%-------------------------------------------------------------------------
-MinDef = [0.10 0.10];
-MaxDef = [0.95 0.95];
-GapDef = [0.01 0.01];
-XTickLDef = 'Margin';
-YTickLDef = 'Margin';
-FontSDef = 10;
-XScaleDef = 'linear';
-YScaleDef = 'linear';
-
-% set default parameters
-Min = MinDef;
-Max = MaxDef;
-Gap = GapDef;
-XTickL = XTickLDef;
-YTickL = YTickLDef;
-FontS = FontSDef;
-XScale = XScaleDef;
-YScale = YScaleDef;
-
-
-MoveFoc = 0;
-if (nargin==1),
- %--- move focus to subplot # ---
- MoveFoc = 1;
-elseif (nargin==2),
- % do nothing
-elseif (nargin>2),
- Narg = length(varargin);
- if (0.5.*Narg==floor(0.5.*Narg)),
-
- for I=1:2:Narg-1,
- switch varargin{I},
- case 'Min'
- Min = varargin{I+1};
- case 'Max'
- Max = varargin{I+1};
- case 'Gap'
- Gap = varargin{I+1};
- case 'XTickL'
- XTickL = varargin{I+1};
- case 'YTickL'
- YTickL = varargin{I+1};
- case 'FontS'
- FontS = varargin{I+1};
- case 'XScale'
- XScale = varargin{I+1};
- case 'YScale'
- YScale = varargin{I+1};
- otherwise
- error('Unknown keyword');
- end
- end
- else
- error('Optional arguments should given as keyword, value');
- end
-else
- error('Illegal number of input arguments');
-end
-
-
-
-
-
-
-
-
-switch MoveFoc
- case 1
- %--- move focus to subplot # ---
- H = get(gcf,'Children');
- Ptot = length(H);
- if (length(M)==1),
- M = Ptot - M + 1;
- elseif (length(M)==2),
- %--- check for subplot size ---
- Pos1 = get(H(1),'Position');
- Pos1x = Pos1(1);
- for Icheck=2:1:Ptot,
- PosN = get(H(Icheck),'Position');
- PosNx = PosN(1);
- if (PosNx==Pos1x),
- NumberOfCol = Icheck - 1;
- break;
- end
- end
- NumberOfRow = Ptot./NumberOfCol;
-
- Row = M(1);
- Col = M(2);
-
- M = (Row-1).*NumberOfCol + Col;
- M = Ptot - M + 1;
- else
- error('Unknown option, undefined subplot index');
- end
-
- set(gcf,'CurrentAxes',H(M));
-
- case 0
- %--- open subplots ---
-
- Xmin = Min(1);
- Ymin = Min(2);
- Xmax = Max(1);
- Ymax = Max(2);
- Xgap = Gap(1);
- Ygap = Gap(2);
-
-
- Xsize = (Xmax - Xmin)./N;
- Ysize = (Ymax - Ymin)./M;
-
- Xbox = Xsize - Xgap;
- Ybox = Ysize - Ygap;
-
-
- Ptot = M.*N;
-
- Hgcf = gcf;
- clf;
- figure(Hgcf);
- for Pi=1:1:Ptot,
- Row = ceil(Pi./N);
- Col = Pi - (Row - 1)*N;
-
- Xstart = Xmin + Xsize.*(Col - 1);
- Ystart = Ymax - Ysize.*Row;
-
-% subplot(M,N,Pi);
-% hold on;
- axes('position',[Xstart,Ystart,Xbox,Ybox]);
- %set(gca,'position',[Xstart,Ystart,Xbox,Ybox]);
- set(gca,'FontSize',FontS);
- box on;
- hold on;
-
- switch XTickL
- case 'Margin'
- if (Row~=M),
- %--- erase XTickLabel ---
- set(gca,'XTickLabel',[]);
- end
- case 'All'
- % do nothing
- case 'None'
- set(gca,'XTickLabel',[]);
- otherwise
- error('Unknown XTickL option');
- end
-
- switch YTickL
- case 'Margin'
- if (Col~=1),
- %--- erase YTickLabel ---
- set(gca,'YTickLabel',[]);
- end
- case 'All'
- % do nothing
- case 'None'
- set(gca,'YTickLabel',[]);
- otherwise
- error('Unknown XTickL option');
- end
-
- switch XScale
- case 'linear'
- set(gca,'XScale','linear');
- case 'log'
- set(gca,'XScale','log');
- otherwise
- error('Unknown XScale option');
- end
-
- switch YScale
- case 'linear'
- set(gca,'YScale','linear');
- case 'log'
- set(gca,'YScale','log');
- otherwise
- error('Unknown YScale option');
- end
-
- end
-
- otherwise
- error('Unknown MoveFoc option');
-end
-
-
-function [lambda, xFcn, yFcn, zFcn] = colorMatchFcn(formulary)
-%colorMatchFcn Popular color matching functions.
-%
-% [LAMBDA, XFCN, YFCN, ZFCN] = colorMatchFcn(FORMULARY) returns the
-% color matching functions XFCN, YFCN, and ZFCN at each wavelength in
-% the vector LAMBDA. FORMULARY is a string specifying which set of
-% color matching functions to return. Supported color matching
-% functions are given below:
-%
-% CIE_1931 CIE 1931 2-degree, XYZ
-% 1931_FULL CIE 1931 2-degree, XYZ (at 1nm resolution)
-% CIE_1964 CIE 1964 10-degree, XYZ
-% 1964_FULL CIE 1964 10-degree, XYZ (at 1nm resolution)
-% Judd CIE 1931 2-degree, XYZ modified by Judd (1951)
-% Judd_Vos CIE 1931 2-degree, XYZ modified by Judd (1951) and Vos (1978)
-% Stiles_2 Stiles and Burch 2-degree, RGB (1955)
-% Stiles_10 Stiles and Burch 10-degree, RGB (1959)
-%
-% Reference: http://cvrl.ioo.ucl.ac.uk/cmfs.htm
-%
-% See also illuminant.
-
-% Copyright 1993-2005 The MathWorks, Inc.
-
-switch (lower(formulary))
- case 'judd_vos'
-
- cmf = [380, 2.689900e-003, 2.000000e-004, 1.226000e-002
- 385, 5.310500e-003, 3.955600e-004, 2.422200e-002
- 390, 1.078100e-002, 8.000000e-004, 4.925000e-002
- 395, 2.079200e-002, 1.545700e-003, 9.513500e-002
- 400, 3.798100e-002, 2.800000e-003, 1.740900e-001
- 405, 6.315700e-002, 4.656200e-003, 2.901300e-001
- 410, 9.994100e-002, 7.400000e-003, 4.605300e-001
- 415, 1.582400e-001, 1.177900e-002, 7.316600e-001
- 420, 2.294800e-001, 1.750000e-002, 1.065800e+000
- 425, 2.810800e-001, 2.267800e-002, 1.314600e+000
- 430, 3.109500e-001, 2.730000e-002, 1.467200e+000
- 435, 3.307200e-001, 3.258400e-002, 1.579600e+000
- 440, 3.333600e-001, 3.790000e-002, 1.616600e+000
- 445, 3.167200e-001, 4.239100e-002, 1.568200e+000
- 450, 2.888200e-001, 4.680000e-002, 1.471700e+000
- 455, 2.596900e-001, 5.212200e-002, 1.374000e+000
- 460, 2.327600e-001, 6.000000e-002, 1.291700e+000
- 465, 2.099900e-001, 7.294200e-002, 1.235600e+000
- 470, 1.747600e-001, 9.098000e-002, 1.113800e+000
- 475, 1.328700e-001, 1.128400e-001, 9.422000e-001
- 480, 9.194400e-002, 1.390200e-001, 7.559600e-001
- 485, 5.698500e-002, 1.698700e-001, 5.864000e-001
- 490, 3.173100e-002, 2.080200e-001, 4.466900e-001
- 495, 1.461300e-002, 2.580800e-001, 3.411600e-001
- 500, 4.849100e-003, 3.230000e-001, 2.643700e-001
- 505, 2.321500e-003, 4.054000e-001, 2.059400e-001
- 510, 9.289900e-003, 5.030000e-001, 1.544500e-001
- 515, 2.927800e-002, 6.081100e-001, 1.091800e-001
- 520, 6.379100e-002, 7.100000e-001, 7.658500e-002
- 525, 1.108100e-001, 7.951000e-001, 5.622700e-002
- 530, 1.669200e-001, 8.620000e-001, 4.136600e-002
- 535, 2.276800e-001, 9.150500e-001, 2.935300e-002
- 540, 2.926900e-001, 9.540000e-001, 2.004200e-002
- 545, 3.622500e-001, 9.800400e-001, 1.331200e-002
- 550, 4.363500e-001, 9.949500e-001, 8.782300e-003
- 555, 5.151300e-001, 1.000100e+000, 5.857300e-003
- 560, 5.974800e-001, 9.950000e-001, 4.049300e-003
- 565, 6.812100e-001, 9.787500e-001, 2.921700e-003
- 570, 7.642500e-001, 9.520000e-001, 2.277100e-003
- 575, 8.439400e-001, 9.155800e-001, 1.970600e-003
- 580, 9.163500e-001, 8.700000e-001, 1.806600e-003
- 585, 9.770300e-001, 8.162300e-001, 1.544900e-003
- 590, 1.023000e+000, 7.570000e-001, 1.234800e-003
- 595, 1.051300e+000, 6.948300e-001, 1.117700e-003
- 600, 1.055000e+000, 6.310000e-001, 9.056400e-004
- 605, 1.036200e+000, 5.665400e-001, 6.946700e-004
- 610, 9.923900e-001, 5.030000e-001, 4.288500e-004
- 615, 9.286100e-001, 4.417200e-001, 3.181700e-004
- 620, 8.434600e-001, 3.810000e-001, 2.559800e-004
- 625, 7.398300e-001, 3.205200e-001, 1.567900e-004
- 630, 6.328900e-001, 2.650000e-001, 9.769400e-005
- 635, 5.335100e-001, 2.170200e-001, 6.894400e-005
- 640, 4.406200e-001, 1.750000e-001, 5.116500e-005
- 645, 3.545300e-001, 1.381200e-001, 3.601600e-005
- 650, 2.786200e-001, 1.070000e-001, 2.423800e-005
- 655, 2.148500e-001, 8.165200e-002, 1.691500e-005
- 660, 1.616100e-001, 6.100000e-002, 1.190600e-005
- 665, 1.182000e-001, 4.432700e-002, 8.148900e-006
- 670, 8.575300e-002, 3.200000e-002, 5.600600e-006
- 675, 6.307700e-002, 2.345400e-002, 3.954400e-006
- 680, 4.583400e-002, 1.700000e-002, 2.791200e-006
- 685, 3.205700e-002, 1.187200e-002, 1.917600e-006
- 690, 2.218700e-002, 8.210000e-003, 1.313500e-006
- 695, 1.561200e-002, 5.772300e-003, 9.151900e-007
- 700, 1.109800e-002, 4.102000e-003, 6.476700e-007
- 705, 7.923300e-003, 2.929100e-003, 4.635200e-007
- 710, 5.653100e-003, 2.091000e-003, 3.330400e-007
- 715, 4.003900e-003, 1.482200e-003, 2.382300e-007
- 720, 2.825300e-003, 1.047000e-003, 1.702600e-007
- 725, 1.994700e-003, 7.401500e-004, 1.220700e-007
- 730, 1.399400e-003, 5.200000e-004, 8.710700e-008
- 735, 9.698000e-004, 3.609300e-004, 6.145500e-008
- 740, 6.684700e-004, 2.492000e-004, 4.316200e-008
- 745, 4.614100e-004, 1.723100e-004, 3.037900e-008
- 750, 3.207300e-004, 1.200000e-004, 2.155400e-008
- 755, 2.257300e-004, 8.462000e-005, 1.549300e-008
- 760, 1.597300e-004, 6.000000e-005, 1.120400e-008
- 765, 1.127500e-004, 4.244600e-005, 8.087300e-009
- 770, 7.951300e-005, 3.000000e-005, 5.834000e-009
- 775, 5.608700e-005, 2.121000e-005, 4.211000e-009
- 780, 3.954100e-005, 1.498900e-005, 3.038300e-009
- 785, 2.785200e-005, 1.058400e-005, 2.190700e-009
- 790, 1.959700e-005, 7.465600e-006, 1.577800e-009
- 795, 1.377000e-005, 5.259200e-006, 1.134800e-009
- 800, 9.670000e-006, 3.702800e-006, 8.156500e-010
- 805, 6.791800e-006, 2.607600e-006, 5.862600e-010
- 810, 4.770600e-006, 1.836500e-006, 4.213800e-010
- 815, 3.355000e-006, 1.295000e-006, 3.031900e-010
- 820, 2.353400e-006, 9.109200e-007, 2.175300e-010
- 825, 1.637700e-006, 6.356400e-007, 1.547600e-010];
-
- case 'judd'
-
- cmf = [370, 0.0008, 0.0001, 0.0046
- 380, 0.0045, 0.0004, 0.0224
- 390, 0.0201, 0.0015, 0.0925
- 400, 0.0611, 0.0045, 0.2799
- 410, 0.1267, 0.0093, 0.5835
- 420, 0.2285, 0.0175, 1.0622
- 430, 0.3081, 0.0273, 1.4526
- 440, 0.3312, 0.0379, 1.6064
- 450, 0.2888, 0.0468, 1.4717
- 460, 0.2323, 0.0600, 1.2880
- 470, 0.1745, 0.0910, 1.1133
- 480, 0.0920, 0.1390, 0.7552
- 490, 0.0318, 0.2080, 0.4461
- 500, 0.0048, 0.3230, 0.2644
- 510, 0.0093, 0.5030, 0.1541
- 520, 0.0636, 0.7100, 0.0763
- 530, 0.1668, 0.8620, 0.0412
- 540, 0.2926, 0.9540, 0.0200
- 550, 0.4364, 0.9950, 0.0088
- 560, 0.5970, 0.9950, 0.0039
- 570, 0.7642, 0.9520, 0.0020
- 580, 0.9159, 0.8700, 0.0016
- 590, 1.0225, 0.7570, 0.0011
- 600, 1.0544, 0.6310, 0.0007
- 610, 0.9922, 0.5030, 0.0003
- 620, 0.8432, 0.3810, 0.0002
- 630, 0.6327, 0.2650, 0.0001
- 640, 0.4404, 0.1750, 0.0000
- 650, 0.2787, 0.1070, 0.0000
- 660, 0.1619, 0.0610, 0.0000
- 670, 0.0858, 0.0320, 0.0000
- 680, 0.0459, 0.0170, 0.0000
- 690, 0.0222, 0.0082, 0.0000
- 700, 0.0113, 0.0041, 0.0000
- 710, 0.0057, 0.0021, 0.0000
- 720, 0.0028, 0.0011, 0.0000
- 730, 0.0015, 0.0005, 0.0000
- 740, 0.0005, 0.0002, 0.0000
- 750, 0.0003, 0.0001, 0.0000
- 760, 0.0002, 0.0001, 0.0000
- 770, 0.0001, 0.0000, 0.0000];
-
- case 'cie_1931'
-
- cmf = [360, 0.000129900000, 0.000003917000, 0.000606100000
- 365, 0.000232100000, 0.000006965000, 0.001086000000
- 370, 0.000414900000, 0.000012390000, 0.001946000000
- 375, 0.000741600000, 0.000022020000, 0.003486000000
- 380, 0.001368000000, 0.000039000000, 0.006450001000
- 385, 0.002236000000, 0.000064000000, 0.010549990000
- 390, 0.004243000000, 0.000120000000, 0.020050010000
- 395, 0.007650000000, 0.000217000000, 0.036210000000
- 400, 0.014310000000, 0.000396000000, 0.067850010000
- 405, 0.023190000000, 0.000640000000, 0.110200000000
- 410, 0.043510000000, 0.001210000000, 0.207400000000
- 415, 0.077630000000, 0.002180000000, 0.371300000000
- 420, 0.134380000000, 0.004000000000, 0.645600000000
- 425, 0.214770000000, 0.007300000000, 1.039050100000
- 430, 0.283900000000, 0.011600000000, 1.385600000000
- 435, 0.328500000000, 0.016840000000, 1.622960000000
- 440, 0.348280000000, 0.023000000000, 1.747060000000
- 445, 0.348060000000, 0.029800000000, 1.782600000000
- 450, 0.336200000000, 0.038000000000, 1.772110000000
- 455, 0.318700000000, 0.048000000000, 1.744100000000
- 460, 0.290800000000, 0.060000000000, 1.669200000000
- 465, 0.251100000000, 0.073900000000, 1.528100000000
- 470, 0.195360000000, 0.090980000000, 1.287640000000
- 475, 0.142100000000, 0.112600000000, 1.041900000000
- 480, 0.095640000000, 0.139020000000, 0.812950100000
- 485, 0.057950010000, 0.169300000000, 0.616200000000
- 490, 0.032010000000, 0.208020000000, 0.465180000000
- 495, 0.014700000000, 0.258600000000, 0.353300000000
- 500, 0.004900000000, 0.323000000000, 0.272000000000
- 505, 0.002400000000, 0.407300000000, 0.212300000000
- 510, 0.009300000000, 0.503000000000, 0.158200000000
- 515, 0.029100000000, 0.608200000000, 0.111700000000
- 520, 0.063270000000, 0.710000000000, 0.078249990000
- 525, 0.109600000000, 0.793200000000, 0.057250010000
- 530, 0.165500000000, 0.862000000000, 0.042160000000
- 535, 0.225749900000, 0.914850100000, 0.029840000000
- 540, 0.290400000000, 0.954000000000, 0.020300000000
- 545, 0.359700000000, 0.980300000000, 0.013400000000
- 550, 0.433449900000, 0.994950100000, 0.008749999000
- 555, 0.512050100000, 1.000000000000, 0.005749999000
- 560, 0.594500000000, 0.995000000000, 0.003900000000
- 565, 0.678400000000, 0.978600000000, 0.002749999000
- 570, 0.762100000000, 0.952000000000, 0.002100000000
- 575, 0.842500000000, 0.915400000000, 0.001800000000
- 580, 0.916300000000, 0.870000000000, 0.001650001000
- 585, 0.978600000000, 0.816300000000, 0.001400000000
- 590, 1.026300000000, 0.757000000000, 0.001100000000
- 595, 1.056700000000, 0.694900000000, 0.001000000000
- 600, 1.062200000000, 0.631000000000, 0.000800000000
- 605, 1.045600000000, 0.566800000000, 0.000600000000
- 610, 1.002600000000, 0.503000000000, 0.000340000000
- 615, 0.938400000000, 0.441200000000, 0.000240000000
- 620, 0.854449900000, 0.381000000000, 0.000190000000
- 625, 0.751400000000, 0.321000000000, 0.000100000000
- 630, 0.642400000000, 0.265000000000, 0.000049999990
- 635, 0.541900000000, 0.217000000000, 0.000030000000
- 640, 0.447900000000, 0.175000000000, 0.000020000000
- 645, 0.360800000000, 0.138200000000, 0.000010000000
- 650, 0.283500000000, 0.107000000000, 0.000000000000
- 655, 0.218700000000, 0.081600000000, 0.000000000000
- 660, 0.164900000000, 0.061000000000, 0.000000000000
- 665, 0.121200000000, 0.044580000000, 0.000000000000
- 670, 0.087400000000, 0.032000000000, 0.000000000000
- 675, 0.063600000000, 0.023200000000, 0.000000000000
- 680, 0.046770000000, 0.017000000000, 0.000000000000
- 685, 0.032900000000, 0.011920000000, 0.000000000000
- 690, 0.022700000000, 0.008210000000, 0.000000000000
- 695, 0.015840000000, 0.005723000000, 0.000000000000
- 700, 0.011359160000, 0.004102000000, 0.000000000000
- 705, 0.008110916000, 0.002929000000, 0.000000000000
- 710, 0.005790346000, 0.002091000000, 0.000000000000
- 715, 0.004109457000, 0.001484000000, 0.000000000000
- 720, 0.002899327000, 0.001047000000, 0.000000000000
- 725, 0.002049190000, 0.000740000000, 0.000000000000
- 730, 0.001439971000, 0.000520000000, 0.000000000000
- 735, 0.000999949300, 0.000361100000, 0.000000000000
- 740, 0.000690078600, 0.000249200000, 0.000000000000
- 745, 0.000476021300, 0.000171900000, 0.000000000000
- 750, 0.000332301100, 0.000120000000, 0.000000000000
- 755, 0.000234826100, 0.000084800000, 0.000000000000
- 760, 0.000166150500, 0.000060000000, 0.000000000000
- 765, 0.000117413000, 0.000042400000, 0.000000000000
- 770, 0.000083075270, 0.000030000000, 0.000000000000
- 775, 0.000058706520, 0.000021200000, 0.000000000000
- 780, 0.000041509940, 0.000014990000, 0.000000000000
- 785, 0.000029353260, 0.000010600000, 0.000000000000
- 790, 0.000020673830, 0.000007465700, 0.000000000000
- 795, 0.000014559770, 0.000005257800, 0.000000000000
- 800, 0.000010253980, 0.000003702900, 0.000000000000
- 805, 0.000007221456, 0.000002607800, 0.000000000000
- 810, 0.000005085868, 0.000001836600, 0.000000000000
- 815, 0.000003581652, 0.000001293400, 0.000000000000
- 820, 0.000002522525, 0.000000910930, 0.000000000000
- 825, 0.000001776509, 0.000000641530, 0.000000000000
- 830, 0.000001251141, 0.000000451810, 0.000000000000];
-
- case 'stiles_2'
-
- cmf = [390, 1.83970e-003, -4.53930e-004, 1.21520e-002
- 395, 4.61530e-003, -1.04640e-003, 3.11100e-002
- 400, 9.62640e-003, -2.16890e-003, 6.23710e-002
- 405, 1.89790e-002, -4.43040e-003, 1.31610e-001
- 410, 3.08030e-002, -7.20480e-003, 2.27500e-001
- 415, 4.24590e-002, -1.25790e-002, 3.58970e-001
- 420, 5.16620e-002, -1.66510e-002, 5.23960e-001
- 425, 5.28370e-002, -2.12400e-002, 6.85860e-001
- 430, 4.42870e-002, -1.99360e-002, 7.96040e-001
- 435, 3.22200e-002, -1.60970e-002, 8.94590e-001
- 440, 1.47630e-002, -7.34570e-003, 9.63950e-001
- 445, -2.33920e-003, 1.36900e-003, 9.98140e-001
- 450, -2.91300e-002, 1.96100e-002, 9.18750e-001
- 455, -6.06770e-002, 4.34640e-002, 8.24870e-001
- 460, -9.62240e-002, 7.09540e-002, 7.85540e-001
- 465, -1.37590e-001, 1.10220e-001, 6.67230e-001
- 470, -1.74860e-001, 1.50880e-001, 6.10980e-001
- 475, -2.12600e-001, 1.97940e-001, 4.88290e-001
- 480, -2.37800e-001, 2.40420e-001, 3.61950e-001
- 485, -2.56740e-001, 2.79930e-001, 2.66340e-001
- 490, -2.77270e-001, 3.33530e-001, 1.95930e-001
- 495, -2.91250e-001, 4.05210e-001, 1.47300e-001
- 500, -2.95000e-001, 4.90600e-001, 1.07490e-001
- 505, -2.97060e-001, 5.96730e-001, 7.67140e-002
- 510, -2.67590e-001, 7.01840e-001, 5.02480e-002
- 515, -2.17250e-001, 8.08520e-001, 2.87810e-002
- 520, -1.47680e-001, 9.10760e-001, 1.33090e-002
- 525, -3.51840e-002, 9.84820e-001, 2.11700e-003
- 530, 1.06140e-001, 1.03390e+000, -4.15740e-003
- 535, 2.59810e-001, 1.05380e+000, -8.30320e-003
- 540, 4.19760e-001, 1.05120e+000, -1.21910e-002
- 545, 5.92590e-001, 1.04980e+000, -1.40390e-002
- 550, 7.90040e-001, 1.03680e+000, -1.46810e-002
- 555, 1.00780e+000, 9.98260e-001, -1.49470e-002
- 560, 1.22830e+000, 9.37830e-001, -1.46130e-002
- 565, 1.47270e+000, 8.80390e-001, -1.37820e-002
- 570, 1.74760e+000, 8.28350e-001, -1.26500e-002
- 575, 2.02140e+000, 7.46860e-001, -1.13560e-002
- 580, 2.27240e+000, 6.49300e-001, -9.93170e-003
- 585, 2.48960e+000, 5.63170e-001, -8.41480e-003
- 590, 2.67250e+000, 4.76750e-001, -7.02100e-003
- 595, 2.80930e+000, 3.84840e-001, -5.74370e-003
- 600, 2.87170e+000, 3.00690e-001, -4.27430e-003
- 605, 2.85250e+000, 2.28530e-001, -2.91320e-003
- 610, 2.76010e+000, 1.65750e-001, -2.26930e-003
- 615, 2.59890e+000, 1.13730e-001, -1.99660e-003
- 620, 2.37430e+000, 7.46820e-002, -1.50690e-003
- 625, 2.10540e+000, 4.65040e-002, -9.38220e-004
- 630, 1.81450e+000, 2.63330e-002, -5.53160e-004
- 635, 1.52470e+000, 1.27240e-002, -3.16680e-004
- 640, 1.25430e+000, 4.50330e-003, -1.43190e-004
- 645, 1.00760e+000, 9.66110e-005, -4.08310e-006
- 650, 7.86420e-001, -1.96450e-003, 1.10810e-004
- 655, 5.96590e-001, -2.63270e-003, 1.91750e-004
- 660, 4.43200e-001, -2.62620e-003, 2.26560e-004
- 665, 3.24100e-001, -2.30270e-003, 2.15200e-004
- 670, 2.34550e-001, -1.87000e-003, 1.63610e-004
- 675, 1.68840e-001, -1.44240e-003, 9.71640e-005
- 680, 1.20860e-001, -1.07550e-003, 5.10330e-005
- 685, 8.58110e-002, -7.90040e-004, 3.52710e-005
- 690, 6.02600e-002, -5.67650e-004, 3.12110e-005
- 695, 4.14800e-002, -3.92740e-004, 2.45080e-005
- 700, 2.81140e-002, -2.62310e-004, 1.65210e-005
- 705, 1.91170e-002, -1.75120e-004, 1.11240e-005
- 710, 1.33050e-002, -1.21400e-004, 8.69650e-006
- 715, 9.40920e-003, -8.57600e-005, 7.43510e-006
- 720, 6.51770e-003, -5.76770e-005, 6.10570e-006
- 725, 4.53770e-003, -3.90030e-005, 5.02770e-006
- 730, 3.17420e-003, -2.65110e-005, 4.12510e-006];
-
- case 'stiles_10'
-
- cmf = [390, 1.5000E-03, -4.0000E-04, 6.2000E-03
- 395, 3.8000E-03, -1.0000E-03, 1.6100E-02
- 400, 8.9000E-03, -2.5000E-03, 4.0000E-02
- 405, 1.8800E-02, -5.9000E-03, 9.0600E-02
- 410, 3.5000E-02, -1.1900E-02, 1.8020E-01
- 415, 5.3100E-02, -2.0100E-02, 3.0880E-01
- 420, 7.0200E-02, -2.8900E-02, 4.6700E-01
- 425, 7.6300E-02, -3.3800E-02, 6.1520E-01
- 430, 7.4500E-02, -3.4900E-02, 7.6380E-01
- 435, 5.6100E-02, -2.7600E-02, 8.7780E-01
- 440, 3.2300E-02, -1.6900E-02, 9.7550E-01
- 445, -4.4000E-03, 2.4000E-03, 1.0019E+00
- 450, -4.7800E-02, 2.8300E-02, 9.9960E-01
- 455, -9.7000E-02, 6.3600E-02, 9.1390E-01
- 460, -1.5860E-01, 1.0820E-01, 8.2970E-01
- 465, -2.2350E-01, 1.6170E-01, 7.4170E-01
- 470, -2.8480E-01, 2.2010E-01, 6.1340E-01
- 475, -3.3460E-01, 2.7960E-01, 4.7200E-01
- 480, -3.7760E-01, 3.4280E-01, 3.4950E-01
- 485, -4.1360E-01, 4.0860E-01, 2.5640E-01
- 490, -4.3170E-01, 4.7160E-01, 1.8190E-01
- 495, -4.4520E-01, 5.4910E-01, 1.3070E-01
- 500, -4.3500E-01, 6.2600E-01, 9.1000E-02
- 505, -4.1400E-01, 7.0970E-01, 5.8000E-02
- 510, -3.6730E-01, 7.9350E-01, 3.5700E-02
- 515, -2.8450E-01, 8.7150E-01, 2.0000E-02
- 520, -1.8550E-01, 9.4770E-01, 9.5000E-03
- 525, -4.3500E-02, 9.9450E-01, 7.0000E-04
- 530, 1.2700E-01, 1.0203E+00, -4.3000E-03
- 535, 3.1290E-01, 1.0375E+00, -6.4000E-03
- 540, 5.3620E-01, 1.0517E+00, -8.2000E-03
- 545, 7.7220E-01, 1.0390E+00, -9.4000E-03
- 550, 1.0059E+00, 1.0029E+00, -9.7000E-03
- 555, 1.2710E+00, 9.6980E-01, -9.7000E-03
- 560, 1.5574E+00, 9.1620E-01, -9.3000E-03
- 565, 1.8465E+00, 8.5710E-01, -8.7000E-03
- 570, 2.1511E+00, 7.8230E-01, -8.0000E-03
- 575, 2.4250E+00, 6.9530E-01, -7.3000E-03
- 580, 2.6574E+00, 5.9660E-01, -6.3000E-03
- 585, 2.9151E+00, 5.0630E-01, -5.3700E-03
- 590, 3.0779E+00, 4.2030E-01, -4.4500E-03
- 595, 3.1613E+00, 3.3600E-01, -3.5700E-03
- 600, 3.1673E+00, 2.5910E-01, -2.7700E-03
- 605, 3.1048E+00, 1.9170E-01, -2.0800E-03
- 610, 2.9462E+00, 1.3670E-01, -1.5000E-03
- 615, 2.7194E+00, 9.3800E-02, -1.0300E-03
- 620, 2.4526E+00, 6.1100E-02, -6.8000E-04
- 625, 2.1700E+00, 3.7100E-02, -4.4200E-04
- 630, 1.8358E+00, 2.1500E-02, -2.7200E-04
- 635, 1.5179E+00, 1.1200E-02, -1.4100E-04
- 640, 1.2428E+00, 4.4000E-03, -5.4900E-05
- 645, 1.0070E+00, 7.8000E-05, -2.2000E-06
- 650, 7.8270E-01, -1.3680E-03, 2.3700E-05
- 655, 5.9340E-01, -1.9880E-03, 2.8600E-05
- 660, 4.4420E-01, -2.1680E-03, 2.6100E-05
- 665, 3.2830E-01, -2.0060E-03, 2.2500E-05
- 670, 2.3940E-01, -1.6420E-03, 1.8200E-05
- 675, 1.7220E-01, -1.2720E-03, 1.3900E-05
- 680, 1.2210E-01, -9.4700E-04, 1.0300E-05
- 685, 8.5300E-02, -6.8300E-04, 7.3800E-06
- 690, 5.8600E-02, -4.7800E-04, 5.2200E-06
- 695, 4.0800E-02, -3.3700E-04, 3.6700E-06
- 700, 2.8400E-02, -2.3500E-04, 2.5600E-06
- 705, 1.9700E-02, -1.6300E-04, 1.7600E-06
- 710, 1.3500E-02, -1.1100E-04, 1.2000E-06
- 715, 9.2400E-03, -7.4800E-05, 8.1700E-07
- 720, 6.3800E-03, -5.0800E-05, 5.5500E-07
- 725, 4.4100E-03, -3.4400E-05, 3.7500E-07
- 730, 3.0700E-03, -2.3400E-05, 2.5400E-07
- 735, 2.1400E-03, -1.5900E-05, 1.7100E-07
- 740, 1.4900E-03, -1.0700E-05, 1.1600E-07
- 745, 1.0500E-03, -7.2300E-06, 7.8500E-08
- 750, 7.3900E-04, -4.8700E-06, 5.3100E-08
- 755, 5.2300E-04, -3.2900E-06, 3.6000E-08
- 760, 3.7200E-04, -2.2200E-06, 2.4400E-08
- 765, 2.6500E-04, -1.5000E-06, 1.6500E-08
- 770, 1.9000E-04, -1.0200E-06, 1.1200E-08
- 775, 1.3600E-04, -6.8800E-07, 7.5300E-09
- 780, 9.8400E-05, -4.6500E-07, 5.0700E-09
- 785, 7.1300E-05, -3.1200E-07, 3.4000E-09
- 790, 5.1800E-05, -2.0800E-07, 2.2700E-09
- 795, 3.7700E-05, -1.3700E-07, 1.5000E-09
- 800, 2.7600E-05, -8.8000E-08, 9.8600E-10
- 805, 2.0300E-05, -5.5300E-08, 6.3900E-10
- 810, 1.4900E-05, -3.3600E-08, 4.0700E-10
- 815, 1.1000E-05, -1.9600E-08, 2.5300E-10
- 820, 8.1800E-06, -1.0900E-08, 1.5200E-10
- 825, 6.0900E-06, -5.7000E-09, 8.6400E-11
- 830, 4.5500E-06, -2.7700E-09, 4.4200E-11];
-
- case 'cie_1964'
-
- cmf = [360, 0.000000122200, 0.000000013398, 0.000000535027
- 365, 0.000000919270, 0.000000100650, 0.000004028300
- 370, 0.000005958600, 0.000000651100, 0.000026143700
- 375, 0.000033266000, 0.000003625000, 0.000146220000
- 380, 0.000159952000, 0.000017364000, 0.000704776000
- 385, 0.000662440000, 0.000071560000, 0.002927800000
- 390, 0.002361600000, 0.000253400000, 0.010482200000
- 395, 0.007242300000, 0.000768500000, 0.032344000000
- 400, 0.019109700000, 0.002004400000, 0.086010900000
- 405, 0.043400000000, 0.004509000000, 0.197120000000
- 410, 0.084736000000, 0.008756000000, 0.389366000000
- 415, 0.140638000000, 0.014456000000, 0.656760000000
- 420, 0.204492000000, 0.021391000000, 0.972542000000
- 425, 0.264737000000, 0.029497000000, 1.282500000000
- 430, 0.314679000000, 0.038676000000, 1.553480000000
- 435, 0.357719000000, 0.049602000000, 1.798500000000
- 440, 0.383734000000, 0.062077000000, 1.967280000000
- 445, 0.386726000000, 0.074704000000, 2.027300000000
- 450, 0.370702000000, 0.089456000000, 1.994800000000
- 455, 0.342957000000, 0.106256000000, 1.900700000000
- 460, 0.302273000000, 0.128201000000, 1.745370000000
- 465, 0.254085000000, 0.152761000000, 1.554900000000
- 470, 0.195618000000, 0.185190000000, 1.317560000000
- 475, 0.132349000000, 0.219940000000, 1.030200000000
- 480, 0.080507000000, 0.253589000000, 0.772125000000
- 485, 0.041072000000, 0.297665000000, 0.570060000000
- 490, 0.016172000000, 0.339133000000, 0.415254000000
- 495, 0.005132000000, 0.395379000000, 0.302356000000
- 500, 0.003816000000, 0.460777000000, 0.218502000000
- 505, 0.015444000000, 0.531360000000, 0.159249000000
- 510, 0.037465000000, 0.606741000000, 0.112044000000
- 515, 0.071358000000, 0.685660000000, 0.082248000000
- 520, 0.117749000000, 0.761757000000, 0.060709000000
- 525, 0.172953000000, 0.823330000000, 0.043050000000
- 530, 0.236491000000, 0.875211000000, 0.030451000000
- 535, 0.304213000000, 0.923810000000, 0.020584000000
- 540, 0.376772000000, 0.961988000000, 0.013676000000
- 545, 0.451584000000, 0.982200000000, 0.007918000000
- 550, 0.529826000000, 0.991761000000, 0.003988000000
- 555, 0.616053000000, 0.999110000000, 0.001091000000
- 560, 0.705224000000, 0.997340000000, 0
- 565, 0.793832000000, 0.982380000000, 0
- 570, 0.878655000000, 0.955552000000, 0
- 575, 0.951162000000, 0.915175000000, 0
- 580, 1.014160000000, 0.868934000000, 0
- 585, 1.074300000000, 0.825623000000, 0
- 590, 1.118520000000, 0.777405000000, 0
- 595, 1.134300000000, 0.720353000000, 0
- 600, 1.123990000000, 0.658341000000, 0
- 605, 1.089100000000, 0.593878000000, 0
- 610, 1.030480000000, 0.527963000000, 0
- 615, 0.950740000000, 0.461834000000, 0
- 620, 0.856297000000, 0.398057000000, 0
- 625, 0.754930000000, 0.339554000000, 0
- 630, 0.647467000000, 0.283493000000, 0
- 635, 0.535110000000, 0.228254000000, 0
- 640, 0.431567000000, 0.179828000000, 0
- 645, 0.343690000000, 0.140211000000, 0
- 650, 0.268329000000, 0.107633000000, 0
- 655, 0.204300000000, 0.081187000000, 0
- 660, 0.152568000000, 0.060281000000, 0
- 665, 0.112210000000, 0.044096000000, 0
- 670, 0.081260600000, 0.031800400000, 0
- 675, 0.057930000000, 0.022601700000, 0
- 680, 0.040850800000, 0.015905100000, 0
- 685, 0.028623000000, 0.011130300000, 0
- 690, 0.019941300000, 0.007748800000, 0
- 695, 0.013842000000, 0.005375100000, 0
- 700, 0.009576880000, 0.003717740000, 0
- 705, 0.006605200000, 0.002564560000, 0
- 710, 0.004552630000, 0.001768470000, 0
- 715, 0.003144700000, 0.001222390000, 0
- 720, 0.002174960000, 0.000846190000, 0
- 725, 0.001505700000, 0.000586440000, 0
- 730, 0.001044760000, 0.000407410000, 0
- 735, 0.000727450000, 0.000284041000, 0
- 740, 0.000508258000, 0.000198730000, 0
- 745, 0.000356380000, 0.000139550000, 0
- 750, 0.000250969000, 0.000098428000, 0
- 755, 0.000177730000, 0.000069819000, 0
- 760, 0.000126390000, 0.000049737000, 0
- 765, 0.000090151000, 0.000035540500, 0
- 770, 0.000064525800, 0.000025486000, 0
- 775, 0.000046339000, 0.000018338400, 0
- 780, 0.000033411700, 0.000013249000, 0
- 785, 0.000024209000, 0.000009619600, 0
- 790, 0.000017611500, 0.000007012800, 0
- 795, 0.000012855000, 0.000005129800, 0
- 800, 0.000009413630, 0.000003764730, 0
- 805, 0.000006913000, 0.000002770810, 0
- 810, 0.000005093470, 0.000002046130, 0
- 815, 0.000003767100, 0.000001516770, 0
- 820, 0.000002795310, 0.000001128090, 0
- 825, 0.000002082000, 0.000000842160, 0
- 830, 0.000001553140, 0.000000629700, 0];
-
- case '1931_full'
-
- cmf = [360, 0.000129900000, 0.000003917000, 0.000606100000
- 361, 0.000145847000, 0.000004393581, 0.000680879200
- 362, 0.000163802100, 0.000004929604, 0.000765145600
- 363, 0.000184003700, 0.000005532136, 0.000860012400
- 364, 0.000206690200, 0.000006208245, 0.000966592800
- 365, 0.000232100000, 0.000006965000, 0.001086000000
- 366, 0.000260728000, 0.000007813219, 0.001220586000
- 367, 0.000293075000, 0.000008767336, 0.001372729000
- 368, 0.000329388000, 0.000009839844, 0.001543579000
- 369, 0.000369914000, 0.000011043230, 0.001734286000
- 370, 0.000414900000, 0.000012390000, 0.001946000000
- 371, 0.000464158700, 0.000013886410, 0.002177777000
- 372, 0.000518986000, 0.000015557280, 0.002435809000
- 373, 0.000581854000, 0.000017442960, 0.002731953000
- 374, 0.000655234700, 0.000019583750, 0.003078064000
- 375, 0.000741600000, 0.000022020000, 0.003486000000
- 376, 0.000845029600, 0.000024839650, 0.003975227000
- 377, 0.000964526800, 0.000028041260, 0.004540880000
- 378, 0.001094949000, 0.000031531040, 0.005158320000
- 379, 0.001231154000, 0.000035215210, 0.005802907000
- 380, 0.001368000000, 0.000039000000, 0.006450001000
- 381, 0.001502050000, 0.000042826400, 0.007083216000
- 382, 0.001642328000, 0.000046914600, 0.007745488000
- 383, 0.001802382000, 0.000051589600, 0.008501152000
- 384, 0.001995757000, 0.000057176400, 0.009414544000
- 385, 0.002236000000, 0.000064000000, 0.010549990000
- 386, 0.002535385000, 0.000072344210, 0.011965800000
- 387, 0.002892603000, 0.000082212240, 0.013655870000
- 388, 0.003300829000, 0.000093508160, 0.015588050000
- 389, 0.003753236000, 0.000106136100, 0.017730150000
- 390, 0.004243000000, 0.000120000000, 0.020050010000
- 391, 0.004762389000, 0.000134984000, 0.022511360000
- 392, 0.005330048000, 0.000151492000, 0.025202880000
- 393, 0.005978712000, 0.000170208000, 0.028279720000
- 394, 0.006741117000, 0.000191816000, 0.031897040000
- 395, 0.007650000000, 0.000217000000, 0.036210000000
- 396, 0.008751373000, 0.000246906700, 0.041437710000
- 397, 0.010028880000, 0.000281240000, 0.047503720000
- 398, 0.011421700000, 0.000318520000, 0.054119880000
- 399, 0.012869010000, 0.000357266700, 0.060998030000
- 400, 0.014310000000, 0.000396000000, 0.067850010000
- 401, 0.015704430000, 0.000433714700, 0.074486320000
- 402, 0.017147440000, 0.000473024000, 0.081361560000
- 403, 0.018781220000, 0.000517876000, 0.089153640000
- 404, 0.020748010000, 0.000572218700, 0.098540480000
- 405, 0.023190000000, 0.000640000000, 0.110200000000
- 406, 0.026207360000, 0.000724560000, 0.124613300000
- 407, 0.029782480000, 0.000825500000, 0.141701700000
- 408, 0.033880920000, 0.000941160000, 0.161303500000
- 409, 0.038468240000, 0.001069880000, 0.183256800000
- 410, 0.043510000000, 0.001210000000, 0.207400000000
- 411, 0.048995600000, 0.001362091000, 0.233692100000
- 412, 0.055022600000, 0.001530752000, 0.262611400000
- 413, 0.061718800000, 0.001720368000, 0.294774600000
- 414, 0.069212000000, 0.001935323000, 0.330798500000
- 415, 0.077630000000, 0.002180000000, 0.371300000000
- 416, 0.086958110000, 0.002454800000, 0.416209100000
- 417, 0.097176720000, 0.002764000000, 0.465464200000
- 418, 0.108406300000, 0.003117800000, 0.519694800000
- 419, 0.120767200000, 0.003526400000, 0.579530300000
- 420, 0.134380000000, 0.004000000000, 0.645600000000
- 421, 0.149358200000, 0.004546240000, 0.718483800000
- 422, 0.165395700000, 0.005159320000, 0.796713300000
- 423, 0.181983100000, 0.005829280000, 0.877845900000
- 424, 0.198611000000, 0.006546160000, 0.959439000000
- 425, 0.214770000000, 0.007300000000, 1.039050100000
- 426, 0.230186800000, 0.008086507000, 1.115367300000
- 427, 0.244879700000, 0.008908720000, 1.188497100000
- 428, 0.258777300000, 0.009767680000, 1.258123300000
- 429, 0.271807900000, 0.010664430000, 1.323929600000
- 430, 0.283900000000, 0.011600000000, 1.385600000000
- 431, 0.294943800000, 0.012573170000, 1.442635200000
- 432, 0.304896500000, 0.013582720000, 1.494803500000
- 433, 0.313787300000, 0.014629680000, 1.542190300000
- 434, 0.321645400000, 0.015715090000, 1.584880700000
- 435, 0.328500000000, 0.016840000000, 1.622960000000
- 436, 0.334351300000, 0.018007360000, 1.656404800000
- 437, 0.339210100000, 0.019214480000, 1.685295900000
- 438, 0.343121300000, 0.020453920000, 1.709874500000
- 439, 0.346129600000, 0.021718240000, 1.730382100000
- 440, 0.348280000000, 0.023000000000, 1.747060000000
- 441, 0.349599900000, 0.024294610000, 1.760044600000
- 442, 0.350147400000, 0.025610240000, 1.769623300000
- 443, 0.350013000000, 0.026958570000, 1.776263700000
- 444, 0.349287000000, 0.028351250000, 1.780433400000
- 445, 0.348060000000, 0.029800000000, 1.782600000000
- 446, 0.346373300000, 0.031310830000, 1.782968200000
- 447, 0.344262400000, 0.032883680000, 1.781699800000
- 448, 0.341808800000, 0.034521120000, 1.779198200000
- 449, 0.339094100000, 0.036225710000, 1.775867100000
- 450, 0.336200000000, 0.038000000000, 1.772110000000
- 451, 0.333197700000, 0.039846670000, 1.768258900000
- 452, 0.330041100000, 0.041768000000, 1.764039000000
- 453, 0.326635700000, 0.043766000000, 1.758943800000
- 454, 0.322886800000, 0.045842670000, 1.752466300000
- 455, 0.318700000000, 0.048000000000, 1.744100000000
- 456, 0.314025100000, 0.050243680000, 1.733559500000
- 457, 0.308884000000, 0.052573040000, 1.720858100000
- 458, 0.303290400000, 0.054980560000, 1.705936900000
- 459, 0.297257900000, 0.057458720000, 1.688737200000
- 460, 0.290800000000, 0.060000000000, 1.669200000000
- 461, 0.283970100000, 0.062601970000, 1.647528700000
- 462, 0.276721400000, 0.065277520000, 1.623412700000
- 463, 0.268917800000, 0.068042080000, 1.596022300000
- 464, 0.260422700000, 0.070911090000, 1.564528000000
- 465, 0.251100000000, 0.073900000000, 1.528100000000
- 466, 0.240847500000, 0.077016000000, 1.486111400000
- 467, 0.229851200000, 0.080266400000, 1.439521500000
- 468, 0.218407200000, 0.083666800000, 1.389879900000
- 469, 0.206811500000, 0.087232800000, 1.338736200000
- 470, 0.195360000000, 0.090980000000, 1.287640000000
- 471, 0.184213600000, 0.094917550000, 1.237422300000
- 472, 0.173327300000, 0.099045840000, 1.187824300000
- 473, 0.162688100000, 0.103367400000, 1.138761100000
- 474, 0.152283300000, 0.107884600000, 1.090148000000
- 475, 0.142100000000, 0.112600000000, 1.041900000000
- 476, 0.132178600000, 0.117532000000, 0.994197600000
- 477, 0.122569600000, 0.122674400000, 0.947347300000
- 478, 0.113275200000, 0.127992800000, 0.901453100000
- 479, 0.104297900000, 0.133452800000, 0.856619300000
- 480, 0.095640000000, 0.139020000000, 0.812950100000
- 481, 0.087299550000, 0.144676400000, 0.770517300000
- 482, 0.079308040000, 0.150469300000, 0.729444800000
- 483, 0.071717760000, 0.156461900000, 0.689913600000
- 484, 0.064580990000, 0.162717700000, 0.652104900000
- 485, 0.057950010000, 0.169300000000, 0.616200000000
- 486, 0.051862110000, 0.176243100000, 0.582328600000
- 487, 0.046281520000, 0.183558100000, 0.550416200000
- 488, 0.041150880000, 0.191273500000, 0.520337600000
- 489, 0.036412830000, 0.199418000000, 0.491967300000
- 490, 0.032010000000, 0.208020000000, 0.465180000000
- 491, 0.027917200000, 0.217119900000, 0.439924600000
- 492, 0.024144400000, 0.226734500000, 0.416183600000
- 493, 0.020687000000, 0.236857100000, 0.393882200000
- 494, 0.017540400000, 0.247481200000, 0.372945900000
- 495, 0.014700000000, 0.258600000000, 0.353300000000
- 496, 0.012161790000, 0.270184900000, 0.334857800000
- 497, 0.009919960000, 0.282293900000, 0.317552100000
- 498, 0.007967240000, 0.295050500000, 0.301337500000
- 499, 0.006296346000, 0.308578000000, 0.286168600000
- 500, 0.004900000000, 0.323000000000, 0.272000000000
- 501, 0.003777173000, 0.338402100000, 0.258817100000
- 502, 0.002945320000, 0.354685800000, 0.246483800000
- 503, 0.002424880000, 0.371698600000, 0.234771800000
- 504, 0.002236293000, 0.389287500000, 0.223453300000
- 505, 0.002400000000, 0.407300000000, 0.212300000000
- 506, 0.002925520000, 0.425629900000, 0.201169200000
- 507, 0.003836560000, 0.444309600000, 0.190119600000
- 508, 0.005174840000, 0.463394400000, 0.179225400000
- 509, 0.006982080000, 0.482939500000, 0.168560800000
- 510, 0.009300000000, 0.503000000000, 0.158200000000
- 511, 0.012149490000, 0.523569300000, 0.148138300000
- 512, 0.015535880000, 0.544512000000, 0.138375800000
- 513, 0.019477520000, 0.565690000000, 0.128994200000
- 514, 0.023992770000, 0.586965300000, 0.120075100000
- 515, 0.029100000000, 0.608200000000, 0.111700000000
- 516, 0.034814850000, 0.629345600000, 0.103904800000
- 517, 0.041120160000, 0.650306800000, 0.096667480000
- 518, 0.047985040000, 0.670875200000, 0.089982720000
- 519, 0.055378610000, 0.690842400000, 0.083845310000
- 520, 0.063270000000, 0.710000000000, 0.078249990000
- 521, 0.071635010000, 0.728185200000, 0.073208990000
- 522, 0.080462240000, 0.745463600000, 0.068678160000
- 523, 0.089739960000, 0.761969400000, 0.064567840000
- 524, 0.099456450000, 0.777836800000, 0.060788350000
- 525, 0.109600000000, 0.793200000000, 0.057250010000
- 526, 0.120167400000, 0.808110400000, 0.053904350000
- 527, 0.131114500000, 0.822496200000, 0.050746640000
- 528, 0.142367900000, 0.836306800000, 0.047752760000
- 529, 0.153854200000, 0.849491600000, 0.044898590000
- 530, 0.165500000000, 0.862000000000, 0.042160000000
- 531, 0.177257100000, 0.873810800000, 0.039507280000
- 532, 0.189140000000, 0.884962400000, 0.036935640000
- 533, 0.201169400000, 0.895493600000, 0.034458360000
- 534, 0.213365800000, 0.905443200000, 0.032088720000
- 535, 0.225749900000, 0.914850100000, 0.029840000000
- 536, 0.238320900000, 0.923734800000, 0.027711810000
- 537, 0.251066800000, 0.932092400000, 0.025694440000
- 538, 0.263992200000, 0.939922600000, 0.023787160000
- 539, 0.277101700000, 0.947225200000, 0.021989250000
- 540, 0.290400000000, 0.954000000000, 0.020300000000
- 541, 0.303891200000, 0.960256100000, 0.018718050000
- 542, 0.317572600000, 0.966007400000, 0.017240360000
- 543, 0.331438400000, 0.971260600000, 0.015863640000
- 544, 0.345482800000, 0.976022500000, 0.014584610000
- 545, 0.359700000000, 0.980300000000, 0.013400000000
- 546, 0.374083900000, 0.984092400000, 0.012307230000
- 547, 0.388639600000, 0.987418200000, 0.011301880000
- 548, 0.403378400000, 0.990312800000, 0.010377920000
- 549, 0.418311500000, 0.992811600000, 0.009529306000
- 550, 0.433449900000, 0.994950100000, 0.008749999000
- 551, 0.448795300000, 0.996710800000, 0.008035200000
- 552, 0.464336000000, 0.998098300000, 0.007381600000
- 553, 0.480064000000, 0.999112000000, 0.006785400000
- 554, 0.495971300000, 0.999748200000, 0.006242800000
- 555, 0.512050100000, 1.000000000000, 0.005749999000
- 556, 0.528295900000, 0.999856700000, 0.005303600000
- 557, 0.544691600000, 0.999304600000, 0.004899800000
- 558, 0.561209400000, 0.998325500000, 0.004534200000
- 559, 0.577821500000, 0.996898700000, 0.004202400000
- 560, 0.594500000000, 0.995000000000, 0.003900000000
- 561, 0.611220900000, 0.992600500000, 0.003623200000
- 562, 0.627975800000, 0.989742600000, 0.003370600000
- 563, 0.644760200000, 0.986444400000, 0.003141400000
- 564, 0.661569700000, 0.982724100000, 0.002934800000
- 565, 0.678400000000, 0.978600000000, 0.002749999000
- 566, 0.695239200000, 0.974083700000, 0.002585200000
- 567, 0.712058600000, 0.969171200000, 0.002438600000
- 568, 0.728828400000, 0.963856800000, 0.002309400000
- 569, 0.745518800000, 0.958134900000, 0.002196800000
- 570, 0.762100000000, 0.952000000000, 0.002100000000
- 571, 0.778543200000, 0.945450400000, 0.002017733000
- 572, 0.794825600000, 0.938499200000, 0.001948200000
- 573, 0.810926400000, 0.931162800000, 0.001889800000
- 574, 0.826824800000, 0.923457600000, 0.001840933000
- 575, 0.842500000000, 0.915400000000, 0.001800000000
- 576, 0.857932500000, 0.907006400000, 0.001766267000
- 577, 0.873081600000, 0.898277200000, 0.001737800000
- 578, 0.887894400000, 0.889204800000, 0.001711200000
- 579, 0.902318100000, 0.879781600000, 0.001683067000
- 580, 0.916300000000, 0.870000000000, 0.001650001000
- 581, 0.929799500000, 0.859861300000, 0.001610133000
- 582, 0.942798400000, 0.849392000000, 0.001564400000
- 583, 0.955277600000, 0.838622000000, 0.001513600000
- 584, 0.967217900000, 0.827581300000, 0.001458533000
- 585, 0.978600000000, 0.816300000000, 0.001400000000
- 586, 0.989385600000, 0.804794700000, 0.001336667000
- 587, 0.999548800000, 0.793082000000, 0.001270000000
- 588, 1.009089200000, 0.781192000000, 0.001205000000
- 589, 1.018006400000, 0.769154700000, 0.001146667000
- 590, 1.026300000000, 0.757000000000, 0.001100000000
- 591, 1.033982700000, 0.744754100000, 0.001068800000
- 592, 1.040986000000, 0.732422400000, 0.001049400000
- 593, 1.047188000000, 0.720003600000, 0.001035600000
- 594, 1.052466700000, 0.707496500000, 0.001021200000
- 595, 1.056700000000, 0.694900000000, 0.001000000000
- 596, 1.059794400000, 0.682219200000, 0.000968640000
- 597, 1.061799200000, 0.669471600000, 0.000929920000
- 598, 1.062806800000, 0.656674400000, 0.000886880000
- 599, 1.062909600000, 0.643844800000, 0.000842560000
- 600, 1.062200000000, 0.631000000000, 0.000800000000
- 601, 1.060735200000, 0.618155500000, 0.000760960000
- 602, 1.058443600000, 0.605314400000, 0.000723680000
- 603, 1.055224400000, 0.592475600000, 0.000685920000
- 604, 1.050976800000, 0.579637900000, 0.000645440000
- 605, 1.045600000000, 0.566800000000, 0.000600000000
- 606, 1.039036900000, 0.553961100000, 0.000547866700
- 607, 1.031360800000, 0.541137200000, 0.000491600000
- 608, 1.022666200000, 0.528352800000, 0.000435400000
- 609, 1.013047700000, 0.515632300000, 0.000383466700
- 610, 1.002600000000, 0.503000000000, 0.000340000000
- 611, 0.991367500000, 0.490468800000, 0.000307253300
- 612, 0.979331400000, 0.478030400000, 0.000283160000
- 613, 0.966491600000, 0.465677600000, 0.000265440000
- 614, 0.952847900000, 0.453403200000, 0.000251813300
- 615, 0.938400000000, 0.441200000000, 0.000240000000
- 616, 0.923194000000, 0.429080000000, 0.000229546700
- 617, 0.907244000000, 0.417036000000, 0.000220640000
- 618, 0.890502000000, 0.405032000000, 0.000211960000
- 619, 0.872920000000, 0.393032000000, 0.000202186700
- 620, 0.854449900000, 0.381000000000, 0.000190000000
- 621, 0.835084000000, 0.368918400000, 0.000174213300
- 622, 0.814946000000, 0.356827200000, 0.000155640000
- 623, 0.794186000000, 0.344776800000, 0.000135960000
- 624, 0.772954000000, 0.332817600000, 0.000116853300
- 625, 0.751400000000, 0.321000000000, 0.000100000000
- 626, 0.729583600000, 0.309338100000, 0.000086133330
- 627, 0.707588800000, 0.297850400000, 0.000074600000
- 628, 0.685602200000, 0.286593600000, 0.000065000000
- 629, 0.663810400000, 0.275624500000, 0.000056933330
- 630, 0.642400000000, 0.265000000000, 0.000049999990
- 631, 0.621514900000, 0.254763200000, 0.000044160000
- 632, 0.601113800000, 0.244889600000, 0.000039480000
- 633, 0.581105200000, 0.235334400000, 0.000035720000
- 634, 0.561397700000, 0.226052800000, 0.000032640000
- 635, 0.541900000000, 0.217000000000, 0.000030000000
- 636, 0.522599500000, 0.208161600000, 0.000027653330
- 637, 0.503546400000, 0.199548800000, 0.000025560000
- 638, 0.484743600000, 0.191155200000, 0.000023640000
- 639, 0.466193900000, 0.182974400000, 0.000021813330
- 640, 0.447900000000, 0.175000000000, 0.000020000000
- 641, 0.429861300000, 0.167223500000, 0.000018133330
- 642, 0.412098000000, 0.159646400000, 0.000016200000
- 643, 0.394644000000, 0.152277600000, 0.000014200000
- 644, 0.377533300000, 0.145125900000, 0.000012133330
- 645, 0.360800000000, 0.138200000000, 0.000010000000
- 646, 0.344456300000, 0.131500300000, 0.000007733333
- 647, 0.328516800000, 0.125024800000, 0.000005400000
- 648, 0.313019200000, 0.118779200000, 0.000003200000
- 649, 0.298001100000, 0.112769100000, 0.000001333333
- 650, 0.283500000000, 0.107000000000, 0.000000000000
- 651, 0.269544800000, 0.101476200000, 0.000000000000
- 652, 0.256118400000, 0.096188640000, 0.000000000000
- 653, 0.243189600000, 0.091122960000, 0.000000000000
- 654, 0.230727200000, 0.086264850000, 0.000000000000
- 655, 0.218700000000, 0.081600000000, 0.000000000000
- 656, 0.207097100000, 0.077120640000, 0.000000000000
- 657, 0.195923200000, 0.072825520000, 0.000000000000
- 658, 0.185170800000, 0.068710080000, 0.000000000000
- 659, 0.174832300000, 0.064769760000, 0.000000000000
- 660, 0.164900000000, 0.061000000000, 0.000000000000
- 661, 0.155366700000, 0.057396210000, 0.000000000000
- 662, 0.146230000000, 0.053955040000, 0.000000000000
- 663, 0.137490000000, 0.050673760000, 0.000000000000
- 664, 0.129146700000, 0.047549650000, 0.000000000000
- 665, 0.121200000000, 0.044580000000, 0.000000000000
- 666, 0.113639700000, 0.041758720000, 0.000000000000
- 667, 0.106465000000, 0.039084960000, 0.000000000000
- 668, 0.099690440000, 0.036563840000, 0.000000000000
- 669, 0.093330610000, 0.034200480000, 0.000000000000
- 670, 0.087400000000, 0.032000000000, 0.000000000000
- 671, 0.081900960000, 0.029962610000, 0.000000000000
- 672, 0.076804280000, 0.028076640000, 0.000000000000
- 673, 0.072077120000, 0.026329360000, 0.000000000000
- 674, 0.067686640000, 0.024708050000, 0.000000000000
- 675, 0.063600000000, 0.023200000000, 0.000000000000
- 676, 0.059806850000, 0.021800770000, 0.000000000000
- 677, 0.056282160000, 0.020501120000, 0.000000000000
- 678, 0.052971040000, 0.019281080000, 0.000000000000
- 679, 0.049818610000, 0.018120690000, 0.000000000000
- 680, 0.046770000000, 0.017000000000, 0.000000000000
- 681, 0.043784050000, 0.015903790000, 0.000000000000
- 682, 0.040875360000, 0.014837180000, 0.000000000000
- 683, 0.038072640000, 0.013810680000, 0.000000000000
- 684, 0.035404610000, 0.012834780000, 0.000000000000
- 685, 0.032900000000, 0.011920000000, 0.000000000000
- 686, 0.030564190000, 0.011068310000, 0.000000000000
- 687, 0.028380560000, 0.010273390000, 0.000000000000
- 688, 0.026344840000, 0.009533311000, 0.000000000000
- 689, 0.024452750000, 0.008846157000, 0.000000000000
- 690, 0.022700000000, 0.008210000000, 0.000000000000
- 691, 0.021084290000, 0.007623781000, 0.000000000000
- 692, 0.019599880000, 0.007085424000, 0.000000000000
- 693, 0.018237320000, 0.006591476000, 0.000000000000
- 694, 0.016987170000, 0.006138485000, 0.000000000000
- 695, 0.015840000000, 0.005723000000, 0.000000000000
- 696, 0.014790640000, 0.005343059000, 0.000000000000
- 697, 0.013831320000, 0.004995796000, 0.000000000000
- 698, 0.012948680000, 0.004676404000, 0.000000000000
- 699, 0.012129200000, 0.004380075000, 0.000000000000
- 700, 0.011359160000, 0.004102000000, 0.000000000000
- 701, 0.010629350000, 0.003838453000, 0.000000000000
- 702, 0.009938846000, 0.003589099000, 0.000000000000
- 703, 0.009288422000, 0.003354219000, 0.000000000000
- 704, 0.008678854000, 0.003134093000, 0.000000000000
- 705, 0.008110916000, 0.002929000000, 0.000000000000
- 706, 0.007582388000, 0.002738139000, 0.000000000000
- 707, 0.007088746000, 0.002559876000, 0.000000000000
- 708, 0.006627313000, 0.002393244000, 0.000000000000
- 709, 0.006195408000, 0.002237275000, 0.000000000000
- 710, 0.005790346000, 0.002091000000, 0.000000000000
- 711, 0.005409826000, 0.001953587000, 0.000000000000
- 712, 0.005052583000, 0.001824580000, 0.000000000000
- 713, 0.004717512000, 0.001703580000, 0.000000000000
- 714, 0.004403507000, 0.001590187000, 0.000000000000
- 715, 0.004109457000, 0.001484000000, 0.000000000000
- 716, 0.003833913000, 0.001384496000, 0.000000000000
- 717, 0.003575748000, 0.001291268000, 0.000000000000
- 718, 0.003334342000, 0.001204092000, 0.000000000000
- 719, 0.003109075000, 0.001122744000, 0.000000000000
- 720, 0.002899327000, 0.001047000000, 0.000000000000
- 721, 0.002704348000, 0.000976589600, 0.000000000000
- 722, 0.002523020000, 0.000911108800, 0.000000000000
- 723, 0.002354168000, 0.000850133200, 0.000000000000
- 724, 0.002196616000, 0.000793238400, 0.000000000000
- 725, 0.002049190000, 0.000740000000, 0.000000000000
- 726, 0.001910960000, 0.000690082700, 0.000000000000
- 727, 0.001781438000, 0.000643310000, 0.000000000000
- 728, 0.001660110000, 0.000599496000, 0.000000000000
- 729, 0.001546459000, 0.000558454700, 0.000000000000
- 730, 0.001439971000, 0.000520000000, 0.000000000000
- 731, 0.001340042000, 0.000483913600, 0.000000000000
- 732, 0.001246275000, 0.000450052800, 0.000000000000
- 733, 0.001158471000, 0.000418345200, 0.000000000000
- 734, 0.001076430000, 0.000388718400, 0.000000000000
- 735, 0.000999949300, 0.000361100000, 0.000000000000
- 736, 0.000928735800, 0.000335383500, 0.000000000000
- 737, 0.000862433200, 0.000311440400, 0.000000000000
- 738, 0.000800750300, 0.000289165600, 0.000000000000
- 739, 0.000743396000, 0.000268453900, 0.000000000000
- 740, 0.000690078600, 0.000249200000, 0.000000000000
- 741, 0.000640515600, 0.000231301900, 0.000000000000
- 742, 0.000594502100, 0.000214685600, 0.000000000000
- 743, 0.000551864600, 0.000199288400, 0.000000000000
- 744, 0.000512429000, 0.000185047500, 0.000000000000
- 745, 0.000476021300, 0.000171900000, 0.000000000000
- 746, 0.000442453600, 0.000159778100, 0.000000000000
- 747, 0.000411511700, 0.000148604400, 0.000000000000
- 748, 0.000382981400, 0.000138301600, 0.000000000000
- 749, 0.000356649100, 0.000128792500, 0.000000000000
- 750, 0.000332301100, 0.000120000000, 0.000000000000
- 751, 0.000309758600, 0.000111859500, 0.000000000000
- 752, 0.000288887100, 0.000104322400, 0.000000000000
- 753, 0.000269539400, 0.000097335600, 0.000000000000
- 754, 0.000251568200, 0.000090845870, 0.000000000000
- 755, 0.000234826100, 0.000084800000, 0.000000000000
- 756, 0.000219171000, 0.000079146670, 0.000000000000
- 757, 0.000204525800, 0.000073858000, 0.000000000000
- 758, 0.000190840500, 0.000068916000, 0.000000000000
- 759, 0.000178065400, 0.000064302670, 0.000000000000
- 760, 0.000166150500, 0.000060000000, 0.000000000000
- 761, 0.000155023600, 0.000055981870, 0.000000000000
- 762, 0.000144621900, 0.000052225600, 0.000000000000
- 763, 0.000134909800, 0.000048718400, 0.000000000000
- 764, 0.000125852000, 0.000045447470, 0.000000000000
- 765, 0.000117413000, 0.000042400000, 0.000000000000
- 766, 0.000109551500, 0.000039561040, 0.000000000000
- 767, 0.000102224500, 0.000036915120, 0.000000000000
- 768, 0.000095394450, 0.000034448680, 0.000000000000
- 769, 0.000089023900, 0.000032148160, 0.000000000000
- 770, 0.000083075270, 0.000030000000, 0.000000000000
- 771, 0.000077512690, 0.000027991250, 0.000000000000
- 772, 0.000072313040, 0.000026113560, 0.000000000000
- 773, 0.000067457780, 0.000024360240, 0.000000000000
- 774, 0.000062928440, 0.000022724610, 0.000000000000
- 775, 0.000058706520, 0.000021200000, 0.000000000000
- 776, 0.000054770280, 0.000019778550, 0.000000000000
- 777, 0.000051099180, 0.000018452850, 0.000000000000
- 778, 0.000047676540, 0.000017216870, 0.000000000000
- 779, 0.000044485670, 0.000016064590, 0.000000000000
- 780, 0.000041509940, 0.000014990000, 0.000000000000
- 781, 0.000038733240, 0.000013987280, 0.000000000000
- 782, 0.000036142030, 0.000013051550, 0.000000000000
- 783, 0.000033723520, 0.000012178180, 0.000000000000
- 784, 0.000031464870, 0.000011362540, 0.000000000000
- 785, 0.000029353260, 0.000010600000, 0.000000000000
- 786, 0.000027375730, 0.000009885877, 0.000000000000
- 787, 0.000025524330, 0.000009217304, 0.000000000000
- 788, 0.000023793760, 0.000008592362, 0.000000000000
- 789, 0.000022178700, 0.000008009133, 0.000000000000
- 790, 0.000020673830, 0.000007465700, 0.000000000000
- 791, 0.000019272260, 0.000006959567, 0.000000000000
- 792, 0.000017966400, 0.000006487995, 0.000000000000
- 793, 0.000016749910, 0.000006048699, 0.000000000000
- 794, 0.000015616480, 0.000005639396, 0.000000000000
- 795, 0.000014559770, 0.000005257800, 0.000000000000
- 796, 0.000013573870, 0.000004901771, 0.000000000000
- 797, 0.000012654360, 0.000004569720, 0.000000000000
- 798, 0.000011797230, 0.000004260194, 0.000000000000
- 799, 0.000010998440, 0.000003971739, 0.000000000000
- 800, 0.000010253980, 0.000003702900, 0.000000000000
- 801, 0.000009559646, 0.000003452163, 0.000000000000
- 802, 0.000008912044, 0.000003218302, 0.000000000000
- 803, 0.000008308358, 0.000003000300, 0.000000000000
- 804, 0.000007745769, 0.000002797139, 0.000000000000
- 805, 0.000007221456, 0.000002607800, 0.000000000000
- 806, 0.000006732475, 0.000002431220, 0.000000000000
- 807, 0.000006276423, 0.000002266531, 0.000000000000
- 808, 0.000005851304, 0.000002113013, 0.000000000000
- 809, 0.000005455118, 0.000001969943, 0.000000000000
- 810, 0.000005085868, 0.000001836600, 0.000000000000
- 811, 0.000004741466, 0.000001712230, 0.000000000000
- 812, 0.000004420236, 0.000001596228, 0.000000000000
- 813, 0.000004120783, 0.000001488090, 0.000000000000
- 814, 0.000003841716, 0.000001387314, 0.000000000000
- 815, 0.000003581652, 0.000001293400, 0.000000000000
- 816, 0.000003339127, 0.000001205820, 0.000000000000
- 817, 0.000003112949, 0.000001124143, 0.000000000000
- 818, 0.000002902121, 0.000001048009, 0.000000000000
- 819, 0.000002705645, 0.000000977058, 0.000000000000
- 820, 0.000002522525, 0.000000910930, 0.000000000000
- 821, 0.000002351726, 0.000000849251, 0.000000000000
- 822, 0.000002192415, 0.000000791721, 0.000000000000
- 823, 0.000002043902, 0.000000738090, 0.000000000000
- 824, 0.000001905497, 0.000000688110, 0.000000000000
- 825, 0.000001776509, 0.000000641530, 0.000000000000
- 826, 0.000001656215, 0.000000598090, 0.000000000000
- 827, 0.000001544022, 0.000000557575, 0.000000000000
- 828, 0.000001439440, 0.000000519808, 0.000000000000
- 829, 0.000001341977, 0.000000484612, 0.000000000000
- 830, 0.000001251141, 0.000000451810, 0.000000000000];
-
- case '1964_full'
-
- cmf = [360, 0.000000122200, 0.000000013398, 0.000000535027
- 361, 0.000000185138, 0.000000020294, 0.000000810720
- 362, 0.000000278830, 0.000000030560, 0.000001221200
- 363, 0.000000417470, 0.000000045740, 0.000001828700
- 364, 0.000000621330, 0.000000068050, 0.000002722200
- 365, 0.000000919270, 0.000000100650, 0.000004028300
- 366, 0.000001351980, 0.000000147980, 0.000005925700
- 367, 0.000001976540, 0.000000216270, 0.000008665100
- 368, 0.000002872500, 0.000000314200, 0.000012596000
- 369, 0.000004149500, 0.000000453700, 0.000018201000
- 370, 0.000005958600, 0.000000651100, 0.000026143700
- 371, 0.000008505600, 0.000000928800, 0.000037330000
- 372, 0.000012068600, 0.000001317500, 0.000052987000
- 373, 0.000017022600, 0.000001857200, 0.000074764000
- 374, 0.000023868000, 0.000002602000, 0.000104870000
- 375, 0.000033266000, 0.000003625000, 0.000146220000
- 376, 0.000046087000, 0.000005019000, 0.000202660000
- 377, 0.000063472000, 0.000006907000, 0.000279230000
- 378, 0.000086892000, 0.000009449000, 0.000382450000
- 379, 0.000118246000, 0.000012848000, 0.000520720000
- 380, 0.000159952000, 0.000017364000, 0.000704776000
- 381, 0.000215080000, 0.000023327000, 0.000948230000
- 382, 0.000287490000, 0.000031150000, 0.001268200000
- 383, 0.000381990000, 0.000041350000, 0.001686100000
- 384, 0.000504550000, 0.000054560000, 0.002228500000
- 385, 0.000662440000, 0.000071560000, 0.002927800000
- 386, 0.000864500000, 0.000093300000, 0.003823700000
- 387, 0.001121500000, 0.000120870000, 0.004964200000
- 388, 0.001446160000, 0.000155640000, 0.006406700000
- 389, 0.001853590000, 0.000199200000, 0.008219300000
- 390, 0.002361600000, 0.000253400000, 0.010482200000
- 391, 0.002990600000, 0.000320200000, 0.013289000000
- 392, 0.003764500000, 0.000402400000, 0.016747000000
- 393, 0.004710200000, 0.000502300000, 0.020980000000
- 394, 0.005858100000, 0.000623200000, 0.026127000000
- 395, 0.007242300000, 0.000768500000, 0.032344000000
- 396, 0.008899600000, 0.000941700000, 0.039802000000
- 397, 0.010870900000, 0.001147800000, 0.048691000000
- 398, 0.013198900000, 0.001390300000, 0.059210000000
- 399, 0.015929200000, 0.001674000000, 0.071576000000
- 400, 0.019109700000, 0.002004400000, 0.086010900000
- 401, 0.022788000000, 0.002386000000, 0.102740000000
- 402, 0.027011000000, 0.002822000000, 0.122000000000
- 403, 0.031829000000, 0.003319000000, 0.144020000000
- 404, 0.037278000000, 0.003880000000, 0.168990000000
- 405, 0.043400000000, 0.004509000000, 0.197120000000
- 406, 0.050223000000, 0.005209000000, 0.228570000000
- 407, 0.057764000000, 0.005985000000, 0.263470000000
- 408, 0.066038000000, 0.006833000000, 0.301900000000
- 409, 0.075033000000, 0.007757000000, 0.343870000000
- 410, 0.084736000000, 0.008756000000, 0.389366000000
- 411, 0.095041000000, 0.009816000000, 0.437970000000
- 412, 0.105836000000, 0.010918000000, 0.489220000000
- 413, 0.117066000000, 0.012058000000, 0.542900000000
- 414, 0.128682000000, 0.013237000000, 0.598810000000
- 415, 0.140638000000, 0.014456000000, 0.656760000000
- 416, 0.152893000000, 0.015717000000, 0.716580000000
- 417, 0.165416000000, 0.017025000000, 0.778120000000
- 418, 0.178191000000, 0.018399000000, 0.841310000000
- 419, 0.191214000000, 0.019848000000, 0.906110000000
- 420, 0.204492000000, 0.021391000000, 0.972542000000
- 421, 0.217650000000, 0.022992000000, 1.038900000000
- 422, 0.230267000000, 0.024598000000, 1.103100000000
- 423, 0.242311000000, 0.026213000000, 1.165100000000
- 424, 0.253793000000, 0.027841000000, 1.224900000000
- 425, 0.264737000000, 0.029497000000, 1.282500000000
- 426, 0.275195000000, 0.031195000000, 1.338200000000
- 427, 0.285301000000, 0.032927000000, 1.392600000000
- 428, 0.295143000000, 0.034738000000, 1.446100000000
- 429, 0.304869000000, 0.036654000000, 1.499400000000
- 430, 0.314679000000, 0.038676000000, 1.553480000000
- 431, 0.324355000000, 0.040792000000, 1.607200000000
- 432, 0.333570000000, 0.042946000000, 1.658900000000
- 433, 0.342243000000, 0.045114000000, 1.708200000000
- 434, 0.350312000000, 0.047333000000, 1.754800000000
- 435, 0.357719000000, 0.049602000000, 1.798500000000
- 436, 0.364482000000, 0.051934000000, 1.839200000000
- 437, 0.370493000000, 0.054337000000, 1.876600000000
- 438, 0.375727000000, 0.056822000000, 1.910500000000
- 439, 0.380158000000, 0.059399000000, 1.940800000000
- 440, 0.383734000000, 0.062077000000, 1.967280000000
- 441, 0.386327000000, 0.064737000000, 1.989100000000
- 442, 0.387858000000, 0.067285000000, 2.005700000000
- 443, 0.388396000000, 0.069764000000, 2.017400000000
- 444, 0.387978000000, 0.072218000000, 2.024400000000
- 445, 0.386726000000, 0.074704000000, 2.027300000000
- 446, 0.384696000000, 0.077272000000, 2.026400000000
- 447, 0.382006000000, 0.079979000000, 2.022300000000
- 448, 0.378709000000, 0.082874000000, 2.015300000000
- 449, 0.374915000000, 0.086000000000, 2.006000000000
- 450, 0.370702000000, 0.089456000000, 1.994800000000
- 451, 0.366089000000, 0.092947000000, 1.981400000000
- 452, 0.361045000000, 0.096275000000, 1.965300000000
- 453, 0.355518000000, 0.099535000000, 1.946400000000
- 454, 0.349486000000, 0.102829000000, 1.924800000000
- 455, 0.342957000000, 0.106256000000, 1.900700000000
- 456, 0.335893000000, 0.109901000000, 1.874100000000
- 457, 0.328284000000, 0.113835000000, 1.845100000000
- 458, 0.320150000000, 0.118167000000, 1.813900000000
- 459, 0.311475000000, 0.122932000000, 1.780600000000
- 460, 0.302273000000, 0.128201000000, 1.745370000000
- 461, 0.292858000000, 0.133457000000, 1.709100000000
- 462, 0.283502000000, 0.138323000000, 1.672300000000
- 463, 0.274044000000, 0.143042000000, 1.634700000000
- 464, 0.264263000000, 0.147787000000, 1.595600000000
- 465, 0.254085000000, 0.152761000000, 1.554900000000
- 466, 0.243392000000, 0.158102000000, 1.512200000000
- 467, 0.232187000000, 0.163941000000, 1.467300000000
- 468, 0.220488000000, 0.170362000000, 1.419900000000
- 469, 0.208198000000, 0.177425000000, 1.370000000000
- 470, 0.195618000000, 0.185190000000, 1.317560000000
- 471, 0.183034000000, 0.193025000000, 1.262400000000
- 472, 0.170222000000, 0.200313000000, 1.205000000000
- 473, 0.157348000000, 0.207156000000, 1.146600000000
- 474, 0.144650000000, 0.213644000000, 1.088000000000
- 475, 0.132349000000, 0.219940000000, 1.030200000000
- 476, 0.120584000000, 0.226170000000, 0.973830000000
- 477, 0.109456000000, 0.232467000000, 0.919430000000
- 478, 0.099042000000, 0.239025000000, 0.867460000000
- 479, 0.089388000000, 0.245997000000, 0.818280000000
- 480, 0.080507000000, 0.253589000000, 0.772125000000
- 481, 0.072034000000, 0.261876000000, 0.728290000000
- 482, 0.063710000000, 0.270643000000, 0.686040000000
- 483, 0.055694000000, 0.279645000000, 0.645530000000
- 484, 0.048117000000, 0.288694000000, 0.606850000000
- 485, 0.041072000000, 0.297665000000, 0.570060000000
- 486, 0.034642000000, 0.306469000000, 0.535220000000
- 487, 0.028896000000, 0.315035000000, 0.502340000000
- 488, 0.023876000000, 0.323335000000, 0.471400000000
- 489, 0.019628000000, 0.331366000000, 0.442390000000
- 490, 0.016172000000, 0.339133000000, 0.415254000000
- 491, 0.013300000000, 0.347860000000, 0.390024000000
- 492, 0.010759000000, 0.358326000000, 0.366399000000
- 493, 0.008542000000, 0.370001000000, 0.344015000000
- 494, 0.006661000000, 0.382464000000, 0.322689000000
- 495, 0.005132000000, 0.395379000000, 0.302356000000
- 496, 0.003982000000, 0.408482000000, 0.283036000000
- 497, 0.003239000000, 0.421588000000, 0.264816000000
- 498, 0.002934000000, 0.434619000000, 0.247848000000
- 499, 0.003114000000, 0.447601000000, 0.232318000000
- 500, 0.003816000000, 0.460777000000, 0.218502000000
- 501, 0.005095000000, 0.474340000000, 0.205851000000
- 502, 0.006936000000, 0.488200000000, 0.193596000000
- 503, 0.009299000000, 0.502340000000, 0.181736000000
- 504, 0.012147000000, 0.516740000000, 0.170281000000
- 505, 0.015444000000, 0.531360000000, 0.159249000000
- 506, 0.019156000000, 0.546190000000, 0.148673000000
- 507, 0.023250000000, 0.561180000000, 0.138609000000
- 508, 0.027690000000, 0.576290000000, 0.129096000000
- 509, 0.032444000000, 0.591500000000, 0.120215000000
- 510, 0.037465000000, 0.606741000000, 0.112044000000
- 511, 0.042956000000, 0.622150000000, 0.104710000000
- 512, 0.049114000000, 0.637830000000, 0.098196000000
- 513, 0.055920000000, 0.653710000000, 0.092361000000
- 514, 0.063349000000, 0.669680000000, 0.087088000000
- 515, 0.071358000000, 0.685660000000, 0.082248000000
- 516, 0.079901000000, 0.701550000000, 0.077744000000
- 517, 0.088909000000, 0.717230000000, 0.073456000000
- 518, 0.098293000000, 0.732570000000, 0.069268000000
- 519, 0.107949000000, 0.747460000000, 0.065060000000
- 520, 0.117749000000, 0.761757000000, 0.060709000000
- 521, 0.127839000000, 0.775340000000, 0.056457000000
- 522, 0.138450000000, 0.788220000000, 0.052609000000
- 523, 0.149516000000, 0.800460000000, 0.049122000000
- 524, 0.161041000000, 0.812140000000, 0.045954000000
- 525, 0.172953000000, 0.823330000000, 0.043050000000
- 526, 0.185209000000, 0.834120000000, 0.040368000000
- 527, 0.197755000000, 0.844600000000, 0.037839000000
- 528, 0.210538000000, 0.854870000000, 0.035384000000
- 529, 0.223460000000, 0.865040000000, 0.032949000000
- 530, 0.236491000000, 0.875211000000, 0.030451000000
- 531, 0.249633000000, 0.885370000000, 0.028029000000
- 532, 0.262972000000, 0.895370000000, 0.025862000000
- 533, 0.276515000000, 0.905150000000, 0.023920000000
- 534, 0.290269000000, 0.914650000000, 0.022174000000
- 535, 0.304213000000, 0.923810000000, 0.020584000000
- 536, 0.318361000000, 0.932550000000, 0.019127000000
- 537, 0.332705000000, 0.940810000000, 0.017740000000
- 538, 0.347232000000, 0.948520000000, 0.016403000000
- 539, 0.361926000000, 0.955600000000, 0.015064000000
- 540, 0.376772000000, 0.961988000000, 0.013676000000
- 541, 0.391683000000, 0.967540000000, 0.012308000000
- 542, 0.406594000000, 0.972230000000, 0.011056000000
- 543, 0.421539000000, 0.976170000000, 0.009915000000
- 544, 0.436517000000, 0.979460000000, 0.008872000000
- 545, 0.451584000000, 0.982200000000, 0.007918000000
- 546, 0.466782000000, 0.984520000000, 0.007030000000
- 547, 0.482147000000, 0.986520000000, 0.006223000000
- 548, 0.497738000000, 0.988320000000, 0.005453000000
- 549, 0.513606000000, 0.990020000000, 0.004714000000
- 550, 0.529826000000, 0.991761000000, 0.003988000000
- 551, 0.546440000000, 0.993530000000, 0.003289000000
- 552, 0.563426000000, 0.995230000000, 0.002646000000
- 553, 0.580726000000, 0.996770000000, 0.002063000000
- 554, 0.598290000000, 0.998090000000, 0.001533000000
- 555, 0.616053000000, 0.999110000000, 0.001091000000
- 556, 0.633948000000, 0.999770000000, 0.000711000000
- 557, 0.651901000000, 1.000000000000, 0.000407000000
- 558, 0.669824000000, 0.999710000000, 0.000184000000
- 559, 0.687632000000, 0.998850000000, 0.000047000000
- 560, 0.705224000000, 0.997340000000, 0.000000000000
- 561, 0.722773000000, 0.995260000000, 0.000000000000
- 562, 0.740483000000, 0.992740000000, 0.000000000000
- 563, 0.758273000000, 0.989750000000, 0.000000000000
- 564, 0.776083000000, 0.986300000000, 0.000000000000
- 565, 0.793832000000, 0.982380000000, 0.000000000000
- 566, 0.811436000000, 0.977980000000, 0.000000000000
- 567, 0.828822000000, 0.973110000000, 0.000000000000
- 568, 0.845879000000, 0.967740000000, 0.000000000000
- 569, 0.862525000000, 0.961890000000, 0.000000000000
- 570, 0.878655000000, 0.955552000000, 0.000000000000
- 571, 0.894208000000, 0.948601000000, 0.000000000000
- 572, 0.909206000000, 0.940981000000, 0.000000000000
- 573, 0.923672000000, 0.932798000000, 0.000000000000
- 574, 0.937638000000, 0.924158000000, 0.000000000000
- 575, 0.951162000000, 0.915175000000, 0.000000000000
- 576, 0.964283000000, 0.905954000000, 0.000000000000
- 577, 0.977068000000, 0.896608000000, 0.000000000000
- 578, 0.989590000000, 0.887249000000, 0.000000000000
- 579, 1.001910000000, 0.877986000000, 0.000000000000
- 580, 1.014160000000, 0.868934000000, 0.000000000000
- 581, 1.026500000000, 0.860164000000, 0.000000000000
- 582, 1.038800000000, 0.851519000000, 0.000000000000
- 583, 1.051000000000, 0.842963000000, 0.000000000000
- 584, 1.062900000000, 0.834393000000, 0.000000000000
- 585, 1.074300000000, 0.825623000000, 0.000000000000
- 586, 1.085200000000, 0.816764000000, 0.000000000000
- 587, 1.095200000000, 0.807544000000, 0.000000000000
- 588, 1.104200000000, 0.797947000000, 0.000000000000
- 589, 1.112000000000, 0.787893000000, 0.000000000000
- 590, 1.118520000000, 0.777405000000, 0.000000000000
- 591, 1.123800000000, 0.766490000000, 0.000000000000
- 592, 1.128000000000, 0.755309000000, 0.000000000000
- 593, 1.131100000000, 0.743845000000, 0.000000000000
- 594, 1.133200000000, 0.732190000000, 0.000000000000
- 595, 1.134300000000, 0.720353000000, 0.000000000000
- 596, 1.134300000000, 0.708281000000, 0.000000000000
- 597, 1.133300000000, 0.696055000000, 0.000000000000
- 598, 1.131200000000, 0.683621000000, 0.000000000000
- 599, 1.128100000000, 0.671048000000, 0.000000000000
- 600, 1.123990000000, 0.658341000000, 0.000000000000
- 601, 1.118900000000, 0.645545000000, 0.000000000000
- 602, 1.112900000000, 0.632718000000, 0.000000000000
- 603, 1.105900000000, 0.619815000000, 0.000000000000
- 604, 1.098000000000, 0.606887000000, 0.000000000000
- 605, 1.089100000000, 0.593878000000, 0.000000000000
- 606, 1.079200000000, 0.580781000000, 0.000000000000
- 607, 1.068400000000, 0.567653000000, 0.000000000000
- 608, 1.056700000000, 0.554490000000, 0.000000000000
- 609, 1.044000000000, 0.541228000000, 0.000000000000
- 610, 1.030480000000, 0.527963000000, 0.000000000000
- 611, 1.016000000000, 0.514634000000, 0.000000000000
- 612, 1.000800000000, 0.501363000000, 0.000000000000
- 613, 0.984790000000, 0.488124000000, 0.000000000000
- 614, 0.968080000000, 0.474935000000, 0.000000000000
- 615, 0.950740000000, 0.461834000000, 0.000000000000
- 616, 0.932800000000, 0.448823000000, 0.000000000000
- 617, 0.914340000000, 0.435917000000, 0.000000000000
- 618, 0.895390000000, 0.423153000000, 0.000000000000
- 619, 0.876030000000, 0.410526000000, 0.000000000000
- 620, 0.856297000000, 0.398057000000, 0.000000000000
- 621, 0.836350000000, 0.385835000000, 0.000000000000
- 622, 0.816290000000, 0.373951000000, 0.000000000000
- 623, 0.796050000000, 0.362311000000, 0.000000000000
- 624, 0.775610000000, 0.350863000000, 0.000000000000
- 625, 0.754930000000, 0.339554000000, 0.000000000000
- 626, 0.733990000000, 0.328309000000, 0.000000000000
- 627, 0.712780000000, 0.317118000000, 0.000000000000
- 628, 0.691290000000, 0.305936000000, 0.000000000000
- 629, 0.669520000000, 0.294737000000, 0.000000000000
- 630, 0.647467000000, 0.283493000000, 0.000000000000
- 631, 0.625110000000, 0.272222000000, 0.000000000000
- 632, 0.602520000000, 0.260990000000, 0.000000000000
- 633, 0.579890000000, 0.249877000000, 0.000000000000
- 634, 0.557370000000, 0.238946000000, 0.000000000000
- 635, 0.535110000000, 0.228254000000, 0.000000000000
- 636, 0.513240000000, 0.217853000000, 0.000000000000
- 637, 0.491860000000, 0.207780000000, 0.000000000000
- 638, 0.471080000000, 0.198072000000, 0.000000000000
- 639, 0.450960000000, 0.188748000000, 0.000000000000
- 640, 0.431567000000, 0.179828000000, 0.000000000000
- 641, 0.412870000000, 0.171285000000, 0.000000000000
- 642, 0.394750000000, 0.163059000000, 0.000000000000
- 643, 0.377210000000, 0.155151000000, 0.000000000000
- 644, 0.360190000000, 0.147535000000, 0.000000000000
- 645, 0.343690000000, 0.140211000000, 0.000000000000
- 646, 0.327690000000, 0.133170000000, 0.000000000000
- 647, 0.312170000000, 0.126400000000, 0.000000000000
- 648, 0.297110000000, 0.119892000000, 0.000000000000
- 649, 0.282500000000, 0.113640000000, 0.000000000000
- 650, 0.268329000000, 0.107633000000, 0.000000000000
- 651, 0.254590000000, 0.101870000000, 0.000000000000
- 652, 0.241300000000, 0.096347000000, 0.000000000000
- 653, 0.228480000000, 0.091063000000, 0.000000000000
- 654, 0.216140000000, 0.086010000000, 0.000000000000
- 655, 0.204300000000, 0.081187000000, 0.000000000000
- 656, 0.192950000000, 0.076583000000, 0.000000000000
- 657, 0.182110000000, 0.072198000000, 0.000000000000
- 658, 0.171770000000, 0.068024000000, 0.000000000000
- 659, 0.161920000000, 0.064052000000, 0.000000000000
- 660, 0.152568000000, 0.060281000000, 0.000000000000
- 661, 0.143670000000, 0.056697000000, 0.000000000000
- 662, 0.135200000000, 0.053292000000, 0.000000000000
- 663, 0.127130000000, 0.050059000000, 0.000000000000
- 664, 0.119480000000, 0.046998000000, 0.000000000000
- 665, 0.112210000000, 0.044096000000, 0.000000000000
- 666, 0.105310000000, 0.041345000000, 0.000000000000
- 667, 0.098786000000, 0.038750700000, 0.000000000000
- 668, 0.092610000000, 0.036297800000, 0.000000000000
- 669, 0.086773000000, 0.033983200000, 0.000000000000
- 670, 0.081260600000, 0.031800400000, 0.000000000000
- 671, 0.076048000000, 0.029739500000, 0.000000000000
- 672, 0.071114000000, 0.027791800000, 0.000000000000
- 673, 0.066454000000, 0.025955100000, 0.000000000000
- 674, 0.062062000000, 0.024226300000, 0.000000000000
- 675, 0.057930000000, 0.022601700000, 0.000000000000
- 676, 0.054050000000, 0.021077900000, 0.000000000000
- 677, 0.050412000000, 0.019650500000, 0.000000000000
- 678, 0.047006000000, 0.018315300000, 0.000000000000
- 679, 0.043823000000, 0.017068600000, 0.000000000000
- 680, 0.040850800000, 0.015905100000, 0.000000000000
- 681, 0.038072000000, 0.014818300000, 0.000000000000
- 682, 0.035468000000, 0.013800800000, 0.000000000000
- 683, 0.033031000000, 0.012849500000, 0.000000000000
- 684, 0.030753000000, 0.011960700000, 0.000000000000
- 685, 0.028623000000, 0.011130300000, 0.000000000000
- 686, 0.026635000000, 0.010355500000, 0.000000000000
- 687, 0.024781000000, 0.009633200000, 0.000000000000
- 688, 0.023052000000, 0.008959900000, 0.000000000000
- 689, 0.021441000000, 0.008332400000, 0.000000000000
- 690, 0.019941300000, 0.007748800000, 0.000000000000
- 691, 0.018544000000, 0.007204600000, 0.000000000000
- 692, 0.017241000000, 0.006697500000, 0.000000000000
- 693, 0.016027000000, 0.006225100000, 0.000000000000
- 694, 0.014896000000, 0.005785000000, 0.000000000000
- 695, 0.013842000000, 0.005375100000, 0.000000000000
- 696, 0.012862000000, 0.004994100000, 0.000000000000
- 697, 0.011949000000, 0.004639200000, 0.000000000000
- 698, 0.011100000000, 0.004309300000, 0.000000000000
- 699, 0.010311000000, 0.004002800000, 0.000000000000
- 700, 0.009576880000, 0.003717740000, 0.000000000000
- 701, 0.008894000000, 0.003452620000, 0.000000000000
- 702, 0.008258100000, 0.003205830000, 0.000000000000
- 703, 0.007666400000, 0.002976230000, 0.000000000000
- 704, 0.007116300000, 0.002762810000, 0.000000000000
- 705, 0.006605200000, 0.002564560000, 0.000000000000
- 706, 0.006130600000, 0.002380480000, 0.000000000000
- 707, 0.005690300000, 0.002209710000, 0.000000000000
- 708, 0.005281900000, 0.002051320000, 0.000000000000
- 709, 0.004903300000, 0.001904490000, 0.000000000000
- 710, 0.004552630000, 0.001768470000, 0.000000000000
- 711, 0.004227500000, 0.001642360000, 0.000000000000
- 712, 0.003925800000, 0.001525350000, 0.000000000000
- 713, 0.003645700000, 0.001416720000, 0.000000000000
- 714, 0.003385900000, 0.001315950000, 0.000000000000
- 715, 0.003144700000, 0.001222390000, 0.000000000000
- 716, 0.002920800000, 0.001135550000, 0.000000000000
- 717, 0.002713000000, 0.001054940000, 0.000000000000
- 718, 0.002520200000, 0.000980140000, 0.000000000000
- 719, 0.002341100000, 0.000910660000, 0.000000000000
- 720, 0.002174960000, 0.000846190000, 0.000000000000
- 721, 0.002020600000, 0.000786290000, 0.000000000000
- 722, 0.001877300000, 0.000730680000, 0.000000000000
- 723, 0.001744100000, 0.000678990000, 0.000000000000
- 724, 0.001620500000, 0.000631010000, 0.000000000000
- 725, 0.001505700000, 0.000586440000, 0.000000000000
- 726, 0.001399200000, 0.000545110000, 0.000000000000
- 727, 0.001300400000, 0.000506720000, 0.000000000000
- 728, 0.001208700000, 0.000471110000, 0.000000000000
- 729, 0.001123600000, 0.000438050000, 0.000000000000
- 730, 0.001044760000, 0.000407410000, 0.000000000000
- 731, 0.000971560000, 0.000378962000, 0.000000000000
- 732, 0.000903600000, 0.000352543000, 0.000000000000
- 733, 0.000840480000, 0.000328001000, 0.000000000000
- 734, 0.000781870000, 0.000305208000, 0.000000000000
- 735, 0.000727450000, 0.000284041000, 0.000000000000
- 736, 0.000676900000, 0.000264375000, 0.000000000000
- 737, 0.000629960000, 0.000246109000, 0.000000000000
- 738, 0.000586370000, 0.000229143000, 0.000000000000
- 739, 0.000545870000, 0.000213376000, 0.000000000000
- 740, 0.000508258000, 0.000198730000, 0.000000000000
- 741, 0.000473300000, 0.000185115000, 0.000000000000
- 742, 0.000440800000, 0.000172454000, 0.000000000000
- 743, 0.000410580000, 0.000160678000, 0.000000000000
- 744, 0.000382490000, 0.000149730000, 0.000000000000
- 745, 0.000356380000, 0.000139550000, 0.000000000000
- 746, 0.000332110000, 0.000130086000, 0.000000000000
- 747, 0.000309550000, 0.000121290000, 0.000000000000
- 748, 0.000288580000, 0.000113106000, 0.000000000000
- 749, 0.000269090000, 0.000105501000, 0.000000000000
- 750, 0.000250969000, 0.000098428000, 0.000000000000
- 751, 0.000234130000, 0.000091853000, 0.000000000000
- 752, 0.000218470000, 0.000085738000, 0.000000000000
- 753, 0.000203910000, 0.000080048000, 0.000000000000
- 754, 0.000190350000, 0.000074751000, 0.000000000000
- 755, 0.000177730000, 0.000069819000, 0.000000000000
- 756, 0.000165970000, 0.000065222000, 0.000000000000
- 757, 0.000155020000, 0.000060939000, 0.000000000000
- 758, 0.000144800000, 0.000056942000, 0.000000000000
- 759, 0.000135280000, 0.000053217000, 0.000000000000
- 760, 0.000126390000, 0.000049737000, 0.000000000000
- 761, 0.000118100000, 0.000046491000, 0.000000000000
- 762, 0.000110370000, 0.000043464000, 0.000000000000
- 763, 0.000103150000, 0.000040635000, 0.000000000000
- 764, 0.000096427000, 0.000038000000, 0.000000000000
- 765, 0.000090151000, 0.000035540500, 0.000000000000
- 766, 0.000084294000, 0.000033244800, 0.000000000000
- 767, 0.000078830000, 0.000031100600, 0.000000000000
- 768, 0.000073729000, 0.000029099000, 0.000000000000
- 769, 0.000068969000, 0.000027230700, 0.000000000000
- 770, 0.000064525800, 0.000025486000, 0.000000000000
- 771, 0.000060376000, 0.000023856100, 0.000000000000
- 772, 0.000056500000, 0.000022333200, 0.000000000000
- 773, 0.000052880000, 0.000020910400, 0.000000000000
- 774, 0.000049498000, 0.000019580800, 0.000000000000
- 775, 0.000046339000, 0.000018338400, 0.000000000000
- 776, 0.000043389000, 0.000017177700, 0.000000000000
- 777, 0.000040634000, 0.000016093400, 0.000000000000
- 778, 0.000038060000, 0.000015080000, 0.000000000000
- 779, 0.000035657000, 0.000014133600, 0.000000000000
- 780, 0.000033411700, 0.000013249000, 0.000000000000
- 781, 0.000031315000, 0.000012422600, 0.000000000000
- 782, 0.000029355000, 0.000011649900, 0.000000000000
- 783, 0.000027524000, 0.000010927700, 0.000000000000
- 784, 0.000025811000, 0.000010251900, 0.000000000000
- 785, 0.000024209000, 0.000009619600, 0.000000000000
- 786, 0.000022711000, 0.000009028100, 0.000000000000
- 787, 0.000021308000, 0.000008474000, 0.000000000000
- 788, 0.000019994000, 0.000007954800, 0.000000000000
- 789, 0.000018764000, 0.000007468600, 0.000000000000
- 790, 0.000017611500, 0.000007012800, 0.000000000000
- 791, 0.000016532000, 0.000006585800, 0.000000000000
- 792, 0.000015521000, 0.000006185700, 0.000000000000
- 793, 0.000014574000, 0.000005810700, 0.000000000000
- 794, 0.000013686000, 0.000005459000, 0.000000000000
- 795, 0.000012855000, 0.000005129800, 0.000000000000
- 796, 0.000012075000, 0.000004820600, 0.000000000000
- 797, 0.000011345000, 0.000004531200, 0.000000000000
- 798, 0.000010659000, 0.000004259100, 0.000000000000
- 799, 0.000010017000, 0.000004004200, 0.000000000000
- 800, 0.000009413630, 0.000003764730, 0.000000000000
- 801, 0.000008847900, 0.000003539950, 0.000000000000
- 802, 0.000008317100, 0.000003329140, 0.000000000000
- 803, 0.000007819000, 0.000003131150, 0.000000000000
- 804, 0.000007351600, 0.000002945290, 0.000000000000
- 805, 0.000006913000, 0.000002770810, 0.000000000000
- 806, 0.000006501500, 0.000002607050, 0.000000000000
- 807, 0.000006115300, 0.000002453290, 0.000000000000
- 808, 0.000005752900, 0.000002308940, 0.000000000000
- 809, 0.000005412700, 0.000002173380, 0.000000000000
- 810, 0.000005093470, 0.000002046130, 0.000000000000
- 811, 0.000004793800, 0.000001926620, 0.000000000000
- 812, 0.000004512500, 0.000001814400, 0.000000000000
- 813, 0.000004248300, 0.000001708950, 0.000000000000
- 814, 0.000004000200, 0.000001609880, 0.000000000000
- 815, 0.000003767100, 0.000001516770, 0.000000000000
- 816, 0.000003548000, 0.000001429210, 0.000000000000
- 817, 0.000003342100, 0.000001346860, 0.000000000000
- 818, 0.000003148500, 0.000001269450, 0.000000000000
- 819, 0.000002966500, 0.000001196620, 0.000000000000
- 820, 0.000002795310, 0.000001128090, 0.000000000000
- 821, 0.000002634500, 0.000001063680, 0.000000000000
- 822, 0.000002483400, 0.000001003130, 0.000000000000
- 823, 0.000002341400, 0.000000946220, 0.000000000000
- 824, 0.000002207800, 0.000000892630, 0.000000000000
- 825, 0.000002082000, 0.000000842160, 0.000000000000
- 826, 0.000001963600, 0.000000794640, 0.000000000000
- 827, 0.000001851900, 0.000000749780, 0.000000000000
- 828, 0.000001746500, 0.000000707440, 0.000000000000
- 829, 0.000001647100, 0.000000667480, 0.000000000000
- 830, 0.000001553140, 0.000000629700, 0.000000000000];
-
- otherwise
-
- error('colorMatchFcn:unrecognizedMatchFcn', ...
- 'Unrecognized color match function.')
-
-end
-
-lambda = cmf(:, 1)';
-xFcn = cmf(:, 2)';
-yFcn = cmf(:, 3)';
-zFcn = cmf(:, 4)';
diff --git a/MST/visualization/real_results/results/README.md b/MST/visualization/real_results/results/README.md
deleted file mode 100755
index 8eaedaa..0000000
--- a/MST/visualization/real_results/results/README.md
+++ /dev/null
@@ -1 +0,0 @@
-Please put the reconstructed HSI here and rename it as method.mat, e.g., mst_plus_plus.mat.
diff --git a/MST/visualization/show_line.m b/MST/visualization/show_line.m
deleted file mode 100755
index a429935..0000000
--- a/MST/visualization/show_line.m
+++ /dev/null
@@ -1,72 +0,0 @@
-%% plot color pics
-clear; clc;
-load(['simulation_results\results\','truth','.mat']);
-
-load(['simulation_results\results\','hdnet','.mat']);
-pred_block_hdnet = pred;
-
-load(['simulation_results\results\','mst_s','.mat']);
-pred_block_mst_s = pred;
-
-load(['simulation_results\results\','mst_m','.mat']);
-pred_block_mst_m = pred;
-
-load(['simulation_results\results\','mst_l','.mat']);
-pred_block_mst_l = pred;
-
-load(['simulation_results\results\','mst_plus_plus','.mat']);
-pred_block_mst_plus_plus = pred;
-
-lam28 = [453.5 457.5 462.0 466.0 471.5 476.5 481.5 487.0 492.5 498.0 504.0 510.0...
- 516.0 522.5 529.5 536.5 544.0 551.5 558.5 567.5 575.5 584.5 594.5 604.0...
- 614.5 625.0 636.5 648.0];
-
-truth(find(truth>0.7))=0.7;
-pred_block_hdnet(find(pred_block_hdnet>0.7))=0.7;
-pred_block_mst_s(find(pred_block_mst_s>0.7))=0.7;
-pred_block_mst_m(find(pred_block_mst_m>0.7))=0.7;
-pred_block_mst_l(find(pred_block_mst_l>0.7))=0.7;
-pred_block_mst_plus_plus(find(pred_block_mst_plus_plus>0.7))=0.7;
-
-f = 2;
-
-%% plot spectrum
-figure(123);
-[yx, rect2crop]=imcrop(sum(squeeze(truth(f, :, :, :)), 3));
-rect2crop=round(rect2crop)
-close(123);
-
-figure;
-
-spec_mean_truth = mean(mean(squeeze(truth(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-spec_mean_hdnet = mean(mean(squeeze(pred_block_hdnet(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-spec_mean_mst_s = mean(mean(squeeze(pred_block_mst_s(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-spec_mean_mst_m = mean(mean(squeeze(pred_block_mst_m(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-spec_mean_mst_l = mean(mean(squeeze(pred_block_mst_l(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-spec_mean_mst_plus_plus = mean(mean(squeeze(pred_block_mst_plus_plus(f,rect2crop(2):rect2crop(2)+rect2crop(4) , rect2crop(1):rect2crop(1)+rect2crop(3),:)),1),2);
-
-spec_mean_truth = spec_mean_truth./max(spec_mean_truth);
-spec_mean_hdnet = spec_mean_hdnet./max(spec_mean_hdnet);
-spec_mean_mst_s = spec_mean_mst_s./max(spec_mean_mst_s);
-spec_mean_mst_m = spec_mean_mst_m./max(spec_mean_mst_m);
-spec_mean_mst_l = spec_mean_mst_l./max(spec_mean_mst_l);
-spec_mean_mst_plus_plus = spec_mean_mst_plus_plus./max(spec_mean_mst_plus_plus);
-
-corr_hdnet = roundn(corr(spec_mean_truth(:),spec_mean_hdnet(:)),-4);
-corr_mst_s = roundn(corr(spec_mean_truth(:),spec_mean_mst_s(:)),-4);
-corr_mst_m = roundn(corr(spec_mean_truth(:),spec_mean_mst_m(:)),-4);
-corr_mst_l = roundn(corr(spec_mean_truth(:),spec_mean_mst_l(:)),-4);
-corr_mst_plus_plus = roundn(corr(spec_mean_truth(:),spec_mean_mst_plus_plus(:)),-4);
-
-X = lam28;
-
-Y(1,:) = spec_mean_truth(:);
-Y(2,:) = spec_mean_hdnet(:); Corr(1)=corr_hdnet;
-Y(3,:) = spec_mean_mst_s(:); Corr(2)=corr_mst_s;
-Y(4,:) = spec_mean_mst_m(:); Corr(3)=corr_mst_m;
-Y(5,:) = spec_mean_mst_l(:); Corr(4)=corr_mst_l;
-Y(6,:) = spec_mean_mst_plus_plus(:); Corr(5)=corr_mst_plus_plus;
-
-createfigure(X,Y,Corr)
-
-
diff --git a/MST/visualization/show_real.m b/MST/visualization/show_real.m
deleted file mode 100755
index 9c921c7..0000000
--- a/MST/visualization/show_real.m
+++ /dev/null
@@ -1,28 +0,0 @@
-%% plot color pics
-clear; clc;
-close all
-
-load('real_results\results\mst.mat');
-x_result_1 = flip(flip(squeeze(pred(1, :, :, :)),1),2);
-x_result_2 = flip(flip(squeeze(pred(2, :, :, :)),1),2);
-x_result_3 = flip(flip(squeeze(pred(3, :, :, :)),1),2);
-x_result_4 = flip(flip(squeeze(pred(4, :, :, :)),1),2);
-x_result_5 = flip(flip(squeeze(pred(5, :, :, :)),1),2);
-
-save_file = 'real_results\rgb_results\mst\';
-mkdir(save_file);
-
-frame = 1;
-for recon = {x_result_1,x_result_2,x_result_3,x_result_4,x_result_5}
- recon = cell2mat(recon);
- intensity = 5;
- for channel=1:28
- img_nb = [channel]; % channel number
- row_num = 1; col_num = 1;
- lam28 = [453.5 457.5 462.0 466.0 471.5 476.5 481.5 487.0 492.5 498.0 504.0 510.0 516.0 522.5 529.5 536.5 544.0 551.5 558.5 567.5 575.5 584.5 594.5 604.0 614.5 625.0 636.5 648.0];
- recon(find(recon>1))=1;
- name = [save_file 'frame' num2str(frame) 'channel' num2str(channel)];
- dispCubeAshwin(recon(:,:,img_nb),intensity,lam28(img_nb), [] ,col_num,row_num,0,1,name);
- end
- frame = frame+1;
-end
\ No newline at end of file
diff --git a/MST/visualization/show_simulation.m b/MST/visualization/show_simulation.m
deleted file mode 100755
index a6497df..0000000
--- a/MST/visualization/show_simulation.m
+++ /dev/null
@@ -1,26 +0,0 @@
-%% plot color pics
-clear; clc;
-load('simulation_results\results\mst_s.mat');
-save_file = 'simulation_results\rgb_results\mst_s\';
-mkdir(save_file);
-
-close all;
-frame = 1;
-for i = 1:10
- recon = squeeze(pred(i,:,:,:));
- intensity = 5;
- for channel=1:28
- img_nb = [channel]; % channel number
- row_num = 1; col_num = 1;
- lam28 = [453.5 457.5 462.0 466.0 471.5 476.5 481.5 487.0 492.5 498.0 504.0 510.0...
- 516.0 522.5 529.5 536.5 544.0 551.5 558.5 567.5 575.5 584.5 594.5 604.0...
- 614.5 625.0 636.5 648.0];
- recon(find(recon>1))=1;
- name = [save_file 'frame' num2str(frame) 'channel' num2str(channel)];
- dispCubeAshwin(recon(:,:,img_nb),intensity,lam28(img_nb), [] ,col_num,row_num,0,1,name);
- end
- frame = frame+1;
-end
-close all;
-
-
diff --git a/MST/visualization/simulation_results/results/README.md b/MST/visualization/simulation_results/results/README.md
deleted file mode 100755
index afd8c6d..0000000
--- a/MST/visualization/simulation_results/results/README.md
+++ /dev/null
@@ -1 +0,0 @@
-Please put the reconstructed HSI here and rename it as method.mat, e.g., mst_s.mat.
diff --git a/Resnet_only.py b/Resnet_only.py
deleted file mode 100644
index 1365597..0000000
--- a/Resnet_only.py
+++ /dev/null
@@ -1,270 +0,0 @@
-import pytorch_lightning as pl
-import torch
-import torch.nn as nn
-from simca.CassiSystem_lightning import CassiSystemOptim
-from MST.simulation.train_code.architecture import *
-from simca import load_yaml_config
-import matplotlib.pyplot as plt
-import torchvision
-import numpy as np
-from simca.functions_acquisition import *
-from piqa import SSIM
-from torch.utils.tensorboard import SummaryWriter
-import io
-import torchvision.transforms as transforms
-from PIL import Image
-from optimization_modules_with_resnet import UnetModel
-
-class ResnetOnly(pl.LightningModule):
-
- def __init__(self,log_dir="tb_logs"):
- super().__init__()
-
- self.mask_generation = UnetModel(classes=1,encoder_weights=None,in_channels=1)
- self.writer = SummaryWriter(log_dir)
-
-
- def _normalize_data_by_itself(self, data):
- # Calculate the mean and std for each batch individually
- # Keep dimensions for broadcasting
- mean = torch.mean(data, dim=[1, 2], keepdim=True)
- std = torch.std(data, dim=[1, 2], keepdim=True)
-
- # Normalize each batch by its mean and std
- normalized_data = (data - mean) / std
- return normalized_data
-
-
- def forward(self, x, pattern=None):
- print("---FORWARD---")
-
- hyperspectral_cube, wavelengths = x
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- batch_size, H, W, C = hyperspectral_cube.shape
-
- #generate stupid acq
- self.acquisition = torch.sum(hyperspectral_cube, dim=-1)
- self.acquisition = self.acquisition.flip(1)
- self.acquisition = self.acquisition.flip(2)
- self.acquisition = self.acquisition.unsqueeze(1).float()
-
- # print("acquisition shape: ", self.acquisition.shape)
- # plt.imshow(self.acquisition[0,0,:,:].cpu().numpy())
- # plt.show()
-
- self.pattern = self.mask_generation(self.acquisition)
- self.pattern = BinarizeFunction.apply(self.pattern)
-
- # print("pattern shape: ", self.pattern.shape)
- # plt.imshow(self.pattern[0,0,:,:].detach().cpu().numpy())
- # plt.show()
-
- return self.pattern
-
-
- def training_step(self, batch, batch_idx):
- print("Training step")
-
- loss = self._common_step(batch, batch_idx)
-
- input_images = self._convert_output_to_images(self._normalize_image_tensor(self.acquisition[:,0,:,:]))
- patterns = self._convert_output_to_images(self._normalize_image_tensor(self.pattern[:,0,:,:]))
-
- if self.global_step % 30 == 0:
- self._log_images('train/input_images', input_images, self.global_step)
- self._log_images('train/patterns', patterns, self.global_step)
-
- self.log_dict(
- { "train_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
-
- return {"loss": loss}
-
- def _normalize_image_tensor(self, tensor):
- # Normalize the tensor to the range [0, 1]
- min_val = tensor.min()
- max_val = tensor.max()
- normalized_tensor = (tensor - min_val) / (max_val - min_val)
- return normalized_tensor
-
- def validation_step(self, batch, batch_idx):
-
- print("Validation step")
- loss = self._common_step(batch, batch_idx)
-
- self.log_dict(
- { "val_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def test_step(self, batch, batch_idx):
- print("Test step")
- loss = self._common_step(batch, batch_idx)
- self.log_dict(
- { "test_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
- return {"loss": loss}
-
- def predict_step(self, batch, batch_idx):
- print("Predict step")
- loss = self._common_step(batch, batch_idx)
-
- return loss
-
- def _common_step(self, batch, batch_idx):
-
- output_pattern = self.forward(batch)
-
- sum_result = torch.mean(output_pattern,dim=(2,3))
- print("sum_result: ", sum_result)
- sum_final = torch.sum(torch.abs(sum_result - 0.5))
- loss1 = sum_final
-
- loss2 = calculate_spectral_flatness(output_pattern)
- loss2 = torch.sum(1 - loss2)
-
- print("mean loss1: ", loss1)
- print("spectral flatness loss 2: ", loss2)
-
- loss = loss1 + loss2
-
- return loss
-
- def configure_optimizers(self):
- optimizer = torch.optim.Adam(self.parameters(), lr=4e-4)
- return { "optimizer":optimizer,
- "lr_scheduler":{
- "scheduler":torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, 500, eta_min=1e-6),
- "interval": "epoch"
- }
- }
-
- def _log_images(self, tag, images, global_step):
- # Convert model output to image grid and log to TensorBoard
- img_grid = torchvision.utils.make_grid(images)
- self.writer.add_image(tag, img_grid, global_step)
-
- def _convert_output_to_images(self, acquired_images):
-
- acquired_images = acquired_images.unsqueeze(1)
-
- # Create a grid of images for visualization
- img_grid = torchvision.utils.make_grid(acquired_images)
- return img_grid
-
- def plot_spectral_filter(self,ref_hyperspectral_cube,recontructed_hyperspectral_cube):
-
-
- batch_size, y,x, lmabda_ = ref_hyperspectral_cube.shape
-
- # Create a figure with subplots arranged horizontally
- fig, axs = plt.subplots(1, batch_size, figsize=(batch_size * 5, 4)) # Adjust figure size as needed
-
- # Check if batch_size is 1, axs might not be iterable
- if batch_size == 1:
- axs = [axs]
-
- # Plot each spectral filter in its own subplot
- for i in range(batch_size):
- colors = ['b', 'g', 'r']
- for j in range(3):
- pix_j_row_value = np.random.randint(0,y)
- pix_j_col_value = np.random.randint(0,x)
-
- pix_j_ref = ref_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- pix_j_reconstructed = recontructed_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- axs[i].plot(pix_j_reconstructed, label="pix reconstructed" + str(j),c=colors[j])
- axs[i].plot(pix_j_ref, label="pix" + str(j), linestyle='--',c=colors[j])
-
- axs[i].set_title(f"Reconstruction quality")
-
- axs[i].set_xlabel("Wavelength index")
- axs[i].set_ylabel("pix values")
- axs[i].grid(True)
-
- plt.legend()
- # Adjust layout
- plt.tight_layout()
-
- # Create a buffer to save plot
- buf = io.BytesIO()
- plt.savefig(buf, format='png')
- plt.close(fig)
- buf.seek(0)
-
- # Convert PNG buffer to PIL Image
- image = Image.open(buf)
-
- # Convert PIL Image to Tensor
- image_tensor = transforms.ToTensor()(image)
- return image_tensor
-
-
-def subsample(input, origin_sampling, target_sampling):
- [bs, row, col, nC] = input.shape
- indices = torch.zeros(len(target_sampling), dtype=torch.int)
- for i in range(len(target_sampling)):
- sample = target_sampling[i]
- idx = torch.abs(origin_sampling-sample).argmin()
- indices[i] = idx
- return input[:,:,:,indices]
-
-def expand_mask_3d(mask_batch):
- if len(mask_batch.shape)==3:
- mask3d = mask_batch.unsqueeze(-1).repeat((1, 1, 1, 28))
- else:
- mask3d = mask_batch.repeat((1, 1, 1, 28))
- mask3d = torch.permute(mask3d, (0, 3, 1, 2))
- return mask3d
-
-class EmptyModule(nn.Module):
- def __init__(self):
- super().__init__()
- self.useless_linear = nn.Linear(1, 1)
- def forward(self, x):
- return x
-
-def calculate_spectral_flatness(pattern):
-
- fft_result = torch.fft.fft2(pattern)
-
- # Calculate the Power Spectrum
- power_spectrum = torch.abs(fft_result)**2
-
- # Calculate the Geometric Mean of the power spectrum
- # Use torch.log and torch.exp for differentiability, adding a small epsilon to avoid log(0)
- epsilon = 1e-10
- geometric_mean = torch.exp(torch.mean(torch.log(power_spectrum + epsilon)))
-
- # Calculate the Arithmetic Mean of the power spectrum
- arithmetic_mean = torch.mean(power_spectrum)
-
- # Compute the Spectral Flatness
- spectral_flatness = geometric_mean / arithmetic_mean
-
- return spectral_flatness
-
-class BinarizeFunction(torch.autograd.Function):
- @staticmethod
- def forward(ctx, input):
- # Forward pass is the binary threshold operation
- return (input > 0.5).float()
-
- @staticmethod
- def backward(ctx, grad_output):
- # For backward pass, just pass the gradients through unchanged
- return grad_output
diff --git a/analyze_cassi.py b/analyze_cassi.py
new file mode 100755
index 0000000..55ccf7b
--- /dev/null
+++ b/analyze_cassi.py
@@ -0,0 +1,26 @@
+import argparse
+from pprint import pprint
+import os
+
+from simca.cost_functions_optics import test_cassi_system
+
+def analyze_system(input_config_dir):
+
+ final_config_path = os.path.join(input_config_dir, "config_system.yml")
+ config_system, performances = test_cassi_system(final_config_path, save_fig_dir=input_config_dir,save_fig=True)
+
+ print(f"\n---- Optical System Configuration for {final_config_path} ----")
+ pprint(config_system)
+
+ print(f"\n---- Optical Performances for {final_config_path} ----")
+ pprint(performances)
+
+
+
+if __name__ == "__main__":
+ parser = argparse.ArgumentParser(description="Analyze existing SD-CASSI system")
+ parser.add_argument("--input_dir", required=True, help="Path to the configuration file to analyze")
+ args = parser.parse_args()
+
+ analyze_system(args.input_config_dir)
+
diff --git a/data_handler.py b/data_handler.py
deleted file mode 100755
index e33b896..0000000
--- a/data_handler.py
+++ /dev/null
@@ -1,212 +0,0 @@
-import os
-from pytorch_lightning.utilities.types import EVAL_DATALOADERS
-import torch
-import scipy.io as sio
-from torch.utils.data import Dataset, DataLoader
-from torch.utils.data import random_split
-from torchvision import datasets
-from torchvision.transforms import ToTensor
-import matplotlib.pyplot as plt
-import numpy as np
-import random
-from pytorch_lightning import LightningDataModule
-
-
-class CubesDataset(Dataset):
- def __init__(self, data_dir, augment=True):
- self.data_dir = data_dir
- self.augment_ = augment
- self.data_file_names = sorted(os.listdir(self.data_dir))
-
- def __len__(self):
- return len(self.data_file_names)
-
- def __getitem__(self, idx):
-
- cube, wavelengths = self.load_hyperspectral_data(idx) # H x W x lambda
-
- if self.augment_:
- cube = self.augment(cube, 128) # lambda x H x W
- else:
- cube = torch.from_numpy(np.transpose(cube, (2, 0, 1))).float()[:,:128,:128] # lambda x H x W
-
- return cube, wavelengths
-
- def load_hyperspectral_data(self, idx):
- file_path = os.path.join(self.data_dir, self.data_file_names[idx])
- data = sio.loadmat(file_path)
- if "img_expand" in data:
- cube = data['img_expand'] / 65536.
- elif "img" in data:
- cube = data['img'] / 65536.
- cube = cube.astype(np.float32) # H x W x lambda
- wavelengths = torch.tensor(np.linspace(450, 650, 28))
-
- return cube, wavelengths
-
- def augment(self, img, crop_size = 128):
- h, w, _ = img.shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data = np.zeros((crop_size, crop_size, 28), dtype=np.float32)
- processed_data = img[x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- processed_data = torch.from_numpy(np.transpose(processed_data, (2, 0, 1))).float()
- processed_data = arguement_1(processed_data)
-
- """ # The other half data use splicing.
- processed_data = np.zeros((4, crop_size//2, crop_size//2, 28), dtype=np.float32)
- for i in range(batch_size - batch_size // 2):
- sample_list = np.random.randint(0, len(train_data), 4)
- for j in range(4):
- x_index = np.random.randint(0, h-crop_size//2)
- y_index = np.random.randint(0, w-crop_size//2)
- processed_data[j] = train_data[sample_list[j]][x_index:x_index+crop_size//2,y_index:y_index+crop_size//2,:]
- gt_batch_2 = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2))).cuda() # [4,28,128,128]
- gt_batch.append(arguement_2(gt_batch_2))
- gt_batch = torch.stack(gt_batch, dim=0) """
- return processed_data
-
-
-class CubesDataModule(LightningDataModule):
- def __init__(self, data_dir, batch_size, num_workers=1):
- super().__init__()
- self.data_dir = data_dir
- self.batch_size = batch_size
- self.num_workers = num_workers
- self.dataset = CubesDataset(self.data_dir,augment=True)
-
- def setup(self, stage=None):
- dataset_size = len(self.dataset)
- train_size = int(0.7 * dataset_size)
- val_size = int(0.2 * dataset_size)
- test_size = dataset_size - train_size - val_size
-
- self.train_ds, self.val_ds, self.test_ds = random_split(self.dataset, [train_size, val_size, test_size])
-
- def train_dataloader(self):
- return DataLoader(self.train_ds,
- batch_size=self.batch_size,
- num_workers=self.num_workers,
- shuffle=True)
-
- def val_dataloader(self):
- return DataLoader(self.val_ds,
- batch_size=self.batch_size,
- num_workers=self.num_workers,
- shuffle=False)
-
- def test_dataloader(self):
- return DataLoader(self.test_ds,
- batch_size=self.batch_size,
- num_workers=self.num_workers,
- shuffle=False)
-
- def predict_dataloader(self):
- return DataLoader(self.train_ds,
- batch_size=self.batch_size,
- num_workers=self.num_workers,
- shuffle=False)
-
-
-def arguement_1(x):
- """
- :param x: c,h,w
- :return: c,h,w
- """
- rotTimes = random.randint(0, 3)
- vFlip = random.randint(0, 1)
- hFlip = random.randint(0, 1)
- # Random rotation
- for j in range(rotTimes):
- x = torch.rot90(x, dims=(1, 2))
- # Random vertical Flip
- for j in range(vFlip):
- x = torch.flip(x, dims=(2,))
- # Random horizontal Flip
- for j in range(hFlip):
- x = torch.flip(x, dims=(1,))
- return x
-
-
-def shuffle_crop(train_data, batch_size, crop_size=256, argument=True):
- if argument:
- gt_batch = []
- # The first half data use the original data.
- index = np.random.choice(range(len(train_data)), batch_size//2)
- processed_data = np.zeros((batch_size//2, crop_size, crop_size, 28), dtype=np.float32)
- for i in range(batch_size//2):
- img = train_data[index[i]]
- h, w, _ = img.shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data[i, :, :, :] = img[x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- processed_data = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2))).cuda().float()
- for i in range(processed_data.shape[0]):
- gt_batch.append(arguement_1(processed_data[i]))
-
- # The other half data use splicing.
- processed_data = np.zeros((4, crop_size//2, crop_size//2, 28), dtype=np.float32)
- for i in range(batch_size - batch_size // 2):
- sample_list = np.random.randint(0, len(train_data), 4)
- for j in range(4):
- x_index = np.random.randint(0, h-crop_size//2)
- y_index = np.random.randint(0, w-crop_size//2)
- processed_data[j] = train_data[sample_list[j]][x_index:x_index+crop_size//2,y_index:y_index+crop_size//2,:]
- gt_batch_2 = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2))).cuda() # [4,28,128,128]
- gt_batch.append(arguement_2(gt_batch_2))
- gt_batch = torch.stack(gt_batch, dim=0)
- return gt_batch
- else:
- index = np.random.choice(range(len(train_data)), batch_size)
- processed_data = np.zeros((batch_size, crop_size, crop_size, 28), dtype=np.float32)
- for i in range(batch_size):
- h, w, _ = train_data[index[i]].shape
- x_index = np.random.randint(0, h - crop_size)
- y_index = np.random.randint(0, w - crop_size)
- processed_data[i, :, :, :] = train_data[index[i]][x_index:x_index + crop_size, y_index:y_index + crop_size, :]
- gt_batch = torch.from_numpy(np.transpose(processed_data, (0, 3, 1, 2)))
- return gt_batch
-
-def arguement_2(generate_gt):
- c, h, w = generate_gt.shape[1],generate_gt.shape[2],generate_gt.shape[3]
- divid_point_h = h//2
- divid_point_w = w//2
- output_img = torch.zeros(c,h,w).cuda()
- output_img[:, :divid_point_h, :divid_point_w] = generate_gt[0]
- output_img[:, :divid_point_h, divid_point_w:] = generate_gt[1]
- output_img[:, divid_point_h:, :divid_point_w] = generate_gt[2]
- output_img[:, divid_point_h:, divid_point_w:] = generate_gt[3]
- return output_img
-
-# class AcquisitionDataset(Dataset):
-# def __init__(self, input, hs_cubes, transform=None, target_transform=None):
-# """_summary_
-
-# Args:
-# input (_type_): List of size 2 with each element being a list:
-# - First list: List of n torch.tensor acquisitions (2D)
-# - Second list: List of n int labels
-# hs_cubes (_type_): List of size m, hs_cubes[m] being the m-th hs cube
-# transform (_type_, optional): _description_. Defaults to None.
-# target_transform (_type_, optional): _description_. Defaults to None.
-# """
-# self.data = input # list of size 2, first elem is a list of n torch.tensor acquisitions (input), second elem is a list of size n with the index of corresponding hs cubes (output)
-# self.labels = self.data[1]
-
-# self.cubes = hs_cubes # list of cubes, number of cubes must be >= max(self.labels)
-
-# self.transform = transform
-# self.target_transform = target_transform
-
-# def __len__(self):
-# return len(self.data[1])
-
-# def __getitem__(self, index):
-# acq = self.data[0][index] # torch tensor of size x*y
-# cube = self.cubes[self.labels[index]] # torch tensor of size x*y*w
-
-# return acq, cube
-
-if __name__ == "__main__":
- data_dir = "/local/users/ademaio/lpaillet/mst_datasets/cave_1024_28/"
- datamodule = CubesDataModule(data_dir, batch_size=5, num_workers=2)
\ No newline at end of file
diff --git a/design_cassi.py b/design_cassi.py
new file mode 100755
index 0000000..9456349
--- /dev/null
+++ b/design_cassi.py
@@ -0,0 +1,116 @@
+import argparse
+from pprint import pprint
+import os
+import json
+import os
+import matplotlib.pyplot as plt
+
+from simca.cost_functions_optics import (
+ optimize_cassi_system,
+ test_cassi_system,
+ plot_optimization_process
+)
+from simca.functions_optim import save_config_system
+
+def optimize_step(params_to_optimize, cost_weights, init_config_path, target_dispersion, iterations, patience, device, index_estimation_method, step_name, output_dir):
+ final_config, latest_optical_params = optimize_cassi_system(
+ params_to_optimize,
+ target_dispersion,
+ cost_weights,
+ init_config_path,
+ iterations,
+ patience,
+ output_dir,
+ step_name,
+ index_estimation_method=index_estimation_method,
+ device=device
+ )
+
+ # Plot the optimization process after each step
+ plot_optimization_process(output_dir, step_name)
+
+ return final_config, latest_optical_params
+
+
+def main(prism_type, output_dir):
+ target_dispersion = 1000 # in [µm] ---> modify to spectral spreading
+ iterations = 2000
+ patience = 500
+ device = "cuda"
+
+ # Ensure the output directory exists
+ os.makedirs(output_dir, exist_ok=True)
+
+ # Set the final config path
+ final_config_path = os.path.join(output_dir, "config_system.yml")
+
+ if prism_type == "amici":
+ # STEP 1: Optimize everything (including prism materials)
+ params_step1 = ['lba_c', 'alpha_c', 'A1', 'A2', 'nd1', 'nd2', 'vd1', 'vd2']
+ init_config_path_step1 = "./init_configs/system_config_amici.yml"
+
+ # STEP 2: Optimize everything (excluding prism materials)
+ params_step2 = ['lba_c', 'alpha_c', 'A1', 'A2']
+
+ cost_weights = {
+ 'cost_dispersion': 1.0,
+ 'cost_distance_glasses': 1.0,
+ 'cost_deviation': 1,
+ 'cost_distorsion': 1.0,
+ 'cost_thickness': 1.0,
+ 'cost_beam_compression': 1.0,
+ 'cost_non_linearity': 1.0,
+ 'cost_distance_total_intern_reflection': 1.0
+ }
+ elif prism_type == "single": # single prism
+ # STEP 1: Optimize everything (including prism material)
+ params_step1 = ['lba_c', 'alpha_c', 'A1', 'nd1', 'vd1']
+ init_config_path_step1 = "./init_configs/system_config_single.yml"
+
+ # STEP 2: Optimize everything (excluding prism material)
+ params_step2 = ['lba_c', 'alpha_c', 'A1']
+
+ cost_weights = {
+ 'cost_dispersion': 20.0,
+ 'cost_distance_glasses': 1.0,
+ 'cost_deviation': 1e-5,
+ 'cost_distorsion': 1.0,
+ 'cost_thickness': 1.0,
+ 'cost_beam_compression': 1.0,
+ 'cost_non_linearity': 1.0,
+ 'cost_distance_total_intern_reflection': 1.0
+ }
+ else:
+ raise ValueError(f"Invalid prism type: {prism_type}")
+
+ # STEP 1
+ config_step1, params_step1 = optimize_step(params_step1, cost_weights, init_config_path_step1, target_dispersion, iterations, patience, device, "cauchy", "step1", output_dir)
+
+ temp_config_path = os.path.join(output_dir, "temp.yml")
+ save_config_system(temp_config_path, os.path.join(output_dir, "optimization_results", "step1"), init_config_path_step1)
+
+ # STEP 2
+ if prism_type == "amici":
+ cost_weights['cost_dispersion'] = 2.0 # Increase weight for dispersion in step 2 for Amici
+ config_step2, params_step2 = optimize_step(params_step2, cost_weights, temp_config_path, target_dispersion, iterations, patience, device, "sellmeier", "step2", output_dir)
+
+ save_config_system(final_config_path, os.path.join(output_dir, "optimization_results", "step2"), temp_config_path, index_estimation_method="sellmeier")
+
+ # Testing
+ config_system, performances = test_cassi_system(final_config_path, index_estimation_method="sellmeier")
+
+ print("\n---- Optical System Configuration----")
+ pprint(config_system)
+
+ print("\n---- Optical Performances ----")
+ pprint(performances)
+
+
+
+if __name__ == "__main__":
+ parser = argparse.ArgumentParser(description="Design SD-CASSI system with Amici or single prism")
+ parser.add_argument("--prism_type", choices=["amici", "single"], required=True, help="Type of prism system to design")
+ parser.add_argument("--output_dir", required=True, help="Directory for the final configuration file")
+ args = parser.parse_args()
+
+ main(args.prism_type, args.output_dir)
\ No newline at end of file
diff --git a/gradient_descent_optics_optim_triplet.py b/gradient_descent_optics_optim_triplet.py
deleted file mode 100755
index c176903..0000000
--- a/gradient_descent_optics_optim_triplet.py
+++ /dev/null
@@ -1,349 +0,0 @@
-from simca.cost_functions_optics import evaluate_spectral_dispersion_values
-from simca import load_yaml_config
-from simca.CassiSystemOptim import CassiSystemOptim
-from torch.optim import Adam, LBFGS
-from opticalglass.glassfactory import get_glass_catalog
-from simca.cost_functions_optics import *
-import matplotlib.pyplot as plt
-import pandas as pd
-import torch
-import os
-import datetime
-import json
-# from torchviz import make_dot
-
-def format_score_details(**kwargs):
- """
- Format the score details into a dictionary.
-
- Args:
- **kwargs: Keyword arguments of score components and their values.
-
- Returns:
- dict: A dictionary containing the score formula and component values.
- """
- score_details = {
- 'formula': "score = cost_dispersion + cost_distance_glasses + cost_deviation + cost_distorsion + cost_thickness + cost_beam_compression",
- 'components': kwargs # This will include all the passed score components and their values.
- }
- return score_details
-
-target_dispersion = 2200
-
-import math
-#matplotlib.use('Agg')
-config_system = load_yaml_config("simca/configs/cassi_system_optim_optics_full_triplet_starting_point.yml")
-
-hoya_pd = get_glass_catalog('Schott')
-list_of_glasses1 = hoya_pd.df.iloc[:, 0].index.tolist()
-# Access the 'nd' values where the first level is NaN
-idx = pd.IndexSlice
-
-nd_values = hoya_pd.df.loc[:, idx[pd.NA, 'nd']]
-vd_values = hoya_pd.df.loc[:, idx["abbe number", 'vd']]
-
-nd_values = torch.tensor(nd_values.values)
-vd_values = torch.tensor(vd_values.values)
-
-cassi_system = CassiSystemOptim(system_config=config_system)
-
-# Assuming 'device' is defined (e.g., 'cuda' or 'cpu')
-device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
-# cassi_system.to(device) # Move your model to the specified device
-
-optim_params = [cassi_system.optical_model.lba_c,
- cassi_system.optical_model.alpha_c,
- cassi_system.optical_model.A1,
- cassi_system.optical_model.A2,
- # cassi_system.optical_model.A3,
- cassi_system.optical_model.nd1,
- cassi_system.optical_model.nd2,
- # cassi_system.optical_model.nd3,
- cassi_system.optical_model.vd1,
- cassi_system.optical_model.vd2,
- # cassi_system.optical_model.vd3,
- ]
-
-optimizer = Adam(optim_params, lr=0.005)
-iterations = 10000
-
-
-# Initialize tracking variables
-best_loss = float('inf') # Set the initial best loss to infinity
-patience = 500 # How many iterations to wait after last improvement
-non_improvement_count = 0 # Counter for iterations without improvement
-
-
-### create a new dir for the results
-
-if not os.path.exists('results'):
- os.makedirs('results')
-
-# list_scores = []
-# numpy_alpha_c = np.linspace(1, 90, 80)
-# for alpha_c in numpy_alpha_c:
-# config_system["system architecture"]["dispersive element"]["alpha_c"] = alpha_c
-# cassi_system = CassiSystemOptim(system_config=config_system)
-#
-# score = testing_model(cassi_system,nd_values, vd_values)
-# is_nan = torch.isnan(score).item()
-# list_scores.append(score.detach().numpy())
-# print(score)
-#
-# # idx_min = list_scores.index(min(list_scores))
-# min_value = np.nanmin(list_scores) # Returns the min of the array, ignoring any NaNs
-# idx_min = list_scores.index(min_value)
-# # print("min score", min(idx_min), min_value)
-# config_system["system architecture"]["dispersive element"]["alpha_c"] = numpy_alpha_c[idx_min]
-# cassi_system = CassiSystemOptim(system_config=config_system)
-
-# create a new dir for the results
-
-run_id = datetime.datetime.now().strftime('%Y-%m-%d_%H-%M-%S')
-results_dir = os.path.join('results', run_id)
-os.makedirs(results_dir, exist_ok=True)
-
-
-for i in range(iterations):
- # Zero the parameter gradients
- optimizer.zero_grad()
-
- cassi_system.optical_model.A3 = cassi_system.optical_model.A1
- cassi_system.optical_model.nd3 = cassi_system.optical_model.nd1
- cassi_system.optical_model.vd3 = cassi_system.optical_model.vd1
-
- alpha_c_out = cassi_system.optical_model.rerun_central_dispersion()
- # Forward pass
- x_vec_out, y_vec_out = cassi_system.propagate_coded_aperture_grid()
-
- alpha_c = cassi_system.optical_model.alpha_c
- alpha_c_out = cassi_system.optical_model.alpha_c_transmis
- list_apex_angles = [cassi_system.optical_model.A1, cassi_system.optical_model.A2, cassi_system.optical_model.A3]
- list_theta_in = cassi_system.optical_model.list_theta_in
- list_theta_out = cassi_system.optical_model.list_theta_out
-
- # evaluate spectral dispersion
- dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
-
- y_second_derivative = calculate_second_derivative(cassi_system.wavelengths, central_coordinates_X)
-
- # evaluate direct_view
- deviation = evaluate_direct_view(alpha_c, alpha_c_out, list_apex_angles)
- # print("deviation in degrees", deviation * 180 / np.pi)
-
- # evaluate beam compression
- beam_compression = evaluate_beam_compression(list_theta_in, list_theta_out)
- # print("beam compression", beam_compression)
-
- # evaluate thickness
- thickness = evaluate_thickness(list_apex_angles)
- # print("thickness", thickness)
-
- # evaluate distortions
- x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system.X_coded_aper_coordinates,
- cassi_system.Y_coded_aper_coordinates,
- central_coordinates_X)
-
- # plt.scatter(cassi_system.X_coordinates_propagated_coded_aperture.detach().numpy()[..., 0],
- # cassi_system.Y_coordinates_propagated_coded_aperture.detach().numpy()[..., 0], color='blue', label="distor")
- # plt.scatter(cassi_system.X_coordinates_propagated_coded_aperture.detach().numpy()[..., -1],
- # cassi_system.Y_coordinates_propagated_coded_aperture.detach().numpy()[..., -1], color='red', label="distor")
- # plt.scatter(x_vec_no_dist.detach().numpy()[..., 0], y_vec_no_dist.detach().numpy()[..., 0], label="no dist",
- # color='green')
- # plt.scatter(x_vec_no_dist.detach().numpy()[..., -1], y_vec_no_dist.detach().numpy()[..., -1], label="no dist",
- # color='green')
- # plt.show()
- distortion_metric = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist)
-
- # print("distortion metric", distortion_metric)
-
- # distance from closest point
- current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
- current_value2 = [cassi_system.optical_model.nd2, cassi_system.optical_model.vd2]
- current_value3 = [cassi_system.optical_model.nd3, cassi_system.optical_model.vd3]
-
- distance_closest_point1, min_idx1 = evaluate_distance(current_value1, nd_values, vd_values)
- distance_closest_point2, min_idx2 = evaluate_distance(current_value2, nd_values, vd_values)
- distance_closest_point3, min_idx3 = evaluate_distance(current_value3, nd_values, vd_values)
-
- # # cost functions
- cost_dispersion = (target_dispersion/5- dispersion/5)**2
- cost_distance_glasses = (10**10*(distance_closest_point1**2 + distance_closest_point2**2 + distance_closest_point3**2))**2
- cost_deviation = (deviation*10)**2
- cost_distorsion = (distortion_metric/1000)**2
- cost_thickness = thickness*10
- cost_beam_compression = torch.abs(beam_compression - 1)*10
- cost_non_linearity = 0.001* y_second_derivative**2
- # cost_distance_total_intern_reflection = 0.1*softplus(cassi_system.optical_model.min_distance_from_total_intern_reflection)**2
- cost_block = ((-1*list_apex_angles[0] + list_apex_angles[1] - list_apex_angles[2])*100)**2
-
-
- score = cost_dispersion + cost_distance_glasses + cost_deviation + cost_thickness + cost_block
- # score = (alpha_c_out - 10)**2
- # Assume `score` is your loss metric that you want to minimize
-
- current_loss = score.item()
-
- is_nan = math.isnan(current_loss)
- if is_nan:
- print("nan value")
- break
-
-
- latest_optical_params = {"alpha_c":cassi_system.optical_model.alpha_c.clone(),
- "lba_c":cassi_system.optical_model.lba_c.clone(),
- "A1":cassi_system.optical_model.A1.clone(),
- "A2":cassi_system.optical_model.A2.clone(),
- "A3":cassi_system.optical_model.A3.clone(),
- "nd1":cassi_system.optical_model.nd1.clone(),
- "nd2":cassi_system.optical_model.nd2.clone(),
- "nd3":cassi_system.optical_model.nd3.clone(),
- "vd1":cassi_system.optical_model.vd1.clone(),
- "vd2":cassi_system.optical_model.vd2.clone(),
- "vd3":cassi_system.optical_model.vd3.clone(),
- }
-
- # Backward pass
- score.backward()
- optimizer.step()
-
-
-
- if i %100 == 0:
- print(f'Iteration {i}, Loss: {current_loss}')
- print("dispersion in microns", dispersion)
- print("cost_dispersion", cost_dispersion)
- print("cost_distance_glasses", cost_distance_glasses)
- print("cost_deviation", cost_deviation)
- print("cost_distorsion", cost_distorsion)
- print("cost_thickness", cost_thickness)
- # print("cost_beam_compression", cost_beam_compression)
- print("cost_block", cost_block)
- print(cost_block)
- # print("cost_block", cost_block)
- # print("cost_distance_total_intern_reflection", cost_distance_total_intern_reflection)
-
- # Saving optimization details at the end of optimization
- optimization_details = {
- 'reason_for_stopping': 'no improvement' if non_improvement_count >= patience else 'completed',
- 'iterations': i + 1,
- 'end_parameters': {param_name: param.item() for param_name, param in latest_optical_params.items()},
- 'current_loss': current_loss,
- # Add other details as needed
- }
-
- details_path = os.path.join(results_dir, 'optimization_details.json')
- with open(details_path, 'a') as f:
- json.dump(optimization_details, f, indent=4)
-
- score_details = format_score_details(
- cost_dispersion=cost_dispersion.item(),
- cost_distance_glasses=cost_distance_glasses.item(),
- cost_deviation=cost_deviation.item(),
- cost_distorsion=cost_distorsion.item(),
- cost_thickness=cost_thickness.item(),
- cost_beam_compression=cost_beam_compression.item(),
- )
-
- # Save the score details to a file
- details_path = os.path.join(results_dir, f'score_details_iteration.json')
- with open(details_path, 'a') as f:
- json.dump(score_details, f, indent=4)
-
- # Check for improvement
- if current_loss < best_loss:
- best_loss = current_loss
- non_improvement_count = 0 # Reset counter
- else:
- non_improvement_count += 1
-
- # Check if it's time to stop
- if non_improvement_count >= patience:
- print(f'Stopping early at iteration {i} due to no improvement.')
- break # Exit the loop
-
- # input("Press Enter to continue...")
-
-
-
-# Testing with closest points
-
-current_glass_values_1 = [latest_optical_params["nd1"], latest_optical_params["vd1"]]
-current_glass_values_2 = [latest_optical_params["nd2"], latest_optical_params["vd2"]]
-current_glass_values_3 = [latest_optical_params["nd3"], latest_optical_params["vd3"]]
-
-
-distance_closest_point1, min_idx_1 = evaluate_distance(current_glass_values_1, nd_values, vd_values)
-distance_closest_point2, min_idx_2 = evaluate_distance(current_glass_values_2, nd_values, vd_values)
-distance_closest_point3, min_idx_3 = evaluate_distance(current_glass_values_3, nd_values, vd_values)
-
-plt.scatter(nd_values, vd_values, c='b', label='all glasses')
-plt.scatter(current_glass_values_1[0].detach().numpy(), current_glass_values_1[1].detach().numpy(), c='r', label='current glass 1')
-plt.scatter(current_glass_values_2[0].detach().numpy(), current_glass_values_2[1].detach().numpy(), c='g', label='current glass 2')
-plt.scatter(current_glass_values_3[0].detach().numpy(), current_glass_values_3[1].detach().numpy(), c='y', label='current glass 3')
-plt.scatter(nd_values[min_idx_1], vd_values[min_idx_1], c='r', label='closest glass 1',marker='x')
-plt.scatter(nd_values[min_idx_2], vd_values[min_idx_2], c='g', label='closest glass 2',marker='x')
-plt.scatter(nd_values[min_idx_3], vd_values[min_idx_3], c='y', label='closest glass 3',marker='x')
-plot_path = os.path.join(results_dir, 'glasses_plot.png')
-plt.savefig(plot_path)
-# plt.close()
-plt.show()
-
-glass_1 = list_of_glasses1[min_idx_1]
-glass_2 = list_of_glasses1[min_idx_2]
-glass_3 = list_of_glasses1[min_idx_3]
-
-# print(glass_1, glass_2, glass_3)
-
-
-
-print(latest_optical_params)
-
-cassi_system_renewal = CassiSystemOptim(system_config=cassi_system.system_config)
-
-
-print(cassi_system_renewal.system_config)
-# set the closest glasses
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]["wavelength center"] = latest_optical_params["lba_c"]
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]["alpha_c"] = latest_optical_params["alpha_c"] * 180 / np.pi
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]["A1"] = latest_optical_params["A1"] * 180 / np.pi
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]["A2"] = latest_optical_params["A2"]* 180 / np.pi
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]["A3"] = latest_optical_params["A3"] * 180 / np.pi
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['continuous glass materials 1'] = False
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['continuous glass materials 2']= False
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['continuous glass materials 3'] = False
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['glass1'] = glass_1
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['glass2'] = glass_2
-cassi_system_renewal.system_config["system architecture"]["dispersive element"]['glass3'] = glass_3
-
-cassi_system_renewal.update_optical_model(cassi_system.system_config)
-
-# pattern : Generate the coded aperture pattern
-# cassi_system_renewal.generate_2D_pattern(config_patterns)
-
-X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture = cassi_system_renewal.propagate_coded_aperture_grid()
-
-# evaluate spectral dispersion
-dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture)
-
-x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system_renewal.X_coded_aper_coordinates,
- cassi_system_renewal.Y_coded_aper_coordinates,
- central_coordinates_X)
-print(cassi_system_renewal.system_config)
-print("dispersion in microns", dispersion)
-
-plt.scatter(X_coordinates_propagated_coded_aperture.detach().numpy()[..., 0], Y_coordinates_propagated_coded_aperture.detach().numpy()[..., 0], color='blue', label="distor")
-plt.scatter(X_coordinates_propagated_coded_aperture.detach().numpy()[..., -1], Y_coordinates_propagated_coded_aperture.detach().numpy()[..., -1], color='red', label="distor")
-#
-plt.scatter(x_vec_no_dist.detach().numpy()[..., 0], y_vec_no_dist.detach().numpy()[..., 0], label="no dist",
- color='green')
-plt.scatter(x_vec_no_dist.detach().numpy()[..., -1], y_vec_no_dist.detach().numpy()[..., -1], label="no dist",
- color='green')
-
-plot_path = os.path.join(results_dir, 'grids.png')
-plt.savefig(plot_path)
-plt.show()
-
-
-
-
diff --git a/init_configs/system_config_amici.yml b/init_configs/system_config_amici.yml
new file mode 100755
index 0000000..30a98fb
--- /dev/null
+++ b/init_configs/system_config_amici.yml
@@ -0,0 +1,38 @@
+##### Configuration file for the chosen optical system
+
+infos:
+ system name: HYACAMEO
+
+system architecture:
+ system type: DD-CASSI
+ focal lens: 75000
+ dispersive element:
+ # dispersive element caracteristics
+ catalog: Schott
+ index evaluation method: cauchy
+ type: amici # name of the dispersive element
+ glass1: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
+ glass2: N-SF4 # glass type of the dispersive element (only used if type == 'prism')
+ glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
+ A1: 19.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
+ A2: 39.4 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
+ A3: 19.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
+ alpha_c: 0
+ delta alpha c: 0
+ delta beta c: 0
+ wavelength center: 520 # central wavelength -- in nm
+detector:
+ number of pixels along X: 112 # number of pixels along X axis -- no units
+ number of pixels along Y: 112 # number of pixels along Y axis -- no units
+ pixel size along X: 71 # pixel size along X -- in um
+ pixel size along Y: 71 # pixel size along Y -- in um
+
+coded aperture:
+ number of pixels along X: 25 # number of pixels along X axis -- no units
+ number of pixels along Y: 25 # number of pixels along Y axis -- no units
+ pixel size along X: 210 # pixel size along X -- in um
+ pixel size along Y: 210 # pixel size along Y -- in um
+spectral range:
+ wavelength min: 450 # minimum wavelength -- in nm
+ wavelength max: 650 # maximum wavelength -- in nm
+ number of spectral samples: 10
diff --git a/init_configs/system_config_single.yml b/init_configs/system_config_single.yml
new file mode 100755
index 0000000..7154424
--- /dev/null
+++ b/init_configs/system_config_single.yml
@@ -0,0 +1,34 @@
+##### Configuration file for the chosen optical system
+
+infos:
+ system name: HYACAMEO
+
+system architecture:
+ system type: DD-CASSI
+ focal lens: 75000
+ dispersive element:
+ # dispersive element caracteristics
+ catalog: Schott
+ type: prism # name of the dispersive element
+ glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
+ A1: 50 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
+ alpha_c: 40.9
+ delta alpha c: 0
+ delta beta c: 0
+ wavelength center: 520 # central wavelength -- in nm
+detector:
+ number of pixels along X: 112 # number of pixels along X axis -- no units
+ number of pixels along Y: 112 # number of pixels along Y axis -- no units
+ pixel size along X: 71 # pixel size along X -- in um
+ pixel size along Y: 71 # pixel size along Y -- in um
+
+coded aperture:
+ number of pixels along X: 25 # number of pixels along X axis -- no units
+ number of pixels along Y: 25 # number of pixels along Y axis -- no units
+ pixel size along X: 210 # pixel size along X -- in um
+ pixel size along Y: 210 # pixel size along Y -- in um
+
+spectral range:
+ wavelength min: 450 # minimum wavelength -- in nm
+ wavelength max: 650 # maximum wavelength -- in nm
+ number of spectral samples: 10
diff --git a/logo_SIMCA.png b/logo_SIMCA.png
deleted file mode 100644
index 896df76..0000000
Binary files a/logo_SIMCA.png and /dev/null differ
diff --git a/main.py b/main.py
deleted file mode 100644
index ffd1a31..0000000
--- a/main.py
+++ /dev/null
@@ -1,77 +0,0 @@
-import sys
-from PyQt5.QtCore import Qt
-from PyQt5.QtWidgets import QApplication, QMainWindow, QDockWidget
-from PyQt5.QtGui import QIcon
-from gui_elements import OpticsWidget
-from gui_elements import EditorSystemConfigWidget
-from gui_elements import FilteringCubeWidget
-from gui_elements import DatasetWidget
-from gui_elements import AcquisitionWidget
-
-from simca import CassiSystem
-import os
-class MainWindow(QMainWindow):
- def __init__(self):
- super().__init__()
-
- self.setWindowIcon(QIcon('logo_SIMCA.png'))
- # self.setWindowIcon(QIcon('Figure_1.ico'))
- self.setWindowTitle('SIMCA')
-
- self.cassi_system = CassiSystem(system_config_path="simca/configs/cassi_system.yml")
-
- self.scene_widget = DatasetWidget(cassi_system=self.cassi_system, dataset_config_path="simca/configs/dataset.yml")
- self.scene_dock = QDockWidget("Dataset")
- self.scene_dock.setWidget(self.scene_widget)
- self.addDockWidget(Qt.RightDockWidgetArea, self.scene_dock)
-
-
- self.system_editor = EditorSystemConfigWidget(initial_system_config_path="simca/configs/cassi_system.yml")
- self.system_config_dock = QDockWidget("Editor Optical Design")
- self.system_config_dock.setWidget(self.system_editor)
- self.addDockWidget(Qt.LeftDockWidgetArea, self.system_config_dock)
- self.system_config_dock.setVisible(False)
- self.system_config_dock.setFixedWidth(int(self.width() / 2))
-
- # --- Initiliaze CASSI SYSTEM -- #
-
-
-
- self.optics_widget = OpticsWidget(cassi_system=self.cassi_system, editor_system_config=self.system_editor, optics_config_path="simca/configs/optics.yml")
- self.optics_dock = QDockWidget("Optical Design")
- self.optics_dock.setWidget(self.optics_widget)
- self.addDockWidget(Qt.RightDockWidgetArea, self.optics_dock)
-
- self.filtering_widget = FilteringCubeWidget(cassi_system=self.cassi_system, system_editor=self.system_editor, filtering_config_path="simca/configs/pattern.yml")
- self.filtering_dock = QDockWidget("Coded Aperture")
- self.filtering_dock.setWidget(self.filtering_widget)
- self.addDockWidget(Qt.RightDockWidgetArea, self.filtering_dock)
-
- self.acquisition_widget = AcquisitionWidget(self.cassi_system, self.system_editor, self.scene_widget, self.filtering_widget, acquisition_config_path="simca/configs/acquisition.yml")
- self.acquisition_dock = QDockWidget("Acquisition")
- self.acquisition_dock.setWidget(self.acquisition_widget)
- self.addDockWidget(Qt.RightDockWidgetArea, self.acquisition_dock)
-
- self.tabifyDockWidget(self.scene_dock, self.optics_dock)
- self.tabifyDockWidget(self.optics_dock, self.filtering_dock)
- self.tabifyDockWidget(self.filtering_dock, self.acquisition_dock)
-
- self.scene_dock.raise_()
- # Connect the signal to the slot
- self.tabifiedDockWidgetActivated.connect(self.check_dock_visibility)
-
- def check_dock_visibility(self, dock_widget):
- # If the currently selected dock widget is the Scene dock, hide the system_config_dock
- if dock_widget is self.scene_dock or dock_widget is self.acquisition_dock or dock_widget is self.filtering_dock:
- self.system_config_dock.setVisible(False)
- else:
- self.system_config_dock.setVisible(True)
-
-
-if __name__ == '__main__':
- app = QApplication(sys.argv)
- app.setWindowIcon(QIcon('logo_SIMCA.png')) # Add this line
-
- main_window = MainWindow()
- main_window.show()
- sys.exit(app.exec_())
\ No newline at end of file
diff --git a/main_script_optim.py b/main_script_optim.py
deleted file mode 100644
index 58f353b..0000000
--- a/main_script_optim.py
+++ /dev/null
@@ -1,329 +0,0 @@
-from simca import load_yaml_config
-from simca.CassiSystemOptim import CassiSystemOptim
-from simca.CassiSystem import CassiSystem
-import numpy as np
-import snoop
-import matplotlib.pyplot as plt
-import matplotlib.animation as anim
-#import matplotlib
-import torch
-import time, datetime
-import os
-from pprint import pprint
-from simca.cost_functions import evaluate_slit_scanning_straightness, evaluate_center, evaluate_mean_lighting, evaluate_max_lighting
-from simca.functions_optim import optim_smile, optim_width
-
-#matplotlib.use('Agg')
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_max_center.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-dataset_name = "washington_mall"
-
-test = "SMILE"
-
-algo = "ADAM"
-
-if test=="SMILE":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim.yml")
- aspect = 0.2
-elif test=="EQUAL_LIGHT" or test=="MAX_CENTER":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_max_center.yml")
- aspect = 1
-elif test == "SMILE_mono":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_smile_mono.yml")
- aspect = 1
-elif test == "MAX_LIGHT":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim.yml")
- aspect = 1
-
-config_system = load_yaml_config("simca/configs/cassi_system_optim_optics_full_triplet.yml")
-#config_system = load_yaml_config("simca/configs/cassi_system_satur_test.yml")
-
-device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
-
-if __name__ == '__main__':
- time_start = time.time()
- # Initialize the CASSI system
- cassi_system = CassiSystemOptim(system_config=config_system)
-
- # time0 = time.time()
- # DATASET : Load the hyperspectral dataset
- list_dataset_data = cassi_system.load_dataset(dataset_name, config_dataset["datasets directory"])
- """ plt.imshow(np.sum(list_dataset_data[0], axis=2))
- plt.show() """
-
- # Loop beginning if optics optim.
- cassi_system.update_optical_model(system_config=config_system)
- X_vec_out, Y_vec_out = cassi_system.propagate_coded_aperture_grid()
- sigma = 1.5
-
- cassi_system.X_coordinates_propagated_coded_aperture = cassi_system.X_coordinates_propagated_coded_aperture.to(device)
- cassi_system.Y_coordinates_propagated_coded_aperture = cassi_system.Y_coordinates_propagated_coded_aperture.to(device)
- cassi_system.X_detector_coordinates_grid = cassi_system.X_detector_coordinates_grid.to(device)
- cassi_system.Y_detector_coordinates_grid = cassi_system.Y_detector_coordinates_grid.to(device)
-
- num_iterations = 1000 # Define num_iterations as needed
-
- first_pos = 0.38
- last_pos = 0.8
- step_pos = 0.2/1
-
- pattern_pos = [0.68, 0.58, 0.48, 0.38]
- pos_slit_detector_list = [20/145, 40/145, 60/145, 80/145]
- image_counter = 0
-
-
-
- gen_randint = torch.Generator()
- gen_randint.manual_seed(2009)
- list_of_rand_seeds = torch.randint(low=0, high=2009, size=(100,), generator=gen_randint)
- for seed_i in range(0, len(list_of_rand_seeds)):
- seed = int(list_of_rand_seeds[seed_i])
-
- pattern_pos = [0.76]
- pattern_pos = [0.2]
- pattern_pos = [0.68]
- pos_slit_detector_list = [50/145] # 64 if pixel_size_Y=200
- pos_slit_detector_list = [33/145]
- patterns1 = []
- corrected_patterns1 = []
- smile_positions = []
- corrected_smile_positions = []
- patterns2 = []
- start_width_values = []
- width_values = []
- cubes1 = []
- corrected_cubes1 = []
- cubes2 = []
- acquisitions = []
-
- prev_position = None
-
- position = pattern_pos[0]
- pos_slit_detector = pos_slit_detector_list[0]
-
- image_counter += 1
- print(f"===== Start of image acquisition {image_counter} =====")
- max_iter_cnt = 25
-
- cassi_system = CassiSystemOptim(system_config=config_system)
- cassi_system.device = device
-
- # time0 = time.time()
- # DATASET : Load the hyperspectral dataset
- cassi_system.load_dataset(dataset_name, config_dataset["datasets directory"])
-
- # Loop beginning if optics optim.
- cassi_system.update_optical_model(system_config=config_system)
- X_vec_out, Y_vec_out = cassi_system.propagate_coded_aperture_grid()
- sigma = 1.5
-
- cassi_system.X_coordinates_propagated_coded_aperture = cassi_system.X_coordinates_propagated_coded_aperture.to(device)
- cassi_system.Y_coordinates_propagated_coded_aperture = cassi_system.Y_coordinates_propagated_coded_aperture.to(device)
- cassi_system.X_detector_coordinates_grid = cassi_system.X_detector_coordinates_grid.to(device)
- cassi_system.Y_detector_coordinates_grid = cassi_system.Y_detector_coordinates_grid.to(device)
-
- # Adjust the learning rate
- if algo == "LBFGS":
- lr = 0.005 # default: 0.05
- elif algo == "ADAM":
- lr = 0.005 # default: 0.005
-
- """ if position == 0.5:
- pos_slit_detector = 0.41
- elif position == 0.7:
- pos_slit_detector = 0.124 """
-
- data = np.load(f"./results/24-03-04_19h33/results.npz")
- if data is None:
- cassi_system = optim_smile(cassi_system, position, pos_slit_detector, sigma, device, algo, lr, num_iterations, max_iter_cnt, prev_position = prev_position, plot_frequency=None)
-
- pattern = cassi_system.pattern.detach().to('cpu').numpy()
- cube = cassi_system.filtering_cube.detach().to('cpu').numpy()
-
- patterns1.append(pattern)
- cubes1.append(cube)
- start_position = cassi_system.array_x_positions.detach().to('cpu').numpy()
- smile_positions.append(start_position)
-
- diffs = np.diff(start_position)
- diffs_ind = np.nonzero(diffs)[0]
- pos_middle = start_position[diffs_ind.min()+1:diffs_ind.max()+1]
- poly_coeffs = np.polyfit(np.linspace(1,2, len(pos_middle)), pos_middle, deg = 2)
- poly = np.poly1d(poly_coeffs)
- start_position[diffs_ind.min()+1:diffs_ind.max()+1] = poly(np.linspace(1,2, len(pos_middle)))
-
- corrected_smile_positions.append(start_position)
-
- start_position = torch.tensor(start_position)
-
- cassi_system.array_x_positions.data = start_position
- cassi_system.generate_custom_slit_pattern()
- cassi_system.generate_filtering_cube()
-
- pattern = cassi_system.pattern.detach().to('cpu').numpy()
- cube = cassi_system.filtering_cube.detach().to('cpu').numpy()
- corrected_patterns1.append(pattern)
- corrected_cubes1.append(cube)
-
- prev_position = (cassi_system.array_x_positions.detach()-position)
- else:
- patterns1.append(data["patterns_smile"][0])
- cubes1.append(data["cubes_smile"][0])
- smile_positions.append(data["smile_positions"][0])
-
- corrected_smile_positions.append(data["corrected_smile_positions"][0])
- start_position = torch.tensor(data["corrected_smile_positions"][0])
-
- corrected_patterns1.append(data["corrected_patterns_smile"][0])
- corrected_cubes1.append(data["corrected_cubes_smile"][0])
-
- prev_position = (start_position - position)
-
- # Adjust the learning rate
- if algo == "LBFGS":
- lr = 0.1 # default: 0.05
- elif algo == "ADAM":
- lr = 0.01 # default: 0.01
-
- target = 100000
- max_iter_cnt = 25
-
- #num_iterations = 1
- gen = torch.Generator()
- gen.manual_seed(seed)
- start_width = torch.rand(size=(1,cassi_system.system_config["detector"]["number of pixels along Y"]), generator=gen)/3
- start_width_values.append(start_width.detach().to('cpu').numpy())
-
- # Create first histogram
- cassi_system.generate_custom_pattern_parameters_slit_width(nb_slits=1, nb_rows=cassi_system.system_config["coded aperture"]["number of pixels along Y"], start_width = start_width)
- cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = start_position)
- cassi_system.generate_filtering_cube()
- cassi_system.filtering_cube = cassi_system.filtering_cube.to(device)
- acq = cassi_system.image_acquisition(use_psf=False, chunck_size=cassi_system.system_config["detector"]["number of pixels along Y"]).detach().to('cpu').numpy()
- fig_first_histo = plt.figure()
- #plt.imshow(torch.sum(cassi_system.dataset, dim=2))
- #plt.imshow(acq, aspect=0.2)
- plt.hist(acq[acq>100].flatten(), bins=100)
-
- # Run optimization
- cassi_system = optim_width(cassi_system, start_position, target, cassi_system.system_config["coded aperture"]["number of pixels along Y"], start_width, device, algo, lr, num_iterations, max_iter_cnt, plot_frequency = None)
-
- pattern = cassi_system.pattern.detach().to('cpu').numpy()
- cube = cassi_system.filtering_cube.detach().to('cpu').numpy()
- acquisition = cassi_system.measurement.detach().to('cpu').numpy()
-
- patterns2.append(pattern)
- cubes2.append(cube)
- acquisitions.append(acquisition)
- width_values.append(cassi_system.array_x_positions.detach().to('cpu').numpy())
-
-
-
- #print(torch.std(cassi_system.measurement.detach()))
-
- print(f"Exec time: {time.time() - time_start}s")
-
- fig1 = plt.figure()
- im1 = plt.imshow(patterns1[0], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig1bis = plt.figure()
- im1bis = plt.imshow(corrected_patterns1[0], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig2 = plt.figure()
- im2 = plt.imshow(cubes1[0][:,:,cubes1[0].shape[2]//2], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig2bis = plt.figure()
- im2bis = plt.imshow(corrected_cubes1[0][:,:,corrected_cubes1[0].shape[2]//2], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig3 = plt.figure()
- im3 = plt.imshow(patterns2[0], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig4 = plt.figure()
- im4 = plt.imshow(cubes2[0][:,:,cubes2[0].shape[2]//2], animated = True, aspect=aspect)
- plt.colorbar()
-
- fig5 = plt.figure()
- im5 = plt.imshow(np.clip(acquisitions[0], 1, None), animated = True, aspect=aspect, cmap="gray", norm="log")
- plt.colorbar()
-
- def update1(i):
- im1.set_array(patterns1[i])
- return im1,
- def update1bis(i):
- im1bis.set_array(corrected_patterns1[i])
- return im1bis,
- def update2(i):
- im2.set_array(cubes1[i][:,:,cubes1[0].shape[2]//2])
- return im2,
- def update2bis(i):
- im2bis.set_array(corrected_cubes1[i][:,:,corrected_cubes1[0].shape[2]//2])
- return im2bis,
- def update3(i):
- im3.set_array(patterns2[i])
- return im3,
- def update4(i):
- im4.set_array(cubes2[i][:,:,cubes2[0].shape[2]//2])
- return im4,
- def update5(i):
- im5.set_array(acquisitions[i])
- return im5,
-
- animation_fig1 = anim.FuncAnimation(fig1, update1, frames=len(patterns1), interval = 1000, repeat=True)
- animation_fig1bis = anim.FuncAnimation(fig1bis, update1bis, frames=len(corrected_patterns1), interval = 1000, repeat=True)
- animation_fig2 = anim.FuncAnimation(fig2, update2, frames=len(cubes1), interval = 1000, repeat=True)
- animation_fig2bis = anim.FuncAnimation(fig2bis, update2bis, frames=len(corrected_cubes1), interval = 1000, repeat=True)
- animation_fig3 = anim.FuncAnimation(fig3, update3, frames=len(patterns2), interval = 1000, repeat=True)
- animation_fig4 = anim.FuncAnimation(fig4, update4, frames=len(cubes2), interval = 1000, repeat=True)
- animation_fig5 = anim.FuncAnimation(fig5, update5, frames=len(acquisitions), interval = 1000, repeat=True)
-
- #print("Var: ", np.var(acquisitions[0][int(pos_slit_detector*145)-2:int(pos_slit_detector*145)+2].flatten()))
- print("Var: ", np.var(acquisitions[0][acquisitions[0]>100].flatten()))
-
-
- fig6 = plt.figure()
- plt.hist(acquisitions[0][acquisitions[0]>100].flatten(), bins=100)
-
- plt.show()
-
-
-
-
- folder = datetime.datetime.now().strftime('%y-%m-%d_%Hh%M')
- os.makedirs(f"./results/{folder}")
-
- fig6.savefig(f"./results/{folder}/histo.png")
- fig_first_histo.savefig(f"./results/{folder}/first_histo.png")
- fig1.savefig(f"./results/{folder}/patterns_smile.png")
- fig1bis.savefig(f"./results/{folder}/corrected_patterns_smile.png")
- fig2.savefig(f"./results/{folder}/cubes_smile.png")
- fig2bis.savefig(f"./results/{folder}/corrected_cubes_smile.png")
- fig3.savefig(f"./results/{folder}/patterns_width.png")
- fig4.savefig(f"./results/{folder}/cubes_width.png")
- fig5.savefig(f"./results/{folder}/acquisitions.png")
- #animation_fig1.save(f"./results/{folder}/patterns_smile.gif")
- #animation_fig1bis.save(f"./results/{folder}/corrected_patterns_smile.gif")
- #animation_fig2.save(f"./results/{folder}/cubes_smile.gif")
- #animation_fig2bis.save(f"./results/{folder}/corrected_cubes_smile.gif")
- #animation_fig3.save(f"./results/{folder}/patterns_width.gif")
- #animation_fig4.save(f"./results/{folder}/cubes_width.gif")
- #animation_fig5.save(f"./results/{folder}/acquisitions.gif")
-
- """np.savez(f"./results/{folder}/results.npz", smile_positions=np.stack(smile_positions, axis=0), patterns_smile=np.stack(patterns1, axis=0), cubes_smile = np.stack(cubes1, axis=0),
- corrected_smile_positions=np.stack(corrected_smile_positions, axis=0), corrected_patterns_smile=np.stack(corrected_patterns1, axis=0), corrected_cubes_smile=np.stack(corrected_cubes1, axis=0),
- start_width_values=np.stack(start_width_values, axis=0), width_values=np.stack(width_values, axis=0), patterns_width=np.stack(patterns2, axis=0), cubes_width = np.stack(cubes2, axis=0),
- acquisitions=np.stack(acquisitions, axis=0),
- variance=np.var(acquisitions[0][acquisitions[0]>500].flatten()))"""
- np.savez(f"./results/{folder}/results.npz", smile_positions=np.stack(smile_positions, axis=0), patterns_smile=np.stack(patterns1, axis=0),
- corrected_smile_positions=np.stack(corrected_smile_positions, axis=0), corrected_patterns_smile=np.stack(corrected_patterns1, axis=0),
- start_width_values=np.stack(start_width_values, axis=0), width_values=np.stack(width_values, axis=0), patterns_width=np.stack(patterns2, axis=0),
- acquisitions=np.stack(acquisitions, axis=0),
- variance=np.var(acquisitions[0][acquisitions[0]>500].flatten()))
- #np.savez(f"./results/{folder}/results.npz", patterns_smile=np.stack(patterns1, axis=0), cubes_smile = np.stack(cubes1, axis=0))
diff --git a/mask_optim_recon.py b/mask_optim_recon.py
deleted file mode 100755
index ce030a9..0000000
--- a/mask_optim_recon.py
+++ /dev/null
@@ -1,175 +0,0 @@
-from simca import load_yaml_config
-from simca.CassiSystemOptim import CassiSystemOptim
-from simca.CassiSystem import CassiSystem
-from data_handler import CubesDataModule
-from MST.simulation.train_code.architecture import *
-from MST.simulation.train_code.utils import *
-import numpy as np
-import snoop
-import matplotlib.pyplot as plt
-import matplotlib.animation as anim
-#import matplotlib
-import torch
-import time, datetime
-import os
-import tqdm
-
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-config_system = load_yaml_config()
-
-# Load datacubes
-# Generate random mask
-# Run SIMCA to make acquisition 1
-# ResNET -> mask
-# Run SIMCA to make acquisition 2
-# Reconstruction MST/CST -> out_cube
-# Compare out_cube with datacube to compute loss
-
-data_dir = "/local/users/ademaio/lpaillet/mst_datasets"
-model_name = 'mst_plus_plus'
-device = 'cuda'
-lr = 0.001
-nb_epochs = 100
-
-def expand_mask_3d(mask):
- mask3d = np.tile(mask[:, :, np.newaxis], (1, 1, 28))
- mask3d = np.transpose(mask3d, [2, 0, 1])
- mask3d = torch.from_numpy(mask3d)
- return mask3d
-
-def train_recons(model, cassi_system, optimizer, mse, nb_epochs, display_iter=10):
- train_losses = []
- test_losses = []
- for e in range(1, nb_epochs + 1):
- avg_loss = 0.0
- mean_losses = []
- # Run the training loop for one epoch
- model.train()
- for batch_idx, (cube, wavelengths) in tqdm(
- enumerate(datamodule.train_dataloader), total=len(datamodule.train_dataloader)):
- optimizer.zero_grad()
- #for i in range(cube.shape[0]):
- # cube_i = cube[i,...]
- # wavelengths_i = wavelengths[i,...]
-
-
- # cassi_system.dataset = cube # b x 28 x H x W
- # cassi_system.wavelengths = wavelengths
- input_mask = np.random.randint(0,1,size=(128,128))
- cassi_system.pattern = torch.tensor(input_mask)
- cassi_system.generate_filtering_cube()
-
- input_acq = cassi_system.image_acquisition(use_psf=False) # b x H x (W + d*(28-1))
- d=2
- input_acq = shift_back(input_acq, step=d)
-
- input_mask_3d = expand_mask_3d(input_mask) #TODO, like in train_method/utils.py
- output = model(input_acq, input_mask_3d)
- loss = torch.sqrt(mse(output, cube))
-
- loss.backward()
- optimizer.step()
- avg_loss += loss.item()
- mean_losses.append(np.mean(np.array(mean_losses)))
- if display_iter and batch_idx % display_iter == 0:
- string = "Train (epoch {}/{}) [{}/{} ({:.0f}%)]\tLoss: {:.6f}"
- string = string.format(
- e,
- nb_epochs,
- batch_idx * len(cube),
- len(cube) * len(datamodule.train_dataloader),
- 100.0 * batch_idx / len(datamodule.train_dataloader),
- mean_losses[batch_idx],
- )
- tqdm.write(string)
-
- avg_loss /= len(datamodule.train_dataloader)
- train_losses.append(avg_loss)
-
- # Run the test loop for one epoch
- avg_loss = 0
- model.eval()
- for batch_idx, (cube, wavelengths) in enumerate(datamodule.val_dataloader):
- with torch.no_grad():
- input_mask = np.random.randint(0,1,size=(128,128))
- cassi_system.pattern = torch.tensor(input_mask)
- # cassi_system.dataset = cube
- # cassi_system.wavelengths = wavelengths
- cassi_system.generate_filtering_cube()
-
- input_acq = cassi_system.image_acquisition(use_psf=False)
- d=2
- input_acq = shift_back(input_acq, step=d)
- input_mask_3d = expand_mask_3d(input_mask) #TODO, like in train_method/utils.py
-
- output = model(input_acq, input_mask_3d)
- loss = torch.sqrt(mse(output, cube))
- avg_loss += loss.item()
-
- avg_loss /= len(datamodule.val_dataloader)
- string = "Test (epoch {}/{})\tLoss:{:.6f}".format(e, nb_epochs, avg_loss)
- tqdm.write(string)
- test_losses.append(avg_loss)
-
-def test_recons(model, mse, cassi_system):
- model.eval()
- avg_loss = 0
-
- for batch_idx, (cube, wavelengths) in enumerate(datamodule.test_dataloader):
- with torch.no_grad():
- input_mask = np.random.randint(0,1,size=(128,128))
- cassi_system.pattern = torch.tensor(input_mask)
- # cassi_system.dataset = cube
- # cassi_system.wavelengths = wavelengths
- cassi_system.generate_filtering_cube()
-
- input_acq = cassi_system.image_acquisition(use_psf=False)
- d=2
- input_acq = shift_back(input_acq, step=d)
- input_mask_3d = expand_mask_3d(input_mask) #TODO, like in train_method/utils.py
-
- output = model(input_acq, input_mask_3d)
- loss = torch.sqrt(mse(output, cube))
- avg_loss += loss.item()
- avg_loss /= len(datamodule.test_dataloader)
- print(f"\nTest loss: {avg_loss:.6f}")
-
-def full_flow(cassi_system, scene, wavelengths, resnet, recons_model, mse):
- input_mask = np.random.randint(0,1,size=(128,128))
- cassi_system.dataset = scene
- cassi_system.wavelengths = wavelengths
- cassi_system.pattern = torch.tensor(input_mask)
- cassi_system.generate_filtering_cube()
-
- acq1 = cassi_system.image_acquisition(use_psf=False)
- new_mask = resnet(acq1)
-
- cassi_system.pattern = new_mask
- cassi_system.generate_filtering_cube()
-
- acq2 = cassi_system.image_acquisition(use_psf=False)
-
- input_mask_3d = expand_mask_3d(new_mask.numpy())
- input_acq = shift_back(acq2, step=d)
- out_cube = recons_model(input_acq, input_mask_3d)
- loss = torch.sqrt(mse(out_cube, scene))
- print(f"\nTest loss: {loss:.6f}")
-
-
-if __name__ == '__main__':
- datamodule = CubesDataModule(data_dir, batch_size=5, num_workers=2)
- cassi_system = CassiSystemOptim(system_config=config_system)
- cassi_system.device = device
-
- cassi_system.update_optical_model(system_config=config_system)
- X_vec_out, Y_vec_out = cassi_system.propagate_coded_aperture_grid()
-
- recons_model = model_generator(model_name, None)
- optimizer = torch.optim.Adam(recons_model.parameters(), lr=lr, betas=(0.9, 0.999))
- mse = torch.nn.MSELoss()
-
- recons_model = train_recons(recons_model, optimizer, mse, cassi_system, nb_epochs)
- test_recons(recons_model, mse, cassi_system)
- torch.save(recons_model.state_dict(), "./recons_model.pt")
\ No newline at end of file
diff --git a/multi_acq_script.py b/multi_acq_script.py
deleted file mode 100644
index d082216..0000000
--- a/multi_acq_script.py
+++ /dev/null
@@ -1,61 +0,0 @@
-import matplotlib.pyplot as plt
-
-from simca import CassiSystem
-from simca.functions_general_purpose import *
-import os
-
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-dataset_name = "indian_pines"
-results_directory = "./data/results/lego_test_1"
-nb_of_acq = 10
-
-if __name__ == '__main__':
-
- # Initialize the CASSI system
- cassi_system = CassiSystem(system_config=config_system)
-
- # DATASET : Load the hyperspectral dataset
- cassi_system.load_dataset(dataset_name, config_dataset["datasets directory"])
-
-
- cassi_system.generate_multiple_patterns(config_patterns,nb_of_acq)
-
- # PROPAGATION : Propagate the pattern grid to the detector plane
- cassi_system.propagate_coded_aperture_grid()
-
- # FILTERING CUBE : Generate the filtering cubes
- cassi_system.generate_multiple_filtering_cubes(nb_of_acq)
-
- # ACQUISITION : Simulate the acquisition with psf (use_psf is optional)
- cassi_system.multiple_image_acquisitions(use_psf=False,nb_of_filtering_cubes=nb_of_acq,chunck_size=50)
-
- # Save the acquisition
- cassi_system.result_directory =results_directory
- os.makedirs(results_directory, exist_ok=True)
-
- save_config_file("config_system", cassi_system.system_config, cassi_system.result_directory)
- save_config_file("config_pattern", config_patterns,cassi_system.result_directory)
- save_config_file("config_acquisition", config_acquisition, cassi_system.result_directory)
-
- save_data_in_hdf5("interpolated_scene",cassi_system.interpolated_scene, cassi_system.result_directory)
- save_data_in_hdf5("panchro",cassi_system.panchro,cassi_system.result_directory)
-
- save_data_in_hdf5("wavelengths",cassi_system.optical_model.system_wavelengths,cassi_system.result_directory)
- save_data_in_hdf5("list_of_compressed_measurements",cassi_system.list_of_measurements,cassi_system.result_directory)
- save_data_in_hdf5("list_of_filtering_cubes",cassi_system.list_of_filtering_cubes,cassi_system.result_directory)
- save_data_in_hdf5("list_of_patterns",cassi_system.list_of_patterns,cassi_system.result_directory)
-
-
-
-
-
-
-
-
-
-
-
diff --git a/optimization_modules.py b/optimization_modules.py
deleted file mode 100755
index 225d3cc..0000000
--- a/optimization_modules.py
+++ /dev/null
@@ -1,315 +0,0 @@
-import pytorch_lightning as pl
-import torch
-import torch.nn as nn
-from simca.CassiSystem_lightning import CassiSystemOptim
-from MST.simulation.train_code.architecture import *
-from simca import load_yaml_config
-import matplotlib.pyplot as plt
-import torchvision
-import numpy as np
-from simca.functions_acquisition import *
-from piqa import SSIM
-from torch.utils.tensorboard import SummaryWriter
-import io
-import torchvision.transforms as transforms
-from PIL import Image
-
-class JointReconstructionModule_V1(pl.LightningModule):
-
- def __init__(self, model_name,log_dir="tb_logs", reconstruction_checkpoint=None):
- super().__init__()
-
- self.model_name = model_name
- self.reconstruction_model = model_generator(self.model_name, reconstruction_checkpoint)
-
- self.loss_fn = nn.MSELoss()
- #self.ssim_loss = SSIM(window_size=11, n_channels=28)
- self.ssim_loss = SSIM(window_size=11, n_channels=3)
-
- self.writer = SummaryWriter(log_dir)
-
- def on_validation_start(self,stage=None):
- print("---VALIDATION START---")
- self.config = "simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml"
-
- config_system = load_yaml_config(self.config)
- self.config_patterns = load_yaml_config("simca/configs/pattern.yml")
- self.cassi_system = CassiSystemOptim(system_config=config_system)
- self.cassi_system.propagate_coded_aperture_grid()
-
- def on_predict_start(self,stage=None):
- print("---PREDICT START---")
- self.config = "simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml"
-
- config_system = load_yaml_config(self.config)
- self.config_patterns = load_yaml_config("simca/configs/pattern.yml")
- self.cassi_system = CassiSystemOptim(system_config=config_system)
- self.cassi_system.propagate_coded_aperture_grid()
-
- def _normalize_data_by_itself(self, data):
- # Calculate the mean and std for each batch individually
- # Keep dimensions for broadcasting
- mean = torch.mean(data, dim=[1, 2], keepdim=True)
- std = torch.std(data, dim=[1, 2], keepdim=True)
-
- # Normalize each batch by its mean and std
- normalized_data = (data - mean) / std
- return normalized_data
-
-
- def forward(self, x, pattern=None):
- print("---FORWARD---")
-
- hyperspectral_cube, wavelengths = x
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- batch_size, H, W, C = hyperspectral_cube.shape
-
- # fig, ax = plt.subplots(1, 1)
- # plt.title(f"entry cube")
- # ax.imshow(hyperspectral_cube[0, :, :, 0].cpu().detach().numpy())
- # plt.show()
- # print(f"batch size:{batch_size}")
- # generate pattern
-
- if pattern is None:
- self.pattern = self.cassi_system.generate_2D_pattern(self.config_patterns,nb_of_patterns=batch_size)
- self.pattern = self.pattern.to(self.device)
- else:
- self.pattern = pattern.to(self.device)
- self.cassi_system.pattern = pattern.to(self.device)
-
- # plt.imshow(pattern[0, :, :].cpu().detach().numpy())
- # plt.show()
-
- # print(f"pattern_size: {pattern.shape}")
-
- # generate first acquisition with simca
-
- filtering_cube = self.cassi_system.generate_filtering_cube().to(self.device)
- self.acquired_image1 = self.cassi_system.image_acquisition(hyperspectral_cube, self.pattern, wavelengths).to(self.device)
-
-
- # self.acquired_image1 = self._normalize_data_by_itself(self.acquired_image1)
- # acquired_cubes = self.acquired_image1.unsqueeze(1).repeat((1, 28, 1, 1)).float().to(self.device) # b x W x R x C
-
- filtering_cubes = subsample(filtering_cube, torch.linspace(450, 650, filtering_cube.shape[-1]), torch.linspace(450, 650, 28)).permute((0, 3, 1, 2)).float().to(self.device)
-
- if self.model_name == "birnat":
- # acquisition = self.acquired_image1.unsqueeze(1)
- acquisition = self.acquired_image1.float()
- filtering_cubes = filtering_cubes.float()
- elif "dauhst" in self.model_name:
- acquisition = self.acquired_image1.float()
-
- filtering_cubes_s = torch.sum(filtering_cubes**2,1)
- filtering_cubes_s[filtering_cubes_s==0] = 1
- filtering_cubes = (filtering_cubes.float(), filtering_cubes_s.float())
-
- elif self.model_name == "mst_plus_plus":
- acquisition = self.acquired_image1.unsqueeze(1).repeat((1, 28, 1, 1)).float().to(self.device)
- #print(f"acquisition shape: {acquisition.shape}")
- #print(f"filtering_cubes shape: {filtering_cubes.shape}")
-
- reconstructed_cube = self.reconstruction_model(acquisition, filtering_cubes)
-
-
- return reconstructed_cube
-
-
- def training_step(self, batch, batch_idx):
- print("Training step")
-
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
-
-
- output_images = self._convert_output_to_images(self._normalize_image_tensor(self.acquired_image1))
- patterns = self._convert_output_to_images(self._normalize_image_tensor(self.pattern))
- input_images = self._convert_output_to_images(self._normalize_image_tensor(ref_cube[:,:,:,0]))
- reconstructed_image = self._convert_output_to_images(self._normalize_image_tensor(reconstructed_cube[:,:,:,0]))
-
- if self.global_step % 30 == 0:
- self._log_images('train/acquisition', output_images, self.global_step)
- self._log_images('train/ground_truth', input_images, self.global_step)
- self._log_images('train/reconstructed', reconstructed_image, self.global_step)
- self._log_images('train/patterns', patterns, self.global_step)
-
- spectral_filter_plot = self.plot_spectral_filter(ref_cube,reconstructed_cube)
-
- self.writer.add_image('Spectral Filter', spectral_filter_plot, self.global_step)
-
- self.log_dict(
- { "train_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "train_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def _normalize_image_tensor(self, tensor):
- # Normalize the tensor to the range [0, 1]
- min_val = tensor.min()
- max_val = tensor.max()
- normalized_tensor = (tensor - min_val) / (max_val - min_val)
- return normalized_tensor
-
- def validation_step(self, batch, batch_idx):
-
- print("Validation step")
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
-
- self.log_dict(
- { "val_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def test_step(self, batch, batch_idx):
- print("Test step")
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
- self.log_dict(
- { "test_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
- return {"loss": loss}
-
- def predict_step(self, batch, batch_idx):
- print("Predict step")
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
- print("Predict loss: ", loss.item())
- print("Predict ssim loss: ", ssim_loss)
- #self.log('predict_step', loss,on_step=True, on_epoch=True, prog_bar=True, logger=True)
- return loss
-
- def _common_step(self, batch, batch_idx):
-
-
- reconstructed_cube = self.forward(batch)
- hyperspectral_cube, wavelengths = batch
-
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- reconstructed_cube = reconstructed_cube.permute(0, 2, 3, 1).to(self.device)
- ref_cube = match_dataset_to_instrument(hyperspectral_cube, reconstructed_cube[0, :, :,0])
-
- # fig, ax = plt.subplots(1, 2)
- # plt.title(f"true cube vs reconstructed cube")
- # ax[0].imshow(hyperspectral_cube[0, :, :, 0].cpu().detach().numpy())
- # ax[1].imshow(reconstructed_cube[0, :, :, 0].cpu().detach().numpy())
- # plt.show()
-
-
- loss = torch.sqrt(self.loss_fn(reconstructed_cube, ref_cube))
- ssim_loss = self.ssim_loss(torch.clamp(reconstructed_cube.permute(0, 3, 1, 2), 0, 1), ref_cube.permute(0, 3, 1, 2))
- #ssim_loss = 0
-
- return loss, ssim_loss, reconstructed_cube, ref_cube
-
- def configure_optimizers(self):
- optimizer = torch.optim.Adam(self.parameters(), lr=4e-4)
- return { "optimizer":optimizer,
- "lr_scheduler":{
- "scheduler":torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, 500, eta_min=1e-6),
- "interval": "epoch"
- }
- }
-
- def _log_images(self, tag, images, global_step):
- # Convert model output to image grid and log to TensorBoard
- img_grid = torchvision.utils.make_grid(images)
- self.writer.add_image(tag, img_grid, global_step)
-
- def _convert_output_to_images(self, acquired_images):
-
- acquired_images = acquired_images.unsqueeze(1)
-
- # Create a grid of images for visualization
- img_grid = torchvision.utils.make_grid(acquired_images)
- return img_grid
-
- def plot_spectral_filter(self,ref_hyperspectral_cube,recontructed_hyperspectral_cube):
-
-
- batch_size, y,x, lmabda_ = ref_hyperspectral_cube.shape
-
- # Create a figure with subplots arranged horizontally
- fig, axs = plt.subplots(1, batch_size, figsize=(batch_size * 5, 4)) # Adjust figure size as needed
-
- # Check if batch_size is 1, axs might not be iterable
- if batch_size == 1:
- axs = [axs]
-
- # Plot each spectral filter in its own subplot
- for i in range(batch_size):
- colors = ['b', 'g', 'r']
- for j in range(3):
- pix_j_row_value = np.random.randint(0,y)
- pix_j_col_value = np.random.randint(0,x)
-
- pix_j_ref = ref_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- pix_j_reconstructed = recontructed_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- axs[i].plot(pix_j_reconstructed, label="pix reconstructed" + str(j),c=colors[j])
- axs[i].plot(pix_j_ref, label="pix" + str(j), linestyle='--',c=colors[j])
-
- axs[i].set_title(f"Reconstruction quality")
-
- axs[i].set_xlabel("Wavelength index")
- axs[i].set_ylabel("pix values")
- axs[i].grid(True)
-
- plt.legend()
- # Adjust layout
- plt.tight_layout()
-
- # Create a buffer to save plot
- buf = io.BytesIO()
- plt.savefig(buf, format='png')
- plt.close(fig)
- buf.seek(0)
-
- # Convert PNG buffer to PIL Image
- image = Image.open(buf)
-
- # Convert PIL Image to Tensor
- image_tensor = transforms.ToTensor()(image)
- return image_tensor
-
-
-def subsample(input, origin_sampling, target_sampling):
- [bs, row, col, nC] = input.shape
- indices = torch.zeros(len(target_sampling), dtype=torch.int)
- for i in range(len(target_sampling)):
- sample = target_sampling[i]
- idx = torch.abs(origin_sampling-sample).argmin()
- indices[i] = idx
- return input[:,:,:,indices]
-
-def expand_mask_3d(mask_batch):
- if len(mask_batch.shape)==3:
- mask3d = mask_batch.unsqueeze(-1).repeat((1, 1, 1, 28))
- else:
- mask3d = mask_batch.repeat((1, 1, 1, 28))
- mask3d = torch.permute(mask3d, (0, 3, 1, 2))
- return mask3d
-
-class EmptyModule(nn.Module):
- def __init__(self):
- super().__init__()
- self.useless_linear = nn.Linear(1, 1)
- def forward(self, x):
- return x
diff --git a/optimization_modules_with_resnet.py b/optimization_modules_with_resnet.py
deleted file mode 100755
index 510a7f8..0000000
--- a/optimization_modules_with_resnet.py
+++ /dev/null
@@ -1,407 +0,0 @@
-import pytorch_lightning as pl
-import torch
-import torch.nn as nn
-from simca.CassiSystem_lightning import CassiSystemOptim
-from MST.simulation.train_code.architecture import *
-from simca import load_yaml_config
-import matplotlib.pyplot as plt
-import torchvision
-import numpy as np
-from simca.functions_acquisition import *
-from piqa import SSIM
-from torch.utils.tensorboard import SummaryWriter
-import io
-import torchvision.transforms as transforms
-from PIL import Image
-import segmentation_models_pytorch as smp
-import torch.nn.functional as F
-
-class UnetModel(nn.Module):
- def __init__(self,encoder_name="resnet18",encoder_weights="",in_channels=1,classes=2,index=0):
- super().__init__()
- self.i= index
- self.model= smp.Unet(encoder_name= encoder_name, in_channels=in_channels,encoder_weights=encoder_weights,classes=classes,activation='sigmoid')
- def forward(self,x):
- x= self.model(x)
- return x
-
-
-class JointReconstructionModule_V2(pl.LightningModule):
-
- def __init__(self, model_name,log_dir="tb_logs",reconstruction_checkpoint=None):
- super().__init__()
-
- self.model_name = model_name
- self.reconstruction_model = model_generator(self.model_name, pretrained_model_path=None)
- if reconstruction_checkpoint is not None:
- #self.reconstruction_model = model_generator(self.model_name, pretrained_model_path=reconstruction_checkpoint)
- self.reconstruction_model.load_state_dict(torch.load(reconstruction_checkpoint), strict=False)
- self.mask_generation = UnetModel(classes=1,encoder_weights=None,in_channels=1)
-
- self.loss_fn = nn.MSELoss()
- self.ssim_loss = SSIM(window_size=11, n_channels=28)
-
- self.writer = SummaryWriter(log_dir)
-
- # for param in self.reconstruction_model.parameters():
- # param.requires_grad = False
-
- def on_validation_start(self,stage=None):
- print("---VALIDATION START---")
- self.config = "simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml"
- config_system = load_yaml_config(self.config)
- self.config_patterns = load_yaml_config("simca/configs/pattern.yml")
- self.cassi_system = CassiSystemOptim(system_config=config_system)
- self.cassi_system.propagate_coded_aperture_grid()
-
- def _normalize_data_by_itself(self, data):
- # Calculate the mean and std for each batch individually
- # Keep dimensions for broadcasting
- mean = torch.mean(data, dim=[1, 2], keepdim=True)
- std = torch.std(data, dim=[1, 2], keepdim=True)
-
- # Normalize each batch by its mean and std
- normalized_data = (data - mean) / std
- return normalized_data
-
-
- def forward(self, x):
- print("---FORWARD---")
-
- hyperspectral_cube, wavelengths = x
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- batch_size, H, W, C = hyperspectral_cube.shape
-
-
- self.pattern = self.cassi_system.generate_2D_pattern(self.config_patterns,nb_of_patterns=batch_size)
- self.pattern = self.pattern.to(self.device)
- filtering_cube = self.cassi_system.generate_filtering_cube().to(self.device)
- self.acquired_image1 = self.cassi_system.image_acquisition(hyperspectral_cube, self.pattern, wavelengths).to(self.device)
-
- self.acquired_image1 = pad_tensor(self.acquired_image1, (128, 128))
-
- # flip along second and thrid axis
- self.acquired_image1 = self.acquired_image1.flip(1)
- self.acquired_image1 = self.acquired_image1.flip(2)
- self.acquired_image1 = self.acquired_image1.unsqueeze(1).float()
- #self.acquired_image1 = self._normalize_data_by_itself(self.acquired_image1)
-
-
- self.pattern = self.mask_generation(self.acquired_image1).squeeze(1)
- self.pattern = BinarizeFunction.apply(self.pattern)
- self.pattern = pad_tensor(self.pattern, (131, 131))
- self.cassi_system.pattern = self.pattern.to(self.device)
-
- filtering_cube = self.cassi_system.generate_filtering_cube().to(self.device)
- self.acquired_image2 = self.cassi_system.image_acquisition(hyperspectral_cube, self.pattern, wavelengths).to(self.device)
-
-
- # self.acquired_image1 = self._normalize_data_by_itself(self.acquired_image1)
- # acquired_cubes = self.acquired_image1.unsqueeze(1).repeat((1, 28, 1, 1)).float().to(self.device) # b x W x R x C
-
- filtering_cubes = subsample(filtering_cube, torch.linspace(450, 650, filtering_cube.shape[-1]), torch.linspace(450, 650, 28)).permute((0, 3, 1, 2)).float().to(self.device)
-
- if self.model_name == "birnat":
- # acquisition = self.acquired_image1.unsqueeze(1)
- acquisition = self.acquired_image2.float()
- filtering_cubes = filtering_cubes.float()
- elif "dauhst" in self.model_name:
- acquisition = self.acquired_image2.float()
- filtering_cubes_s = torch.sum(filtering_cubes**2,1)
- filtering_cubes_s[filtering_cubes_s==0] = 1
- filtering_cubes = (filtering_cubes.float(), filtering_cubes_s.float())
-
- elif self.model_name == "mst_plus_plus":
- acquisition = self.acquired_image2.unsqueeze(1).repeat((1, 28, 1, 1)).float().to(self.device)
-
-
- reconstructed_cube = self.reconstruction_model(acquisition, filtering_cubes)
-
-
- return reconstructed_cube
-
-
- def training_step(self, batch, batch_idx):
- print("Training step")
-
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
-
-
-
- output_images = self._convert_output_to_images(self._normalize_image_tensor(self.acquired_image2))
- patterns = self._convert_output_to_images(self._normalize_image_tensor(self.pattern))
- input_images = self._convert_output_to_images(self._normalize_image_tensor(ref_cube[:,:,:,0]))
- reconstructed_image = self._convert_output_to_images(self._normalize_image_tensor(reconstructed_cube[:,:,:,0]))
-
- if self.global_step % 30 == 0:
- self._log_images('train/acquisition2', output_images, self.global_step)
- self._log_images('train/ground_truth', input_images, self.global_step)
- self._log_images('train/reconstructed', reconstructed_image, self.global_step)
- self._log_images('train/patterns', patterns, self.global_step)
-
- plt.imshow(self.pattern[0,:,:].cpu().detach().numpy())
- plt.colorbar()
- plt.savefig('./pattern.png')
-
- spectral_filter_plot = self.plot_spectral_filter(ref_cube,reconstructed_cube)
- self.log_gradients(self.global_step)
- self.writer.add_image('Spectral Filter', spectral_filter_plot, self.global_step)
-
- self.log_dict(
- { "train_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "train_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def _normalize_image_tensor(self, tensor):
- # Normalize the tensor to the range [0, 1]
- min_val = tensor.min()
- max_val = tensor.max()
- normalized_tensor = (tensor - min_val) / (max_val - min_val)
- return normalized_tensor
-
- def validation_step(self, batch, batch_idx):
-
- print("Validation step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
-
- self.log_dict(
- { "val_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "val_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def test_step(self, batch, batch_idx):
- print("Test step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
- self.log_dict(
- { "test_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "test_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def predict_step(self, batch, batch_idx):
- print("Predict step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
- print("Predict loss: ", loss.item())
- print("Predict ssim loss: ", ssim_loss)
- #self.log('predict_step', loss,on_step=True, on_epoch=True, prog_bar=True, logger=True)
- return loss
-
- def _common_step(self, batch, batch_idx):
-
-
- reconstructed_cube = self.forward(batch)
- hyperspectral_cube, wavelengths = batch
-
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- reconstructed_cube = reconstructed_cube.permute(0, 2, 3, 1).to(self.device)
- ref_cube = match_dataset_to_instrument(hyperspectral_cube, reconstructed_cube[0, :, :,0])
-
- # fig, ax = plt.subplots(1, 2)
- # plt.title(f"true cube vs reconstructed cube")
- # ax[0].imshow(hyperspectral_cube[0, :, :, 0].cpu().detach().numpy())
- # ax[1].imshow(reconstructed_cube[0, :, :, 0].cpu().detach().numpy())
- # plt.show()
- total_sum_pattern = torch.sum(self.pattern, dim=(1, 2))
- total_half_pattern_equal_1 = torch.sum(torch.ones_like(self.pattern), dim=(1, 2)) / 2
-
- print(f"total_sum_pattern {total_sum_pattern}")
- print(f"total_half_pattern_equal_1 {total_half_pattern_equal_1}")
-
-
-
- loss1 = torch.sqrt(self.loss_fn(reconstructed_cube, ref_cube))
- loss2 = torch.sum(torch.abs((total_sum_pattern - total_half_pattern_equal_1)/(self.pattern.shape[1]*self.pattern.shape[2]))**2)
- loss = loss1 + loss2
-
- ssim_loss = self.ssim_loss(torch.clamp(reconstructed_cube.permute(0, 3, 1, 2), 0, 1), ref_cube.permute(0, 3, 1, 2))
- print(f"loss1 {loss1}")
- print(f"loss2 {loss2}")
- return loss, ssim_loss, reconstructed_cube, ref_cube
-
- def configure_optimizers(self):
- optimizer = torch.optim.Adam(self.parameters(), lr=4e-4)
- return { "optimizer":optimizer,
- "lr_scheduler":{
- "scheduler":torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, 500, eta_min=1e-6),
- "interval": "epoch"
- }
- }
-
- def _log_images(self, tag, images, global_step):
- # Convert model output to image grid and log to TensorBoard
- img_grid = torchvision.utils.make_grid(images)
- self.writer.add_image(tag, img_grid, global_step)
-
- def _convert_output_to_images(self, acquired_images):
-
- acquired_images = acquired_images.unsqueeze(1)
-
- # Create a grid of images for visualization
- img_grid = torchvision.utils.make_grid(acquired_images)
- return img_grid
-
- def log_gradients(self, step):
- for name, param in self.mask_generation.named_parameters():
- if param.grad is not None:
- self.writer.add_scalar(f"Gradients/{name}", param.grad.norm(), step)
-
-
- def plot_spectral_filter(self,ref_hyperspectral_cube,recontructed_hyperspectral_cube):
-
-
- batch_size, y,x, lmabda_ = ref_hyperspectral_cube.shape
-
- # Create a figure with subplots arranged horizontally
- fig, axs = plt.subplots(1, batch_size, figsize=(batch_size * 5, 4)) # Adjust figure size as needed
-
- # Check if batch_size is 1, axs might not be iterable
- if batch_size == 1:
- axs = [axs]
-
- # Plot each spectral filter in its own subplot
- for i in range(batch_size):
- colors = ['b', 'g', 'r']
- for j in range(3):
- pix_j_row_value = np.random.randint(0,y)
- pix_j_col_value = np.random.randint(0,x)
-
- pix_j_ref = ref_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- pix_j_reconstructed = recontructed_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- axs[i].plot(pix_j_reconstructed, label="pix reconstructed" + str(j),c=colors[j])
- axs[i].plot(pix_j_ref, label="pix" + str(j), linestyle='--',c=colors[j])
-
- axs[i].set_title(f"Reconstruction quality")
-
- axs[i].set_xlabel("Wavelength index")
- axs[i].set_ylabel("pix values")
- axs[i].grid(True)
-
- plt.legend()
- # Adjust layout
- plt.tight_layout()
-
- # Create a buffer to save plot
- buf = io.BytesIO()
- plt.savefig(buf, format='png')
- plt.close(fig)
- buf.seek(0)
-
- # Convert PNG buffer to PIL Image
- image = Image.open(buf)
-
- # Convert PIL Image to Tensor
- image_tensor = transforms.ToTensor()(image)
- return image_tensor
-
-
-def subsample(input, origin_sampling, target_sampling):
- [bs, row, col, nC] = input.shape
- indices = torch.zeros(len(target_sampling), dtype=torch.int)
- for i in range(len(target_sampling)):
- sample = target_sampling[i]
- idx = torch.abs(origin_sampling-sample).argmin()
- indices[i] = idx
- return input[:,:,:,indices]
-
-def expand_mask_3d(mask_batch):
- if len(mask_batch.shape)==3:
- mask3d = mask_batch.unsqueeze(-1).repeat((1, 1, 1, 28))
- else:
- mask3d = mask_batch.repeat((1, 1, 1, 28))
- mask3d = torch.permute(mask3d, (0, 3, 1, 2))
- return mask3d
-
-class EmptyModule(nn.Module):
- def __init__(self):
- super().__init__()
- self.useless_linear = nn.Linear(1, 1)
- def forward(self, x):
- return x
-
-
-def pad_tensor(input_tensor, target_shape):
- [bs, row, col] = input_tensor.shape
- [target_row, target_col] = target_shape
-
- # Calculate padding for rows
- pad_row_total = max(target_row - row, 0)
- pad_row_top = pad_row_total // 2
- pad_row_bottom = pad_row_total - pad_row_top
-
- # Calculate padding for columns
- pad_col_total = max(target_col - col, 0)
- pad_col_left = pad_col_total // 2
- pad_col_right = pad_col_total - pad_col_left
-
- # Apply padding
- padded_tensor = F.pad(input_tensor, (pad_col_left, pad_col_right, pad_row_top, pad_row_bottom), 'constant', 0)
- return padded_tensor
-
-def crop_tensor(input_tensor, target_shape):
- [bs, row, col] = input_tensor.shape
- [target_row, target_col] = target_shape
- crop_row = (row-target_row)//2
- crop_col = (col-target_col)//2
- return input_tensor[:,crop_row:crop_row+target_row,crop_col:crop_col+target_col]
-
-# img = torch.randn(3, 112, 112) # Example tensor
-# target_height = 128
-# target_width = 128
-#
-# plt.imshow(img[0,...].cpu().detach().numpy())
-# plt.show()
-#
-# zda = pad_tensor(img, (target_height, target_width))
-#
-# plt.imshow(zda[0,...].cpu().detach().numpy())
-# plt.show()
-
-
-class BinarizeFunction(torch.autograd.Function):
- @staticmethod
- def forward(ctx, input):
- # Forward pass is the binary threshold operation
- return (input > 0.5).float()
-
- @staticmethod
- def backward(ctx, grad_output):
- # For backward pass, just pass the gradients through unchanged
- return grad_output
\ No newline at end of file
diff --git a/optimization_modules_with_resnet_v2.py b/optimization_modules_with_resnet_v2.py
deleted file mode 100755
index 62081bf..0000000
--- a/optimization_modules_with_resnet_v2.py
+++ /dev/null
@@ -1,385 +0,0 @@
-import pytorch_lightning as pl
-import torch
-import torch.nn as nn
-from simca.CassiSystem_lightning import CassiSystemOptim
-from MST.simulation.train_code.architecture import *
-from simca import load_yaml_config
-import matplotlib.pyplot as plt
-import torchvision
-import numpy as np
-from simca.functions_acquisition import *
-from piqa import SSIM
-from torch.utils.tensorboard import SummaryWriter
-import io
-import torchvision.transforms as transforms
-from PIL import Image
-import segmentation_models_pytorch as smp
-import torch.nn.functional as F
-
-class UnetModel(nn.Module):
- def __init__(self,encoder_name="resnet18",encoder_weights="",in_channels=1,classes=2,index=0):
- super().__init__()
- self.i= index
- self.model= smp.Unet(encoder_name= encoder_name, in_channels=in_channels,encoder_weights=encoder_weights,classes=classes,activation='sigmoid')
- def forward(self,x):
- x= self.model(x)
- return x
-
-class JointReconstructionModule_V3(pl.LightningModule):
- def __init__(self, recon_lightning_module, log_dir="tb_logs",resnet_checkpoint=None):
- super().__init__()
-
- self.reconstruction_module = recon_lightning_module
- self.mask_generation = UnetModel(classes=1,encoder_weights=None,in_channels=1)
-
- if resnet_checkpoint is not None:
- # Load the weights from the checkpoint into self.seg_model
- checkpoint = torch.load(resnet_checkpoint, map_location=self.device)
- # Adjust the keys
- adjusted_state_dict = {key.replace('mask_generation.', ''): value
- for key, value in checkpoint['state_dict'].items()}
- # Filter out unexpected keys
- model_keys = set(self.mask_generation.state_dict().keys())
- filtered_state_dict = {k: v for k, v in adjusted_state_dict.items() if k in model_keys}
- self.mask_generation.load_state_dict(filtered_state_dict)
-
- # Freeze the seg_model parameters
- # for param in self.mask_generation.parameters():
- # param.requires_grad = False
-
- self.loss_fn = nn.MSELoss()
- self.ssim_loss = SSIM(window_size=11, n_channels=28)
- self.reconstruction_module.ssim_loss = SSIM(window_size=11, n_channels=28)
-
- self.writer = SummaryWriter(log_dir)
-
- # for param in self.reconstruction_model.parameters():
- # param.requires_grad = False
-
- def on_validation_start(self,stage=None):
- print("---VALIDATION START---")
- self.config = "simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml"
- config_system = load_yaml_config(self.config)
- self.reconstruction_module.config_patterns = load_yaml_config("simca/configs/pattern.yml")
- self.reconstruction_module.cassi_system = CassiSystemOptim(system_config=config_system)
- self.reconstruction_module.cassi_system.propagate_coded_aperture_grid()
-
- self.first_config_patterns = load_yaml_config("simca/configs/pattern.yml")
- self.first_cassi_system = CassiSystemOptim(system_config=config_system)
- self.first_cassi_system.propagate_coded_aperture_grid()
-
-
- def _normalize_data_by_itself(self, data):
- # Calculate the mean and std for each batch individually
- # Keep dimensions for broadcasting
- mean = torch.mean(data, dim=[1, 2], keepdim=True)
- std = torch.std(data, dim=[1, 2], keepdim=True)
-
- # Normalize each batch by its mean and std
- normalized_data = (data - mean) / std
- return normalized_data
-
- def forward(self, x):
- print("---FORWARD---")
-
- hyperspectral_cube, wavelengths = x
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- batch_size, H, W, C = hyperspectral_cube.shape
-
-
- self.pattern = self.first_cassi_system.generate_2D_pattern(self.first_config_patterns, nb_of_patterns=batch_size)
- self.pattern = self.pattern.to(self.device)
- filtering_cube = self.first_cassi_system.generate_filtering_cube().to(self.device)
- self.acquired_image1 = self.first_cassi_system.image_acquisition(hyperspectral_cube, self.pattern, wavelengths).to(self.device)
-
- self.acquired_image1 = pad_tensor(self.acquired_image1, (128, 128))
-
- # flip along second and thrid axis
- self.acquired_image1 = self.acquired_image1.flip(1)
- self.acquired_image1 = self.acquired_image1.flip(2)
- self.acquired_image1 = self.acquired_image1.unsqueeze(1).float()
- #self.acquired_image1 = self._normalize_data_by_itself(self.acquired_image1)
-
- self.pattern = self.mask_generation(self.acquired_image1).squeeze(1)
- self.pattern = BinarizeFunction.apply(self.pattern)
- self.pattern = pad_tensor(self.pattern, (131, 131))
- #self.reconstruction_module.pattern = self.pattern.to(self.device)
- #self.reconstruction_module.cassi_system.pattern = self.pattern.to(self.device)
-
- reconstructed_cube = self.reconstruction_module.forward(x, self.pattern)
-
- self.acquired_image2 = self.reconstruction_module.acquired_image1
-
- return reconstructed_cube
-
- def training_step(self, batch, batch_idx):
- print("Training step")
-
- loss, ssim_loss, reconstructed_cube, ref_cube = self._common_step(batch, batch_idx)
-
-
-
- output_images = self._convert_output_to_images(self._normalize_image_tensor(self.acquired_image2))
- patterns = self._convert_output_to_images(self._normalize_image_tensor(self.pattern))
- input_images = self._convert_output_to_images(self._normalize_image_tensor(ref_cube[:,:,:,0]))
- reconstructed_image = self._convert_output_to_images(self._normalize_image_tensor(reconstructed_cube[:,:,:,0]))
-
- if self.global_step % 30 == 0:
- self._log_images('train/acquisition2', output_images, self.global_step)
- self._log_images('train/ground_truth', input_images, self.global_step)
- self._log_images('train/reconstructed', reconstructed_image, self.global_step)
- self._log_images('train/patterns', patterns, self.global_step)
-
- plt.imshow(self.pattern[0,:,:].cpu().detach().numpy())
- plt.colorbar()
- plt.savefig('./pattern.png')
-
- spectral_filter_plot = self.plot_spectral_filter(ref_cube,reconstructed_cube)
- self.log_gradients(self.global_step)
- self.writer.add_image('Spectral Filter', spectral_filter_plot, self.global_step)
-
- self.log_dict(
- { "train_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "train_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def _normalize_image_tensor(self, tensor):
- # Normalize the tensor to the range [0, 1]
- min_val = tensor.min()
- max_val = tensor.max()
- normalized_tensor = (tensor - min_val) / (max_val - min_val)
- return normalized_tensor
-
- def validation_step(self, batch, batch_idx):
-
- print("Validation step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
-
- self.log_dict(
- { "val_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "val_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def test_step(self, batch, batch_idx):
- print("Test step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
- self.log_dict(
- { "test_loss": loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- self.log_dict(
- { "test_ssim_loss": ssim_loss,
- },
- on_step=True,
- on_epoch=True,
- prog_bar=True,
- )
-
- return {"loss": loss}
-
- def predict_step(self, batch, batch_idx):
- print("Predict step")
- loss, ssim_loss, reconstructed_cube, ref_cube= self._common_step(batch, batch_idx)
- print("Predict loss: ", loss.item())
- print("Predict ssim loss: ", ssim_loss)
- #self.log('predict_step', loss,on_step=True, on_epoch=True, prog_bar=True, logger=True)
- return loss
-
- def _common_step(self, batch, batch_idx):
-
- reconstructed_cube = self.forward(batch)
- hyperspectral_cube, wavelengths = batch
-
- hyperspectral_cube = hyperspectral_cube.permute(0, 2, 3, 1).to(self.device)
- reconstructed_cube = reconstructed_cube.permute(0, 2, 3, 1).to(self.device)
- ref_cube = match_dataset_to_instrument(hyperspectral_cube, reconstructed_cube[0, :, :,0])
-
- # fig, ax = plt.subplots(1, 2)
- # plt.title(f"true cube vs reconstructed cube")
- # ax[0].imshow(hyperspectral_cube[0, :, :, 0].cpu().detach().numpy())
- # ax[1].imshow(reconstructed_cube[0, :, :, 0].cpu().detach().numpy())
- # plt.show()
- total_sum_pattern = torch.sum(self.pattern, dim=(1, 2))
- total_half_pattern_equal_1 = torch.sum(torch.ones_like(self.pattern), dim=(1, 2)) / 2
-
- print(f"total_sum_pattern {total_sum_pattern}")
- print(f"total_half_pattern_equal_1 {total_half_pattern_equal_1}")
-
-
-
- loss1 = torch.sqrt(self.loss_fn(reconstructed_cube, ref_cube))
- loss2 = torch.sum(torch.abs((total_sum_pattern - total_half_pattern_equal_1)/(self.pattern.shape[1]*self.pattern.shape[2]))**2)
- loss = loss1
-
- ssim_loss = self.ssim_loss(torch.clamp(reconstructed_cube.permute(0, 3, 1, 2), 0, 1), ref_cube.permute(0, 3, 1, 2))
- print(f"loss1 {loss1}")
- print(f"loss2 {loss2}")
- return loss, ssim_loss, reconstructed_cube, ref_cube
-
- def configure_optimizers(self):
- optimizer = torch.optim.Adam(self.parameters(), lr=1e-4)
- return { "optimizer":optimizer,
- "lr_scheduler":{
- "scheduler":torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, 500, eta_min=1e-6),
- "interval": "epoch"
- }
- }
-
- def _log_images(self, tag, images, global_step):
- # Convert model output to image grid and log to TensorBoard
- img_grid = torchvision.utils.make_grid(images)
- self.writer.add_image(tag, img_grid, global_step)
-
- def _convert_output_to_images(self, acquired_images):
-
- acquired_images = acquired_images.unsqueeze(1)
-
- # Create a grid of images for visualization
- img_grid = torchvision.utils.make_grid(acquired_images)
- return img_grid
-
- def log_gradients(self, step):
- for name, param in self.mask_generation.named_parameters():
- if param.grad is not None:
- self.writer.add_scalar(f"Gradients/{name}", param.grad.norm(), step)
-
-
- def plot_spectral_filter(self,ref_hyperspectral_cube,recontructed_hyperspectral_cube):
-
-
- batch_size, y,x, lmabda_ = ref_hyperspectral_cube.shape
-
- # Create a figure with subplots arranged horizontally
- fig, axs = plt.subplots(1, batch_size, figsize=(batch_size * 5, 4)) # Adjust figure size as needed
-
- # Check if batch_size is 1, axs might not be iterable
- if batch_size == 1:
- axs = [axs]
-
- # Plot each spectral filter in its own subplot
- for i in range(batch_size):
- colors = ['b', 'g', 'r']
- for j in range(3):
- pix_j_row_value = np.random.randint(0,y)
- pix_j_col_value = np.random.randint(0,x)
-
- pix_j_ref = ref_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- pix_j_reconstructed = recontructed_hyperspectral_cube[i, pix_j_row_value,pix_j_col_value,:].cpu().detach().numpy()
- axs[i].plot(pix_j_reconstructed, label="pix reconstructed" + str(j),c=colors[j])
- axs[i].plot(pix_j_ref, label="pix" + str(j), linestyle='--',c=colors[j])
-
- axs[i].set_title(f"Reconstruction quality")
-
- axs[i].set_xlabel("Wavelength index")
- axs[i].set_ylabel("pix values")
- axs[i].grid(True)
-
- plt.legend()
- # Adjust layout
- plt.tight_layout()
-
- # Create a buffer to save plot
- buf = io.BytesIO()
- plt.savefig(buf, format='png')
- plt.close(fig)
- buf.seek(0)
-
- # Convert PNG buffer to PIL Image
- image = Image.open(buf)
-
- # Convert PIL Image to Tensor
- image_tensor = transforms.ToTensor()(image)
- return image_tensor
-
-
-def subsample(input, origin_sampling, target_sampling):
- [bs, row, col, nC] = input.shape
- indices = torch.zeros(len(target_sampling), dtype=torch.int)
- for i in range(len(target_sampling)):
- sample = target_sampling[i]
- idx = torch.abs(origin_sampling-sample).argmin()
- indices[i] = idx
- return input[:,:,:,indices]
-
-def expand_mask_3d(mask_batch):
- if len(mask_batch.shape)==3:
- mask3d = mask_batch.unsqueeze(-1).repeat((1, 1, 1, 28))
- else:
- mask3d = mask_batch.repeat((1, 1, 1, 28))
- mask3d = torch.permute(mask3d, (0, 3, 1, 2))
- return mask3d
-
-class EmptyModule(nn.Module):
- def __init__(self):
- super().__init__()
- self.useless_linear = nn.Linear(1, 1)
- def forward(self, x):
- return x
-
-
-def pad_tensor(input_tensor, target_shape):
- [bs, row, col] = input_tensor.shape
- [target_row, target_col] = target_shape
-
- # Calculate padding for rows
- pad_row_total = max(target_row - row, 0)
- pad_row_top = pad_row_total // 2
- pad_row_bottom = pad_row_total - pad_row_top
-
- # Calculate padding for columns
- pad_col_total = max(target_col - col, 0)
- pad_col_left = pad_col_total // 2
- pad_col_right = pad_col_total - pad_col_left
-
- # Apply padding
- padded_tensor = F.pad(input_tensor, (pad_col_left, pad_col_right, pad_row_top, pad_row_bottom), 'constant', 0)
- return padded_tensor
-
-def crop_tensor(input_tensor, target_shape):
- [bs, row, col] = input_tensor.shape
- [target_row, target_col] = target_shape
- crop_row = (row-target_row)//2
- crop_col = (col-target_col)//2
- return input_tensor[:,crop_row:crop_row+target_row,crop_col:crop_col+target_col]
-
-
-class BinarizeFunction(torch.autograd.Function):
- @staticmethod
- def forward(ctx, input):
- # Forward pass is the binary threshold operation
- return (input > 0.5).float()
-
- @staticmethod
- def backward(ctx, grad_output):
- # For backward pass, just pass the gradients through unchanged
- return grad_output
diff --git a/outputs/amici/config_system.yml b/outputs/amici/config_system.yml
new file mode 100755
index 0000000..9c06d18
--- /dev/null
+++ b/outputs/amici/config_system.yml
@@ -0,0 +1,33 @@
+coded aperture:
+ number of pixels along X: 25
+ number of pixels along Y: 25
+ pixel size along X: 210
+ pixel size along Y: 210
+detector:
+ number of pixels along X: 112
+ number of pixels along Y: 112
+ pixel size along X: 71
+ pixel size along Y: 71
+infos:
+ system name: HYACAMEO
+spectral range:
+ number of spectral samples: 10
+ wavelength max: 650
+ wavelength min: 450
+system architecture:
+ dispersive element:
+ A1: 22.990923887808794
+ A2: 33.78312991797481
+ A3: 22.990923887808794
+ alpha_c: 5.892854562568398
+ catalog: Schott
+ delta alpha c: 0
+ delta beta c: 0
+ glass1: N-BAK4
+ glass2: N-SF14
+ glass3: N-BAK4
+ index evaluation method: cauchy
+ type: amici
+ wavelength center: 520.0
+ focal lens: 75000
+ system type: DD-CASSI
diff --git a/outputs/amici/optimization_plot_individual_step1.png b/outputs/amici/optimization_plot_individual_step1.png
new file mode 100755
index 0000000..15ba443
Binary files /dev/null and b/outputs/amici/optimization_plot_individual_step1.png differ
diff --git a/outputs/amici/optimization_plot_individual_step2.png b/outputs/amici/optimization_plot_individual_step2.png
new file mode 100755
index 0000000..03dcc76
Binary files /dev/null and b/outputs/amici/optimization_plot_individual_step2.png differ
diff --git a/outputs/amici/optimization_plot_total_step1.png b/outputs/amici/optimization_plot_total_step1.png
new file mode 100755
index 0000000..2870a8a
Binary files /dev/null and b/outputs/amici/optimization_plot_total_step1.png differ
diff --git a/outputs/amici/optimization_plot_total_step2.png b/outputs/amici/optimization_plot_total_step2.png
new file mode 100755
index 0000000..9c60bdb
Binary files /dev/null and b/outputs/amici/optimization_plot_total_step2.png differ
diff --git a/outputs/amici/optimization_results/step1/optimization_details.json b/outputs/amici/optimization_results/step1/optimization_details.json
new file mode 100755
index 0000000..6e2e6c8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/optimization_details.json
@@ -0,0 +1,5402 @@
+[
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 0,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 19.700000434365958,
+ "A2": 39.400000868731915,
+ "nd1": 1.6073800325393677,
+ "vd1": 56.6585807800293,
+ "nd2": 1.7551300525665283,
+ "vd2": 27.379623413085938,
+ "delta_beta_c": 0.0,
+ "alpha_c": 0.0,
+ "delta_alpha_c": 0.0,
+ "A3": 19.700000434365958,
+ "nd3": 1.6073800325393677,
+ "vd3": 56.6585807800293
+ },
+ "optical system values": {
+ "dispersion [um]": 1243.885498046875,
+ "deviation [deg]": -367.6203427918692,
+ "max distortion [um]": 41.7684326171875,
+ "mean distortion [um]": 11.958077430725098,
+ "beam_compression [no units]": 0.7342777252197266
+ },
+ "current_loss": 396061.0625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 10,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.781266733430876,
+ "A2": 34.29354995464987,
+ "nd1": 1.5652458667755127,
+ "vd1": 56.61178970336914,
+ "nd2": 1.7575560808181763,
+ "vd2": 27.443378448486328,
+ "delta_beta_c": 0.0,
+ "alpha_c": -1.611391996089454,
+ "delta_alpha_c": 0.0,
+ "A3": 24.781266733430876,
+ "nd3": 1.5652458667755127,
+ "vd3": 56.61178970336914
+ },
+ "optical system values": {
+ "dispersion [um]": 871.670166015625,
+ "deviation [deg]": 96.72697385575368,
+ "max distortion [um]": 47.5394172668457,
+ "mean distortion [um]": 18.500751495361328,
+ "beam_compression [no units]": 0.7594806551933289
+ },
+ "current_loss": 63466.390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 20,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.518244686230148,
+ "A2": 34.78474300881133,
+ "nd1": 1.560623288154602,
+ "vd1": 56.560523986816406,
+ "nd2": 1.7593114376068115,
+ "vd2": 27.38224983215332,
+ "delta_beta_c": 0.0,
+ "alpha_c": 0.053162657342875244,
+ "delta_alpha_c": 0.0,
+ "A3": 24.518244686230148,
+ "nd3": 1.560623288154602,
+ "vd3": 56.560523986816406
+ },
+ "optical system values": {
+ "dispersion [um]": 910.2132568359375,
+ "deviation [deg]": 36.702308373008655,
+ "max distortion [um]": 24.300939559936523,
+ "mean distortion [um]": 8.328362464904785,
+ "beam_compression [no units]": 0.7736459970474243
+ },
+ "current_loss": 48344.37109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 30,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.408639474426554,
+ "A2": 36.21067818674031,
+ "nd1": 1.5656262636184692,
+ "vd1": 56.485748291015625,
+ "nd2": 1.7578474283218384,
+ "vd2": 27.318180084228516,
+ "delta_beta_c": 0.0,
+ "alpha_c": 1.811167665514628,
+ "delta_alpha_c": 0.0,
+ "A3": 23.408639474426554,
+ "nd3": 1.5656262636184692,
+ "vd3": 56.485748291015625
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.7440795898438,
+ "deviation [deg]": -85.41633768456347,
+ "max distortion [um]": 5.092158794403076,
+ "mean distortion [um]": 0.9526662826538086,
+ "beam_compression [no units]": 0.7779462337493896
+ },
+ "current_loss": 38495.9921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 40,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.310364463746225,
+ "A2": 35.58620082111521,
+ "nd1": 1.5661166906356812,
+ "vd1": 56.402000427246094,
+ "nd2": 1.758665919303894,
+ "vd2": 27.290983200073242,
+ "delta_beta_c": 0.0,
+ "alpha_c": 4.175413741052447,
+ "delta_alpha_c": 0.0,
+ "A3": 24.310364463746225,
+ "nd3": 1.5661166906356812,
+ "vd3": 56.402000427246094
+ },
+ "optical system values": {
+ "dispersion [um]": 941.2090454101562,
+ "deviation [deg]": 2.3581230243903137,
+ "max distortion [um]": 8.212969779968262,
+ "mean distortion [um]": 1.7621599435806274,
+ "beam_compression [no units]": 0.785879909992218
+ },
+ "current_loss": 24444.15234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 50,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.46821696565439,
+ "A2": 35.77123064573086,
+ "nd1": 1.565541386604309,
+ "vd1": 56.32564163208008,
+ "nd2": 1.7594786882400513,
+ "vd2": 27.263164520263672,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.474400347278555,
+ "delta_alpha_c": 0.0,
+ "A3": 24.46821696565439,
+ "nd3": 1.565541386604309,
+ "vd3": 56.32564163208008
+ },
+ "optical system values": {
+ "dispersion [um]": 947.7142333984375,
+ "deviation [deg]": 0.7147843125620061,
+ "max distortion [um]": 4.563945293426514,
+ "mean distortion [um]": 1.0583419799804688,
+ "beam_compression [no units]": 0.7855594158172607
+ },
+ "current_loss": 24540.59765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 60,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.37563716654945,
+ "A2": 36.23438235825484,
+ "nd1": 1.5651732683181763,
+ "vd1": 56.25839614868164,
+ "nd2": 1.7582603693008423,
+ "vd2": 27.238332748413086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.701168604138503,
+ "delta_alpha_c": 0.0,
+ "A3": 24.37563716654945,
+ "nd3": 1.5651732683181763,
+ "vd3": 56.25839614868164
+ },
+ "optical system values": {
+ "dispersion [um]": 973.6182861328125,
+ "deviation [deg]": -25.1059927095935,
+ "max distortion [um]": 3.2885828018188477,
+ "mean distortion [um]": 0.6835103034973145,
+ "beam_compression [no units]": 0.7802240252494812
+ },
+ "current_loss": 23572.501953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 70,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.70832202064243,
+ "A2": 36.23447798090322,
+ "nd1": 1.565058708190918,
+ "vd1": 56.20002365112305,
+ "nd2": 1.7586079835891724,
+ "vd2": 27.224163055419922,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.663256046071127,
+ "delta_alpha_c": 0.0,
+ "A3": 24.70832202064243,
+ "nd3": 1.565058708190918,
+ "vd3": 56.20002365112305
+ },
+ "optical system values": {
+ "dispersion [um]": 963.78857421875,
+ "deviation [deg]": -4.290760695095153,
+ "max distortion [um]": 5.502186298370361,
+ "mean distortion [um]": 1.0332753658294678,
+ "beam_compression [no units]": 0.7796860933303833
+ },
+ "current_loss": 23411.11328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 80,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.752719957794806,
+ "A2": 36.48439801772857,
+ "nd1": 1.565555214881897,
+ "vd1": 56.15278625488281,
+ "nd2": 1.7581883668899536,
+ "vd2": 27.213685989379883,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.515620538919582,
+ "delta_alpha_c": 0.0,
+ "A3": 24.752719957794806,
+ "nd3": 1.565555214881897,
+ "vd3": 56.15278625488281
+ },
+ "optical system values": {
+ "dispersion [um]": 973.274658203125,
+ "deviation [deg]": -10.467001940761495,
+ "max distortion [um]": 3.805499792098999,
+ "mean distortion [um]": 0.8912726044654846,
+ "beam_compression [no units]": 0.7768886089324951
+ },
+ "current_loss": 21883.185546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 90,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.883130467165152,
+ "A2": 36.61474193275451,
+ "nd1": 1.565574288368225,
+ "vd1": 56.11540603637695,
+ "nd2": 1.758040189743042,
+ "vd2": 27.209375381469727,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.2577919968090026,
+ "delta_alpha_c": 0.0,
+ "A3": 24.883130467165152,
+ "nd3": 1.565574288368225,
+ "vd3": 56.11540603637695
+ },
+ "optical system values": {
+ "dispersion [um]": 975.1571044921875,
+ "deviation [deg]": -7.469134583847226,
+ "max distortion [um]": 4.424908638000488,
+ "mean distortion [um]": 0.9388195872306824,
+ "beam_compression [no units]": 0.7751697897911072
+ },
+ "current_loss": 21619.59375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 100,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.992898437316427,
+ "A2": 36.72618671434702,
+ "nd1": 1.5655118227005005,
+ "vd1": 56.08656311035156,
+ "nd2": 1.7580280303955078,
+ "vd2": 27.209564208984375,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.30287039155744,
+ "delta_alpha_c": 0.0,
+ "A3": 24.992898437316427,
+ "nd3": 1.5655118227005005,
+ "vd3": 56.08656311035156
+ },
+ "optical system values": {
+ "dispersion [um]": 976.953857421875,
+ "deviation [deg]": -5.511059794569379,
+ "max distortion [um]": 4.581758975982666,
+ "mean distortion [um]": 0.9754363298416138,
+ "beam_compression [no units]": 0.7736455202102661
+ },
+ "current_loss": 21772.43359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 110,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.057271262696506,
+ "A2": 36.85153093090051,
+ "nd1": 1.5656832456588745,
+ "vd1": 56.06486129760742,
+ "nd2": 1.7578811645507812,
+ "vd2": 27.212736129760742,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.279806977164423,
+ "delta_alpha_c": 0.0,
+ "A3": 25.057271262696506,
+ "nd3": 1.5656832456588745,
+ "vd3": 56.06486129760742
+ },
+ "optical system values": {
+ "dispersion [um]": 980.2111206054688,
+ "deviation [deg]": -6.178981005297164,
+ "max distortion [um]": 4.573357582092285,
+ "mean distortion [um]": 0.9652649760246277,
+ "beam_compression [no units]": 0.7720276713371277
+ },
+ "current_loss": 21453.78125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 120,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.1269016261902,
+ "A2": 36.93943205042399,
+ "nd1": 1.5657163858413696,
+ "vd1": 56.048667907714844,
+ "nd2": 1.7577874660491943,
+ "vd2": 27.218402862548828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.426851558484689,
+ "delta_alpha_c": 0.0,
+ "A3": 25.1269016261902,
+ "nd3": 1.5657163858413696,
+ "vd3": 56.048667907714844
+ },
+ "optical system values": {
+ "dispersion [um]": 981.5252685546875,
+ "deviation [deg]": -5.309029629109572,
+ "max distortion [um]": 4.462231159210205,
+ "mean distortion [um]": 0.9754527807235718,
+ "beam_compression [no units]": 0.7708723545074463
+ },
+ "current_loss": 21360.9765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 130,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.18442718692734,
+ "A2": 37.01580381062849,
+ "nd1": 1.5658539533615112,
+ "vd1": 56.036808013916016,
+ "nd2": 1.7576956748962402,
+ "vd2": 27.225231170654297,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.457510997008407,
+ "delta_alpha_c": 0.0,
+ "A3": 25.18442718692734,
+ "nd3": 1.5658539533615112,
+ "vd3": 56.036808013916016
+ },
+ "optical system values": {
+ "dispersion [um]": 982.4967041015625,
+ "deviation [deg]": -4.393879049202597,
+ "max distortion [um]": 4.516024589538574,
+ "mean distortion [um]": 0.9893767833709717,
+ "beam_compression [no units]": 0.7698540687561035
+ },
+ "current_loss": 21165.013671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 140,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.228300907060916,
+ "A2": 37.08578934395902,
+ "nd1": 1.5659021139144897,
+ "vd1": 56.02824020385742,
+ "nd2": 1.7576682567596436,
+ "vd2": 27.232439041137695,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.425455211686244,
+ "delta_alpha_c": 0.0,
+ "A3": 25.228300907060916,
+ "nd3": 1.5659021139144897,
+ "vd3": 56.02824020385742
+ },
+ "optical system values": {
+ "dispersion [um]": 983.9241943359375,
+ "deviation [deg]": -4.5019868564987355,
+ "max distortion [um]": 4.573421001434326,
+ "mean distortion [um]": 0.9927244186401367,
+ "beam_compression [no units]": 0.7689188718795776
+ },
+ "current_loss": 21175.953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 150,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.266847079641884,
+ "A2": 37.14214181970621,
+ "nd1": 1.5659223794937134,
+ "vd1": 56.02200698852539,
+ "nd2": 1.757604956626892,
+ "vd2": 27.239652633666992,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.507199769446603,
+ "delta_alpha_c": 0.0,
+ "A3": 25.266847079641884,
+ "nd3": 1.5659223794937134,
+ "vd3": 56.02200698852539
+ },
+ "optical system values": {
+ "dispersion [um]": 984.7855224609375,
+ "deviation [deg]": -4.338406387197869,
+ "max distortion [um]": 4.4920268058776855,
+ "mean distortion [um]": 0.992405116558075,
+ "beam_compression [no units]": 0.7681785225868225
+ },
+ "current_loss": 21168.828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 160,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.30173568592231,
+ "A2": 37.18831731359008,
+ "nd1": 1.5660526752471924,
+ "vd1": 56.017478942871094,
+ "nd2": 1.7575714588165283,
+ "vd2": 27.24643325805664,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.466477327841341,
+ "delta_alpha_c": 0.0,
+ "A3": 25.30173568592231,
+ "nd3": 1.5660526752471924,
+ "vd3": 56.017478942871094
+ },
+ "optical system values": {
+ "dispersion [um]": 985.223876953125,
+ "deviation [deg]": -3.679192387001381,
+ "max distortion [um]": 4.588613986968994,
+ "mean distortion [um]": 1.0035090446472168,
+ "beam_compression [no units]": 0.7675459980964661
+ },
+ "current_loss": 21036.416015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 170,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.326425112224612,
+ "A2": 37.23115284496982,
+ "nd1": 1.5660583972930908,
+ "vd1": 56.01417922973633,
+ "nd2": 1.7574938535690308,
+ "vd2": 27.252595901489258,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.523038978131862,
+ "delta_alpha_c": 0.0,
+ "A3": 25.326425112224612,
+ "nd3": 1.5660583972930908,
+ "vd3": 56.01417922973633
+ },
+ "optical system values": {
+ "dispersion [um]": 985.94091796875,
+ "deviation [deg]": -3.81997709994733,
+ "max distortion [um]": 4.5062174797058105,
+ "mean distortion [um]": 0.9986117482185364,
+ "beam_compression [no units]": 0.7669985294342041
+ },
+ "current_loss": 21028.556640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 180,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.34924135914704,
+ "A2": 37.26527988515779,
+ "nd1": 1.5661214590072632,
+ "vd1": 56.0117301940918,
+ "nd2": 1.757497787475586,
+ "vd2": 27.258068084716797,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.529021796957971,
+ "delta_alpha_c": 0.0,
+ "A3": 25.34924135914704,
+ "nd3": 1.5661214590072632,
+ "vd3": 56.0117301940918
+ },
+ "optical system values": {
+ "dispersion [um]": 986.4730224609375,
+ "deviation [deg]": -3.6949436570010765,
+ "max distortion [um]": 4.5103607177734375,
+ "mean distortion [um]": 1.0025465488433838,
+ "beam_compression [no units]": 0.7665287256240845
+ },
+ "current_loss": 21022.478515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 190,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.36847687939709,
+ "A2": 37.29372762305089,
+ "nd1": 1.5661958456039429,
+ "vd1": 56.00989532470703,
+ "nd2": 1.7574349641799927,
+ "vd2": 27.262826919555664,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.506589321289533,
+ "delta_alpha_c": 0.0,
+ "A3": 25.36847687939709,
+ "nd3": 1.5661958456039429,
+ "vd3": 56.00989532470703
+ },
+ "optical system values": {
+ "dispersion [um]": 986.6578979492188,
+ "deviation [deg]": -3.3577058414960472,
+ "max distortion [um]": 4.583846569061279,
+ "mean distortion [um]": 1.0088410377502441,
+ "beam_compression [no units]": 0.7661559581756592
+ },
+ "current_loss": 20921.396484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 200,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.3832335030989,
+ "A2": 37.318022605928626,
+ "nd1": 1.5662204027175903,
+ "vd1": 56.00850296020508,
+ "nd2": 1.7574290037155151,
+ "vd2": 27.266883850097656,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.523401405044696,
+ "delta_alpha_c": 0.0,
+ "A3": 25.3832335030989,
+ "nd3": 1.5662204027175903,
+ "vd3": 56.00850296020508
+ },
+ "optical system values": {
+ "dispersion [um]": 987.089111328125,
+ "deviation [deg]": -3.4092650185497697,
+ "max distortion [um]": 4.563814640045166,
+ "mean distortion [um]": 1.0105103254318237,
+ "beam_compression [no units]": 0.7658281922340393
+ },
+ "current_loss": 20954.873046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 210,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.39510266432909,
+ "A2": 37.33800773944009,
+ "nd1": 1.5662448406219482,
+ "vd1": 56.007450103759766,
+ "nd2": 1.7573987245559692,
+ "vd2": 27.270286560058594,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.534952108704834,
+ "delta_alpha_c": 0.0,
+ "A3": 25.39510266432909,
+ "nd3": 1.5662448406219482,
+ "vd3": 56.007450103759766
+ },
+ "optical system values": {
+ "dispersion [um]": 987.3663940429688,
+ "deviation [deg]": -3.397035564840862,
+ "max distortion [um]": 4.56070613861084,
+ "mean distortion [um]": 1.0065451860427856,
+ "beam_compression [no units]": 0.7655667066574097
+ },
+ "current_loss": 20961.865234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 220,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.40479470276134,
+ "A2": 37.35402794813835,
+ "nd1": 1.5662708282470703,
+ "vd1": 56.00664520263672,
+ "nd2": 1.757366418838501,
+ "vd2": 27.273073196411133,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.525512787271876,
+ "delta_alpha_c": 0.0,
+ "A3": 25.40479470276134,
+ "nd3": 1.5662708282470703,
+ "vd3": 56.00664520263672
+ },
+ "optical system values": {
+ "dispersion [um]": 987.552490234375,
+ "deviation [deg]": -3.3383343577928333,
+ "max distortion [um]": 4.570685863494873,
+ "mean distortion [um]": 1.010372281074524,
+ "beam_compression [no units]": 0.7653584480285645
+ },
+ "current_loss": 20954.078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 230,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.411638552309693,
+ "A2": 37.36722045852023,
+ "nd1": 1.5663071870803833,
+ "vd1": 56.00603485107422,
+ "nd2": 1.7573415040969849,
+ "vd2": 27.275300979614258,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5296194385103465,
+ "delta_alpha_c": 0.0,
+ "A3": 25.411638552309693,
+ "nd3": 1.5663071870803833,
+ "vd3": 56.00603485107422
+ },
+ "optical system values": {
+ "dispersion [um]": 987.7261352539062,
+ "deviation [deg]": -3.3219959049679284,
+ "max distortion [um]": 4.564815998077393,
+ "mean distortion [um]": 1.0120433568954468,
+ "beam_compression [no units]": 0.7651867866516113
+ },
+ "current_loss": 20942.02734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 240,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.417116364024043,
+ "A2": 37.377021779979195,
+ "nd1": 1.5663601160049438,
+ "vd1": 56.005577087402344,
+ "nd2": 1.757318139076233,
+ "vd2": 27.277036666870117,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5264519382827535,
+ "delta_alpha_c": 0.0,
+ "A3": 25.417116364024043,
+ "nd3": 1.5663601160049438,
+ "vd3": 56.005577087402344
+ },
+ "optical system values": {
+ "dispersion [um]": 987.775634765625,
+ "deviation [deg]": -3.1942231292776766,
+ "max distortion [um]": 4.562950134277344,
+ "mean distortion [um]": 1.0097028017044067,
+ "beam_compression [no units]": 0.7650575041770935
+ },
+ "current_loss": 20902.501953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 250,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.421149590728934,
+ "A2": 37.384162742756445,
+ "nd1": 1.5664036273956299,
+ "vd1": 56.005245208740234,
+ "nd2": 1.757266879081726,
+ "vd2": 27.278324127197266,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.51841579383741,
+ "delta_alpha_c": 0.0,
+ "A3": 25.421149590728934,
+ "nd3": 1.5664036273956299,
+ "vd3": 56.005245208740234
+ },
+ "optical system values": {
+ "dispersion [um]": 987.71142578125,
+ "deviation [deg]": -3.004422630970189,
+ "max distortion [um]": 4.605084419250488,
+ "mean distortion [um]": 1.0151185989379883,
+ "beam_compression [no units]": 0.7649738788604736
+ },
+ "current_loss": 20844.53515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 260,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.423231090878495,
+ "A2": 37.38962347899787,
+ "nd1": 1.5664223432540894,
+ "vd1": 56.00502395629883,
+ "nd2": 1.7572224140167236,
+ "vd2": 27.27922821044922,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.523836829604285,
+ "delta_alpha_c": 0.0,
+ "A3": 25.423231090878495,
+ "nd3": 1.5664223432540894,
+ "vd3": 56.00502395629883
+ },
+ "optical system values": {
+ "dispersion [um]": 987.7127685546875,
+ "deviation [deg]": -2.9572661511667744,
+ "max distortion [um]": 4.600214958190918,
+ "mean distortion [um]": 1.0164793729782104,
+ "beam_compression [no units]": 0.7649149894714355
+ },
+ "current_loss": 20827.427734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 270,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.424436619267002,
+ "A2": 37.39314444151501,
+ "nd1": 1.5664547681808472,
+ "vd1": 56.0048828125,
+ "nd2": 1.7572113275527954,
+ "vd2": 27.279796600341797,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.524976190535208,
+ "delta_alpha_c": 0.0,
+ "A3": 25.424436619267002,
+ "nd3": 1.5664547681808472,
+ "vd3": 56.0048828125
+ },
+ "optical system values": {
+ "dispersion [um]": 987.7451171875,
+ "deviation [deg]": -2.9141206999534504,
+ "max distortion [um]": 4.600940227508545,
+ "mean distortion [um]": 1.016453742980957,
+ "beam_compression [no units]": 0.7648693323135376
+ },
+ "current_loss": 20824.87890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 280,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.42506841176523,
+ "A2": 37.39504323410428,
+ "nd1": 1.5664770603179932,
+ "vd1": 56.00480270385742,
+ "nd2": 1.7571818828582764,
+ "vd2": 27.280107498168945,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.523254129090718,
+ "delta_alpha_c": 0.0,
+ "A3": 25.42506841176523,
+ "nd3": 1.5664770603179932,
+ "vd3": 56.00480270385742
+ },
+ "optical system values": {
+ "dispersion [um]": 987.67041015625,
+ "deviation [deg]": -2.8235252842458127,
+ "max distortion [um]": 4.600596904754639,
+ "mean distortion [um]": 1.0122605562210083,
+ "beam_compression [no units]": 0.7648518085479736
+ },
+ "current_loss": 20814.640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 290,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.425261364609284,
+ "A2": 37.395828705858825,
+ "nd1": 1.5664924383163452,
+ "vd1": 56.0047721862793,
+ "nd2": 1.7571660280227661,
+ "vd2": 27.280231475830078,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.522571963947363,
+ "delta_alpha_c": 0.0,
+ "A3": 25.425261364609284,
+ "nd3": 1.5664924383163452,
+ "vd3": 56.0047721862793
+ },
+ "optical system values": {
+ "dispersion [um]": 987.6459350585938,
+ "deviation [deg]": -2.763160926134886,
+ "max distortion [um]": 4.603357791900635,
+ "mean distortion [um]": 1.0138829946517944,
+ "beam_compression [no units]": 0.7648451924324036
+ },
+ "current_loss": 20826.72265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 300,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.42531429857535,
+ "A2": 37.3959482341693,
+ "nd1": 1.566497564315796,
+ "vd1": 56.0047721862793,
+ "nd2": 1.7571609020233154,
+ "vd2": 27.28025245666504,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.521793749268805,
+ "delta_alpha_c": 0.0,
+ "A3": 25.42531429857535,
+ "nd3": 1.566497564315796,
+ "vd3": 56.0047721862793
+ },
+ "optical system values": {
+ "dispersion [um]": 987.6163330078125,
+ "deviation [deg]": -2.736843353489181,
+ "max distortion [um]": 4.607226371765137,
+ "mean distortion [um]": 1.017181634902954,
+ "beam_compression [no units]": 0.7648449540138245
+ },
+ "current_loss": 20865.00390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 310,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.42528697781867,
+ "A2": 37.39609849833104,
+ "nd1": 1.5665066242218018,
+ "vd1": 56.0047721862793,
+ "nd2": 1.757150411605835,
+ "vd2": 27.280271530151367,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.522730338958743,
+ "delta_alpha_c": 0.0,
+ "A3": 25.42528697781867,
+ "nd3": 1.5665066242218018,
+ "vd3": 56.0047721862793
+ },
+ "optical system values": {
+ "dispersion [um]": 987.5755004882812,
+ "deviation [deg]": -2.6936979022758565,
+ "max distortion [um]": 4.6122026443481445,
+ "mean distortion [um]": 1.0155420303344727,
+ "beam_compression [no units]": 0.7648456692695618
+ },
+ "current_loss": 20890.578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 320,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.425215260832385,
+ "A2": 37.39707180028777,
+ "nd1": 1.5665801763534546,
+ "vd1": 56.004737854003906,
+ "nd2": 1.7570701837539673,
+ "vd2": 27.2804012298584,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.524905754209391,
+ "delta_alpha_c": 0.0,
+ "A3": 25.425215260832385,
+ "nd3": 1.5665801763534546,
+ "vd3": 56.004737854003906
+ },
+ "optical system values": {
+ "dispersion [um]": 987.275634765625,
+ "deviation [deg]": -2.3331751181166074,
+ "max distortion [um]": 4.624635696411133,
+ "mean distortion [um]": 1.0212907791137695,
+ "beam_compression [no units]": 0.7648528218269348
+ },
+ "current_loss": 20742.49609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 330,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.42470641173922,
+ "A2": 37.40017612126554,
+ "nd1": 1.566649317741394,
+ "vd1": 56.00464630126953,
+ "nd2": 1.7570420503616333,
+ "vd2": 27.28075408935547,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.525858565598608,
+ "delta_alpha_c": 0.0,
+ "A3": 25.42470641173922,
+ "nd3": 1.566649317741394,
+ "vd3": 56.00464630126953
+ },
+ "optical system values": {
+ "dispersion [um]": 987.241455078125,
+ "deviation [deg]": -2.233383066134959,
+ "max distortion [um]": 4.6266770362854,
+ "mean distortion [um]": 1.024780511856079,
+ "beam_compression [no units]": 0.7648167610168457
+ },
+ "current_loss": 20659.517578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 340,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.42404388338973,
+ "A2": 37.40613204622179,
+ "nd1": 1.5666093826293945,
+ "vd1": 56.00448226928711,
+ "nd2": 1.7570375204086304,
+ "vd2": 27.281457901000977,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.51463272281087,
+ "delta_alpha_c": 0.0,
+ "A3": 25.42404388338973,
+ "nd3": 1.5666093826293945,
+ "vd3": 56.00448226928711
+ },
+ "optical system values": {
+ "dispersion [um]": 987.5850830078125,
+ "deviation [deg]": -2.6628798752973473,
+ "max distortion [um]": 4.614688396453857,
+ "mean distortion [um]": 1.0193318128585815,
+ "beam_compression [no units]": 0.7647477388381958
+ },
+ "current_loss": 20748.07421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 350,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.423611873924724,
+ "A2": 37.41515131102079,
+ "nd1": 1.5666677951812744,
+ "vd1": 56.00418472290039,
+ "nd2": 1.757031798362732,
+ "vd2": 27.28266143798828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5114379018265955,
+ "delta_alpha_c": 0.0,
+ "A3": 25.423611873924724,
+ "nd3": 1.5666677951812744,
+ "vd3": 56.00418472290039
+ },
+ "optical system values": {
+ "dispersion [um]": 987.8642578125,
+ "deviation [deg]": -2.91304451827235,
+ "max distortion [um]": 4.606467247009277,
+ "mean distortion [um]": 1.013279914855957,
+ "beam_compression [no units]": 0.7646303176879883
+ },
+ "current_loss": 20695.396484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 360,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.4262141759985,
+ "A2": 37.42539317968123,
+ "nd1": 1.566693663597107,
+ "vd1": 56.003726959228516,
+ "nd2": 1.7569998502731323,
+ "vd2": 27.28451156616211,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.495043740271273,
+ "delta_alpha_c": 0.0,
+ "A3": 25.4262141759985,
+ "nd3": 1.566693663597107,
+ "vd3": 56.003726959228516
+ },
+ "optical system values": {
+ "dispersion [um]": 988.0711059570312,
+ "deviation [deg]": -3.058232141912019,
+ "max distortion [um]": 4.600214958190918,
+ "mean distortion [um]": 1.0108965635299683,
+ "beam_compression [no units]": 0.7645047307014465
+ },
+ "current_loss": 20661.041015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 370,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.431968610374234,
+ "A2": 37.43690887862187,
+ "nd1": 1.5666999816894531,
+ "vd1": 56.00309753417969,
+ "nd2": 1.7570040225982666,
+ "vd2": 27.287111282348633,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.506450156185194,
+ "delta_alpha_c": 0.0,
+ "A3": 25.431968610374234,
+ "nd3": 1.5666999816894531,
+ "vd3": 56.00309753417969
+ },
+ "optical system values": {
+ "dispersion [um]": 988.2939453125,
+ "deviation [deg]": -3.1952013404328694,
+ "max distortion [um]": 4.577730655670166,
+ "mean distortion [um]": 1.010656476020813,
+ "beam_compression [no units]": 0.764349102973938
+ },
+ "current_loss": 20683.748046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 380,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.441947516751625,
+ "A2": 37.44971206822106,
+ "nd1": 1.5667091608047485,
+ "vd1": 56.002296447753906,
+ "nd2": 1.7569950819015503,
+ "vd2": 27.29050064086914,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.509736330949616,
+ "delta_alpha_c": 0.0,
+ "A3": 25.441947516751625,
+ "nd3": 1.5667091608047485,
+ "vd3": 56.002296447753906
+ },
+ "optical system values": {
+ "dispersion [um]": 988.3297729492188,
+ "deviation [deg]": -3.0723202608488163,
+ "max distortion [um]": 4.582841873168945,
+ "mean distortion [um]": 1.0106350183486938,
+ "beam_compression [no units]": 0.7641748785972595
+ },
+ "current_loss": 20688.484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 390,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.454364800662706,
+ "A2": 37.46614550336411,
+ "nd1": 1.5667376518249512,
+ "vd1": 56.001373291015625,
+ "nd2": 1.7569527626037598,
+ "vd2": 27.294641494750977,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5024579106153215,
+ "delta_alpha_c": 0.0,
+ "A3": 25.454364800662706,
+ "nd3": 1.5667376518249512,
+ "vd3": 56.001373291015625
+ },
+ "optical system values": {
+ "dispersion [um]": 988.3177490234375,
+ "deviation [deg]": -2.817948648231909,
+ "max distortion [um]": 4.620075225830078,
+ "mean distortion [um]": 1.014163851737976,
+ "beam_compression [no units]": 0.7639597654342651
+ },
+ "current_loss": 20633.06640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 400,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.466959669492212,
+ "A2": 37.48804308984317,
+ "nd1": 1.5667554140090942,
+ "vd1": 56.0003776550293,
+ "nd2": 1.7569173574447632,
+ "vd2": 27.299421310424805,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.535446016759191,
+ "delta_alpha_c": 0.0,
+ "A3": 25.466959669492212,
+ "nd3": 1.5667554140090942,
+ "vd3": 56.0003776550293
+ },
+ "optical system values": {
+ "dispersion [um]": 988.5653686523438,
+ "deviation [deg]": -2.8523866754705245,
+ "max distortion [um]": 4.5738630294799805,
+ "mean distortion [um]": 1.0151296854019165,
+ "beam_compression [no units]": 0.7636749148368835
+ },
+ "current_loss": 20596.96875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 410,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.48323430273706,
+ "A2": 37.5124063746126,
+ "nd1": 1.5667706727981567,
+ "vd1": 55.99938201904297,
+ "nd2": 1.7569034099578857,
+ "vd2": 27.304683685302734,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.549481628616744,
+ "delta_alpha_c": 0.0,
+ "A3": 25.48323430273706,
+ "nd3": 1.5667706727981567,
+ "vd3": 55.99938201904297
+ },
+ "optical system values": {
+ "dispersion [um]": 988.852294921875,
+ "deviation [deg]": -2.8126654969089038,
+ "max distortion [um]": 4.551174163818359,
+ "mean distortion [um]": 1.014139175415039,
+ "beam_compression [no units]": 0.7633456587791443
+ },
+ "current_loss": 20586.603515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 420,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.504722077865917,
+ "A2": 37.53766099906873,
+ "nd1": 1.5667734146118164,
+ "vd1": 55.998451232910156,
+ "nd2": 1.756915807723999,
+ "vd2": 27.31021499633789,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.500892516634919,
+ "delta_alpha_c": 0.0,
+ "A3": 25.504722077865917,
+ "nd3": 1.5667734146118164,
+ "vd3": 55.998451232910156
+ },
+ "optical system values": {
+ "dispersion [um]": 989.1029052734375,
+ "deviation [deg]": -2.5691536716289054,
+ "max distortion [um]": 4.6658453941345215,
+ "mean distortion [um]": 1.0183769464492798,
+ "beam_compression [no units]": 0.7629881501197815
+ },
+ "current_loss": 20618.4453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 430,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.52625766431897,
+ "A2": 37.566344378488196,
+ "nd1": 1.566785454750061,
+ "vd1": 55.99763488769531,
+ "nd2": 1.7569667100906372,
+ "vd2": 27.31578254699707,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.51479536669048,
+ "delta_alpha_c": 0.0,
+ "A3": 25.52625766431897,
+ "nd3": 1.566785454750061,
+ "vd3": 55.99763488769531
+ },
+ "optical system values": {
+ "dispersion [um]": 989.5922241210938,
+ "deviation [deg]": -2.5413684620852934,
+ "max distortion [um]": 4.67410135269165,
+ "mean distortion [um]": 1.0259065628051758,
+ "beam_compression [no units]": 0.7625744342803955
+ },
+ "current_loss": 20675.396484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 440,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.548404552702735,
+ "A2": 37.59737392788757,
+ "nd1": 1.5668096542358398,
+ "vd1": 55.99695587158203,
+ "nd2": 1.7569180727005005,
+ "vd2": 27.321142196655273,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.521840706819348,
+ "delta_alpha_c": 0.0,
+ "A3": 25.548404552702735,
+ "nd3": 1.5668096542358398,
+ "vd3": 55.99695587158203
+ },
+ "optical system values": {
+ "dispersion [um]": 989.918212890625,
+ "deviation [deg]": -2.3118469986595964,
+ "max distortion [um]": 4.676136493682861,
+ "mean distortion [um]": 1.022752046585083,
+ "beam_compression [no units]": 0.7621614336967468
+ },
+ "current_loss": 20612.79296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 450,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.567928648445218,
+ "A2": 37.6310296850228,
+ "nd1": 1.5668429136276245,
+ "vd1": 55.996395111083984,
+ "nd2": 1.7568936347961426,
+ "vd2": 27.326122283935547,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.595072287552933,
+ "delta_alpha_c": 0.0,
+ "A3": 25.567928648445218,
+ "nd3": 1.5668429136276245,
+ "vd3": 55.996395111083984
+ },
+ "optical system values": {
+ "dispersion [um]": 990.5572509765625,
+ "deviation [deg]": -2.4059644441014334,
+ "max distortion [um]": 4.56954288482666,
+ "mean distortion [um]": 1.0254584550857544,
+ "beam_compression [no units]": 0.7617102265357971
+ },
+ "current_loss": 20570.8359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 460,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.592657348335248,
+ "A2": 37.6596140266993,
+ "nd1": 1.5668236017227173,
+ "vd1": 55.99592208862305,
+ "nd2": 1.7569022178649902,
+ "vd2": 27.33059310913086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.562347997465755,
+ "delta_alpha_c": 0.0,
+ "A3": 25.592657348335248,
+ "nd3": 1.5668236017227173,
+ "vd3": 55.99592208862305
+ },
+ "optical system values": {
+ "dispersion [um]": 990.9791259765625,
+ "deviation [deg]": -2.1609849819235283,
+ "max distortion [um]": 4.639413356781006,
+ "mean distortion [um]": 1.0236672163009644,
+ "beam_compression [no units]": 0.7613087296485901
+ },
+ "current_loss": 20615.373046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 470,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.612567349765836,
+ "A2": 37.68884040615779,
+ "nd1": 1.5668420791625977,
+ "vd1": 55.9954833984375,
+ "nd2": 1.7569314241409302,
+ "vd2": 27.334489822387695,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.594128013900178,
+ "delta_alpha_c": 0.0,
+ "A3": 25.612567349765836,
+ "nd3": 1.5668420791625977,
+ "vd3": 55.9954833984375
+ },
+ "optical system values": {
+ "dispersion [um]": 991.6046752929688,
+ "deviation [deg]": -2.197086160225042,
+ "max distortion [um]": 4.590400695800781,
+ "mean distortion [um]": 1.0240486860275269,
+ "beam_compression [no units]": 0.7608950734138489
+ },
+ "current_loss": 20656.12109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 480,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.63566192689694,
+ "A2": 37.71140393608093,
+ "nd1": 1.5668210983276367,
+ "vd1": 55.99506759643555,
+ "nd2": 1.75696861743927,
+ "vd2": 27.337791442871094,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.508181609139792,
+ "delta_alpha_c": 0.0,
+ "A3": 25.63566192689694,
+ "nd3": 1.5668210983276367,
+ "vd3": 55.99506759643555
+ },
+ "optical system values": {
+ "dispersion [um]": 991.9318237304688,
+ "deviation [deg]": -1.8558368892430999,
+ "max distortion [um]": 4.785603046417236,
+ "mean distortion [um]": 1.0336451530456543,
+ "beam_compression [no units]": 0.7605578303337097
+ },
+ "current_loss": 20776.666015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 490,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.64655437107582,
+ "A2": 37.73710593792769,
+ "nd1": 1.5668729543685913,
+ "vd1": 55.99466323852539,
+ "nd2": 1.7569328546524048,
+ "vd2": 27.34056282043457,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.6044616632275845,
+ "delta_alpha_c": 0.0,
+ "A3": 25.64655437107582,
+ "nd3": 1.5668729543685913,
+ "vd3": 55.99466323852539
+ },
+ "optical system values": {
+ "dispersion [um]": 992.5169677734375,
+ "deviation [deg]": -2.073128898959889,
+ "max distortion [um]": 4.611535549163818,
+ "mean distortion [um]": 1.0318876504898071,
+ "beam_compression [no units]": 0.7602245807647705
+ },
+ "current_loss": 20667.404296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 500,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.66275045714521,
+ "A2": 37.7530236937884,
+ "nd1": 1.5668829679489136,
+ "vd1": 55.994327545166016,
+ "nd2": 1.7571768760681152,
+ "vd2": 27.342632293701172,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5456430623031965,
+ "delta_alpha_c": 0.0,
+ "A3": 25.66275045714521,
+ "nd3": 1.5668829679489136,
+ "vd3": 55.994327545166016
+ },
+ "optical system values": {
+ "dispersion [um]": 993.3123168945312,
+ "deviation [deg]": -2.2690930026630785,
+ "max distortion [um]": 4.723114490509033,
+ "mean distortion [um]": 1.0300663709640503,
+ "beam_compression [no units]": 0.7599111795425415
+ },
+ "current_loss": 21032.638671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 510,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.666034070588694,
+ "A2": 37.77287905370563,
+ "nd1": 1.5668742656707764,
+ "vd1": 55.99406814575195,
+ "nd2": 1.7571498155593872,
+ "vd2": 27.34383773803711,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.673200687034593,
+ "delta_alpha_c": 0.0,
+ "A3": 25.666034070588694,
+ "nd3": 1.5668742656707764,
+ "vd3": 55.99406814575195
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0594482421875,
+ "deviation [deg]": -2.9304591527783552,
+ "max distortion [um]": 4.470736026763916,
+ "mean distortion [um]": 1.0124491453170776,
+ "beam_compression [no units]": 0.7596608996391296
+ },
+ "current_loss": 21059.7890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 520,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.68092388297932,
+ "A2": 37.777933393691434,
+ "nd1": 1.5668915510177612,
+ "vd1": 55.993858337402344,
+ "nd2": 1.7518500089645386,
+ "vd2": 27.344972610473633,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.541653378054263,
+ "delta_alpha_c": 0.0,
+ "A3": 25.68092388297932,
+ "nd3": 1.5668915510177612,
+ "vd3": 55.993858337402344
+ },
+ "optical system values": {
+ "dispersion [um]": 979.725830078125,
+ "deviation [deg]": 10.214097965042495,
+ "max distortion [um]": 5.451061248779297,
+ "mean distortion [um]": 1.1929699182510376,
+ "beam_compression [no units]": 0.7613667249679565
+ },
+ "current_loss": 26700.904296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 530,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.656101267988205,
+ "A2": 37.80094430100521,
+ "nd1": 1.5680350065231323,
+ "vd1": 55.99382400512695,
+ "nd2": 1.7737277746200562,
+ "vd2": 27.280658721923828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.481627114307252,
+ "delta_alpha_c": 0.0,
+ "A3": 25.656101267988205,
+ "nd3": 1.5680350065231323,
+ "vd3": 55.99382400512695
+ },
+ "optical system values": {
+ "dispersion [um]": 1042.5635986328125,
+ "deviation [deg]": -39.98634528822083,
+ "max distortion [um]": 2.9382853507995605,
+ "mean distortion [um]": 0.5825880169868469,
+ "beam_compression [no units]": 0.7534803748130798
+ },
+ "current_loss": 1681366.75
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 540,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.644027201082913,
+ "A2": 37.6122398346161,
+ "nd1": 1.581474781036377,
+ "vd1": 55.981292724609375,
+ "nd2": 1.7677875757217407,
+ "vd2": 27.1127986907959,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.782691607637659,
+ "delta_alpha_c": 0.0,
+ "A3": 25.644027201082913,
+ "nd3": 1.581474781036377,
+ "vd3": 55.981292724609375
+ },
+ "optical system values": {
+ "dispersion [um]": 1005.2811279296875,
+ "deviation [deg]": 23.330674572598152,
+ "max distortion [um]": 6.072061538696289,
+ "mean distortion [um]": 1.4005300998687744,
+ "beam_compression [no units]": 0.756646990776062
+ },
+ "current_loss": 1543568.375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 550,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.10483499252918,
+ "A2": 37.75527424111992,
+ "nd1": 1.5782746076583862,
+ "vd1": 55.983638763427734,
+ "nd2": 1.7583742141723633,
+ "vd2": 27.003536224365234,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.818066011122801,
+ "delta_alpha_c": 0.0,
+ "A3": 25.10483499252918,
+ "nd3": 1.5782746076583862,
+ "vd3": 55.983638763427734
+ },
+ "optical system values": {
+ "dispersion [um]": 1020.1544799804688,
+ "deviation [deg]": -7.8684974521651645,
+ "max distortion [um]": 4.085507869720459,
+ "mean distortion [um]": 0.9043729305267334,
+ "beam_compression [no units]": 0.7587468028068542
+ },
+ "current_loss": 467492.90625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 560,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.983887168898992,
+ "A2": 36.3880445391072,
+ "nd1": 1.5701472759246826,
+ "vd1": 55.98970031738281,
+ "nd2": 1.7614399194717407,
+ "vd2": 26.956085205078125,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.302923866878404,
+ "delta_alpha_c": 0.0,
+ "A3": 25.983887168898992,
+ "nd3": 1.5701472759246826,
+ "vd3": 55.98970031738281
+ },
+ "optical system values": {
+ "dispersion [um]": 945.812744140625,
+ "deviation [deg]": 82.74201126599084,
+ "max distortion [um]": 19.419885635375977,
+ "mean distortion [um]": 5.4546403884887695,
+ "beam_compression [no units]": 0.7708035111427307
+ },
+ "current_loss": 47459.609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 570,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 25.07671510371624,
+ "A2": 36.85244959134388,
+ "nd1": 1.567124366760254,
+ "vd1": 55.97869110107422,
+ "nd2": 1.7623234987258911,
+ "vd2": 26.886655807495117,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.9333597187806895,
+ "delta_alpha_c": 0.0,
+ "A3": 25.07671510371624,
+ "nd3": 1.567124366760254,
+ "vd3": 55.97869110107422
+ },
+ "optical system values": {
+ "dispersion [um]": 1010.6492919921875,
+ "deviation [deg]": -10.947568928121715,
+ "max distortion [um]": 4.892678737640381,
+ "mean distortion [um]": 0.9287903904914856,
+ "beam_compression [no units]": 0.7702602744102478
+ },
+ "current_loss": 24253.580078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 580,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.778314384162137,
+ "A2": 36.80232624811974,
+ "nd1": 1.567675232887268,
+ "vd1": 55.993385314941406,
+ "nd2": 1.7628788948059082,
+ "vd2": 26.83204460144043,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.947951876587526,
+ "delta_alpha_c": 0.0,
+ "A3": 24.778314384162137,
+ "nd3": 1.567675232887268,
+ "vd3": 55.993385314941406
+ },
+ "optical system values": {
+ "dispersion [um]": 1022.6534423828125,
+ "deviation [deg]": -28.032733891585842,
+ "max distortion [um]": 3.418208122253418,
+ "mean distortion [um]": 0.6788540482521057,
+ "beam_compression [no units]": 0.7707670331001282
+ },
+ "current_loss": 24688.67578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 590,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.942008405357956,
+ "A2": 36.366491877181225,
+ "nd1": 1.5701868534088135,
+ "vd1": 56.00664520263672,
+ "nd2": 1.7615246772766113,
+ "vd2": 26.79477310180664,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.2439945877987535,
+ "delta_alpha_c": 0.0,
+ "A3": 24.942008405357956,
+ "nd3": 1.5701868534088135,
+ "vd3": 56.00664520263672
+ },
+ "optical system values": {
+ "dispersion [um]": 988.6600341796875,
+ "deviation [deg]": 13.542648930622931,
+ "max distortion [um]": 6.252706527709961,
+ "mean distortion [um]": 1.2737032175064087,
+ "beam_compression [no units]": 0.7764519453048706
+ },
+ "current_loss": 20937.83984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 600,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.87303374002458,
+ "A2": 36.21469092287769,
+ "nd1": 1.5687803030014038,
+ "vd1": 56.00685501098633,
+ "nd2": 1.7629239559173584,
+ "vd2": 26.770963668823242,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.065183650422405,
+ "delta_alpha_c": 0.0,
+ "A3": 24.87303374002458,
+ "nd3": 1.5687803030014038,
+ "vd3": 56.00685501098633
+ },
+ "optical system values": {
+ "dispersion [um]": 990.54296875,
+ "deviation [deg]": 8.631808657954524,
+ "max distortion [um]": 6.262302875518799,
+ "mean distortion [um]": 1.229844093322754,
+ "beam_compression [no units]": 0.7780309915542603
+ },
+ "current_loss": 20649.3203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 610,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.750909957664753,
+ "A2": 36.16875790070936,
+ "nd1": 1.566654920578003,
+ "vd1": 56.005550384521484,
+ "nd2": 1.7629330158233643,
+ "vd2": 26.75204086303711,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.7311228256304165,
+ "delta_alpha_c": 0.0,
+ "A3": 24.750909957664753,
+ "nd3": 1.566654920578003,
+ "vd3": 56.005550384521484
+ },
+ "optical system values": {
+ "dispersion [um]": 996.8292236328125,
+ "deviation [deg]": -3.727816503702702,
+ "max distortion [um]": 4.2066521644592285,
+ "mean distortion [um]": 1.0129090547561646,
+ "beam_compression [no units]": 0.7790936231613159
+ },
+ "current_loss": 21309.04296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 620,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.692557944038043,
+ "A2": 36.148619087941576,
+ "nd1": 1.567040205001831,
+ "vd1": 55.99013137817383,
+ "nd2": 1.7626503705978394,
+ "vd2": 26.73638153076172,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5210454166678655,
+ "delta_alpha_c": 0.0,
+ "A3": 24.692557944038043,
+ "nd3": 1.567040205001831,
+ "vd3": 55.99013137817383
+ },
+ "optical system values": {
+ "dispersion [um]": 997.240234375,
+ "deviation [deg]": -4.894795304534401,
+ "max distortion [um]": 4.369887828826904,
+ "mean distortion [um]": 0.9930426478385925,
+ "beam_compression [no units]": 0.7795013189315796
+ },
+ "current_loss": 20063.91796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 630,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.707485322469104,
+ "A2": 36.085955517401295,
+ "nd1": 1.5673378705978394,
+ "vd1": 55.984989166259766,
+ "nd2": 1.7629531621932983,
+ "vd2": 26.723800659179688,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.566909710057677,
+ "delta_alpha_c": 0.0,
+ "A3": 24.707485322469104,
+ "nd3": 1.5673378705978394,
+ "vd3": 55.984989166259766
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4110107421875,
+ "deviation [deg]": -0.8002923579158949,
+ "max distortion [um]": 4.606663227081299,
+ "mean distortion [um]": 1.0529526472091675,
+ "beam_compression [no units]": 0.7801207304000854
+ },
+ "current_loss": 19808.94921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 640,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.702528312678968,
+ "A2": 36.05539725105466,
+ "nd1": 1.566939353942871,
+ "vd1": 55.9892463684082,
+ "nd2": 1.7629814147949219,
+ "vd2": 26.71243667602539,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.461515195409326,
+ "delta_alpha_c": 0.0,
+ "A3": 24.702528312678968,
+ "nd3": 1.566939353942871,
+ "vd3": 55.9892463684082
+ },
+ "optical system values": {
+ "dispersion [um]": 994.575439453125,
+ "deviation [deg]": -0.9710148038502148,
+ "max distortion [um]": 4.788801193237305,
+ "mean distortion [um]": 1.05276620388031,
+ "beam_compression [no units]": 0.7805306911468506
+ },
+ "current_loss": 20175.201171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 650,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.681183971522678,
+ "A2": 36.044612382355204,
+ "nd1": 1.567095160484314,
+ "vd1": 55.99301528930664,
+ "nd2": 1.7629414796829224,
+ "vd2": 26.702199935913086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.407154146692018,
+ "delta_alpha_c": 0.0,
+ "A3": 24.681183971522678,
+ "nd3": 1.567095160484314,
+ "vd3": 55.99301528930664
+ },
+ "optical system values": {
+ "dispersion [um]": 995.1571655273438,
+ "deviation [deg]": -1.3440606331309763,
+ "max distortion [um]": 4.81472110748291,
+ "mean distortion [um]": 1.046362042427063,
+ "beam_compression [no units]": 0.7806869745254517
+ },
+ "current_loss": 19820.826171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 660,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.675642980558507,
+ "A2": 36.01296470083595,
+ "nd1": 1.5671381950378418,
+ "vd1": 55.99342727661133,
+ "nd2": 1.7630207538604736,
+ "vd2": 26.693159103393555,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.447030925500668,
+ "delta_alpha_c": 0.0,
+ "A3": 24.675642980558507,
+ "nd3": 1.5671381950378418,
+ "vd3": 55.99342727661133
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3851318359375,
+ "deviation [deg]": -0.30006072232667963,
+ "max distortion [um]": 4.842239856719971,
+ "mean distortion [um]": 1.0610973834991455,
+ "beam_compression [no units]": 0.7810502052307129
+ },
+ "current_loss": 19758.109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 670,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.658125252884716,
+ "A2": 35.99341669943137,
+ "nd1": 1.5670703649520874,
+ "vd1": 55.99245834350586,
+ "nd2": 1.7630443572998047,
+ "vd2": 26.684921264648438,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.455006025130304,
+ "delta_alpha_c": 0.0,
+ "A3": 24.658125252884716,
+ "nd3": 1.5670703649520874,
+ "vd3": 55.99245834350586
+ },
+ "optical system values": {
+ "dispersion [um]": 994.673095703125,
+ "deviation [deg]": -0.8158481671114518,
+ "max distortion [um]": 4.786591053009033,
+ "mean distortion [um]": 1.054877519607544,
+ "beam_compression [no units]": 0.7813110947608948
+ },
+ "current_loss": 19797.783203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 680,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.637279515537838,
+ "A2": 35.979889509780165,
+ "nd1": 1.5671155452728271,
+ "vd1": 55.99161911010742,
+ "nd2": 1.7630512714385986,
+ "vd2": 26.67742919921875,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.461598011453013,
+ "delta_alpha_c": 0.0,
+ "A3": 24.637279515537838,
+ "nd3": 1.5671155452728271,
+ "vd3": 55.99161911010742
+ },
+ "optical system values": {
+ "dispersion [um]": 995.0908203125,
+ "deviation [deg]": -1.457353834667624,
+ "max distortion [um]": 4.698612213134766,
+ "mean distortion [um]": 1.0413607358932495,
+ "beam_compression [no units]": 0.7814980149269104
+ },
+ "current_loss": 19686.14453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 690,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.627322807275252,
+ "A2": 35.9565131873458,
+ "nd1": 1.567126989364624,
+ "vd1": 55.991580963134766,
+ "nd2": 1.7630786895751953,
+ "vd2": 26.670663833618164,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.5407914935583715,
+ "delta_alpha_c": 0.0,
+ "A3": 24.627322807275252,
+ "nd3": 1.567126989364624,
+ "vd3": 55.991580963134766
+ },
+ "optical system values": {
+ "dispersion [um]": 994.6749267578125,
+ "deviation [deg]": -1.0667955070766557,
+ "max distortion [um]": 4.609322547912598,
+ "mean distortion [um]": 1.0476340055465698,
+ "beam_compression [no units]": 0.7817814350128174
+ },
+ "current_loss": 19677.798828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 700,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.608486853091648,
+ "A2": 35.94707386591284,
+ "nd1": 1.5671207904815674,
+ "vd1": 55.9919319152832,
+ "nd2": 1.7630945444107056,
+ "vd2": 26.664514541625977,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.558585417006724,
+ "delta_alpha_c": 0.0,
+ "A3": 24.608486853091648,
+ "nd3": 1.5671207904815674,
+ "vd3": 55.9919319152832
+ },
+ "optical system values": {
+ "dispersion [um]": 995.3013305664062,
+ "deviation [deg]": -1.9361594869956267,
+ "max distortion [um]": 4.491276741027832,
+ "mean distortion [um]": 1.0349409580230713,
+ "beam_compression [no units]": 0.7819142937660217
+ },
+ "current_loss": 19680.69140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 710,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.607489645472825,
+ "A2": 35.92470841147563,
+ "nd1": 1.5671364068984985,
+ "vd1": 55.99205780029297,
+ "nd2": 1.7631031274795532,
+ "vd2": 26.658946990966797,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.42823509867844,
+ "delta_alpha_c": 0.0,
+ "A3": 24.607489645472825,
+ "nd3": 1.5671364068984985,
+ "vd3": 55.99205780029297
+ },
+ "optical system values": {
+ "dispersion [um]": 994.5517578125,
+ "deviation [deg]": -0.9435231857192077,
+ "max distortion [um]": 4.789769172668457,
+ "mean distortion [um]": 1.0554641485214233,
+ "beam_compression [no units]": 0.7821877598762512
+ },
+ "current_loss": 19603.875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 720,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.600883144998132,
+ "A2": 35.908455976345586,
+ "nd1": 1.5671459436416626,
+ "vd1": 55.992027282714844,
+ "nd2": 1.76311457157135,
+ "vd2": 26.6539306640625,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.4343425684569,
+ "delta_alpha_c": 0.0,
+ "A3": 24.600883144998132,
+ "nd3": 1.5671459436416626,
+ "vd3": 55.992027282714844
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2606201171875,
+ "deviation [deg]": -0.628787161630521,
+ "max distortion [um]": 4.800381183624268,
+ "mean distortion [um]": 1.0543217658996582,
+ "beam_compression [no units]": 0.7823886275291443
+ },
+ "current_loss": 19577.8046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 730,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.592111474556543,
+ "A2": 35.898145805793455,
+ "nd1": 1.5671509504318237,
+ "vd1": 55.99199295043945,
+ "nd2": 1.7631231546401978,
+ "vd2": 26.6494197845459,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.377774514864031,
+ "delta_alpha_c": 0.0,
+ "A3": 24.592111474556543,
+ "nd3": 1.5671509504318237,
+ "vd3": 55.99199295043945
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3363647460938,
+ "deviation [deg]": -0.7401236740525188,
+ "max distortion [um]": 4.8758769035339355,
+ "mean distortion [um]": 1.053671956062317,
+ "beam_compression [no units]": 0.782519519329071
+ },
+ "current_loss": 19579.0078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 740,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.59113475750523,
+ "A2": 35.88115229513846,
+ "nd1": 1.5671594142913818,
+ "vd1": 55.991920471191406,
+ "nd2": 1.7631282806396484,
+ "vd2": 26.645387649536133,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3636962143241655,
+ "delta_alpha_c": 0.0,
+ "A3": 24.59113475750523,
+ "nd3": 1.5671594142913818,
+ "vd3": 55.991920471191406
+ },
+ "optical system values": {
+ "dispersion [um]": 993.7376098632812,
+ "deviation [deg]": -0.00723980875464844,
+ "max distortion [um]": 4.959170818328857,
+ "mean distortion [um]": 1.0686713457107544,
+ "beam_compression [no units]": 0.782720685005188
+ },
+ "current_loss": 19570.705078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 750,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.58568255900027,
+ "A2": 35.87141927557119,
+ "nd1": 1.56716787815094,
+ "vd1": 55.991920471191406,
+ "nd2": 1.7631326913833618,
+ "vd2": 26.64179801940918,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.326790140917648,
+ "delta_alpha_c": 0.0,
+ "A3": 24.58568255900027,
+ "nd3": 1.56716787815094,
+ "vd3": 55.991920471191406
+ },
+ "optical system values": {
+ "dispersion [um]": 993.6646118164062,
+ "deviation [deg]": 0.09538936807155349,
+ "max distortion [um]": 5.024023532867432,
+ "mean distortion [um]": 1.0659704208374023,
+ "beam_compression [no units]": 0.7828391194343567
+ },
+ "current_loss": 19566.4765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 760,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.567953095462208,
+ "A2": 35.87243697375752,
+ "nd1": 1.5671736001968384,
+ "vd1": 55.99192810058594,
+ "nd2": 1.7631369829177856,
+ "vd2": 26.638628005981445,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.490035077175538,
+ "delta_alpha_c": 0.0,
+ "A3": 24.567953095462208,
+ "nd3": 1.5671736001968384,
+ "vd3": 55.99192810058594
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4921875,
+ "deviation [deg]": -1.1228551384631815,
+ "max distortion [um]": 4.662271976470947,
+ "mean distortion [um]": 1.04716956615448,
+ "beam_compression [no units]": 0.7828584909439087
+ },
+ "current_loss": 19515.880859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 770,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.56183666106046,
+ "A2": 35.8666347280576,
+ "nd1": 1.5671805143356323,
+ "vd1": 55.99192810058594,
+ "nd2": 1.763139009475708,
+ "vd2": 26.63585090637207,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.478729406551874,
+ "delta_alpha_c": 0.0,
+ "A3": 24.56183666106046,
+ "nd3": 1.5671805143356323,
+ "vd3": 55.99192810058594
+ },
+ "optical system values": {
+ "dispersion [um]": 994.577392578125,
+ "deviation [deg]": -1.2461275665423353,
+ "max distortion [um]": 4.648731231689453,
+ "mean distortion [um]": 1.0413703918457031,
+ "beam_compression [no units]": 0.7829359173774719
+ },
+ "current_loss": 19500.974609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 780,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.56178714218898,
+ "A2": 35.85753008589397,
+ "nd1": 1.5671879053115845,
+ "vd1": 55.99191665649414,
+ "nd2": 1.763139247894287,
+ "vd2": 26.63344383239746,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.400704740568234,
+ "delta_alpha_c": 0.0,
+ "A3": 24.56178714218898,
+ "nd3": 1.5671879053115845,
+ "vd3": 55.99191665649414
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2562255859375,
+ "deviation [deg]": -0.808608326673797,
+ "max distortion [um]": 4.809816837310791,
+ "mean distortion [um]": 1.0536881685256958,
+ "beam_compression [no units]": 0.7830447554588318
+ },
+ "current_loss": 19489.82421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 790,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.555686075712863,
+ "A2": 35.85373933090462,
+ "nd1": 1.5671944618225098,
+ "vd1": 55.99190139770508,
+ "nd2": 1.763139247894287,
+ "vd2": 26.63138198852539,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.45820255366187,
+ "delta_alpha_c": 0.0,
+ "A3": 24.555686075712863,
+ "nd3": 1.5671944618225098,
+ "vd3": 55.99190139770508
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3857421875,
+ "deviation [deg]": -1.0193454358606366,
+ "max distortion [um]": 4.7033820152282715,
+ "mean distortion [um]": 1.0496777296066284,
+ "beam_compression [no units]": 0.7830989956855774
+ },
+ "current_loss": 19471.28515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 800,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.553964868042023,
+ "A2": 35.84883183998596,
+ "nd1": 1.567200779914856,
+ "vd1": 55.99190139770508,
+ "nd2": 1.7631381750106812,
+ "vd2": 26.629638671875,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.411477656436636,
+ "delta_alpha_c": 0.0,
+ "A3": 24.553964868042023,
+ "nd3": 1.567200779914856,
+ "vd3": 55.99190139770508
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3052978515625,
+ "deviation [deg]": -0.8866808573424806,
+ "max distortion [um]": 4.779542446136475,
+ "mean distortion [um]": 1.0511364936828613,
+ "beam_compression [no units]": 0.7831599712371826
+ },
+ "current_loss": 19466.541015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 810,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.550128009275767,
+ "A2": 35.846441273776456,
+ "nd1": 1.5672069787979126,
+ "vd1": 55.991886138916016,
+ "nd2": 1.763136625289917,
+ "vd2": 26.628189086914062,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.413357239118859,
+ "delta_alpha_c": 0.0,
+ "A3": 24.550128009275767,
+ "nd3": 1.5672069787979126,
+ "vd3": 55.991886138916016
+ },
+ "optical system values": {
+ "dispersion [um]": 994.39453125,
+ "deviation [deg]": -1.0096598007307354,
+ "max distortion [um]": 4.767237663269043,
+ "mean distortion [um]": 1.0496538877487183,
+ "beam_compression [no units]": 0.7831940650939941
+ },
+ "current_loss": 19457.6796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 820,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54942108469667,
+ "A2": 35.84211434893725,
+ "nd1": 1.567212700843811,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763134241104126,
+ "vd2": 26.627010345458984,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.407284347173071,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54942108469667,
+ "nd3": 1.567212700843811,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.25146484375,
+ "deviation [deg]": -0.8349260060412081,
+ "max distortion [um]": 4.788493633270264,
+ "mean distortion [um]": 1.0526090860366821,
+ "beam_compression [no units]": 0.7832470536231995
+ },
+ "current_loss": 19456.14453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 830,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.545994037280618,
+ "A2": 35.84122642434515,
+ "nd1": 1.5672179460525513,
+ "vd1": 55.991859436035156,
+ "nd2": 1.7631317377090454,
+ "vd2": 26.626073837280273,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.426723919324574,
+ "delta_alpha_c": 0.0,
+ "A3": 24.545994037280618,
+ "nd3": 1.5672179460525513,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.36328125,
+ "deviation [deg]": -1.0011481043644301,
+ "max distortion [um]": 4.743048191070557,
+ "mean distortion [um]": 1.0486458539962769,
+ "beam_compression [no units]": 0.7832632660865784
+ },
+ "current_loss": 19443.91015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 840,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54307754650502,
+ "A2": 35.84075514129242,
+ "nd1": 1.5672229528427124,
+ "vd1": 55.991859436035156,
+ "nd2": 1.7631289958953857,
+ "vd2": 26.625356674194336,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.447807432631934,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54307754650502,
+ "nd3": 1.5672229528427124,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4608154296875,
+ "deviation [deg]": -1.152107878182994,
+ "max distortion [um]": 4.694158554077148,
+ "mean distortion [um]": 1.046212911605835,
+ "beam_compression [no units]": 0.7832733392715454
+ },
+ "current_loss": 19444.96875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 850,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.5423074426761,
+ "A2": 35.83939934874217,
+ "nd1": 1.5672272443771362,
+ "vd1": 55.991859436035156,
+ "nd2": 1.7631261348724365,
+ "vd2": 26.624832153320312,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.442568677538534,
+ "delta_alpha_c": 0.0,
+ "A3": 24.5423074426761,
+ "nd3": 1.5672272443771362,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4285888671875,
+ "deviation [deg]": -1.1216810929778798,
+ "max distortion [um]": 4.714298725128174,
+ "mean distortion [um]": 1.0434184074401855,
+ "beam_compression [no units]": 0.7832912802696228
+ },
+ "current_loss": 19443.1953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 860,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.541971055859477,
+ "A2": 35.838344084515406,
+ "nd1": 1.5672309398651123,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763123631477356,
+ "vd2": 26.624473571777344,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.436018953011315,
+ "delta_alpha_c": 0.0,
+ "A3": 24.541971055859477,
+ "nd3": 1.5672309398651123,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4022216796875,
+ "deviation [deg]": -1.078633612290463,
+ "max distortion [um]": 4.720553874969482,
+ "mean distortion [um]": 1.0459576845169067,
+ "beam_compression [no units]": 0.7833048105239868
+ },
+ "current_loss": 19442.400390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 870,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.541726876596652,
+ "A2": 35.837725952395516,
+ "nd1": 1.567233681678772,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763121247291565,
+ "vd2": 26.624248504638672,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.432428407942004,
+ "delta_alpha_c": 0.0,
+ "A3": 24.541726876596652,
+ "nd3": 1.567233681678772,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3878784179688,
+ "deviation [deg]": -1.053685599295051,
+ "max distortion [um]": 4.735516548156738,
+ "mean distortion [um]": 1.0482102632522583,
+ "beam_compression [no units]": 0.7833130359649658
+ },
+ "current_loss": 19445.4296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 880,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54146220676631,
+ "A2": 35.83750055615291,
+ "nd1": 1.5672354698181152,
+ "vd1": 55.991859436035156,
+ "nd2": 1.7631198167800903,
+ "vd2": 26.62413215637207,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.432451459830453,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54146220676631,
+ "nd3": 1.5672354698181152,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.380615234375,
+ "deviation [deg]": -1.0520224482321527,
+ "max distortion [um]": 4.7292280197143555,
+ "mean distortion [um]": 1.0505719184875488,
+ "beam_compression [no units]": 0.783316433429718
+ },
+ "current_loss": 19452.326171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 890,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54146220676631,
+ "A2": 35.837343461802,
+ "nd1": 1.5672365427017212,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763118863105774,
+ "vd2": 26.624088287353516,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.430769098860514,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54146220676631,
+ "nd3": 1.5672365427017212,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.371826171875,
+ "deviation [deg]": -1.0391081613372453,
+ "max distortion [um]": 4.73596715927124,
+ "mean distortion [um]": 1.046816349029541,
+ "beam_compression [no units]": 0.7833186388015747
+ },
+ "current_loss": 19460.5546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 900,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54141439544212,
+ "A2": 35.83735029199117,
+ "nd1": 1.5672365427017212,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763118863105774,
+ "vd2": 26.624080657958984,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.431199400778225,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54141439544212,
+ "nd3": 1.5672365427017212,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3768310546875,
+ "deviation [deg]": -1.0430215395665452,
+ "max distortion [um]": 4.73019552230835,
+ "mean distortion [um]": 1.0470854043960571,
+ "beam_compression [no units]": 0.7833184599876404
+ },
+ "current_loss": 19472.04296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 910,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.541402442611076,
+ "A2": 35.83733663161283,
+ "nd1": 1.5672365427017212,
+ "vd1": 55.991859436035156,
+ "nd2": 1.763118863105774,
+ "vd2": 26.624074935913086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.431151162567212,
+ "delta_alpha_c": 0.0,
+ "A3": 24.541402442611076,
+ "nd3": 1.5672365427017212,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3616943359375,
+ "deviation [deg]": -1.0437064794742505,
+ "max distortion [um]": 4.743982315063477,
+ "mean distortion [um]": 1.0444271564483643,
+ "beam_compression [no units]": 0.7833187580108643
+ },
+ "current_loss": 19483.9296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 920,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.541294867131647,
+ "A2": 35.8372751599103,
+ "nd1": 1.567238211631775,
+ "vd1": 55.991859436035156,
+ "nd2": 1.7631173133850098,
+ "vd2": 26.624032974243164,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.431204523420102,
+ "delta_alpha_c": 0.0,
+ "A3": 24.541294867131647,
+ "nd3": 1.567238211631775,
+ "vd3": 55.991859436035156
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3684692382812,
+ "deviation [deg]": -1.0385211919554473,
+ "max distortion [um]": 4.731646537780762,
+ "mean distortion [um]": 1.0483157634735107,
+ "beam_compression [no units]": 0.7833199501037598
+ },
+ "current_loss": 19490.5546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 930,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.54099604635546,
+ "A2": 35.837104405181044,
+ "nd1": 1.567243218421936,
+ "vd1": 55.99184799194336,
+ "nd2": 1.7631126642227173,
+ "vd2": 26.623916625976562,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.431123841810532,
+ "delta_alpha_c": 0.0,
+ "A3": 24.54099604635546,
+ "nd3": 1.567243218421936,
+ "vd3": 55.99184799194336
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3729248046875,
+ "deviation [deg]": -1.0259982535556404,
+ "max distortion [um]": 4.721521377563477,
+ "mean distortion [um]": 1.0477383136749268,
+ "beam_compression [no units]": 0.783323347568512
+ },
+ "current_loss": 19489.005859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 940,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.540140565161916,
+ "A2": 35.836988291965156,
+ "nd1": 1.5672533512115479,
+ "vd1": 55.9918098449707,
+ "nd2": 1.7631032466888428,
+ "vd2": 26.623682022094727,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.433914400973305,
+ "delta_alpha_c": 0.0,
+ "A3": 24.540140565161916,
+ "nd3": 1.5672533512115479,
+ "vd3": 55.9918098449707
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3631591796875,
+ "deviation [deg]": -1.0278571322269419,
+ "max distortion [um]": 4.724874019622803,
+ "mean distortion [um]": 1.0500599145889282,
+ "beam_compression [no units]": 0.7833276987075806
+ },
+ "current_loss": 19475.5859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 950,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.539008461306985,
+ "A2": 35.836650197601244,
+ "nd1": 1.5672687292099,
+ "vd1": 55.99177169799805,
+ "nd2": 1.7630889415740967,
+ "vd2": 26.623291015625,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.4315887215609155,
+ "delta_alpha_c": 0.0,
+ "A3": 24.539008461306985,
+ "nd3": 1.5672687292099,
+ "vd3": 55.99177169799805
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3438110351562,
+ "deviation [deg]": -1.0102467701125333,
+ "max distortion [um]": 4.723214149475098,
+ "mean distortion [um]": 1.0468504428863525,
+ "beam_compression [no units]": 0.7833362817764282
+ },
+ "current_loss": 19446.365234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 960,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.537106253623136,
+ "A2": 35.83635649946693,
+ "nd1": 1.5672870874404907,
+ "vd1": 55.99171447753906,
+ "nd2": 1.7630723714828491,
+ "vd2": 26.622709274291992,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.428756327489476,
+ "delta_alpha_c": 0.0,
+ "A3": 24.537106253623136,
+ "nd3": 1.5672870874404907,
+ "vd3": 55.99171447753906
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3712158203125,
+ "deviation [deg]": -1.0321618589513424,
+ "max distortion [um]": 4.713298320770264,
+ "mean distortion [um]": 1.0459994077682495,
+ "beam_compression [no units]": 0.7833457589149475
+ },
+ "current_loss": 19409.66015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 970,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.534934253467075,
+ "A2": 35.83550272582068,
+ "nd1": 1.5673032999038696,
+ "vd1": 55.99166488647461,
+ "nd2": 1.7630587816238403,
+ "vd2": 26.621915817260742,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.422437975620391,
+ "delta_alpha_c": 0.0,
+ "A3": 24.534934253467075,
+ "nd3": 1.5673032999038696,
+ "vd3": 55.99166488647461
+ },
+ "optical system values": {
+ "dispersion [um]": 994.374267578125,
+ "deviation [deg]": -1.0598492046907526,
+ "max distortion [um]": 4.731404781341553,
+ "mean distortion [um]": 1.044187307357788,
+ "beam_compression [no units]": 0.7833616137504578
+ },
+ "current_loss": 19380.078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 980,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.532191932515314,
+ "A2": 35.83389763136573,
+ "nd1": 1.5673130750656128,
+ "vd1": 55.99162673950195,
+ "nd2": 1.7630527019500732,
+ "vd2": 26.620878219604492,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.430298242694606,
+ "delta_alpha_c": 0.0,
+ "A3": 24.532191932515314,
+ "nd3": 1.5673130750656128,
+ "vd3": 55.99162673950195
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4306640625,
+ "deviation [deg]": -1.126083683506482,
+ "max distortion [um]": 4.707043170928955,
+ "mean distortion [um]": 1.0445152521133423,
+ "beam_compression [no units]": 0.7833858728408813
+ },
+ "current_loss": 19365.13671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 990,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.531148621119595,
+ "A2": 35.82983366880957,
+ "nd1": 1.5673166513442993,
+ "vd1": 55.9915885925293,
+ "nd2": 1.763053059577942,
+ "vd2": 26.61956787109375,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.415157847738803,
+ "delta_alpha_c": 0.0,
+ "A3": 24.531148621119595,
+ "nd3": 1.5673166513442993,
+ "vd3": 55.9915885925293
+ },
+ "optical system values": {
+ "dispersion [um]": 994.340087890625,
+ "deviation [deg]": -0.9976260746302307,
+ "max distortion [um]": 4.738935947418213,
+ "mean distortion [um]": 1.0479211807250977,
+ "beam_compression [no units]": 0.783435583114624
+ },
+ "current_loss": 19362.9765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1000,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.52772840389271,
+ "A2": 35.82632295157618,
+ "nd1": 1.5673190355300903,
+ "vd1": 55.9915657043457,
+ "nd2": 1.7630552053451538,
+ "vd2": 26.617958068847656,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.429425259141314,
+ "delta_alpha_c": 0.0,
+ "A3": 24.52772840389271,
+ "nd3": 1.5673190355300903,
+ "vd3": 55.9915657043457
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3619384765625,
+ "deviation [deg]": -1.061414598671155,
+ "max distortion [um]": 4.717684745788574,
+ "mean distortion [um]": 1.0472619533538818,
+ "beam_compression [no units]": 0.7834816575050354
+ },
+ "current_loss": 19360.28515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1010,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.52613184717422,
+ "A2": 35.82056168701128,
+ "nd1": 1.5673245191574097,
+ "vd1": 55.991546630859375,
+ "nd2": 1.763055443763733,
+ "vd2": 26.61603546142578,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.395956051547782,
+ "delta_alpha_c": 0.0,
+ "A3": 24.52613184717422,
+ "nd3": 1.5673245191574097,
+ "vd3": 55.991546630859375
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2559204101562,
+ "deviation [deg]": -0.8857024861047291,
+ "max distortion [um]": 4.781026840209961,
+ "mean distortion [um]": 1.0505439043045044,
+ "beam_compression [no units]": 0.7835520505905151
+ },
+ "current_loss": 19359.044921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1020,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.520467912804985,
+ "A2": 35.81638502633381,
+ "nd1": 1.5673309564590454,
+ "vd1": 55.991546630859375,
+ "nd2": 1.763055682182312,
+ "vd2": 26.613788604736328,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.417407114409854,
+ "delta_alpha_c": 0.0,
+ "A3": 24.520467912804985,
+ "nd3": 1.5673309564590454,
+ "vd3": 55.991546630859375
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3529052734375,
+ "deviation [deg]": -1.05114188743775,
+ "max distortion [um]": 4.731404781341553,
+ "mean distortion [um]": 1.04362154006958,
+ "beam_compression [no units]": 0.783609926700592
+ },
+ "current_loss": 19336.583984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1030,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.51901820515365,
+ "A2": 35.807594572872006,
+ "nd1": 1.5673362016677856,
+ "vd1": 55.99153137207031,
+ "nd2": 1.7630575895309448,
+ "vd2": 26.611225128173828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.384397663924828,
+ "delta_alpha_c": 0.0,
+ "A3": 24.51901820515365,
+ "nd3": 1.5673362016677856,
+ "vd3": 55.99153137207031
+ },
+ "optical system values": {
+ "dispersion [um]": 994.120849609375,
+ "deviation [deg]": -0.7317098414904151,
+ "max distortion [um]": 4.801590919494629,
+ "mean distortion [um]": 1.0507992506027222,
+ "beam_compression [no units]": 0.7837156057357788
+ },
+ "current_loss": 19339.978515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1040,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.513277431156254,
+ "A2": 35.800798534647846,
+ "nd1": 1.5673407316207886,
+ "vd1": 55.99151611328125,
+ "nd2": 1.7630608081817627,
+ "vd2": 26.608354568481445,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.395087763749545,
+ "delta_alpha_c": 0.0,
+ "A3": 24.513277431156254,
+ "nd3": 1.5673407316207886,
+ "vd3": 55.99151611328125
+ },
+ "optical system values": {
+ "dispersion [um]": 994.1361083984375,
+ "deviation [deg]": -0.7938352144684412,
+ "max distortion [um]": 4.784622669219971,
+ "mean distortion [um]": 1.0486901998519897,
+ "beam_compression [no units]": 0.783804178237915
+ },
+ "current_loss": 19324.583984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1050,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.50499241169303,
+ "A2": 35.79554270408152,
+ "nd1": 1.5673458576202393,
+ "vd1": 55.99151611328125,
+ "nd2": 1.7630643844604492,
+ "vd2": 26.605188369750977,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.39569223549109,
+ "delta_alpha_c": 0.0,
+ "A3": 24.50499241169303,
+ "nd3": 1.5673458576202393,
+ "vd3": 55.99151611328125
+ },
+ "optical system values": {
+ "dispersion [um]": 994.360107421875,
+ "deviation [deg]": -1.0945807166202675,
+ "max distortion [um]": 4.7486114501953125,
+ "mean distortion [um]": 1.044543743133545,
+ "beam_compression [no units]": 0.7838775515556335
+ },
+ "current_loss": 19308.572265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1060,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.500487901935408,
+ "A2": 35.78535889202903,
+ "nd1": 1.5673508644104004,
+ "vd1": 55.99150085449219,
+ "nd2": 1.7630683183670044,
+ "vd2": 26.60175132751465,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.385611730049798,
+ "delta_alpha_c": 0.0,
+ "A3": 24.500487901935408,
+ "nd3": 1.5673508644104004,
+ "vd3": 55.99150085449219
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2235107421875,
+ "deviation [deg]": -0.918477308919594,
+ "max distortion [um]": 4.778332710266113,
+ "mean distortion [um]": 1.047347903251648,
+ "beam_compression [no units]": 0.7840040922164917
+ },
+ "current_loss": 19300.23046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1070,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.493693571258536,
+ "A2": 35.77560538189425,
+ "nd1": 1.567355751991272,
+ "vd1": 55.99148941040039,
+ "nd2": 1.7630727291107178,
+ "vd2": 26.598073959350586,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.408659776517183,
+ "delta_alpha_c": 0.0,
+ "A3": 24.493693571258536,
+ "nd3": 1.567355751991272,
+ "vd3": 55.99148941040039
+ },
+ "optical system values": {
+ "dispersion [um]": 994.156005859375,
+ "deviation [deg]": -0.9153466276804952,
+ "max distortion [um]": 4.739903450012207,
+ "mean distortion [um]": 1.0482254028320312,
+ "beam_compression [no units]": 0.78412926197052
+ },
+ "current_loss": 19278.453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1080,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.48870411806984,
+ "A2": 35.76485124904607,
+ "nd1": 1.567360758781433,
+ "vd1": 55.99150085449219,
+ "nd2": 1.763076901435852,
+ "vd2": 26.594194412231445,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.363571563371813,
+ "delta_alpha_c": 0.0,
+ "A3": 24.48870411806984,
+ "nd3": 1.567360758781433,
+ "vd3": 55.99150085449219
+ },
+ "optical system values": {
+ "dispersion [um]": 994.036376953125,
+ "deviation [deg]": -0.74589593095312,
+ "max distortion [um]": 4.820188045501709,
+ "mean distortion [um]": 1.0492669343948364,
+ "beam_compression [no units]": 0.7842621803283691
+ },
+ "current_loss": 19282.24609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1090,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.46966496575843,
+ "A2": 35.764779532059784,
+ "nd1": 1.5673644542694092,
+ "vd1": 55.99152374267578,
+ "nd2": 1.7630823850631714,
+ "vd2": 26.590150833129883,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.455767164335938,
+ "delta_alpha_c": 0.0,
+ "A3": 24.46966496575843,
+ "nd3": 1.5673644542694092,
+ "vd3": 55.99152374267578
+ },
+ "optical system values": {
+ "dispersion [um]": 994.9451904296875,
+ "deviation [deg]": -2.008753298815461,
+ "max distortion [um]": 4.570437908172607,
+ "mean distortion [um]": 1.0307327508926392,
+ "beam_compression [no units]": 0.7842870950698853
+ },
+ "current_loss": 19276.625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1100,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.473624767929746,
+ "A2": 35.74470219099453,
+ "nd1": 1.5673701763153076,
+ "vd1": 55.991493225097656,
+ "nd2": 1.7630856037139893,
+ "vd2": 26.585987091064453,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3471534961543945,
+ "delta_alpha_c": 0.0,
+ "A3": 24.473624767929746,
+ "nd3": 1.5673701763153076,
+ "vd3": 55.991493225097656
+ },
+ "optical system values": {
+ "dispersion [um]": 994.063232421875,
+ "deviation [deg]": -0.810565015788447,
+ "max distortion [um]": 4.826753616333008,
+ "mean distortion [um]": 1.048498511314392,
+ "beam_compression [no units]": 0.7845205068588257
+ },
+ "current_loss": 19259.826171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1110,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.45984656882654,
+ "A2": 35.73660500173348,
+ "nd1": 1.5673737525939941,
+ "vd1": 55.99146270751953,
+ "nd2": 1.7630901336669922,
+ "vd2": 26.58174705505371,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.496889598894469,
+ "delta_alpha_c": 0.0,
+ "A3": 24.45984656882654,
+ "nd3": 1.5673737525939941,
+ "vd3": 55.99146270751953
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3284301757812,
+ "deviation [deg]": -1.3519853601154836,
+ "max distortion [um]": 4.549030780792236,
+ "mean distortion [um]": 1.0382682085037231,
+ "beam_compression [no units]": 0.7846325039863586
+ },
+ "current_loss": 19258.865234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1120,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.45288319096771,
+ "A2": 35.72646217081601,
+ "nd1": 1.5673788785934448,
+ "vd1": 55.991485595703125,
+ "nd2": 1.7630935907363892,
+ "vd2": 26.577468872070312,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.441337962827463,
+ "delta_alpha_c": 0.0,
+ "A3": 24.45288319096771,
+ "nd3": 1.5673788785934448,
+ "vd3": 55.991485595703125
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3353271484375,
+ "deviation [deg]": -1.340049391097475,
+ "max distortion [um]": 4.633672714233398,
+ "mean distortion [um]": 1.0371065139770508,
+ "beam_compression [no units]": 0.7847657799720764
+ },
+ "current_loss": 19227.658203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1130,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.464313512543725,
+ "A2": 35.69912092356845,
+ "nd1": 1.5673843622207642,
+ "vd1": 55.991455078125,
+ "nd2": 1.7630949020385742,
+ "vd2": 26.57320213317871,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.313177147014989,
+ "delta_alpha_c": 0.0,
+ "A3": 24.464313512543725,
+ "nd3": 1.5673843622207642,
+ "vd3": 55.991455078125
+ },
+ "optical system values": {
+ "dispersion [um]": 992.82080078125,
+ "deviation [deg]": 0.6938475949609485,
+ "max distortion [um]": 5.001622676849365,
+ "mean distortion [um]": 1.0727025270462036,
+ "beam_compression [no units]": 0.785069465637207
+ },
+ "current_loss": 19252.984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1140,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.441671435445134,
+ "A2": 35.699906395323005,
+ "nd1": 1.567387342453003,
+ "vd1": 55.991424560546875,
+ "nd2": 1.7630985975265503,
+ "vd2": 26.568981170654297,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.46630785377256,
+ "delta_alpha_c": 0.0,
+ "A3": 24.441671435445134,
+ "nd3": 1.567387342453003,
+ "vd3": 55.991424560546875
+ },
+ "optical system values": {
+ "dispersion [um]": 993.8828125,
+ "deviation [deg]": -0.8472532701934646,
+ "max distortion [um]": 4.621757984161377,
+ "mean distortion [um]": 1.045655369758606,
+ "beam_compression [no units]": 0.7850956916809082
+ },
+ "current_loss": 19210.80078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1150,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.417449877100978,
+ "A2": 35.70598184858973,
+ "nd1": 1.567391276359558,
+ "vd1": 55.99150085449219,
+ "nd2": 1.7631014585494995,
+ "vd2": 26.564836502075195,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.516613477670173,
+ "delta_alpha_c": 0.0,
+ "A3": 24.417449877100978,
+ "nd3": 1.567391276359558,
+ "vd3": 55.99150085449219
+ },
+ "optical system values": {
+ "dispersion [um]": 995.308349609375,
+ "deviation [deg]": -2.731462231640269,
+ "max distortion [um]": 4.386504173278809,
+ "mean distortion [um]": 1.0170490741729736,
+ "beam_compression [no units]": 0.7850466966629028
+ },
+ "current_loss": 19239.72265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1160,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.41690175442008,
+ "A2": 35.69378996092126,
+ "nd1": 1.5673961639404297,
+ "vd1": 55.9915657043457,
+ "nd2": 1.763102412223816,
+ "vd2": 26.560810089111328,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.346922550383084,
+ "delta_alpha_c": 0.0,
+ "A3": 24.41690175442008,
+ "nd3": 1.5673961639404297,
+ "vd3": 55.9915657043457
+ },
+ "optical system values": {
+ "dispersion [um]": 994.9984130859375,
+ "deviation [deg]": -2.194249070398548,
+ "max distortion [um]": 4.690389633178711,
+ "mean distortion [um]": 1.0265427827835083,
+ "beam_compression [no units]": 0.7852036356925964
+ },
+ "current_loss": 19179.6015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1170,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.414538508967258,
+ "A2": 35.6780634503573,
+ "nd1": 1.567400574684143,
+ "vd1": 55.99148941040039,
+ "nd2": 1.7631022930145264,
+ "vd2": 26.556936264038086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.4249706951419965,
+ "delta_alpha_c": 0.0,
+ "A3": 24.414538508967258,
+ "nd3": 1.567400574684143,
+ "vd3": 55.99148941040039
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4560546875,
+ "deviation [deg]": -1.6134011389224956,
+ "max distortion [um]": 4.6104631423950195,
+ "mean distortion [um]": 1.0333640575408936,
+ "beam_compression [no units]": 0.7853935360908508
+ },
+ "current_loss": 19174.23046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1180,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.43204257626271,
+ "A2": 35.64670263678319,
+ "nd1": 1.5674058198928833,
+ "vd1": 55.99139404296875,
+ "nd2": 1.7631003856658936,
+ "vd2": 26.553232192993164,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.30305736798597,
+ "delta_alpha_c": 0.0,
+ "A3": 24.43204257626271,
+ "nd3": 1.5674058198928833,
+ "vd3": 55.99139404296875
+ },
+ "optical system values": {
+ "dispersion [um]": 992.4411010742188,
+ "deviation [deg]": 1.0163126184257394,
+ "max distortion [um]": 5.039153575897217,
+ "mean distortion [um]": 1.0746285915374756,
+ "beam_compression [no units]": 0.7857363224029541
+ },
+ "current_loss": 19208.94140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1190,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.408596244389347,
+ "A2": 35.653119599508415,
+ "nd1": 1.567408800125122,
+ "vd1": 55.99141311645508,
+ "nd2": 1.7631011009216309,
+ "vd2": 26.54970359802246,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3993399833947,
+ "delta_alpha_c": 0.0,
+ "A3": 24.408596244389347,
+ "nd3": 1.567408800125122,
+ "vd3": 55.99141311645508
+ },
+ "optical system values": {
+ "dispersion [um]": 993.818359375,
+ "deviation [deg]": -0.8325779684314576,
+ "max distortion [um]": 4.708636283874512,
+ "mean distortion [um]": 1.0461704730987549,
+ "beam_compression [no units]": 0.7857002019882202
+ },
+ "current_loss": 19143.451171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1200,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.4102235369591,
+ "A2": 35.64081842881322,
+ "nd1": 1.5674140453338623,
+ "vd1": 55.991451263427734,
+ "nd2": 1.7630993127822876,
+ "vd2": 26.5463809967041,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.239732549756665,
+ "delta_alpha_c": 0.0,
+ "A3": 24.4102235369591,
+ "nd3": 1.5674140453338623,
+ "vd3": 55.991451263427734
+ },
+ "optical system values": {
+ "dispersion [um]": 993.3602294921875,
+ "deviation [deg]": -0.1372628566345216,
+ "max distortion [um]": 5.020359992980957,
+ "mean distortion [um]": 1.0583397150039673,
+ "beam_compression [no units]": 0.7858315706253052
+ },
+ "current_loss": 19194.619140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1210,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.376617298695347,
+ "A2": 35.65554431666377,
+ "nd1": 1.5674158334732056,
+ "vd1": 55.99149703979492,
+ "nd2": 1.7630999088287354,
+ "vd2": 26.543262481689453,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.495403605863168,
+ "delta_alpha_c": 0.0,
+ "A3": 24.376617298695347,
+ "nd3": 1.5674158334732056,
+ "vd3": 55.99149703979492
+ },
+ "optical system values": {
+ "dispersion [um]": 995.4305419921875,
+ "deviation [deg]": -3.04521999121291,
+ "max distortion [um]": 4.377158164978027,
+ "mean distortion [um]": 1.0096725225448608,
+ "beam_compression [no units]": 0.7857051491737366
+ },
+ "current_loss": 19189.990234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1220,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.38470936531452,
+ "A2": 35.63909722114238,
+ "nd1": 1.5674214363098145,
+ "vd1": 55.991539001464844,
+ "nd2": 1.763096809387207,
+ "vd2": 26.540359497070312,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.377543142205897,
+ "delta_alpha_c": 0.0,
+ "A3": 24.38470936531452,
+ "nd3": 1.5674214363098145,
+ "vd3": 55.991539001464844
+ },
+ "optical system values": {
+ "dispersion [um]": 994.494384765625,
+ "deviation [deg]": -1.7270856889542439,
+ "max distortion [um]": 4.664588928222656,
+ "mean distortion [um]": 1.0345643758773804,
+ "beam_compression [no units]": 0.7859011888504028
+ },
+ "current_loss": 19122.59375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1230,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.393894262200895,
+ "A2": 35.61713133277161,
+ "nd1": 1.5674246549606323,
+ "vd1": 55.9913444519043,
+ "nd2": 1.7630935907363892,
+ "vd2": 26.53768539428711,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3926421291398565,
+ "delta_alpha_c": 0.0,
+ "A3": 24.393894262200895,
+ "nd3": 1.5674246549606323,
+ "vd3": 55.9913444519043
+ },
+ "optical system values": {
+ "dispersion [um]": 993.1573486328125,
+ "deviation [deg]": -0.08736687733444377,
+ "max distortion [um]": 4.777201175689697,
+ "mean distortion [um]": 1.0566145181655884,
+ "beam_compression [no units]": 0.7861505150794983
+ },
+ "current_loss": 19119.748046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1240,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.373273921096626,
+ "A2": 35.629572522344795,
+ "nd1": 1.5674290657043457,
+ "vd1": 55.99148178100586,
+ "nd2": 1.763092041015625,
+ "vd2": 26.535200119018555,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.370724052093285,
+ "delta_alpha_c": 0.0,
+ "A3": 24.373273921096626,
+ "nd3": 1.5674290657043457,
+ "vd3": 55.99148178100586
+ },
+ "optical system values": {
+ "dispersion [um]": 994.6947631835938,
+ "deviation [deg]": -2.015895328809767,
+ "max distortion [um]": 4.652565956115723,
+ "mean distortion [um]": 1.0285693407058716,
+ "beam_compression [no units]": 0.7860314846038818
+ },
+ "current_loss": 19113.12890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1250,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.368588411325998,
+ "A2": 35.623199955849174,
+ "nd1": 1.5674318075180054,
+ "vd1": 55.99143600463867,
+ "nd2": 1.7630895376205444,
+ "vd2": 26.532941818237305,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.416159324225857,
+ "delta_alpha_c": 0.0,
+ "A3": 24.368588411325998,
+ "nd3": 1.5674318075180054,
+ "vd3": 55.99143600463867
+ },
+ "optical system values": {
+ "dispersion [um]": 994.648193359375,
+ "deviation [deg]": -2.0194173585439663,
+ "max distortion [um]": 4.576861381530762,
+ "mean distortion [um]": 1.025853157043457,
+ "beam_compression [no units]": 0.7861129641532898
+ },
+ "current_loss": 19124.78515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1260,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.36518014693016,
+ "A2": 35.61881497440203,
+ "nd1": 1.5674362182617188,
+ "vd1": 55.99143981933594,
+ "nd2": 1.7630865573883057,
+ "vd2": 26.5308780670166,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.382954786462663,
+ "delta_alpha_c": 0.0,
+ "A3": 24.36518014693016,
+ "nd3": 1.5674362182617188,
+ "vd3": 55.99143981933594
+ },
+ "optical system values": {
+ "dispersion [um]": 994.6668090820312,
+ "deviation [deg]": -2.0259724191564747,
+ "max distortion [um]": 4.626003742218018,
+ "mean distortion [um]": 1.0308036804199219,
+ "beam_compression [no units]": 0.7861716747283936
+ },
+ "current_loss": 19108.74609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1270,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.3765370439726,
+ "A2": 35.600981350479124,
+ "nd1": 1.5674405097961426,
+ "vd1": 55.991397857666016,
+ "nd2": 1.7630822658538818,
+ "vd2": 26.52901268005371,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.320812444733417,
+ "delta_alpha_c": 0.0,
+ "A3": 24.3765370439726,
+ "nd3": 1.5674405097961426,
+ "vd3": 55.991397857666016
+ },
+ "optical system values": {
+ "dispersion [um]": 993.4330444335938,
+ "deviation [deg]": -0.42656169544913375,
+ "max distortion [um]": 4.854032516479492,
+ "mean distortion [um]": 1.0501755475997925,
+ "beam_compression [no units]": 0.7863669991493225
+ },
+ "current_loss": 19118.314453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1280,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.36212875991846,
+ "A2": 35.605660030060584,
+ "nd1": 1.5674434900283813,
+ "vd1": 55.99138641357422,
+ "nd2": 1.7630798816680908,
+ "vd2": 26.527326583862305,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.449973883259298,
+ "delta_alpha_c": 0.0,
+ "A3": 24.36212875991846,
+ "nd3": 1.5674434900283813,
+ "vd3": 55.99138641357422
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2572631835938,
+ "deviation [deg]": -1.5858115502655812,
+ "max distortion [um]": 4.552414417266846,
+ "mean distortion [um]": 1.0340828895568848,
+ "beam_compression [no units]": 0.7863306403160095
+ },
+ "current_loss": 19117.720703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1290,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.363878995893273,
+ "A2": 35.60057836931809,
+ "nd1": 1.567447543144226,
+ "vd1": 55.99140548706055,
+ "nd2": 1.7630764245986938,
+ "vd2": 26.52581214904785,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.342498295348208,
+ "delta_alpha_c": 0.0,
+ "A3": 24.363878995893273,
+ "nd3": 1.567447543144226,
+ "vd3": 55.99140548706055
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0531005859375,
+ "deviation [deg]": -1.2166792059358253,
+ "max distortion [um]": 4.740771770477295,
+ "mean distortion [um]": 1.039737582206726,
+ "beam_compression [no units]": 0.7863925695419312
+ },
+ "current_loss": 19094.080078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1300,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.368421071691333,
+ "A2": 35.59127906676312,
+ "nd1": 1.5674515962600708,
+ "vd1": 55.99137496948242,
+ "nd2": 1.7630726099014282,
+ "vd2": 26.524457931518555,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.306863490900959,
+ "delta_alpha_c": 0.0,
+ "A3": 24.368421071691333,
+ "nd3": 1.5674515962600708,
+ "vd3": 55.99137496948242
+ },
+ "optical system values": {
+ "dispersion [um]": 993.4807739257812,
+ "deviation [deg]": -0.46550012365970045,
+ "max distortion [um]": 4.863921642303467,
+ "mean distortion [um]": 1.049826741218567,
+ "beam_compression [no units]": 0.7864949703216553
+ },
+ "current_loss": 19109.705078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1310,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.358059674720423,
+ "A2": 35.59382672732353,
+ "nd1": 1.5674543380737305,
+ "vd1": 55.99135208129883,
+ "nd2": 1.7630698680877686,
+ "vd2": 26.523256301879883,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.419675590987944,
+ "delta_alpha_c": 0.0,
+ "A3": 24.358059674720423,
+ "nd3": 1.5674543380737305,
+ "vd3": 55.99135208129883
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0055541992188,
+ "deviation [deg]": -1.2574764594568404,
+ "max distortion [um]": 4.617681980133057,
+ "mean distortion [um]": 1.036993384361267,
+ "beam_compression [no units]": 0.7864813804626465
+ },
+ "current_loss": 19094.4453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1320,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.356167712320328,
+ "A2": 35.59323933105491,
+ "nd1": 1.5674582719802856,
+ "vd1": 55.99138641357422,
+ "nd2": 1.7630667686462402,
+ "vd2": 26.522188186645508,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.350580116683625,
+ "delta_alpha_c": 0.0,
+ "A3": 24.356167712320328,
+ "nd3": 1.5674582719802856,
+ "vd3": 55.99138641357422
+ },
+ "optical system values": {
+ "dispersion [um]": 994.12109375,
+ "deviation [deg]": -1.3381905124261735,
+ "max distortion [um]": 4.710779666900635,
+ "mean distortion [um]": 1.0353559255599976,
+ "beam_compression [no units]": 0.7864928841590881
+ },
+ "current_loss": 19078.94921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1330,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.357581561478522,
+ "A2": 35.588297689190405,
+ "nd1": 1.5674614906311035,
+ "vd1": 55.991363525390625,
+ "nd2": 1.7630629539489746,
+ "vd2": 26.52124786376953,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.33607578309428,
+ "delta_alpha_c": 0.0,
+ "A3": 24.357581561478522,
+ "nd3": 1.5674614906311035,
+ "vd3": 55.991363525390625
+ },
+ "optical system values": {
+ "dispersion [um]": 993.8599853515625,
+ "deviation [deg]": -0.9991913618889272,
+ "max distortion [um]": 4.769865989685059,
+ "mean distortion [um]": 1.0419617891311646,
+ "beam_compression [no units]": 0.7865499258041382
+ },
+ "current_loss": 19083.78515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1340,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.358238967186136,
+ "A2": 35.583103330326615,
+ "nd1": 1.5674653053283691,
+ "vd1": 55.99131774902344,
+ "nd2": 1.7630597352981567,
+ "vd2": 26.520423889160156,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.366742051807169,
+ "delta_alpha_c": 0.0,
+ "A3": 24.358238967186136,
+ "nd3": 1.5674653053283691,
+ "vd3": 55.99131774902344
+ },
+ "optical system values": {
+ "dispersion [um]": 993.5987548828125,
+ "deviation [deg]": -0.6977609731902484,
+ "max distortion [um]": 4.7441582679748535,
+ "mean distortion [um]": 1.0500150918960571,
+ "beam_compression [no units]": 0.7866120338439941
+ },
+ "current_loss": 19071.8671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1350,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.348010758904042,
+ "A2": 35.5903262553739,
+ "nd1": 1.5674680471420288,
+ "vd1": 55.99135971069336,
+ "nd2": 1.7630572319030762,
+ "vd2": 26.519702911376953,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3854772607005135,
+ "delta_alpha_c": 0.0,
+ "A3": 24.348010758904042,
+ "nd3": 1.5674680471420288,
+ "vd3": 55.99135971069336
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3560180664062,
+ "deviation [deg]": -1.6970502522442301,
+ "max distortion [um]": 4.634122371673584,
+ "mean distortion [um]": 1.029607892036438,
+ "beam_compression [no units]": 0.7865405678749084
+ },
+ "current_loss": 19076.609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1360,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.355107325451684,
+ "A2": 35.581809009478896,
+ "nd1": 1.5674717426300049,
+ "vd1": 55.99132537841797,
+ "nd2": 1.763053297996521,
+ "vd2": 26.519081115722656,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.33055699024491,
+ "delta_alpha_c": 0.0,
+ "A3": 24.355107325451684,
+ "nd3": 1.5674717426300049,
+ "vd3": 55.99132537841797
+ },
+ "optical system values": {
+ "dispersion [um]": 993.694091796875,
+ "deviation [deg]": -0.8129131067590504,
+ "max distortion [um]": 4.789912700653076,
+ "mean distortion [um]": 1.0453377962112427,
+ "beam_compression [no units]": 0.7866321802139282
+ },
+ "current_loss": 19078.73828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1370,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.348763787260037,
+ "A2": 35.58407663228334,
+ "nd1": 1.5674747228622437,
+ "vd1": 55.99131393432617,
+ "nd2": 1.7630507946014404,
+ "vd2": 26.51854705810547,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.406372943805698,
+ "delta_alpha_c": 0.0,
+ "A3": 24.348763787260037,
+ "nd3": 1.5674747228622437,
+ "vd3": 55.99131393432617
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0504760742188,
+ "deviation [deg]": -1.325276332252972,
+ "max distortion [um]": 4.623000621795654,
+ "mean distortion [um]": 1.0352814197540283,
+ "beam_compression [no units]": 0.7866147756576538
+ },
+ "current_loss": 19075.26171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1380,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.348874777834048,
+ "A2": 35.583752198297766,
+ "nd1": 1.567478060722351,
+ "vd1": 55.99132537841797,
+ "nd2": 1.763047695159912,
+ "vd2": 26.518089294433594,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.344047894516154,
+ "delta_alpha_c": 0.0,
+ "A3": 24.348874777834048,
+ "nd3": 1.567478060722351,
+ "vd3": 55.99132537841797
+ },
+ "optical system values": {
+ "dispersion [um]": 994.054931640625,
+ "deviation [deg]": -1.2869248200633503,
+ "max distortion [um]": 4.728711128234863,
+ "mean distortion [um]": 1.0365442037582397,
+ "beam_compression [no units]": 0.7866196036338806
+ },
+ "current_loss": 19065.73046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1390,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.350910174206714,
+ "A2": 35.579596028187815,
+ "nd1": 1.5674811601638794,
+ "vd1": 55.99128723144531,
+ "nd2": 1.7630445957183838,
+ "vd2": 26.51770782470703,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.355456444864192,
+ "delta_alpha_c": 0.0,
+ "A3": 24.350910174206714,
+ "nd3": 1.5674811601638794,
+ "vd3": 55.99128723144531
+ },
+ "optical system values": {
+ "dispersion [um]": 993.76416015625,
+ "deviation [deg]": -0.943718806605905,
+ "max distortion [um]": 4.743223667144775,
+ "mean distortion [um]": 1.0399364233016968,
+ "beam_compression [no units]": 0.786666989326477
+ },
+ "current_loss": 19062.345703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1400,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34908139105644,
+ "A2": 35.580330273523586,
+ "nd1": 1.5674843788146973,
+ "vd1": 55.99129104614258,
+ "nd2": 1.7630414962768555,
+ "vd2": 26.51738739013672,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.352670581456473,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34908139105644,
+ "nd3": 1.5674843788146973,
+ "vd3": 55.99129104614258
+ },
+ "optical system values": {
+ "dispersion [um]": 993.8992919921875,
+ "deviation [deg]": -1.0829383390148635,
+ "max distortion [um]": 4.724148750305176,
+ "mean distortion [um]": 1.0389859676361084,
+ "beam_compression [no units]": 0.7866615056991577
+ },
+ "current_loss": 19059.380859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1410,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34579265497108,
+ "A2": 35.58207538685652,
+ "nd1": 1.5674872398376465,
+ "vd1": 55.99129104614258,
+ "nd2": 1.7630391120910645,
+ "vd2": 26.517126083374023,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.374485351891847,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34579265497108,
+ "nd3": 1.5674872398376465,
+ "vd3": 55.99129104614258
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0970458984375,
+ "deviation [deg]": -1.3684216767445905,
+ "max distortion [um]": 4.679548263549805,
+ "mean distortion [um]": 1.0358331203460693,
+ "beam_compression [no units]": 0.786645770072937
+ },
+ "current_loss": 19057.833984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1420,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34669423994152,
+ "A2": 35.58056591504995,
+ "nd1": 1.5674901008605957,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630361318588257,
+ "vd2": 26.516916275024414,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.363442216664406,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34669423994152,
+ "nd3": 1.5674901008605957,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9873046875,
+ "deviation [deg]": -1.2242124777035261,
+ "max distortion [um]": 4.6965436935424805,
+ "mean distortion [um]": 1.037223219871521,
+ "beam_compression [no units]": 0.7866632342338562
+ },
+ "current_loss": 19051.7890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1430,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34609318329456,
+ "A2": 35.58043614145572,
+ "nd1": 1.5674927234649658,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630336284637451,
+ "vd2": 26.516752243041992,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.366264792338914,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34609318329456,
+ "nd3": 1.5674927234649658,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0004272460938,
+ "deviation [deg]": -1.245344869552134,
+ "max distortion [um]": 4.6974778175354,
+ "mean distortion [um]": 1.0377862453460693,
+ "beam_compression [no units]": 0.7866661548614502
+ },
+ "current_loss": 19052.212890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1440,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.346193928584817,
+ "A2": 35.57987948103837,
+ "nd1": 1.567495346069336,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630311250686646,
+ "vd2": 26.51662826538086,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.364511568156336,
+ "delta_alpha_c": 0.0,
+ "A3": 24.346193928584817,
+ "nd3": 1.567495346069336,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9698486328125,
+ "deviation [deg]": -1.1994601923165173,
+ "max distortion [um]": 4.692916393280029,
+ "mean distortion [um]": 1.0368252992630005,
+ "beam_compression [no units]": 0.7866731286048889
+ },
+ "current_loss": 19050.26171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1450,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34543236249236,
+ "A2": 35.58018000936185,
+ "nd1": 1.567497730255127,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630289793014526,
+ "vd2": 26.51654052734375,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.368888011867021,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34543236249236,
+ "nd3": 1.567497730255127,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0108642578125,
+ "deviation [deg]": -1.2520955510513396,
+ "max distortion [um]": 4.693333148956299,
+ "mean distortion [um]": 1.0376684665679932,
+ "beam_compression [no units]": 0.786670982837677
+ },
+ "current_loss": 19052.04296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1460,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34564751345122,
+ "A2": 35.57985557537627,
+ "nd1": 1.5674999952316284,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630269527435303,
+ "vd2": 26.516477584838867,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.363910938396198,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34564751345122,
+ "nd3": 1.5674999952316284,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.97705078125,
+ "deviation [deg]": -1.21208088779882,
+ "max distortion [um]": 4.688079357147217,
+ "mean distortion [um]": 1.035811424255371,
+ "beam_compression [no units]": 0.7866750359535217
+ },
+ "current_loss": 19050.23828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1470,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345456268154457,
+ "A2": 35.579899971605876,
+ "nd1": 1.567501425743103,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630256414413452,
+ "vd2": 26.516441345214844,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.364139749733393,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345456268154457,
+ "nd3": 1.567501425743103,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9732055664062,
+ "deviation [deg]": -1.220396856556722,
+ "max distortion [um]": 4.705700397491455,
+ "mean distortion [um]": 1.0393940210342407,
+ "beam_compression [no units]": 0.7866749167442322
+ },
+ "current_loss": 19052.478515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1480,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345570673823055,
+ "A2": 35.57976678291706,
+ "nd1": 1.5675026178359985,
+ "vd1": 55.99128341674805,
+ "nd2": 1.7630244493484497,
+ "vd2": 26.516422271728516,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.362057822697009,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345570673823055,
+ "nd3": 1.5675026178359985,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.95654296875,
+ "deviation [deg]": -1.1997536770074164,
+ "max distortion [um]": 4.705041408538818,
+ "mean distortion [um]": 1.0387715101242065,
+ "beam_compression [no units]": 0.7866765856742859
+ },
+ "current_loss": 19054.384765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1490,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345471636080088,
+ "A2": 35.57981800933584,
+ "nd1": 1.5675033330917358,
+ "vd1": 55.99128341674805,
+ "nd2": 1.763023853302002,
+ "vd2": 26.516416549682617,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.362791641145962,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345471636080088,
+ "nd3": 1.5675033330917358,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9592895507812,
+ "deviation [deg]": -1.2053303130213202,
+ "max distortion [um]": 4.703799247741699,
+ "mean distortion [um]": 1.037937045097351,
+ "beam_compression [no units]": 0.786676287651062
+ },
+ "current_loss": 19057.802734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1500,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.3454921266476,
+ "A2": 35.57979751876833,
+ "nd1": 1.5675033330917358,
+ "vd1": 55.99128341674805,
+ "nd2": 1.763023853302002,
+ "vd2": 26.516416549682617,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.362495381690713,
+ "delta_alpha_c": 0.0,
+ "A3": 24.3454921266476,
+ "nd3": 1.5675033330917358,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9598999023438,
+ "deviation [deg]": -1.2028843582465152,
+ "max distortion [um]": 4.691740036010742,
+ "mean distortion [um]": 1.037368655204773,
+ "beam_compression [no units]": 0.7866765260696411
+ },
+ "current_loss": 19062.70703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1510,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345468220985506,
+ "A2": 35.57981117914667,
+ "nd1": 1.5675033330917358,
+ "vd1": 55.99128341674805,
+ "nd2": 1.763023853302002,
+ "vd2": 26.516416549682617,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.362699433592167,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345468220985506,
+ "nd3": 1.5675033330917358,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9632568359375,
+ "deviation [deg]": -1.205428070103816,
+ "max distortion [um]": 4.704249382019043,
+ "mean distortion [um]": 1.0400433540344238,
+ "beam_compression [no units]": 0.7866762280464172
+ },
+ "current_loss": 19067.80859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1520,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34540333418839,
+ "A2": 35.579841914997935,
+ "nd1": 1.567504644393921,
+ "vd1": 55.99128341674805,
+ "nd2": 1.763022541999817,
+ "vd2": 26.51641273498535,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.36300849965211,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34540333418839,
+ "nd3": 1.567504644393921,
+ "vd3": 55.99128341674805
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9755859375,
+ "deviation [deg]": -1.204547616031119,
+ "max distortion [um]": 4.687595844268799,
+ "mean distortion [um]": 1.0352369546890259,
+ "beam_compression [no units]": 0.786676287651062
+ },
+ "current_loss": 19069.51953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1530,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345304296445423,
+ "A2": 35.579869235754614,
+ "nd1": 1.5675082206726074,
+ "vd1": 55.99127960205078,
+ "nd2": 1.7630189657211304,
+ "vd2": 26.516393661499023,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3629974005947085,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345304296445423,
+ "nd3": 1.5675082206726074,
+ "vd3": 55.99127960205078
+ },
+ "optical system values": {
+ "dispersion [um]": 993.96435546875,
+ "deviation [deg]": -1.1937856924984118,
+ "max distortion [um]": 4.694575786590576,
+ "mean distortion [um]": 1.0387628078460693,
+ "beam_compression [no units]": 0.7866768836975098
+ },
+ "current_loss": 19065.98046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1540,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.344792032257672,
+ "A2": 35.58020049992936,
+ "nd1": 1.5675153732299805,
+ "vd1": 55.991241455078125,
+ "nd2": 1.7630120515823364,
+ "vd2": 26.516359329223633,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.364927782808883,
+ "delta_alpha_c": 0.0,
+ "A3": 24.344792032257672,
+ "nd3": 1.5675153732299805,
+ "vd3": 55.991241455078125
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9725341796875,
+ "deviation [deg]": -1.2074826763835205,
+ "max distortion [um]": 4.693850040435791,
+ "mean distortion [um]": 1.0376811027526855,
+ "beam_compression [no units]": 0.7866750955581665
+ },
+ "current_loss": 19055.166015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1550,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.3443753907183,
+ "A2": 35.58046346221241,
+ "nd1": 1.567524790763855,
+ "vd1": 55.99120330810547,
+ "nd2": 1.7630032300949097,
+ "vd2": 26.516300201416016,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.36289110577575,
+ "delta_alpha_c": 0.0,
+ "A3": 24.3443753907183,
+ "nd3": 1.567524790763855,
+ "vd3": 55.99120330810547
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9597778320312,
+ "deviation [deg]": -1.200145025502517,
+ "max distortion [um]": 4.702865123748779,
+ "mean distortion [um]": 1.0365245342254639,
+ "beam_compression [no units]": 0.7866743206977844
+ },
+ "current_loss": 19037.87890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1560,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.343415749139915,
+ "A2": 35.581125990561894,
+ "nd1": 1.567533254623413,
+ "vd1": 55.99116516113281,
+ "nd2": 1.7629964351654053,
+ "vd2": 26.516212463378906,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.36257008688476,
+ "delta_alpha_c": 0.0,
+ "A3": 24.343415749139915,
+ "nd3": 1.567533254623413,
+ "vd3": 55.99116516113281
+ },
+ "optical system values": {
+ "dispersion [um]": 993.990966796875,
+ "deviation [deg]": -1.2552262322904384,
+ "max distortion [um]": 4.698653697967529,
+ "mean distortion [um]": 1.0377862453460693,
+ "beam_compression [no units]": 0.7866688966751099
+ },
+ "current_loss": 19025.22265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1570,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.341901154691467,
+ "A2": 35.58194219816771,
+ "nd1": 1.5675371885299683,
+ "vd1": 55.99114227294922,
+ "nd2": 1.7629936933517456,
+ "vd2": 26.516090393066406,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3718237125496575,
+ "delta_alpha_c": 0.0,
+ "A3": 24.341901154691467,
+ "nd3": 1.5675371885299683,
+ "vd3": 55.99114227294922
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0958862304688,
+ "deviation [deg]": -1.3755636000171907,
+ "max distortion [um]": 4.667524337768555,
+ "mean distortion [um]": 1.037495493888855,
+ "beam_compression [no units]": 0.7866617441177368
+ },
+ "current_loss": 19025.462890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1580,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.344003145408536,
+ "A2": 35.57954480176904,
+ "nd1": 1.567537784576416,
+ "vd1": 55.99113845825195,
+ "nd2": 1.7629929780960083,
+ "vd2": 26.515932083129883,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.356440418991497,
+ "delta_alpha_c": 0.0,
+ "A3": 24.344003145408536,
+ "nd3": 1.567537784576416,
+ "vd3": 55.99113845825195
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9019775390625,
+ "deviation [deg]": -1.1225616537722825,
+ "max distortion [um]": 4.712022304534912,
+ "mean distortion [um]": 1.0389114618301392,
+ "beam_compression [no units]": 0.7866875529289246
+ },
+ "current_loss": 19025.67578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1590,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.34197457922504,
+ "A2": 35.58074691506296,
+ "nd1": 1.5675394535064697,
+ "vd1": 55.99113845825195,
+ "nd2": 1.762990951538086,
+ "vd2": 26.515729904174805,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3581411360948294,
+ "delta_alpha_c": 0.0,
+ "A3": 24.34197457922504,
+ "nd3": 1.5675394535064697,
+ "vd3": 55.99113845825195
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0296630859375,
+ "deviation [deg]": -1.3036547281050619,
+ "max distortion [um]": 4.700621604919434,
+ "mean distortion [um]": 1.0368269681930542,
+ "beam_compression [no units]": 0.7866764664649963
+ },
+ "current_loss": 19024.166015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1600,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.340009192291372,
+ "A2": 35.58091083960304,
+ "nd1": 1.567543387413025,
+ "vd1": 55.99111557006836,
+ "nd2": 1.7629872560501099,
+ "vd2": 26.515487670898438,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.38379703416469,
+ "delta_alpha_c": 0.0,
+ "A3": 24.340009192291372,
+ "nd3": 1.567543387413025,
+ "vd3": 55.99111557006836
+ },
+ "optical system values": {
+ "dispersion [um]": 994.1124877929688,
+ "deviation [deg]": -1.4222309742430086,
+ "max distortion [um]": 4.647972106933594,
+ "mean distortion [um]": 1.0341248512268066,
+ "beam_compression [no units]": 0.7866777181625366
+ },
+ "current_loss": 19029.015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1610,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.336308937308516,
+ "A2": 35.5832433492046,
+ "nd1": 1.5675461292266846,
+ "vd1": 55.991119384765625,
+ "nd2": 1.7629849910736084,
+ "vd2": 26.515199661254883,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.39473899721505,
+ "delta_alpha_c": 0.0,
+ "A3": 24.336308937308516,
+ "nd3": 1.5675461292266846,
+ "vd3": 55.991119384765625
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3580322265625,
+ "deviation [deg]": -1.762306306461355,
+ "max distortion [um]": 4.607044219970703,
+ "mean distortion [um]": 1.0264087915420532,
+ "beam_compression [no units]": 0.7866548895835876
+ },
+ "current_loss": 19034.40234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1620,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.340801494235095,
+ "A2": 35.5780728960029,
+ "nd1": 1.5675487518310547,
+ "vd1": 55.99110794067383,
+ "nd2": 1.7629822492599487,
+ "vd2": 26.51487159729004,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.364970044604373,
+ "delta_alpha_c": 0.0,
+ "A3": 24.340801494235095,
+ "nd3": 1.5675487518310547,
+ "vd3": 55.99110794067383
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9500122070312,
+ "deviation [deg]": -1.212276615407223,
+ "max distortion [um]": 4.692123889923096,
+ "mean distortion [um]": 1.036720871925354,
+ "beam_compression [no units]": 0.7867116928100586
+ },
+ "current_loss": 19017.8359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1630,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33420182394957,
+ "A2": 35.58213685855905,
+ "nd1": 1.5675512552261353,
+ "vd1": 55.9911003112793,
+ "nd2": 1.7629799842834473,
+ "vd2": 26.51449966430664,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.4037347832387805,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33420182394957,
+ "nd3": 1.5675512552261353,
+ "vd3": 55.9911003112793
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4085083007812,
+ "deviation [deg]": -1.8257035887288846,
+ "max distortion [um]": 4.573511600494385,
+ "mean distortion [um]": 1.0269172191619873,
+ "beam_compression [no units]": 0.78667151927948
+ },
+ "current_loss": 19034.57421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1640,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33535441837201,
+ "A2": 35.57973263197121,
+ "nd1": 1.567553997039795,
+ "vd1": 55.991092681884766,
+ "nd2": 1.7629773616790771,
+ "vd2": 26.514089584350586,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.383074314773138,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33535441837201,
+ "nd3": 1.567553997039795,
+ "vd3": 55.991092681884766
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2708740234375,
+ "deviation [deg]": -1.6245543042285975,
+ "max distortion [um]": 4.623551845550537,
+ "mean distortion [um]": 1.0265326499938965,
+ "beam_compression [no units]": 0.7867001295089722
+ },
+ "current_loss": 19023.734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1650,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33745640908908,
+ "A2": 35.576607820425934,
+ "nd1": 1.5675567388534546,
+ "vd1": 55.99109649658203,
+ "nd2": 1.762974500656128,
+ "vd2": 26.513643264770508,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.351291737017776,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33745640908908,
+ "nd3": 1.5675567388534546,
+ "vd3": 55.99109649658203
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0595092773438,
+ "deviation [deg]": -1.3270373471200716,
+ "max distortion [um]": 4.694125175476074,
+ "mean distortion [um]": 1.0352901220321655,
+ "beam_compression [no units]": 0.7867354154586792
+ },
+ "current_loss": 19010.935546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1660,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.331620012443302,
+ "A2": 35.57883787718994,
+ "nd1": 1.5675591230392456,
+ "vd1": 55.99108123779297,
+ "nd2": 1.7629722356796265,
+ "vd2": 26.51317024230957,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.408860840210875,
+ "delta_alpha_c": 0.0,
+ "A3": 24.331620012443302,
+ "nd3": 1.5675591230392456,
+ "vd3": 55.99108123779297
+ },
+ "optical system values": {
+ "dispersion [um]": 994.3781127929688,
+ "deviation [deg]": -1.8050604091795788,
+ "max distortion [um]": 4.572786331176758,
+ "mean distortion [um]": 1.0298107862472534,
+ "beam_compression [no units]": 0.7867157459259033
+ },
+ "current_loss": 19030.62890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1670,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.345362353053368,
+ "A2": 35.564754027121374,
+ "nd1": 1.5675625801086426,
+ "vd1": 55.99103546142578,
+ "nd2": 1.7629684209823608,
+ "vd2": 26.512678146362305,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.327053530087516,
+ "delta_alpha_c": 0.0,
+ "A3": 24.345362353053368,
+ "nd3": 1.5675625801086426,
+ "vd3": 55.99103546142578
+ },
+ "optical system values": {
+ "dispersion [um]": 993.1975708007812,
+ "deviation [deg]": -0.22453190351529684,
+ "max distortion [um]": 4.828978538513184,
+ "mean distortion [um]": 1.0526829957962036,
+ "beam_compression [no units]": 0.7868654131889343
+ },
+ "current_loss": 19025.7421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1680,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.326205379978777,
+ "A2": 35.58028929238857,
+ "nd1": 1.5675638914108276,
+ "vd1": 55.991085052490234,
+ "nd2": 1.7629674673080444,
+ "vd2": 26.512161254882812,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.387350013193566,
+ "delta_alpha_c": 0.0,
+ "A3": 24.326205379978777,
+ "nd3": 1.5675638914108276,
+ "vd3": 55.991085052490234
+ },
+ "optical system values": {
+ "dispersion [um]": 994.705322265625,
+ "deviation [deg]": -2.2077502199535477,
+ "max distortion [um]": 4.56598424911499,
+ "mean distortion [um]": 1.0241847038269043,
+ "beam_compression [no units]": 0.7867077589035034
+ },
+ "current_loss": 19025.2578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1690,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.346197343679403,
+ "A2": 35.56169068727862,
+ "nd1": 1.567568302154541,
+ "vd1": 55.99105453491211,
+ "nd2": 1.762963056564331,
+ "vd2": 26.51165008544922,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.246027849737302,
+ "delta_alpha_c": 0.0,
+ "A3": 24.346197343679403,
+ "nd3": 1.567568302154541,
+ "vd3": 55.99105453491211
+ },
+ "optical system values": {
+ "dispersion [um]": 993.0677490234375,
+ "deviation [deg]": 0.0002935057434229774,
+ "max distortion [um]": 4.974780082702637,
+ "mean distortion [um]": 1.0591011047363281,
+ "beam_compression [no units]": 0.7868940830230713
+ },
+ "current_loss": 19053.48046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1700,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.331662701125616,
+ "A2": 35.57074068792889,
+ "nd1": 1.5675694942474365,
+ "vd1": 55.99106216430664,
+ "nd2": 1.762961745262146,
+ "vd2": 26.511131286621094,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.348966057605387,
+ "delta_alpha_c": 0.0,
+ "A3": 24.331662701125616,
+ "nd3": 1.5675694942474365,
+ "vd3": 55.99106216430664
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0638427734375,
+ "deviation [deg]": -1.3764441608115936,
+ "max distortion [um]": 4.691431522369385,
+ "mean distortion [um]": 1.0360558032989502,
+ "beam_compression [no units]": 0.7868160009384155
+ },
+ "current_loss": 19000.87109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1710,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.31939226628169,
+ "A2": 35.580053650862205,
+ "nd1": 1.5675718784332275,
+ "vd1": 55.99113845825195,
+ "nd2": 1.7629600763320923,
+ "vd2": 26.510618209838867,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.416750135589063,
+ "delta_alpha_c": 0.0,
+ "A3": 24.31939226628169,
+ "nd3": 1.5675718784332275,
+ "vd3": 55.99113845825195
+ },
+ "optical system values": {
+ "dispersion [um]": 994.982177734375,
+ "deviation [deg]": -2.6104400307275166,
+ "max distortion [um]": 4.480194091796875,
+ "mean distortion [um]": 1.0136849880218506,
+ "beam_compression [no units]": 0.786719024181366
+ },
+ "current_loss": 19035.19921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1720,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.346110258767485,
+ "A2": 35.552572384736656,
+ "nd1": 1.5675748586654663,
+ "vd1": 55.99092102050781,
+ "nd2": 1.7629550695419312,
+ "vd2": 26.51013946533203,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.315833663715301,
+ "delta_alpha_c": 0.0,
+ "A3": 24.346110258767485,
+ "nd3": 1.5675748586654663,
+ "vd3": 55.99092102050781
+ },
+ "optical system values": {
+ "dispersion [um]": 992.6143798828125,
+ "deviation [deg]": 0.45141184464034423,
+ "max distortion [um]": 4.909631729125977,
+ "mean distortion [um]": 1.0619155168533325,
+ "beam_compression [no units]": 0.7870104908943176
+ },
+ "current_loss": 19030.54296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1730,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.314568445180367,
+ "A2": 35.58191146231645,
+ "nd1": 1.5675766468048096,
+ "vd1": 55.99113464355469,
+ "nd2": 1.7629553079605103,
+ "vd2": 26.509654998779297,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.378151882815675,
+ "delta_alpha_c": 0.0,
+ "A3": 24.314568445180367,
+ "nd3": 1.5675766468048096,
+ "vd3": 55.99113464355469
+ },
+ "optical system values": {
+ "dispersion [um]": 995.3004150390625,
+ "deviation [deg]": -2.9930738447773897,
+ "max distortion [um]": 4.517682075500488,
+ "mean distortion [um]": 1.0113245248794556,
+ "beam_compression [no units]": 0.786706805229187
+ },
+ "current_loss": 19025.98828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1740,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33096943692486,
+ "A2": 35.56217221561511,
+ "nd1": 1.5675796270370483,
+ "vd1": 55.990989685058594,
+ "nd2": 1.7629512548446655,
+ "vd2": 26.509227752685547,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.379377474884869,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33096943692486,
+ "nd3": 1.5675796270370483,
+ "vd3": 55.990989685058594
+ },
+ "optical system values": {
+ "dispersion [um]": 993.6883544921875,
+ "deviation [deg]": -0.9752217734921195,
+ "max distortion [um]": 4.67547082901001,
+ "mean distortion [um]": 1.041542887687683,
+ "beam_compression [no units]": 0.7869208455085754
+ },
+ "current_loss": 18998.884765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1750,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.32587582335132,
+ "A2": 35.56758172543776,
+ "nd1": 1.5675811767578125,
+ "vd1": 55.99102783203125,
+ "nd2": 1.762948989868164,
+ "vd2": 26.508813858032227,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.342120073622919,
+ "delta_alpha_c": 0.0,
+ "A3": 24.32587582335132,
+ "nd3": 1.5675811767578125,
+ "vd3": 55.99102783203125
+ },
+ "optical system values": {
+ "dispersion [um]": 994.1878662109375,
+ "deviation [deg]": -1.5537216139975687,
+ "max distortion [um]": 4.6861114501953125,
+ "mean distortion [um]": 1.030296802520752,
+ "beam_compression [no units]": 0.7868642210960388
+ },
+ "current_loss": 18993.197265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1760,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.31294627525249,
+ "A2": 35.580576160333706,
+ "nd1": 1.5675840377807617,
+ "vd1": 55.99113464355469,
+ "nd2": 1.7629480361938477,
+ "vd2": 26.5084285736084,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.332103174318272,
+ "delta_alpha_c": 0.0,
+ "A3": 24.31294627525249,
+ "nd3": 1.5675840377807617,
+ "vd3": 55.99113464355469
+ },
+ "optical system values": {
+ "dispersion [um]": 995.3715209960938,
+ "deviation [deg]": -3.0020745399995854,
+ "max distortion [um]": 4.573096752166748,
+ "mean distortion [um]": 1.0093696117401123,
+ "beam_compression [no units]": 0.7867279052734375
+ },
+ "current_loss": 19005.58203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1770,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.353864231022744,
+ "A2": 35.533331741844734,
+ "nd1": 1.5675890445709229,
+ "vd1": 55.9908561706543,
+ "nd2": 1.762941837310791,
+ "vd2": 26.50811767578125,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3865483197397355,
+ "delta_alpha_c": 0.0,
+ "A3": 24.353864231022744,
+ "nd3": 1.5675890445709229,
+ "vd3": 55.9908561706543
+ },
+ "optical system values": {
+ "dispersion [um]": 991.3887939453125,
+ "deviation [deg]": 1.9236367620392314,
+ "max distortion [um]": 4.909019947052002,
+ "mean distortion [um]": 1.0848206281661987,
+ "beam_compression [no units]": 0.7872325778007507
+ },
+ "current_loss": 19025.044921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1780,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.319248832309118,
+ "A2": 35.56785493300456,
+ "nd1": 1.5675870180130005,
+ "vd1": 55.99101638793945,
+ "nd2": 1.7629421949386597,
+ "vd2": 26.50779151916504,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.444958389974392,
+ "delta_alpha_c": 0.0,
+ "A3": 24.319248832309118,
+ "nd3": 1.5675870180130005,
+ "vd3": 55.99101638793945
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4544677734375,
+ "deviation [deg]": -1.9753914532579453,
+ "max distortion [um]": 4.480158805847168,
+ "mean distortion [um]": 1.0238192081451416,
+ "beam_compression [no units]": 0.7868662476539612
+ },
+ "current_loss": 19026.455078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1790,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.323971908120182,
+ "A2": 35.56530385734956,
+ "nd1": 1.5675911903381348,
+ "vd1": 55.9909782409668,
+ "nd2": 1.7629395723342896,
+ "vd2": 26.507516860961914,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.332680325303138,
+ "delta_alpha_c": 0.0,
+ "A3": 24.323971908120182,
+ "nd3": 1.5675911903381348,
+ "vd3": 55.9909782409668
+ },
+ "optical system values": {
+ "dispersion [um]": 994.1777954101562,
+ "deviation [deg]": -1.5255450559588561,
+ "max distortion [um]": 4.692465782165527,
+ "mean distortion [um]": 1.0299975872039795,
+ "beam_compression [no units]": 0.7868958711624146
+ },
+ "current_loss": 18989.294921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1800,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.323645766587315,
+ "A2": 35.56548827245715,
+ "nd1": 1.567594289779663,
+ "vd1": 55.99105453491211,
+ "nd2": 1.7629376649856567,
+ "vd2": 26.507282257080078,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.303757035489072,
+ "delta_alpha_c": 0.0,
+ "A3": 24.323645766587315,
+ "nd3": 1.567594289779663,
+ "vd3": 55.99105453491211
+ },
+ "optical system values": {
+ "dispersion [um]": 994.2036743164062,
+ "deviation [deg]": -1.5427640695781641,
+ "max distortion [um]": 4.740805149078369,
+ "mean distortion [um]": 1.0347721576690674,
+ "beam_compression [no units]": 0.7868937253952026
+ },
+ "current_loss": 18997.642578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1810,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.314544539518273,
+ "A2": 35.57200427292534,
+ "nd1": 1.567595362663269,
+ "vd1": 55.99103546142578,
+ "nd2": 1.7629358768463135,
+ "vd2": 26.507081985473633,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.357983187970273,
+ "delta_alpha_c": 0.0,
+ "A3": 24.314544539518273,
+ "nd3": 1.567595362663269,
+ "vd3": 55.99103546142578
+ },
+ "optical system values": {
+ "dispersion [um]": 994.8809814453125,
+ "deviation [deg]": -2.440500228422545,
+ "max distortion [um]": 4.575514316558838,
+ "mean distortion [um]": 1.0144619941711426,
+ "beam_compression [no units]": 0.7868300080299377
+ },
+ "current_loss": 18997.658203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1820,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.31556565279919,
+ "A2": 35.56827157454393,
+ "nd1": 1.5675976276397705,
+ "vd1": 55.990970611572266,
+ "nd2": 1.762933373451233,
+ "vd2": 26.506916046142578,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.39713425917961,
+ "delta_alpha_c": 0.0,
+ "A3": 24.31556565279919,
+ "nd3": 1.5675976276397705,
+ "vd3": 55.990970611572266
+ },
+ "optical system values": {
+ "dispersion [um]": 994.6256103515625,
+ "deviation [deg]": -2.188574463858737,
+ "max distortion [um]": 4.544231414794922,
+ "mean distortion [um]": 1.018859624862671,
+ "beam_compression [no units]": 0.7868717312812805
+ },
+ "current_loss": 19005.80859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1830,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.344896192642516,
+ "A2": 35.540438553676125,
+ "nd1": 1.5676015615463257,
+ "vd1": 55.990901947021484,
+ "nd2": 1.7629287242889404,
+ "vd2": 26.50678253173828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.286748583795271,
+ "delta_alpha_c": 0.0,
+ "A3": 24.344896192642516,
+ "nd3": 1.5676015615463257,
+ "vd3": 55.990901947021484
+ },
+ "optical system values": {
+ "dispersion [um]": 992.142822265625,
+ "deviation [deg]": 1.065230219817959,
+ "max distortion [um]": 4.99232816696167,
+ "mean distortion [um]": 1.0739513635635376,
+ "beam_compression [no units]": 0.7871584296226501
+ },
+ "current_loss": 19033.04296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1840,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.290630339686764,
+ "A2": 35.592976368771865,
+ "nd1": 1.5676004886627197,
+ "vd1": 55.991111755371094,
+ "nd2": 1.7629313468933105,
+ "vd2": 26.506635665893555,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.386758774943537,
+ "delta_alpha_c": 0.0,
+ "A3": 24.290630339686764,
+ "nd3": 1.5676004886627197,
+ "vd3": 55.991111755371094
+ },
+ "optical system values": {
+ "dispersion [um]": 996.8260498046875,
+ "deviation [deg]": -4.9720852982954415,
+ "max distortion [um]": 4.338632106781006,
+ "mean distortion [um]": 0.9775665998458862,
+ "beam_compression [no units]": 0.7866097092628479
+ },
+ "current_loss": 19062.80859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1850,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.309910256166418,
+ "A2": 35.57646438645336,
+ "nd1": 1.5676051378250122,
+ "vd1": 55.99110412597656,
+ "nd2": 1.762927770614624,
+ "vd2": 26.50653648376465,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.286799810214046,
+ "delta_alpha_c": 0.0,
+ "A3": 24.309910256166418,
+ "nd3": 1.5676051378250122,
+ "vd3": 55.99110412597656
+ },
+ "optical system values": {
+ "dispersion [um]": 995.2990112304688,
+ "deviation [deg]": -2.9085440639395466,
+ "max distortion [um]": 4.647763729095459,
+ "mean distortion [um]": 1.0136916637420654,
+ "beam_compression [no units]": 0.7867847084999084
+ },
+ "current_loss": 18994.533203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1860,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.314708464058352,
+ "A2": 35.569685423702126,
+ "nd1": 1.5676072835922241,
+ "vd1": 55.99102783203125,
+ "nd2": 1.7629252672195435,
+ "vd2": 26.50645637512207,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.365475905489777,
+ "delta_alpha_c": 0.0,
+ "A3": 24.314708464058352,
+ "nd3": 1.5676072835922241,
+ "vd3": 55.99102783203125
+ },
+ "optical system values": {
+ "dispersion [um]": 994.743896484375,
+ "deviation [deg]": -2.264886033021174,
+ "max distortion [um]": 4.58027982711792,
+ "mean distortion [um]": 1.0188130140304565,
+ "beam_compression [no units]": 0.7868590354919434
+ },
+ "current_loss": 18990.7109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1870,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.326271974323184,
+ "A2": 35.555854290632844,
+ "nd1": 1.567609190940857,
+ "vd1": 55.990882873535156,
+ "nd2": 1.762921929359436,
+ "vd2": 26.50640106201172,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.417127076653883,
+ "delta_alpha_c": 0.0,
+ "A3": 24.326271974323184,
+ "nd3": 1.567609190940857,
+ "vd3": 55.990882873535156
+ },
+ "optical system values": {
+ "dispersion [um]": 993.572265625,
+ "deviation [deg]": -0.846079224708163,
+ "max distortion [um]": 4.627077102661133,
+ "mean distortion [um]": 1.0421415567398071,
+ "beam_compression [no units]": 0.7870068550109863
+ },
+ "current_loss": 18993.169921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1880,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.32570336107478,
+ "A2": 35.556533894455264,
+ "nd1": 1.567610740661621,
+ "vd1": 55.99085998535156,
+ "nd2": 1.7629197835922241,
+ "vd2": 26.506349563598633,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.385026041328469,
+ "delta_alpha_c": 0.0,
+ "A3": 24.32570336107478,
+ "nd3": 1.567610740661621,
+ "vd3": 55.99085998535156
+ },
+ "optical system values": {
+ "dispersion [um]": 993.6300048828125,
+ "deviation [deg]": -0.9064435828190894,
+ "max distortion [um]": 4.658543586730957,
+ "mean distortion [um]": 1.0389251708984375,
+ "beam_compression [no units]": 0.787001371383667
+ },
+ "current_loss": 18982.224609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1890,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.320474851265136,
+ "A2": 35.56061151738976,
+ "nd1": 1.5676133632659912,
+ "vd1": 55.990909576416016,
+ "nd2": 1.7629183530807495,
+ "vd2": 26.506311416625977,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.390000126591531,
+ "delta_alpha_c": 0.0,
+ "A3": 24.320474851265136,
+ "nd3": 1.5676133632659912,
+ "vd3": 55.990909576416016
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0101928710938,
+ "deviation [deg]": -1.4312318829086161,
+ "max distortion [um]": 4.622758865356445,
+ "mean distortion [um]": 1.0348092317581177,
+ "beam_compression [no units]": 0.7869599461555481
+ },
+ "current_loss": 18986.36328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1900,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.332400361555976,
+ "A2": 35.55296512061393,
+ "nd1": 1.5676168203353882,
+ "vd1": 55.99098205566406,
+ "nd2": 1.7629154920578003,
+ "vd2": 26.50627899169922,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.270155066093548,
+ "delta_alpha_c": 0.0,
+ "A3": 24.332400361555976,
+ "nd3": 1.5676168203353882,
+ "vd3": 55.99098205566406
+ },
+ "optical system values": {
+ "dispersion [um]": 993.21630859375,
+ "deviation [deg]": -0.27012312274044104,
+ "max distortion [um]": 4.914262294769287,
+ "mean distortion [um]": 1.0546094179153442,
+ "beam_compression [no units]": 0.7870306968688965
+ },
+ "current_loss": 19007.53125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1910,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.30560552944202,
+ "A2": 35.577195216694555,
+ "nd1": 1.5676170587539673,
+ "vd1": 55.990997314453125,
+ "nd2": 1.762915849685669,
+ "vd2": 26.506250381469727,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.3808942037674345,
+ "delta_alpha_c": 0.0,
+ "A3": 24.30560552944202,
+ "nd3": 1.5676170587539673,
+ "vd3": 55.990997314453125
+ },
+ "optical system values": {
+ "dispersion [um]": 995.416748046875,
+ "deviation [deg]": -3.1674161308892574,
+ "max distortion [um]": 4.488548755645752,
+ "mean distortion [um]": 1.0057696104049683,
+ "beam_compression [no units]": 0.7867829203605652
+ },
+ "current_loss": 19006.37109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1920,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33099505013425,
+ "A2": 35.55262361115543,
+ "nd1": 1.5676202774047852,
+ "vd1": 55.99085998535156,
+ "nd2": 1.7629116773605347,
+ "vd2": 26.506244659423828,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.319492510676312,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33099505013425,
+ "nd3": 1.5676202774047852,
+ "vd3": 55.99085998535156
+ },
+ "optical system values": {
+ "dispersion [um]": 993.2477416992188,
+ "deviation [deg]": -0.32950910961361607,
+ "max distortion [um]": 4.809267997741699,
+ "mean distortion [um]": 1.0496938228607178,
+ "beam_compression [no units]": 0.7870411276817322
+ },
+ "current_loss": 18986.86328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1930,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.333708342782035,
+ "A2": 35.54712872396816,
+ "nd1": 1.567622423171997,
+ "vd1": 55.99081802368164,
+ "nd2": 1.7629094123840332,
+ "vd2": 26.506240844726562,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.381680956182455,
+ "delta_alpha_c": 0.0,
+ "A3": 24.333708342782035,
+ "nd3": 1.567622423171997,
+ "vd3": 55.99081802368164
+ },
+ "optical system values": {
+ "dispersion [um]": 992.81591796875,
+ "deviation [deg]": 0.11622827522926239,
+ "max distortion [um]": 4.757187843322754,
+ "mean distortion [um]": 1.0552685260772705,
+ "beam_compression [no units]": 0.7871041893959045
+ },
+ "current_loss": 18971.310546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1940,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.3226007476443,
+ "A2": 35.560509064552214,
+ "nd1": 1.5676238536834717,
+ "vd1": 55.990901947021484,
+ "nd2": 1.7629085779190063,
+ "vd2": 26.5062255859375,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.327246482931569,
+ "delta_alpha_c": 0.0,
+ "A3": 24.3226007476443,
+ "nd3": 1.5676238536834717,
+ "vd3": 55.990901947021484
+ },
+ "optical system values": {
+ "dispersion [um]": 993.9410400390625,
+ "deviation [deg]": -1.2326263102656299,
+ "max distortion [um]": 4.717860221862793,
+ "mean distortion [um]": 1.0312246084213257,
+ "beam_compression [no units]": 0.7869608402252197
+ },
+ "current_loss": 18973.302734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1950,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.317199775558112,
+ "A2": 35.566755272548185,
+ "nd1": 1.5676265954971313,
+ "vd1": 55.99095916748047,
+ "nd2": 1.7629072666168213,
+ "vd2": 26.506216049194336,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.317963402075876,
+ "delta_alpha_c": 0.0,
+ "A3": 24.317199775558112,
+ "nd3": 1.5676265954971313,
+ "vd3": 55.99095916748047
+ },
+ "optical system values": {
+ "dispersion [um]": 994.4466552734375,
+ "deviation [deg]": -1.8694360093240068,
+ "max distortion [um]": 4.684968948364258,
+ "mean distortion [um]": 1.0233421325683594,
+ "beam_compression [no units]": 0.7868944406509399
+ },
+ "current_loss": 18971.390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1960,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.336880965651506,
+ "A2": 35.54622030880854,
+ "nd1": 1.5676286220550537,
+ "vd1": 55.99082946777344,
+ "nd2": 1.7629034519195557,
+ "vd2": 26.506227493286133,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.320041487130853,
+ "delta_alpha_c": 0.0,
+ "A3": 24.336880965651506,
+ "nd3": 1.5676286220550537,
+ "vd3": 55.99082946777344
+ },
+ "optical system values": {
+ "dispersion [um]": 992.652587890625,
+ "deviation [deg]": 0.3995591562152966,
+ "max distortion [um]": 4.875683784484863,
+ "mean distortion [um]": 1.061545729637146,
+ "beam_compression [no units]": 0.787109911441803
+ },
+ "current_loss": 18992.8671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1970,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.313878596074197,
+ "A2": 35.56769100846448,
+ "nd1": 1.5676295757293701,
+ "vd1": 55.99087905883789,
+ "nd2": 1.7629036903381348,
+ "vd2": 26.506221771240234,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.385644600335179,
+ "delta_alpha_c": 0.0,
+ "A3": 24.313878596074197,
+ "nd3": 1.5676295757293701,
+ "vd3": 55.99087905883789
+ },
+ "optical system values": {
+ "dispersion [um]": 994.579345703125,
+ "deviation [deg]": -2.116176379647306,
+ "max distortion [um]": 4.566018581390381,
+ "mean distortion [um]": 1.0228331089019775,
+ "beam_compression [no units]": 0.786887526512146
+ },
+ "current_loss": 18984.06640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1980,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.31877925680368,
+ "A2": 35.56357240439496,
+ "nd1": 1.5676323175430298,
+ "vd1": 55.99088668823242,
+ "nd2": 1.7629014253616333,
+ "vd2": 26.5062255859375,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.365513044643389,
+ "delta_alpha_c": 0.0,
+ "A3": 24.31877925680368,
+ "nd3": 1.5676323175430298,
+ "vd3": 55.99088668823242
+ },
+ "optical system values": {
+ "dispersion [um]": 994.1763916015625,
+ "deviation [deg]": -1.5879639136277814,
+ "max distortion [um]": 4.637990951538086,
+ "mean distortion [um]": 1.032683253288269,
+ "beam_compression [no units]": 0.7869310975074768
+ },
+ "current_loss": 18969.533203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1990,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33140144638986,
+ "A2": 35.55279436588468,
+ "nd1": 1.5676347017288208,
+ "vd1": 55.99085998535156,
+ "nd2": 1.7628986835479736,
+ "vd2": 26.506235122680664,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.308127075897412,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33140144638986,
+ "nd3": 1.5676347017288208,
+ "vd3": 55.99085998535156
+ },
+ "optical system values": {
+ "dispersion [um]": 993.16552734375,
+ "deviation [deg]": -0.23920717859687746,
+ "max distortion [um]": 4.8455305099487305,
+ "mean distortion [um]": 1.0507311820983887,
+ "beam_compression [no units]": 0.7870405316352844
+ },
+ "current_loss": 18984.498046875
+ }
+]
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_0.json b/outputs/amici/optimization_results/step1/score_details_iteration_0.json
new file mode 100755
index 0000000..748c89e
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_0.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 59480.13671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 313508.0,
+ "cost_distorsion": 1744.6019287109375,
+ "cost_thickness": 3546.5693359375,
+ "cost_beam_compression": 2.6572227478027344,
+ "cost_non_linearity": 1495.161865234375,
+ "cost_distance_total_intern_reflection": 16283.9560546875
+ },
+ "weighted components": {
+ "cost_dispersion": 59480.13671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 313508.0,
+ "cost_distorsion": 1744.6019287109375,
+ "cost_thickness": 3546.5693359375,
+ "cost_beam_compression": 2.6572227478027344,
+ "cost_non_linearity": 1495.161865234375,
+ "cost_distance_total_intern_reflection": 16283.9560546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 59480.13671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 313508.0,
+ "cost_distorsion": 1744.6019287109375,
+ "cost_thickness": 3546.5693359375,
+ "cost_beam_compression": 2.6572227478027344,
+ "cost_non_linearity": 1495.161865234375,
+ "cost_distance_total_intern_reflection": 16283.9560546875
+ },
+ "weighted components": {
+ "cost_dispersion": 59480.13671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 313508.0,
+ "cost_distorsion": 1744.6019287109375,
+ "cost_thickness": 3546.5693359375,
+ "cost_beam_compression": 2.6572227478027344,
+ "cost_non_linearity": 1495.161865234375,
+ "cost_distance_total_intern_reflection": 16283.9560546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_10.json b/outputs/amici/optimization_results/step1/score_details_iteration_10.json
new file mode 100755
index 0000000..27c2176
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_10.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 16468.546875,
+ "cost_distance_glasses": 1472.1645358804467,
+ "cost_deviation": 21704.24609375,
+ "cost_distorsion": 2259.99609375,
+ "cost_thickness": 3661.91259765625,
+ "cost_beam_compression": 2.405193328857422,
+ "cost_non_linearity": 738.843505859375,
+ "cost_distance_total_intern_reflection": 17158.271484375
+ },
+ "weighted components": {
+ "cost_dispersion": 16468.546875,
+ "cost_distance_glasses": 1472.1645358804467,
+ "cost_deviation": 21704.24609375,
+ "cost_distorsion": 2259.99609375,
+ "cost_thickness": 3661.91259765625,
+ "cost_beam_compression": 2.405193328857422,
+ "cost_non_linearity": 738.843505859375,
+ "cost_distance_total_intern_reflection": 17158.271484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 16468.546875,
+ "cost_distance_glasses": 1472.1645358804467,
+ "cost_deviation": 21704.24609375,
+ "cost_distorsion": 2259.99609375,
+ "cost_thickness": 3661.91259765625,
+ "cost_beam_compression": 2.405193328857422,
+ "cost_non_linearity": 738.843505859375,
+ "cost_distance_total_intern_reflection": 17158.271484375
+ },
+ "weighted components": {
+ "cost_dispersion": 16468.546875,
+ "cost_distance_glasses": 1472.1645358804467,
+ "cost_deviation": 21704.24609375,
+ "cost_distorsion": 2259.99609375,
+ "cost_thickness": 3661.91259765625,
+ "cost_beam_compression": 2.405193328857422,
+ "cost_non_linearity": 738.843505859375,
+ "cost_distance_total_intern_reflection": 17158.271484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_100.json b/outputs/amici/optimization_results/step1/score_details_iteration_100.json
new file mode 100755
index 0000000..3afc182
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_100.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 531.1246948242188,
+ "cost_distance_glasses": 2355.4127507450416,
+ "cost_deviation": 70.4562759399414,
+ "cost_distorsion": 20.992515563964844,
+ "cost_thickness": 3957.136962890625,
+ "cost_beam_compression": 2.263544797897339,
+ "cost_non_linearity": 924.8933715820312,
+ "cost_distance_total_intern_reflection": 13910.1533203125
+ },
+ "weighted components": {
+ "cost_dispersion": 531.1246948242188,
+ "cost_distance_glasses": 2355.4127507450416,
+ "cost_deviation": 70.4562759399414,
+ "cost_distorsion": 20.992515563964844,
+ "cost_thickness": 3957.136962890625,
+ "cost_beam_compression": 2.263544797897339,
+ "cost_non_linearity": 924.8933715820312,
+ "cost_distance_total_intern_reflection": 13910.1533203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 531.1246948242188,
+ "cost_distance_glasses": 2355.4127507450416,
+ "cost_deviation": 70.4562759399414,
+ "cost_distorsion": 20.992515563964844,
+ "cost_thickness": 3957.136962890625,
+ "cost_beam_compression": 2.263544797897339,
+ "cost_non_linearity": 924.8933715820312,
+ "cost_distance_total_intern_reflection": 13910.1533203125
+ },
+ "weighted components": {
+ "cost_dispersion": 531.1246948242188,
+ "cost_distance_glasses": 2355.4127507450416,
+ "cost_deviation": 70.4562759399414,
+ "cost_distorsion": 20.992515563964844,
+ "cost_thickness": 3957.136962890625,
+ "cost_beam_compression": 2.263544797897339,
+ "cost_non_linearity": 924.8933715820312,
+ "cost_distance_total_intern_reflection": 13910.1533203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1000.json b/outputs/amici/optimization_results/step1/score_details_iteration_1000.json
new file mode 100755
index 0000000..06ab2f0
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1000.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.787736892700195,
+ "cost_distance_glasses": 930.5992338352881,
+ "cost_deviation": 2.613482713699341,
+ "cost_distorsion": 22.256549835205078,
+ "cost_thickness": 3787.5283203125,
+ "cost_beam_compression": 2.1651835441589355,
+ "cost_non_linearity": 958.071533203125,
+ "cost_distance_total_intern_reflection": 13625.2626953125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.787736892700195,
+ "cost_distance_glasses": 930.5992338352881,
+ "cost_deviation": 2.613482713699341,
+ "cost_distorsion": 22.256549835205078,
+ "cost_thickness": 3787.5283203125,
+ "cost_beam_compression": 2.1651835441589355,
+ "cost_non_linearity": 958.071533203125,
+ "cost_distance_total_intern_reflection": 13625.2626953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.787736892700195,
+ "cost_distance_glasses": 930.5992338352881,
+ "cost_deviation": 2.613482713699341,
+ "cost_distorsion": 22.256549835205078,
+ "cost_thickness": 3787.5283203125,
+ "cost_beam_compression": 2.1651835441589355,
+ "cost_non_linearity": 958.071533203125,
+ "cost_distance_total_intern_reflection": 13625.2626953125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.787736892700195,
+ "cost_distance_glasses": 930.5992338352881,
+ "cost_deviation": 2.613482713699341,
+ "cost_distorsion": 22.256549835205078,
+ "cost_thickness": 3787.5283203125,
+ "cost_beam_compression": 2.1651835441589355,
+ "cost_non_linearity": 958.071533203125,
+ "cost_distance_total_intern_reflection": 13625.2626953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1010.json b/outputs/amici/optimization_results/step1/score_details_iteration_1010.json
new file mode 100755
index 0000000..9159e0d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1010.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.994449615478516,
+ "cost_distance_glasses": 923.373573216803,
+ "cost_deviation": 1.819806694984436,
+ "cost_distorsion": 22.858217239379883,
+ "cost_thickness": 3786.6611328125,
+ "cost_beam_compression": 2.1644794940948486,
+ "cost_non_linearity": 957.6709594726562,
+ "cost_distance_total_intern_reflection": 13631.5029296875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.994449615478516,
+ "cost_distance_glasses": 923.373573216803,
+ "cost_deviation": 1.819806694984436,
+ "cost_distorsion": 22.858217239379883,
+ "cost_thickness": 3786.6611328125,
+ "cost_beam_compression": 2.1644794940948486,
+ "cost_non_linearity": 957.6709594726562,
+ "cost_distance_total_intern_reflection": 13631.5029296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.994449615478516,
+ "cost_distance_glasses": 923.373573216803,
+ "cost_deviation": 1.819806694984436,
+ "cost_distorsion": 22.858217239379883,
+ "cost_thickness": 3786.6611328125,
+ "cost_beam_compression": 2.1644794940948486,
+ "cost_non_linearity": 957.6709594726562,
+ "cost_distance_total_intern_reflection": 13631.5029296875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.994449615478516,
+ "cost_distance_glasses": 923.373573216803,
+ "cost_deviation": 1.819806694984436,
+ "cost_distorsion": 22.858217239379883,
+ "cost_thickness": 3786.6611328125,
+ "cost_beam_compression": 2.1644794940948486,
+ "cost_non_linearity": 957.6709594726562,
+ "cost_distance_total_intern_reflection": 13631.5029296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1020.json b/outputs/amici/optimization_results/step1/score_details_iteration_1020.json
new file mode 100755
index 0000000..fd5f0f8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1020.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.889678955078125,
+ "cost_distance_glasses": 913.4088050734512,
+ "cost_deviation": 2.5631394386291504,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3785.35888671875,
+ "cost_beam_compression": 2.163900852203369,
+ "cost_non_linearity": 957.892333984375,
+ "cost_distance_total_intern_reflection": 13620.9208984375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.889678955078125,
+ "cost_distance_glasses": 913.4088050734512,
+ "cost_deviation": 2.5631394386291504,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3785.35888671875,
+ "cost_beam_compression": 2.163900852203369,
+ "cost_non_linearity": 957.892333984375,
+ "cost_distance_total_intern_reflection": 13620.9208984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.889678955078125,
+ "cost_distance_glasses": 913.4088050734512,
+ "cost_deviation": 2.5631394386291504,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3785.35888671875,
+ "cost_beam_compression": 2.163900852203369,
+ "cost_non_linearity": 957.892333984375,
+ "cost_distance_total_intern_reflection": 13620.9208984375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.889678955078125,
+ "cost_distance_glasses": 913.4088050734512,
+ "cost_deviation": 2.5631394386291504,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3785.35888671875,
+ "cost_beam_compression": 2.163900852203369,
+ "cost_non_linearity": 957.892333984375,
+ "cost_distance_total_intern_reflection": 13620.9208984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1030.json b/outputs/amici/optimization_results/step1/score_details_iteration_1030.json
new file mode 100755
index 0000000..c5d1a68
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1030.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.56441116333008,
+ "cost_distance_glasses": 905.4031260785991,
+ "cost_deviation": 1.242016315460205,
+ "cost_distorsion": 23.055274963378906,
+ "cost_thickness": 3784.183837890625,
+ "cost_beam_compression": 2.162843942642212,
+ "cost_non_linearity": 957.6445922851562,
+ "cost_distance_total_intern_reflection": 13631.7216796875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.56441116333008,
+ "cost_distance_glasses": 905.4031260785991,
+ "cost_deviation": 1.242016315460205,
+ "cost_distorsion": 23.055274963378906,
+ "cost_thickness": 3784.183837890625,
+ "cost_beam_compression": 2.162843942642212,
+ "cost_non_linearity": 957.6445922851562,
+ "cost_distance_total_intern_reflection": 13631.7216796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.56441116333008,
+ "cost_distance_glasses": 905.4031260785991,
+ "cost_deviation": 1.242016315460205,
+ "cost_distorsion": 23.055274963378906,
+ "cost_thickness": 3784.183837890625,
+ "cost_beam_compression": 2.162843942642212,
+ "cost_non_linearity": 957.6445922851562,
+ "cost_distance_total_intern_reflection": 13631.7216796875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.56441116333008,
+ "cost_distance_glasses": 905.4031260785991,
+ "cost_deviation": 1.242016315460205,
+ "cost_distorsion": 23.055274963378906,
+ "cost_thickness": 3784.183837890625,
+ "cost_beam_compression": 2.162843942642212,
+ "cost_non_linearity": 957.6445922851562,
+ "cost_distance_total_intern_reflection": 13631.7216796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1040.json b/outputs/amici/optimization_results/step1/score_details_iteration_1040.json
new file mode 100755
index 0000000..8a41e30
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1040.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.385223388671875,
+ "cost_distance_glasses": 898.5398070393293,
+ "cost_deviation": 1.4618749618530273,
+ "cost_distorsion": 22.892614364624023,
+ "cost_thickness": 3782.5849609375,
+ "cost_beam_compression": 2.1619582176208496,
+ "cost_non_linearity": 957.7122802734375,
+ "cost_distance_total_intern_reflection": 13624.8447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.385223388671875,
+ "cost_distance_glasses": 898.5398070393293,
+ "cost_deviation": 1.4618749618530273,
+ "cost_distorsion": 22.892614364624023,
+ "cost_thickness": 3782.5849609375,
+ "cost_beam_compression": 2.1619582176208496,
+ "cost_non_linearity": 957.7122802734375,
+ "cost_distance_total_intern_reflection": 13624.8447265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.385223388671875,
+ "cost_distance_glasses": 898.5398070393293,
+ "cost_deviation": 1.4618749618530273,
+ "cost_distorsion": 22.892614364624023,
+ "cost_thickness": 3782.5849609375,
+ "cost_beam_compression": 2.1619582176208496,
+ "cost_non_linearity": 957.7122802734375,
+ "cost_distance_total_intern_reflection": 13624.8447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.385223388671875,
+ "cost_distance_glasses": 898.5398070393293,
+ "cost_deviation": 1.4618749618530273,
+ "cost_distorsion": 22.892614364624023,
+ "cost_thickness": 3782.5849609375,
+ "cost_beam_compression": 2.1619582176208496,
+ "cost_non_linearity": 957.7122802734375,
+ "cost_distance_total_intern_reflection": 13624.8447265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1050.json b/outputs/amici/optimization_results/step1/score_details_iteration_1050.json
new file mode 100755
index 0000000..c3312c0
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1050.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.808387756347656,
+ "cost_distance_glasses": 890.3134169891584,
+ "cost_deviation": 2.779362201690674,
+ "cost_distorsion": 22.5493106842041,
+ "cost_thickness": 3780.7744140625,
+ "cost_beam_compression": 2.161224365234375,
+ "cost_non_linearity": 958.0860595703125,
+ "cost_distance_total_intern_reflection": 13620.099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.808387756347656,
+ "cost_distance_glasses": 890.3134169891584,
+ "cost_deviation": 2.779362201690674,
+ "cost_distorsion": 22.5493106842041,
+ "cost_thickness": 3780.7744140625,
+ "cost_beam_compression": 2.161224365234375,
+ "cost_non_linearity": 958.0860595703125,
+ "cost_distance_total_intern_reflection": 13620.099609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.808387756347656,
+ "cost_distance_glasses": 890.3134169891584,
+ "cost_deviation": 2.779362201690674,
+ "cost_distorsion": 22.5493106842041,
+ "cost_thickness": 3780.7744140625,
+ "cost_beam_compression": 2.161224365234375,
+ "cost_non_linearity": 958.0860595703125,
+ "cost_distance_total_intern_reflection": 13620.099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.808387756347656,
+ "cost_distance_glasses": 890.3134169891584,
+ "cost_deviation": 2.779362201690674,
+ "cost_distorsion": 22.5493106842041,
+ "cost_thickness": 3780.7744140625,
+ "cost_beam_compression": 2.161224365234375,
+ "cost_non_linearity": 958.0860595703125,
+ "cost_distance_total_intern_reflection": 13620.099609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1060.json b/outputs/amici/optimization_results/step1/score_details_iteration_1060.json
new file mode 100755
index 0000000..8c51f64
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1060.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.367828369140625,
+ "cost_distance_glasses": 881.9315661082527,
+ "cost_deviation": 1.9569799900054932,
+ "cost_distorsion": 22.83246421813965,
+ "cost_thickness": 3778.991943359375,
+ "cost_beam_compression": 2.159959077835083,
+ "cost_non_linearity": 957.8168334960938,
+ "cost_distance_total_intern_reflection": 13621.171875
+ },
+ "weighted components": {
+ "cost_dispersion": 33.367828369140625,
+ "cost_distance_glasses": 881.9315661082527,
+ "cost_deviation": 1.9569799900054932,
+ "cost_distorsion": 22.83246421813965,
+ "cost_thickness": 3778.991943359375,
+ "cost_beam_compression": 2.159959077835083,
+ "cost_non_linearity": 957.8168334960938,
+ "cost_distance_total_intern_reflection": 13621.171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.367828369140625,
+ "cost_distance_glasses": 881.9315661082527,
+ "cost_deviation": 1.9569799900054932,
+ "cost_distorsion": 22.83246421813965,
+ "cost_thickness": 3778.991943359375,
+ "cost_beam_compression": 2.159959077835083,
+ "cost_non_linearity": 957.8168334960938,
+ "cost_distance_total_intern_reflection": 13621.171875
+ },
+ "weighted components": {
+ "cost_dispersion": 33.367828369140625,
+ "cost_distance_glasses": 881.9315661082527,
+ "cost_deviation": 1.9569799900054932,
+ "cost_distorsion": 22.83246421813965,
+ "cost_thickness": 3778.991943359375,
+ "cost_beam_compression": 2.159959077835083,
+ "cost_non_linearity": 957.8168334960938,
+ "cost_distance_total_intern_reflection": 13621.171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1070.json b/outputs/amici/optimization_results/step1/score_details_iteration_1070.json
new file mode 100755
index 0000000..6ce1151
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1070.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.15226745605469,
+ "cost_distance_glasses": 873.7890096635194,
+ "cost_deviation": 1.9436615705490112,
+ "cost_distorsion": 22.466684341430664,
+ "cost_thickness": 3776.914794921875,
+ "cost_beam_compression": 2.1587073802948,
+ "cost_non_linearity": 957.61279296875,
+ "cost_distance_total_intern_reflection": 13609.416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.15226745605469,
+ "cost_distance_glasses": 873.7890096635194,
+ "cost_deviation": 1.9436615705490112,
+ "cost_distorsion": 22.466684341430664,
+ "cost_thickness": 3776.914794921875,
+ "cost_beam_compression": 2.1587073802948,
+ "cost_non_linearity": 957.61279296875,
+ "cost_distance_total_intern_reflection": 13609.416015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.15226745605469,
+ "cost_distance_glasses": 873.7890096635194,
+ "cost_deviation": 1.9436615705490112,
+ "cost_distorsion": 22.466684341430664,
+ "cost_thickness": 3776.914794921875,
+ "cost_beam_compression": 2.1587073802948,
+ "cost_non_linearity": 957.61279296875,
+ "cost_distance_total_intern_reflection": 13609.416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.15226745605469,
+ "cost_distance_glasses": 873.7890096635194,
+ "cost_deviation": 1.9436615705490112,
+ "cost_distorsion": 22.466684341430664,
+ "cost_thickness": 3776.914794921875,
+ "cost_beam_compression": 2.1587073802948,
+ "cost_non_linearity": 957.61279296875,
+ "cost_distance_total_intern_reflection": 13609.416015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1080.json b/outputs/amici/optimization_results/step1/score_details_iteration_1080.json
new file mode 100755
index 0000000..c9f5447
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1080.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.56480026245117,
+ "cost_distance_glasses": 865.139261922922,
+ "cost_deviation": 1.2906426191329956,
+ "cost_distorsion": 23.23421287536621,
+ "cost_thickness": 3774.99853515625,
+ "cost_beam_compression": 2.1573781967163086,
+ "cost_non_linearity": 957.4092407226562,
+ "cost_distance_total_intern_reflection": 13622.4521484375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.56480026245117,
+ "cost_distance_glasses": 865.139261922922,
+ "cost_deviation": 1.2906426191329956,
+ "cost_distorsion": 23.23421287536621,
+ "cost_thickness": 3774.99853515625,
+ "cost_beam_compression": 2.1573781967163086,
+ "cost_non_linearity": 957.4092407226562,
+ "cost_distance_total_intern_reflection": 13622.4521484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.56480026245117,
+ "cost_distance_glasses": 865.139261922922,
+ "cost_deviation": 1.2906426191329956,
+ "cost_distorsion": 23.23421287536621,
+ "cost_thickness": 3774.99853515625,
+ "cost_beam_compression": 2.1573781967163086,
+ "cost_non_linearity": 957.4092407226562,
+ "cost_distance_total_intern_reflection": 13622.4521484375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.56480026245117,
+ "cost_distance_glasses": 865.139261922922,
+ "cost_deviation": 1.2906426191329956,
+ "cost_distorsion": 23.23421287536621,
+ "cost_thickness": 3774.99853515625,
+ "cost_beam_compression": 2.1573781967163086,
+ "cost_non_linearity": 957.4092407226562,
+ "cost_distance_total_intern_reflection": 13622.4521484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1090.json b/outputs/amici/optimization_results/step1/score_details_iteration_1090.json
new file mode 100755
index 0000000..9314835
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1090.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.55109977722168,
+ "cost_distance_glasses": 859.6921443386365,
+ "cost_deviation": 9.360579490661621,
+ "cost_distorsion": 20.88890266418457,
+ "cost_thickness": 3772.151123046875,
+ "cost_beam_compression": 2.1571290493011475,
+ "cost_non_linearity": 959.1082153320312,
+ "cost_distance_total_intern_reflection": 13627.7158203125
+ },
+ "weighted components": {
+ "cost_dispersion": 25.55109977722168,
+ "cost_distance_glasses": 859.6921443386365,
+ "cost_deviation": 9.360579490661621,
+ "cost_distorsion": 20.88890266418457,
+ "cost_thickness": 3772.151123046875,
+ "cost_beam_compression": 2.1571290493011475,
+ "cost_non_linearity": 959.1082153320312,
+ "cost_distance_total_intern_reflection": 13627.7158203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.55109977722168,
+ "cost_distance_glasses": 859.6921443386365,
+ "cost_deviation": 9.360579490661621,
+ "cost_distorsion": 20.88890266418457,
+ "cost_thickness": 3772.151123046875,
+ "cost_beam_compression": 2.1571290493011475,
+ "cost_non_linearity": 959.1082153320312,
+ "cost_distance_total_intern_reflection": 13627.7158203125
+ },
+ "weighted components": {
+ "cost_dispersion": 25.55109977722168,
+ "cost_distance_glasses": 859.6921443386365,
+ "cost_deviation": 9.360579490661621,
+ "cost_distorsion": 20.88890266418457,
+ "cost_thickness": 3772.151123046875,
+ "cost_beam_compression": 2.1571290493011475,
+ "cost_non_linearity": 959.1082153320312,
+ "cost_distance_total_intern_reflection": 13627.7158203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_110.json b/outputs/amici/optimization_results/step1/score_details_iteration_110.json
new file mode 100755
index 0000000..1e7b4f9
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_110.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 391.5997619628906,
+ "cost_distance_glasses": 2081.338791174662,
+ "cost_deviation": 88.56929779052734,
+ "cost_distorsion": 20.915599822998047,
+ "cost_thickness": 3980.997802734375,
+ "cost_beam_compression": 2.2797231674194336,
+ "cost_non_linearity": 930.8782958984375,
+ "cost_distance_total_intern_reflection": 13957.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 391.5997619628906,
+ "cost_distance_glasses": 2081.338791174662,
+ "cost_deviation": 88.56929779052734,
+ "cost_distorsion": 20.915599822998047,
+ "cost_thickness": 3980.997802734375,
+ "cost_beam_compression": 2.2797231674194336,
+ "cost_non_linearity": 930.8782958984375,
+ "cost_distance_total_intern_reflection": 13957.203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 391.5997619628906,
+ "cost_distance_glasses": 2081.338791174662,
+ "cost_deviation": 88.56929779052734,
+ "cost_distorsion": 20.915599822998047,
+ "cost_thickness": 3980.997802734375,
+ "cost_beam_compression": 2.2797231674194336,
+ "cost_non_linearity": 930.8782958984375,
+ "cost_distance_total_intern_reflection": 13957.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 391.5997619628906,
+ "cost_distance_glasses": 2081.338791174662,
+ "cost_deviation": 88.56929779052734,
+ "cost_distorsion": 20.915599822998047,
+ "cost_thickness": 3980.997802734375,
+ "cost_beam_compression": 2.2797231674194336,
+ "cost_non_linearity": 930.8782958984375,
+ "cost_distance_total_intern_reflection": 13957.203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1100.json b/outputs/amici/optimization_results/step1/score_details_iteration_1100.json
new file mode 100755
index 0000000..e016e01
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1100.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.245208740234375,
+ "cost_distance_glasses": 849.6400160140835,
+ "cost_deviation": 1.5241413116455078,
+ "cost_distorsion": 23.297550201416016,
+ "cost_thickness": 3770.554931640625,
+ "cost_beam_compression": 2.154794931411743,
+ "cost_non_linearity": 957.463623046875,
+ "cost_distance_total_intern_reflection": 13619.9462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.245208740234375,
+ "cost_distance_glasses": 849.6400160140835,
+ "cost_deviation": 1.5241413116455078,
+ "cost_distorsion": 23.297550201416016,
+ "cost_thickness": 3770.554931640625,
+ "cost_beam_compression": 2.154794931411743,
+ "cost_non_linearity": 957.463623046875,
+ "cost_distance_total_intern_reflection": 13619.9462890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.245208740234375,
+ "cost_distance_glasses": 849.6400160140835,
+ "cost_deviation": 1.5241413116455078,
+ "cost_distorsion": 23.297550201416016,
+ "cost_thickness": 3770.554931640625,
+ "cost_beam_compression": 2.154794931411743,
+ "cost_non_linearity": 957.463623046875,
+ "cost_distance_total_intern_reflection": 13619.9462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.245208740234375,
+ "cost_distance_glasses": 849.6400160140835,
+ "cost_deviation": 1.5241413116455078,
+ "cost_distorsion": 23.297550201416016,
+ "cost_thickness": 3770.554931640625,
+ "cost_beam_compression": 2.154794931411743,
+ "cost_non_linearity": 957.463623046875,
+ "cost_distance_total_intern_reflection": 13619.9462890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1110.json b/outputs/amici/optimization_results/step1/score_details_iteration_1110.json
new file mode 100755
index 0000000..b254e10
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1110.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.16670608520508,
+ "cost_distance_glasses": 844.3452364853551,
+ "cost_deviation": 4.240269660949707,
+ "cost_distorsion": 20.693681716918945,
+ "cost_thickness": 3767.61962890625,
+ "cost_beam_compression": 2.153675079345703,
+ "cost_non_linearity": 957.9776611328125,
+ "cost_distance_total_intern_reflection": 13629.6689453125
+ },
+ "weighted components": {
+ "cost_dispersion": 32.16670608520508,
+ "cost_distance_glasses": 844.3452364853551,
+ "cost_deviation": 4.240269660949707,
+ "cost_distorsion": 20.693681716918945,
+ "cost_thickness": 3767.61962890625,
+ "cost_beam_compression": 2.153675079345703,
+ "cost_non_linearity": 957.9776611328125,
+ "cost_distance_total_intern_reflection": 13629.6689453125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.16670608520508,
+ "cost_distance_glasses": 844.3452364853551,
+ "cost_deviation": 4.240269660949707,
+ "cost_distorsion": 20.693681716918945,
+ "cost_thickness": 3767.61962890625,
+ "cost_beam_compression": 2.153675079345703,
+ "cost_non_linearity": 957.9776611328125,
+ "cost_distance_total_intern_reflection": 13629.6689453125
+ },
+ "weighted components": {
+ "cost_dispersion": 32.16670608520508,
+ "cost_distance_glasses": 844.3452364853551,
+ "cost_deviation": 4.240269660949707,
+ "cost_distorsion": 20.693681716918945,
+ "cost_thickness": 3767.61962890625,
+ "cost_beam_compression": 2.153675079345703,
+ "cost_non_linearity": 957.9776611328125,
+ "cost_distance_total_intern_reflection": 13629.6689453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1120.json b/outputs/amici/optimization_results/step1/score_details_iteration_1120.json
new file mode 100755
index 0000000..81f838a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1120.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.08852005004883,
+ "cost_distance_glasses": 836.6540157769568,
+ "cost_deviation": 4.165729999542236,
+ "cost_distorsion": 21.470922470092773,
+ "cost_thickness": 3765.47802734375,
+ "cost_beam_compression": 2.1523423194885254,
+ "cost_non_linearity": 957.9348754882812,
+ "cost_distance_total_intern_reflection": 13607.7138671875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.08852005004883,
+ "cost_distance_glasses": 836.6540157769568,
+ "cost_deviation": 4.165729999542236,
+ "cost_distorsion": 21.470922470092773,
+ "cost_thickness": 3765.47802734375,
+ "cost_beam_compression": 2.1523423194885254,
+ "cost_non_linearity": 957.9348754882812,
+ "cost_distance_total_intern_reflection": 13607.7138671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.08852005004883,
+ "cost_distance_glasses": 836.6540157769568,
+ "cost_deviation": 4.165729999542236,
+ "cost_distorsion": 21.470922470092773,
+ "cost_thickness": 3765.47802734375,
+ "cost_beam_compression": 2.1523423194885254,
+ "cost_non_linearity": 957.9348754882812,
+ "cost_distance_total_intern_reflection": 13607.7138671875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.08852005004883,
+ "cost_distance_glasses": 836.6540157769568,
+ "cost_deviation": 4.165729999542236,
+ "cost_distorsion": 21.470922470092773,
+ "cost_thickness": 3765.47802734375,
+ "cost_beam_compression": 2.1523423194885254,
+ "cost_non_linearity": 957.9348754882812,
+ "cost_distance_total_intern_reflection": 13607.7138671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1130.json b/outputs/amici/optimization_results/step1/score_details_iteration_1130.json
new file mode 100755
index 0000000..6130f2b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1130.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.54090118408203,
+ "cost_distance_glasses": 827.2075401186639,
+ "cost_deviation": 1.1168057918548584,
+ "cost_distorsion": 25.0162296295166,
+ "cost_thickness": 3764.20703125,
+ "cost_beam_compression": 2.1493053436279297,
+ "cost_non_linearity": 954.944091796875,
+ "cost_distance_total_intern_reflection": 13626.8017578125
+ },
+ "weighted components": {
+ "cost_dispersion": 51.54090118408203,
+ "cost_distance_glasses": 827.2075401186639,
+ "cost_deviation": 1.1168057918548584,
+ "cost_distorsion": 25.0162296295166,
+ "cost_thickness": 3764.20703125,
+ "cost_beam_compression": 2.1493053436279297,
+ "cost_non_linearity": 954.944091796875,
+ "cost_distance_total_intern_reflection": 13626.8017578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.54090118408203,
+ "cost_distance_glasses": 827.2075401186639,
+ "cost_deviation": 1.1168057918548584,
+ "cost_distorsion": 25.0162296295166,
+ "cost_thickness": 3764.20703125,
+ "cost_beam_compression": 2.1493053436279297,
+ "cost_non_linearity": 954.944091796875,
+ "cost_distance_total_intern_reflection": 13626.8017578125
+ },
+ "weighted components": {
+ "cost_dispersion": 51.54090118408203,
+ "cost_distance_glasses": 827.2075401186639,
+ "cost_deviation": 1.1168057918548584,
+ "cost_distorsion": 25.0162296295166,
+ "cost_thickness": 3764.20703125,
+ "cost_beam_compression": 2.1493053436279297,
+ "cost_non_linearity": 954.944091796875,
+ "cost_distance_total_intern_reflection": 13626.8017578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1140.json b/outputs/amici/optimization_results/step1/score_details_iteration_1140.json
new file mode 100755
index 0000000..82c7351
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1140.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.41998291015625,
+ "cost_distance_glasses": 824.4104626803263,
+ "cost_deviation": 1.6652368307113647,
+ "cost_distorsion": 21.360647201538086,
+ "cost_thickness": 3760.919189453125,
+ "cost_beam_compression": 2.149043083190918,
+ "cost_non_linearity": 957.0648193359375,
+ "cost_distance_total_intern_reflection": 13605.8115234375
+ },
+ "weighted components": {
+ "cost_dispersion": 37.41998291015625,
+ "cost_distance_glasses": 824.4104626803263,
+ "cost_deviation": 1.6652368307113647,
+ "cost_distorsion": 21.360647201538086,
+ "cost_thickness": 3760.919189453125,
+ "cost_beam_compression": 2.149043083190918,
+ "cost_non_linearity": 957.0648193359375,
+ "cost_distance_total_intern_reflection": 13605.8115234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.41998291015625,
+ "cost_distance_glasses": 824.4104626803263,
+ "cost_deviation": 1.6652368307113647,
+ "cost_distorsion": 21.360647201538086,
+ "cost_thickness": 3760.919189453125,
+ "cost_beam_compression": 2.149043083190918,
+ "cost_non_linearity": 957.0648193359375,
+ "cost_distance_total_intern_reflection": 13605.8115234375
+ },
+ "weighted components": {
+ "cost_dispersion": 37.41998291015625,
+ "cost_distance_glasses": 824.4104626803263,
+ "cost_deviation": 1.6652368307113647,
+ "cost_distorsion": 21.360647201538086,
+ "cost_thickness": 3760.919189453125,
+ "cost_beam_compression": 2.149043083190918,
+ "cost_non_linearity": 957.0648193359375,
+ "cost_distance_total_intern_reflection": 13605.8115234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1150.json b/outputs/amici/optimization_results/step1/score_details_iteration_1150.json
new file mode 100755
index 0000000..28975a8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1150.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.01158332824707,
+ "cost_distance_glasses": 820.5067234979609,
+ "cost_deviation": 17.30772590637207,
+ "cost_distorsion": 19.241418838500977,
+ "cost_thickness": 3757.97509765625,
+ "cost_beam_compression": 2.1495330333709717,
+ "cost_non_linearity": 959.7456665039062,
+ "cost_distance_total_intern_reflection": 13640.7861328125
+ },
+ "weighted components": {
+ "cost_dispersion": 22.01158332824707,
+ "cost_distance_glasses": 820.5067234979609,
+ "cost_deviation": 17.30772590637207,
+ "cost_distorsion": 19.241418838500977,
+ "cost_thickness": 3757.97509765625,
+ "cost_beam_compression": 2.1495330333709717,
+ "cost_non_linearity": 959.7456665039062,
+ "cost_distance_total_intern_reflection": 13640.7861328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.01158332824707,
+ "cost_distance_glasses": 820.5067234979609,
+ "cost_deviation": 17.30772590637207,
+ "cost_distorsion": 19.241418838500977,
+ "cost_thickness": 3757.97509765625,
+ "cost_beam_compression": 2.1495330333709717,
+ "cost_non_linearity": 959.7456665039062,
+ "cost_distance_total_intern_reflection": 13640.7861328125
+ },
+ "weighted components": {
+ "cost_dispersion": 22.01158332824707,
+ "cost_distance_glasses": 820.5067234979609,
+ "cost_deviation": 17.30772590637207,
+ "cost_distorsion": 19.241418838500977,
+ "cost_thickness": 3757.97509765625,
+ "cost_beam_compression": 2.1495330333709717,
+ "cost_non_linearity": 959.7456665039062,
+ "cost_distance_total_intern_reflection": 13640.7861328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1160.json b/outputs/amici/optimization_results/step1/score_details_iteration_1160.json
new file mode 100755
index 0000000..6cab650
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1160.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.015871047973633,
+ "cost_distance_glasses": 814.4134301488675,
+ "cost_deviation": 11.169180870056152,
+ "cost_distorsion": 21.999755859375,
+ "cost_thickness": 3756.56787109375,
+ "cost_beam_compression": 2.147963523864746,
+ "cost_non_linearity": 959.3143310546875,
+ "cost_distance_total_intern_reflection": 13588.97265625
+ },
+ "weighted components": {
+ "cost_dispersion": 25.015871047973633,
+ "cost_distance_glasses": 814.4134301488675,
+ "cost_deviation": 11.169180870056152,
+ "cost_distorsion": 21.999755859375,
+ "cost_thickness": 3756.56787109375,
+ "cost_beam_compression": 2.147963523864746,
+ "cost_non_linearity": 959.3143310546875,
+ "cost_distance_total_intern_reflection": 13588.97265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.015871047973633,
+ "cost_distance_glasses": 814.4134301488675,
+ "cost_deviation": 11.169180870056152,
+ "cost_distorsion": 21.999755859375,
+ "cost_thickness": 3756.56787109375,
+ "cost_beam_compression": 2.147963523864746,
+ "cost_non_linearity": 959.3143310546875,
+ "cost_distance_total_intern_reflection": 13588.97265625
+ },
+ "weighted components": {
+ "cost_dispersion": 25.015871047973633,
+ "cost_distance_glasses": 814.4134301488675,
+ "cost_deviation": 11.169180870056152,
+ "cost_distorsion": 21.999755859375,
+ "cost_thickness": 3756.56787109375,
+ "cost_beam_compression": 2.147963523864746,
+ "cost_non_linearity": 959.3143310546875,
+ "cost_distance_total_intern_reflection": 13588.97265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1170.json b/outputs/amici/optimization_results/step1/score_details_iteration_1170.json
new file mode 100755
index 0000000..9e87dda
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1170.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.735328674316406,
+ "cost_distance_glasses": 808.8206561147508,
+ "cost_deviation": 6.038571357727051,
+ "cost_distorsion": 21.256370544433594,
+ "cost_thickness": 3754.50634765625,
+ "cost_beam_compression": 2.1460647583007812,
+ "cost_non_linearity": 958.1098022460938,
+ "cost_distance_total_intern_reflection": 13592.6171875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.735328674316406,
+ "cost_distance_glasses": 808.8206561147508,
+ "cost_deviation": 6.038571357727051,
+ "cost_distorsion": 21.256370544433594,
+ "cost_thickness": 3754.50634765625,
+ "cost_beam_compression": 2.1460647583007812,
+ "cost_non_linearity": 958.1098022460938,
+ "cost_distance_total_intern_reflection": 13592.6171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.735328674316406,
+ "cost_distance_glasses": 808.8206561147508,
+ "cost_deviation": 6.038571357727051,
+ "cost_distorsion": 21.256370544433594,
+ "cost_thickness": 3754.50634765625,
+ "cost_beam_compression": 2.1460647583007812,
+ "cost_non_linearity": 958.1098022460938,
+ "cost_distance_total_intern_reflection": 13592.6171875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.735328674316406,
+ "cost_distance_glasses": 808.8206561147508,
+ "cost_deviation": 6.038571357727051,
+ "cost_distorsion": 21.256370544433594,
+ "cost_thickness": 3754.50634765625,
+ "cost_beam_compression": 2.1460647583007812,
+ "cost_non_linearity": 958.1098022460938,
+ "cost_distance_total_intern_reflection": 13592.6171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1180.json b/outputs/amici/optimization_results/step1/score_details_iteration_1180.json
new file mode 100755
index 0000000..4f9e07c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1180.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 57.1369514465332,
+ "cost_distance_glasses": 801.239809220577,
+ "cost_deviation": 2.3960955142974854,
+ "cost_distorsion": 25.393068313598633,
+ "cost_thickness": 3753.704345703125,
+ "cost_beam_compression": 2.142636775970459,
+ "cost_non_linearity": 954.2283935546875,
+ "cost_distance_total_intern_reflection": 13612.69921875
+ },
+ "weighted components": {
+ "cost_dispersion": 57.1369514465332,
+ "cost_distance_glasses": 801.239809220577,
+ "cost_deviation": 2.3960955142974854,
+ "cost_distorsion": 25.393068313598633,
+ "cost_thickness": 3753.704345703125,
+ "cost_beam_compression": 2.142636775970459,
+ "cost_non_linearity": 954.2283935546875,
+ "cost_distance_total_intern_reflection": 13612.69921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 57.1369514465332,
+ "cost_distance_glasses": 801.239809220577,
+ "cost_deviation": 2.3960955142974854,
+ "cost_distorsion": 25.393068313598633,
+ "cost_thickness": 3753.704345703125,
+ "cost_beam_compression": 2.142636775970459,
+ "cost_non_linearity": 954.2283935546875,
+ "cost_distance_total_intern_reflection": 13612.69921875
+ },
+ "weighted components": {
+ "cost_dispersion": 57.1369514465332,
+ "cost_distance_glasses": 801.239809220577,
+ "cost_deviation": 2.3960955142974854,
+ "cost_distorsion": 25.393068313598633,
+ "cost_thickness": 3753.704345703125,
+ "cost_beam_compression": 2.142636775970459,
+ "cost_non_linearity": 954.2283935546875,
+ "cost_distance_total_intern_reflection": 13612.69921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1190.json b/outputs/amici/optimization_results/step1/score_details_iteration_1190.json
new file mode 100755
index 0000000..c90a3de
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1190.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 38.21268081665039,
+ "cost_distance_glasses": 800.1331533605832,
+ "cost_deviation": 1.6080492734909058,
+ "cost_distorsion": 22.171255111694336,
+ "cost_thickness": 3750.912841796875,
+ "cost_beam_compression": 2.142997980117798,
+ "cost_non_linearity": 957.1276245117188,
+ "cost_distance_total_intern_reflection": 13571.142578125
+ },
+ "weighted components": {
+ "cost_dispersion": 38.21268081665039,
+ "cost_distance_glasses": 800.1331533605832,
+ "cost_deviation": 1.6080492734909058,
+ "cost_distorsion": 22.171255111694336,
+ "cost_thickness": 3750.912841796875,
+ "cost_beam_compression": 2.142997980117798,
+ "cost_non_linearity": 957.1276245117188,
+ "cost_distance_total_intern_reflection": 13571.142578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 38.21268081665039,
+ "cost_distance_glasses": 800.1331533605832,
+ "cost_deviation": 1.6080492734909058,
+ "cost_distorsion": 22.171255111694336,
+ "cost_thickness": 3750.912841796875,
+ "cost_beam_compression": 2.142997980117798,
+ "cost_non_linearity": 957.1276245117188,
+ "cost_distance_total_intern_reflection": 13571.142578125
+ },
+ "weighted components": {
+ "cost_dispersion": 38.21268081665039,
+ "cost_distance_glasses": 800.1331533605832,
+ "cost_deviation": 1.6080492734909058,
+ "cost_distorsion": 22.171255111694336,
+ "cost_thickness": 3750.912841796875,
+ "cost_beam_compression": 2.142997980117798,
+ "cost_non_linearity": 957.1276245117188,
+ "cost_distance_total_intern_reflection": 13571.142578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_120.json b/outputs/amici/optimization_results/step1/score_details_iteration_120.json
new file mode 100755
index 0000000..f04cada
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_120.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 341.3157043457031,
+ "cost_distance_glasses": 2053.18665834132,
+ "cost_deviation": 65.38525390625,
+ "cost_distorsion": 19.91150665283203,
+ "cost_thickness": 4001.521484375,
+ "cost_beam_compression": 2.291276454925537,
+ "cost_non_linearity": 933.2816162109375,
+ "cost_distance_total_intern_reflection": 13944.08203125
+ },
+ "weighted components": {
+ "cost_dispersion": 341.3157043457031,
+ "cost_distance_glasses": 2053.18665834132,
+ "cost_deviation": 65.38525390625,
+ "cost_distorsion": 19.91150665283203,
+ "cost_thickness": 4001.521484375,
+ "cost_beam_compression": 2.291276454925537,
+ "cost_non_linearity": 933.2816162109375,
+ "cost_distance_total_intern_reflection": 13944.08203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 341.3157043457031,
+ "cost_distance_glasses": 2053.18665834132,
+ "cost_deviation": 65.38525390625,
+ "cost_distorsion": 19.91150665283203,
+ "cost_thickness": 4001.521484375,
+ "cost_beam_compression": 2.291276454925537,
+ "cost_non_linearity": 933.2816162109375,
+ "cost_distance_total_intern_reflection": 13944.08203125
+ },
+ "weighted components": {
+ "cost_dispersion": 341.3157043457031,
+ "cost_distance_glasses": 2053.18665834132,
+ "cost_deviation": 65.38525390625,
+ "cost_distorsion": 19.91150665283203,
+ "cost_thickness": 4001.521484375,
+ "cost_beam_compression": 2.291276454925537,
+ "cost_non_linearity": 933.2816162109375,
+ "cost_distance_total_intern_reflection": 13944.08203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1200.json b/outputs/amici/optimization_results/step1/score_details_iteration_1200.json
new file mode 100755
index 0000000..2bf8b64
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1200.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.086551666259766,
+ "cost_distance_glasses": 794.28502711736,
+ "cost_deviation": 0.043707460165023804,
+ "cost_distorsion": 25.20401382446289,
+ "cost_thickness": 3749.819091796875,
+ "cost_beam_compression": 2.1416842937469482,
+ "cost_non_linearity": 956.1942749023438,
+ "cost_distance_total_intern_reflection": 13622.8447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 44.086551666259766,
+ "cost_distance_glasses": 794.28502711736,
+ "cost_deviation": 0.043707460165023804,
+ "cost_distorsion": 25.20401382446289,
+ "cost_thickness": 3749.819091796875,
+ "cost_beam_compression": 2.1416842937469482,
+ "cost_non_linearity": 956.1942749023438,
+ "cost_distance_total_intern_reflection": 13622.8447265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.086551666259766,
+ "cost_distance_glasses": 794.28502711736,
+ "cost_deviation": 0.043707460165023804,
+ "cost_distorsion": 25.20401382446289,
+ "cost_thickness": 3749.819091796875,
+ "cost_beam_compression": 2.1416842937469482,
+ "cost_non_linearity": 956.1942749023438,
+ "cost_distance_total_intern_reflection": 13622.8447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 44.086551666259766,
+ "cost_distance_glasses": 794.28502711736,
+ "cost_deviation": 0.043707460165023804,
+ "cost_distorsion": 25.20401382446289,
+ "cost_thickness": 3749.819091796875,
+ "cost_beam_compression": 2.1416842937469482,
+ "cost_non_linearity": 956.1942749023438,
+ "cost_distance_total_intern_reflection": 13622.8447265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1210.json b/outputs/amici/optimization_results/step1/score_details_iteration_1210.json
new file mode 100755
index 0000000..d00db84
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1210.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 20.879945755004883,
+ "cost_distance_glasses": 796.0760323579418,
+ "cost_deviation": 21.512300491333008,
+ "cost_distorsion": 19.159513473510742,
+ "cost_thickness": 3746.423828125,
+ "cost_beam_compression": 2.142948627471924,
+ "cost_non_linearity": 959.9381103515625,
+ "cost_distance_total_intern_reflection": 13623.857421875
+ },
+ "weighted components": {
+ "cost_dispersion": 20.879945755004883,
+ "cost_distance_glasses": 796.0760323579418,
+ "cost_deviation": 21.512300491333008,
+ "cost_distorsion": 19.159513473510742,
+ "cost_thickness": 3746.423828125,
+ "cost_beam_compression": 2.142948627471924,
+ "cost_non_linearity": 959.9381103515625,
+ "cost_distance_total_intern_reflection": 13623.857421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 20.879945755004883,
+ "cost_distance_glasses": 796.0760323579418,
+ "cost_deviation": 21.512300491333008,
+ "cost_distorsion": 19.159513473510742,
+ "cost_thickness": 3746.423828125,
+ "cost_beam_compression": 2.142948627471924,
+ "cost_non_linearity": 959.9381103515625,
+ "cost_distance_total_intern_reflection": 13623.857421875
+ },
+ "weighted components": {
+ "cost_dispersion": 20.879945755004883,
+ "cost_distance_glasses": 796.0760323579418,
+ "cost_deviation": 21.512300491333008,
+ "cost_distorsion": 19.159513473510742,
+ "cost_thickness": 3746.423828125,
+ "cost_beam_compression": 2.142948627471924,
+ "cost_non_linearity": 959.9381103515625,
+ "cost_distance_total_intern_reflection": 13623.857421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1220.json b/outputs/amici/optimization_results/step1/score_details_iteration_1220.json
new file mode 100755
index 0000000..14971b6
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1220.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.311800003051758,
+ "cost_distance_glasses": 789.670358835447,
+ "cost_deviation": 6.919540882110596,
+ "cost_distorsion": 21.758390426635742,
+ "cost_thickness": 3745.83984375,
+ "cost_beam_compression": 2.1409881114959717,
+ "cost_non_linearity": 958.1409912109375,
+ "cost_distance_total_intern_reflection": 13567.8125
+ },
+ "weighted components": {
+ "cost_dispersion": 30.311800003051758,
+ "cost_distance_glasses": 789.670358835447,
+ "cost_deviation": 6.919540882110596,
+ "cost_distorsion": 21.758390426635742,
+ "cost_thickness": 3745.83984375,
+ "cost_beam_compression": 2.1409881114959717,
+ "cost_non_linearity": 958.1409912109375,
+ "cost_distance_total_intern_reflection": 13567.8125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.311800003051758,
+ "cost_distance_glasses": 789.670358835447,
+ "cost_deviation": 6.919540882110596,
+ "cost_distorsion": 21.758390426635742,
+ "cost_thickness": 3745.83984375,
+ "cost_beam_compression": 2.1409881114959717,
+ "cost_non_linearity": 958.1409912109375,
+ "cost_distance_total_intern_reflection": 13567.8125
+ },
+ "weighted components": {
+ "cost_dispersion": 30.311800003051758,
+ "cost_distance_glasses": 789.670358835447,
+ "cost_deviation": 6.919540882110596,
+ "cost_distorsion": 21.758390426635742,
+ "cost_thickness": 3745.83984375,
+ "cost_beam_compression": 2.1409881114959717,
+ "cost_non_linearity": 958.1409912109375,
+ "cost_distance_total_intern_reflection": 13567.8125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1230.json b/outputs/amici/optimization_results/step1/score_details_iteration_1230.json
new file mode 100755
index 0000000..cfa14bc
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1230.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.821876525878906,
+ "cost_distance_glasses": 786.7497477616666,
+ "cost_deviation": 0.01770692504942417,
+ "cost_distorsion": 22.821651458740234,
+ "cost_thickness": 3744.821044921875,
+ "cost_beam_compression": 2.1384949684143066,
+ "cost_non_linearity": 955.6814575195312,
+ "cost_distance_total_intern_reflection": 13560.6953125
+ },
+ "weighted components": {
+ "cost_dispersion": 46.821876525878906,
+ "cost_distance_glasses": 786.7497477616666,
+ "cost_deviation": 0.01770692504942417,
+ "cost_distorsion": 22.821651458740234,
+ "cost_thickness": 3744.821044921875,
+ "cost_beam_compression": 2.1384949684143066,
+ "cost_non_linearity": 955.6814575195312,
+ "cost_distance_total_intern_reflection": 13560.6953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.821876525878906,
+ "cost_distance_glasses": 786.7497477616666,
+ "cost_deviation": 0.01770692504942417,
+ "cost_distorsion": 22.821651458740234,
+ "cost_thickness": 3744.821044921875,
+ "cost_beam_compression": 2.1384949684143066,
+ "cost_non_linearity": 955.6814575195312,
+ "cost_distance_total_intern_reflection": 13560.6953125
+ },
+ "weighted components": {
+ "cost_dispersion": 46.821876525878906,
+ "cost_distance_glasses": 786.7497477616666,
+ "cost_deviation": 0.01770692504942417,
+ "cost_distorsion": 22.821651458740234,
+ "cost_thickness": 3744.821044921875,
+ "cost_beam_compression": 2.1384949684143066,
+ "cost_non_linearity": 955.6814575195312,
+ "cost_distance_total_intern_reflection": 13560.6953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1240.json b/outputs/amici/optimization_results/step1/score_details_iteration_1240.json
new file mode 100755
index 0000000..57ad86c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1240.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.145538330078125,
+ "cost_distance_glasses": 784.3741231935688,
+ "cost_deviation": 9.42725944519043,
+ "cost_distorsion": 21.64636993408203,
+ "cost_thickness": 3743.107421875,
+ "cost_beam_compression": 2.1396851539611816,
+ "cost_non_linearity": 958.6423950195312,
+ "cost_distance_total_intern_reflection": 13565.6455078125
+ },
+ "weighted components": {
+ "cost_dispersion": 28.145538330078125,
+ "cost_distance_glasses": 784.3741231935688,
+ "cost_deviation": 9.42725944519043,
+ "cost_distorsion": 21.64636993408203,
+ "cost_thickness": 3743.107421875,
+ "cost_beam_compression": 2.1396851539611816,
+ "cost_non_linearity": 958.6423950195312,
+ "cost_distance_total_intern_reflection": 13565.6455078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.145538330078125,
+ "cost_distance_glasses": 784.3741231935688,
+ "cost_deviation": 9.42725944519043,
+ "cost_distorsion": 21.64636993408203,
+ "cost_thickness": 3743.107421875,
+ "cost_beam_compression": 2.1396851539611816,
+ "cost_non_linearity": 958.6423950195312,
+ "cost_distance_total_intern_reflection": 13565.6455078125
+ },
+ "weighted components": {
+ "cost_dispersion": 28.145538330078125,
+ "cost_distance_glasses": 784.3741231935688,
+ "cost_deviation": 9.42725944519043,
+ "cost_distorsion": 21.64636993408203,
+ "cost_thickness": 3743.107421875,
+ "cost_beam_compression": 2.1396851539611816,
+ "cost_non_linearity": 958.6423950195312,
+ "cost_distance_total_intern_reflection": 13565.6455078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1250.json b/outputs/amici/optimization_results/step1/score_details_iteration_1250.json
new file mode 100755
index 0000000..91188db
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1250.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.641834259033203,
+ "cost_distance_glasses": 783.5464494762659,
+ "cost_deviation": 9.460229873657227,
+ "cost_distorsion": 20.947660446166992,
+ "cost_thickness": 3741.719970703125,
+ "cost_beam_compression": 2.1388702392578125,
+ "cost_non_linearity": 958.4049682617188,
+ "cost_distance_total_intern_reflection": 13579.92578125
+ },
+ "weighted components": {
+ "cost_dispersion": 28.641834259033203,
+ "cost_distance_glasses": 783.5464494762659,
+ "cost_deviation": 9.460229873657227,
+ "cost_distorsion": 20.947660446166992,
+ "cost_thickness": 3741.719970703125,
+ "cost_beam_compression": 2.1388702392578125,
+ "cost_non_linearity": 958.4049682617188,
+ "cost_distance_total_intern_reflection": 13579.92578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.641834259033203,
+ "cost_distance_glasses": 783.5464494762659,
+ "cost_deviation": 9.460229873657227,
+ "cost_distorsion": 20.947660446166992,
+ "cost_thickness": 3741.719970703125,
+ "cost_beam_compression": 2.1388702392578125,
+ "cost_non_linearity": 958.4049682617188,
+ "cost_distance_total_intern_reflection": 13579.92578125
+ },
+ "weighted components": {
+ "cost_dispersion": 28.641834259033203,
+ "cost_distance_glasses": 783.5464494762659,
+ "cost_deviation": 9.460229873657227,
+ "cost_distorsion": 20.947660446166992,
+ "cost_thickness": 3741.719970703125,
+ "cost_beam_compression": 2.1388702392578125,
+ "cost_non_linearity": 958.4049682617188,
+ "cost_distance_total_intern_reflection": 13579.92578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1260.json b/outputs/amici/optimization_results/step1/score_details_iteration_1260.json
new file mode 100755
index 0000000..b2cbdd2
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1260.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.44292449951172,
+ "cost_distance_glasses": 780.2767780891508,
+ "cost_deviation": 9.521744728088379,
+ "cost_distorsion": 21.39990997314453,
+ "cost_thickness": 3740.73828125,
+ "cost_beam_compression": 2.1382832527160645,
+ "cost_non_linearity": 958.7904052734375,
+ "cost_distance_total_intern_reflection": 13567.4375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.44292449951172,
+ "cost_distance_glasses": 780.2767780891508,
+ "cost_deviation": 9.521744728088379,
+ "cost_distorsion": 21.39990997314453,
+ "cost_thickness": 3740.73828125,
+ "cost_beam_compression": 2.1382832527160645,
+ "cost_non_linearity": 958.7904052734375,
+ "cost_distance_total_intern_reflection": 13567.4375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.44292449951172,
+ "cost_distance_glasses": 780.2767780891508,
+ "cost_deviation": 9.521744728088379,
+ "cost_distorsion": 21.39990997314453,
+ "cost_thickness": 3740.73828125,
+ "cost_beam_compression": 2.1382832527160645,
+ "cost_non_linearity": 958.7904052734375,
+ "cost_distance_total_intern_reflection": 13567.4375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.44292449951172,
+ "cost_distance_glasses": 780.2767780891508,
+ "cost_deviation": 9.521744728088379,
+ "cost_distorsion": 21.39990997314453,
+ "cost_thickness": 3740.73828125,
+ "cost_beam_compression": 2.1382832527160645,
+ "cost_non_linearity": 958.7904052734375,
+ "cost_distance_total_intern_reflection": 13567.4375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1270.json b/outputs/amici/optimization_results/step1/score_details_iteration_1270.json
new file mode 100755
index 0000000..c37b979
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1270.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 43.12490463256836,
+ "cost_distance_glasses": 776.0311035993935,
+ "cost_deviation": 0.42209792137145996,
+ "cost_distorsion": 23.56163215637207,
+ "cost_thickness": 3740.489990234375,
+ "cost_beam_compression": 2.1363301277160645,
+ "cost_non_linearity": 956.2947387695312,
+ "cost_distance_total_intern_reflection": 13576.25390625
+ },
+ "weighted components": {
+ "cost_dispersion": 43.12490463256836,
+ "cost_distance_glasses": 776.0311035993935,
+ "cost_deviation": 0.42209792137145996,
+ "cost_distorsion": 23.56163215637207,
+ "cost_thickness": 3740.489990234375,
+ "cost_beam_compression": 2.1363301277160645,
+ "cost_non_linearity": 956.2947387695312,
+ "cost_distance_total_intern_reflection": 13576.25390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 43.12490463256836,
+ "cost_distance_glasses": 776.0311035993935,
+ "cost_deviation": 0.42209792137145996,
+ "cost_distorsion": 23.56163215637207,
+ "cost_thickness": 3740.489990234375,
+ "cost_beam_compression": 2.1363301277160645,
+ "cost_non_linearity": 956.2947387695312,
+ "cost_distance_total_intern_reflection": 13576.25390625
+ },
+ "weighted components": {
+ "cost_dispersion": 43.12490463256836,
+ "cost_distance_glasses": 776.0311035993935,
+ "cost_deviation": 0.42209792137145996,
+ "cost_distorsion": 23.56163215637207,
+ "cost_thickness": 3740.489990234375,
+ "cost_beam_compression": 2.1363301277160645,
+ "cost_non_linearity": 956.2947387695312,
+ "cost_distance_total_intern_reflection": 13576.25390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1280.json b/outputs/amici/optimization_results/step1/score_details_iteration_1280.json
new file mode 100755
index 0000000..70ebc98
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1280.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.979026794433594,
+ "cost_distance_glasses": 775.56564473925,
+ "cost_deviation": 5.833815097808838,
+ "cost_distorsion": 20.724477767944336,
+ "cost_thickness": 3738.8583984375,
+ "cost_beam_compression": 2.1366934776306152,
+ "cost_non_linearity": 957.6902465820312,
+ "cost_distance_total_intern_reflection": 13583.931640625
+ },
+ "weighted components": {
+ "cost_dispersion": 32.979026794433594,
+ "cost_distance_glasses": 775.56564473925,
+ "cost_deviation": 5.833815097808838,
+ "cost_distorsion": 20.724477767944336,
+ "cost_thickness": 3738.8583984375,
+ "cost_beam_compression": 2.1366934776306152,
+ "cost_non_linearity": 957.6902465820312,
+ "cost_distance_total_intern_reflection": 13583.931640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.979026794433594,
+ "cost_distance_glasses": 775.56564473925,
+ "cost_deviation": 5.833815097808838,
+ "cost_distorsion": 20.724477767944336,
+ "cost_thickness": 3738.8583984375,
+ "cost_beam_compression": 2.1366934776306152,
+ "cost_non_linearity": 957.6902465820312,
+ "cost_distance_total_intern_reflection": 13583.931640625
+ },
+ "weighted components": {
+ "cost_dispersion": 32.979026794433594,
+ "cost_distance_glasses": 775.56564473925,
+ "cost_deviation": 5.833815097808838,
+ "cost_distorsion": 20.724477767944336,
+ "cost_thickness": 3738.8583984375,
+ "cost_beam_compression": 2.1366934776306152,
+ "cost_non_linearity": 957.6902465820312,
+ "cost_distance_total_intern_reflection": 13583.931640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1290.json b/outputs/amici/optimization_results/step1/score_details_iteration_1290.json
new file mode 100755
index 0000000..60f5e64
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1290.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.3656120300293,
+ "cost_distance_glasses": 772.6957702739708,
+ "cost_deviation": 3.4340107440948486,
+ "cost_distorsion": 22.474916458129883,
+ "cost_thickness": 3738.567138671875,
+ "cost_beam_compression": 2.1360743045806885,
+ "cost_non_linearity": 957.56884765625,
+ "cost_distance_total_intern_reflection": 13561.837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.3656120300293,
+ "cost_distance_glasses": 772.6957702739708,
+ "cost_deviation": 3.4340107440948486,
+ "cost_distorsion": 22.474916458129883,
+ "cost_thickness": 3738.567138671875,
+ "cost_beam_compression": 2.1360743045806885,
+ "cost_non_linearity": 957.56884765625,
+ "cost_distance_total_intern_reflection": 13561.837890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.3656120300293,
+ "cost_distance_glasses": 772.6957702739708,
+ "cost_deviation": 3.4340107440948486,
+ "cost_distorsion": 22.474916458129883,
+ "cost_thickness": 3738.567138671875,
+ "cost_beam_compression": 2.1360743045806885,
+ "cost_non_linearity": 957.56884765625,
+ "cost_distance_total_intern_reflection": 13561.837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.3656120300293,
+ "cost_distance_glasses": 772.6957702739708,
+ "cost_deviation": 3.4340107440948486,
+ "cost_distorsion": 22.474916458129883,
+ "cost_thickness": 3738.567138671875,
+ "cost_beam_compression": 2.1360743045806885,
+ "cost_non_linearity": 957.56884765625,
+ "cost_distance_total_intern_reflection": 13561.837890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_130.json b/outputs/amici/optimization_results/step1/score_details_iteration_130.json
new file mode 100755
index 0000000..0d87c27
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_130.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 306.3653564453125,
+ "cost_distance_glasses": 1869.584139785671,
+ "cost_deviation": 44.786354064941406,
+ "cost_distorsion": 20.39447784423828,
+ "cost_thickness": 4018.9404296875,
+ "cost_beam_compression": 2.301459312438965,
+ "cost_non_linearity": 935.2412719726562,
+ "cost_distance_total_intern_reflection": 13967.400390625
+ },
+ "weighted components": {
+ "cost_dispersion": 306.3653564453125,
+ "cost_distance_glasses": 1869.584139785671,
+ "cost_deviation": 44.786354064941406,
+ "cost_distorsion": 20.39447784423828,
+ "cost_thickness": 4018.9404296875,
+ "cost_beam_compression": 2.301459312438965,
+ "cost_non_linearity": 935.2412719726562,
+ "cost_distance_total_intern_reflection": 13967.400390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 306.3653564453125,
+ "cost_distance_glasses": 1869.584139785671,
+ "cost_deviation": 44.786354064941406,
+ "cost_distorsion": 20.39447784423828,
+ "cost_thickness": 4018.9404296875,
+ "cost_beam_compression": 2.301459312438965,
+ "cost_non_linearity": 935.2412719726562,
+ "cost_distance_total_intern_reflection": 13967.400390625
+ },
+ "weighted components": {
+ "cost_dispersion": 306.3653564453125,
+ "cost_distance_glasses": 1869.584139785671,
+ "cost_deviation": 44.786354064941406,
+ "cost_distorsion": 20.39447784423828,
+ "cost_thickness": 4018.9404296875,
+ "cost_beam_compression": 2.301459312438965,
+ "cost_non_linearity": 935.2412719726562,
+ "cost_distance_total_intern_reflection": 13967.400390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1300.json b/outputs/amici/optimization_results/step1/score_details_iteration_1300.json
new file mode 100755
index 0000000..551b097
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1300.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 42.500308990478516,
+ "cost_distance_glasses": 769.5030176525559,
+ "cost_deviation": 0.5026770830154419,
+ "cost_distorsion": 23.657733917236328,
+ "cost_thickness": 3738.23291015625,
+ "cost_beam_compression": 2.1350502967834473,
+ "cost_non_linearity": 956.4365234375,
+ "cost_distance_total_intern_reflection": 13576.7373046875
+ },
+ "weighted components": {
+ "cost_dispersion": 42.500308990478516,
+ "cost_distance_glasses": 769.5030176525559,
+ "cost_deviation": 0.5026770830154419,
+ "cost_distorsion": 23.657733917236328,
+ "cost_thickness": 3738.23291015625,
+ "cost_beam_compression": 2.1350502967834473,
+ "cost_non_linearity": 956.4365234375,
+ "cost_distance_total_intern_reflection": 13576.7373046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 42.500308990478516,
+ "cost_distance_glasses": 769.5030176525559,
+ "cost_deviation": 0.5026770830154419,
+ "cost_distorsion": 23.657733917236328,
+ "cost_thickness": 3738.23291015625,
+ "cost_beam_compression": 2.1350502967834473,
+ "cost_non_linearity": 956.4365234375,
+ "cost_distance_total_intern_reflection": 13576.7373046875
+ },
+ "weighted components": {
+ "cost_dispersion": 42.500308990478516,
+ "cost_distance_glasses": 769.5030176525559,
+ "cost_deviation": 0.5026770830154419,
+ "cost_distorsion": 23.657733917236328,
+ "cost_thickness": 3738.23291015625,
+ "cost_beam_compression": 2.1350502967834473,
+ "cost_non_linearity": 956.4365234375,
+ "cost_distance_total_intern_reflection": 13576.7373046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1310.json b/outputs/amici/optimization_results/step1/score_details_iteration_1310.json
new file mode 100755
index 0000000..542b6fb
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1310.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.933380126953125,
+ "cost_distance_glasses": 769.1376512504438,
+ "cost_deviation": 3.668168306350708,
+ "cost_distorsion": 21.322986602783203,
+ "cost_thickness": 3736.971435546875,
+ "cost_beam_compression": 2.135186195373535,
+ "cost_non_linearity": 957.302001953125,
+ "cost_distance_total_intern_reflection": 13567.9736328125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.933380126953125,
+ "cost_distance_glasses": 769.1376512504438,
+ "cost_deviation": 3.668168306350708,
+ "cost_distorsion": 21.322986602783203,
+ "cost_thickness": 3736.971435546875,
+ "cost_beam_compression": 2.135186195373535,
+ "cost_non_linearity": 957.302001953125,
+ "cost_distance_total_intern_reflection": 13567.9736328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.933380126953125,
+ "cost_distance_glasses": 769.1376512504438,
+ "cost_deviation": 3.668168306350708,
+ "cost_distorsion": 21.322986602783203,
+ "cost_thickness": 3736.971435546875,
+ "cost_beam_compression": 2.135186195373535,
+ "cost_non_linearity": 957.302001953125,
+ "cost_distance_total_intern_reflection": 13567.9736328125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.933380126953125,
+ "cost_distance_glasses": 769.1376512504438,
+ "cost_deviation": 3.668168306350708,
+ "cost_distorsion": 21.322986602783203,
+ "cost_thickness": 3736.971435546875,
+ "cost_beam_compression": 2.135186195373535,
+ "cost_non_linearity": 957.302001953125,
+ "cost_distance_total_intern_reflection": 13567.9736328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1320.json b/outputs/amici/optimization_results/step1/score_details_iteration_1320.json
new file mode 100755
index 0000000..978b97a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1320.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.56153869628906,
+ "cost_distance_glasses": 766.8383028012722,
+ "cost_deviation": 4.154181003570557,
+ "cost_distorsion": 22.191444396972656,
+ "cost_thickness": 3736.626708984375,
+ "cost_beam_compression": 2.135071277618408,
+ "cost_non_linearity": 957.5435180664062,
+ "cost_distance_total_intern_reflection": 13554.8984375
+ },
+ "weighted components": {
+ "cost_dispersion": 34.56153869628906,
+ "cost_distance_glasses": 766.8383028012722,
+ "cost_deviation": 4.154181003570557,
+ "cost_distorsion": 22.191444396972656,
+ "cost_thickness": 3736.626708984375,
+ "cost_beam_compression": 2.135071277618408,
+ "cost_non_linearity": 957.5435180664062,
+ "cost_distance_total_intern_reflection": 13554.8984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.56153869628906,
+ "cost_distance_glasses": 766.8383028012722,
+ "cost_deviation": 4.154181003570557,
+ "cost_distorsion": 22.191444396972656,
+ "cost_thickness": 3736.626708984375,
+ "cost_beam_compression": 2.135071277618408,
+ "cost_non_linearity": 957.5435180664062,
+ "cost_distance_total_intern_reflection": 13554.8984375
+ },
+ "weighted components": {
+ "cost_dispersion": 34.56153869628906,
+ "cost_distance_glasses": 766.8383028012722,
+ "cost_deviation": 4.154181003570557,
+ "cost_distorsion": 22.191444396972656,
+ "cost_thickness": 3736.626708984375,
+ "cost_beam_compression": 2.135071277618408,
+ "cost_non_linearity": 957.5435180664062,
+ "cost_distance_total_intern_reflection": 13554.8984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1330.json b/outputs/amici/optimization_results/step1/score_details_iteration_1330.json
new file mode 100755
index 0000000..fb00208
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1330.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.69977951049805,
+ "cost_distance_glasses": 764.7327398405301,
+ "cost_deviation": 2.316044330596924,
+ "cost_distorsion": 22.75162124633789,
+ "cost_thickness": 3736.301025390625,
+ "cost_beam_compression": 2.134500741958618,
+ "cost_non_linearity": 957.1179809570312,
+ "cost_distance_total_intern_reflection": 13560.73046875
+ },
+ "weighted components": {
+ "cost_dispersion": 37.69977951049805,
+ "cost_distance_glasses": 764.7327398405301,
+ "cost_deviation": 2.316044330596924,
+ "cost_distorsion": 22.75162124633789,
+ "cost_thickness": 3736.301025390625,
+ "cost_beam_compression": 2.134500741958618,
+ "cost_non_linearity": 957.1179809570312,
+ "cost_distance_total_intern_reflection": 13560.73046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.69977951049805,
+ "cost_distance_glasses": 764.7327398405301,
+ "cost_deviation": 2.316044330596924,
+ "cost_distorsion": 22.75162124633789,
+ "cost_thickness": 3736.301025390625,
+ "cost_beam_compression": 2.134500741958618,
+ "cost_non_linearity": 957.1179809570312,
+ "cost_distance_total_intern_reflection": 13560.73046875
+ },
+ "weighted components": {
+ "cost_dispersion": 37.69977951049805,
+ "cost_distance_glasses": 764.7327398405301,
+ "cost_deviation": 2.316044330596924,
+ "cost_distorsion": 22.75162124633789,
+ "cost_thickness": 3736.301025390625,
+ "cost_beam_compression": 2.134500741958618,
+ "cost_non_linearity": 957.1179809570312,
+ "cost_distance_total_intern_reflection": 13560.73046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1340.json b/outputs/amici/optimization_results/step1/score_details_iteration_1340.json
new file mode 100755
index 0000000..d1edb0d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1340.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.9759407043457,
+ "cost_distance_glasses": 762.3802071826499,
+ "cost_deviation": 1.129439353942871,
+ "cost_distorsion": 22.507038116455078,
+ "cost_thickness": 3735.83544921875,
+ "cost_beam_compression": 2.1338796615600586,
+ "cost_non_linearity": 956.4086303710938,
+ "cost_distance_total_intern_reflection": 13550.4970703125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.9759407043457,
+ "cost_distance_glasses": 762.3802071826499,
+ "cost_deviation": 1.129439353942871,
+ "cost_distorsion": 22.507038116455078,
+ "cost_thickness": 3735.83544921875,
+ "cost_beam_compression": 2.1338796615600586,
+ "cost_non_linearity": 956.4086303710938,
+ "cost_distance_total_intern_reflection": 13550.4970703125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.9759407043457,
+ "cost_distance_glasses": 762.3802071826499,
+ "cost_deviation": 1.129439353942871,
+ "cost_distorsion": 22.507038116455078,
+ "cost_thickness": 3735.83544921875,
+ "cost_beam_compression": 2.1338796615600586,
+ "cost_non_linearity": 956.4086303710938,
+ "cost_distance_total_intern_reflection": 13550.4970703125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.9759407043457,
+ "cost_distance_glasses": 762.3802071826499,
+ "cost_deviation": 1.129439353942871,
+ "cost_distorsion": 22.507038116455078,
+ "cost_thickness": 3735.83544921875,
+ "cost_beam_compression": 2.1338796615600586,
+ "cost_non_linearity": 956.4086303710938,
+ "cost_distance_total_intern_reflection": 13550.4970703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1350.json b/outputs/amici/optimization_results/step1/score_details_iteration_1350.json
new file mode 100755
index 0000000..9d18977
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1350.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.85453224182129,
+ "cost_distance_glasses": 762.1363747931667,
+ "cost_deviation": 6.680960655212402,
+ "cost_distorsion": 21.47509002685547,
+ "cost_thickness": 3735.100830078125,
+ "cost_beam_compression": 2.134594440460205,
+ "cost_non_linearity": 958.048583984375,
+ "cost_distance_total_intern_reflection": 13559.1767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.85453224182129,
+ "cost_distance_glasses": 762.1363747931667,
+ "cost_deviation": 6.680960655212402,
+ "cost_distorsion": 21.47509002685547,
+ "cost_thickness": 3735.100830078125,
+ "cost_beam_compression": 2.134594440460205,
+ "cost_non_linearity": 958.048583984375,
+ "cost_distance_total_intern_reflection": 13559.1767578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.85453224182129,
+ "cost_distance_glasses": 762.1363747931667,
+ "cost_deviation": 6.680960655212402,
+ "cost_distorsion": 21.47509002685547,
+ "cost_thickness": 3735.100830078125,
+ "cost_beam_compression": 2.134594440460205,
+ "cost_non_linearity": 958.048583984375,
+ "cost_distance_total_intern_reflection": 13559.1767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.85453224182129,
+ "cost_distance_glasses": 762.1363747931667,
+ "cost_deviation": 6.680960655212402,
+ "cost_distorsion": 21.47509002685547,
+ "cost_thickness": 3735.100830078125,
+ "cost_beam_compression": 2.134594440460205,
+ "cost_non_linearity": 958.048583984375,
+ "cost_distance_total_intern_reflection": 13559.1767578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1360.json b/outputs/amici/optimization_results/step1/score_details_iteration_1360.json
new file mode 100755
index 0000000..55d346b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1360.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.76447677612305,
+ "cost_distance_glasses": 759.1165189830461,
+ "cost_deviation": 1.5329843759536743,
+ "cost_distorsion": 22.94326400756836,
+ "cost_thickness": 3735.23046875,
+ "cost_beam_compression": 2.1336781978607178,
+ "cost_non_linearity": 956.6328125,
+ "cost_distance_total_intern_reflection": 13561.3837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 39.76447677612305,
+ "cost_distance_glasses": 759.1165189830461,
+ "cost_deviation": 1.5329843759536743,
+ "cost_distorsion": 22.94326400756836,
+ "cost_thickness": 3735.23046875,
+ "cost_beam_compression": 2.1336781978607178,
+ "cost_non_linearity": 956.6328125,
+ "cost_distance_total_intern_reflection": 13561.3837890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.76447677612305,
+ "cost_distance_glasses": 759.1165189830461,
+ "cost_deviation": 1.5329843759536743,
+ "cost_distorsion": 22.94326400756836,
+ "cost_thickness": 3735.23046875,
+ "cost_beam_compression": 2.1336781978607178,
+ "cost_non_linearity": 956.6328125,
+ "cost_distance_total_intern_reflection": 13561.3837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 39.76447677612305,
+ "cost_distance_glasses": 759.1165189830461,
+ "cost_deviation": 1.5329843759536743,
+ "cost_distorsion": 22.94326400756836,
+ "cost_thickness": 3735.23046875,
+ "cost_beam_compression": 2.1336781978607178,
+ "cost_non_linearity": 956.6328125,
+ "cost_distance_total_intern_reflection": 13561.3837890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1370.json b/outputs/amici/optimization_results/step1/score_details_iteration_1370.json
new file mode 100755
index 0000000..f8a5e1f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1370.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.39683532714844,
+ "cost_distance_glasses": 758.4124035177101,
+ "cost_deviation": 4.074388027191162,
+ "cost_distorsion": 21.372135162353516,
+ "cost_thickness": 3734.534912109375,
+ "cost_beam_compression": 2.133852243423462,
+ "cost_non_linearity": 957.4221801757812,
+ "cost_distance_total_intern_reflection": 13561.916015625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.39683532714844,
+ "cost_distance_glasses": 758.4124035177101,
+ "cost_deviation": 4.074388027191162,
+ "cost_distorsion": 21.372135162353516,
+ "cost_thickness": 3734.534912109375,
+ "cost_beam_compression": 2.133852243423462,
+ "cost_non_linearity": 957.4221801757812,
+ "cost_distance_total_intern_reflection": 13561.916015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.39683532714844,
+ "cost_distance_glasses": 758.4124035177101,
+ "cost_deviation": 4.074388027191162,
+ "cost_distorsion": 21.372135162353516,
+ "cost_thickness": 3734.534912109375,
+ "cost_beam_compression": 2.133852243423462,
+ "cost_non_linearity": 957.4221801757812,
+ "cost_distance_total_intern_reflection": 13561.916015625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.39683532714844,
+ "cost_distance_glasses": 758.4124035177101,
+ "cost_deviation": 4.074388027191162,
+ "cost_distorsion": 21.372135162353516,
+ "cost_thickness": 3734.534912109375,
+ "cost_beam_compression": 2.133852243423462,
+ "cost_non_linearity": 957.4221801757812,
+ "cost_distance_total_intern_reflection": 13561.916015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1380.json b/outputs/amici/optimization_results/step1/score_details_iteration_1380.json
new file mode 100755
index 0000000..bce4553
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1380.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.34383773803711,
+ "cost_distance_glasses": 756.5758956896291,
+ "cost_deviation": 3.841987133026123,
+ "cost_distorsion": 22.360708236694336,
+ "cost_thickness": 3734.5166015625,
+ "cost_beam_compression": 2.1338038444519043,
+ "cost_non_linearity": 957.6176147460938,
+ "cost_distance_total_intern_reflection": 13553.3408203125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.34383773803711,
+ "cost_distance_glasses": 756.5758956896291,
+ "cost_deviation": 3.841987133026123,
+ "cost_distorsion": 22.360708236694336,
+ "cost_thickness": 3734.5166015625,
+ "cost_beam_compression": 2.1338038444519043,
+ "cost_non_linearity": 957.6176147460938,
+ "cost_distance_total_intern_reflection": 13553.3408203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.34383773803711,
+ "cost_distance_glasses": 756.5758956896291,
+ "cost_deviation": 3.841987133026123,
+ "cost_distorsion": 22.360708236694336,
+ "cost_thickness": 3734.5166015625,
+ "cost_beam_compression": 2.1338038444519043,
+ "cost_non_linearity": 957.6176147460938,
+ "cost_distance_total_intern_reflection": 13553.3408203125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.34383773803711,
+ "cost_distance_glasses": 756.5758956896291,
+ "cost_deviation": 3.841987133026123,
+ "cost_distorsion": 22.360708236694336,
+ "cost_thickness": 3734.5166015625,
+ "cost_beam_compression": 2.1338038444519043,
+ "cost_non_linearity": 957.6176147460938,
+ "cost_distance_total_intern_reflection": 13553.3408203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1390.json b/outputs/amici/optimization_results/step1/score_details_iteration_1390.json
new file mode 100755
index 0000000..37a2fa0
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1390.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 38.88570022583008,
+ "cost_distance_glasses": 754.9694616002789,
+ "cost_deviation": 2.066020965576172,
+ "cost_distorsion": 22.498170852661133,
+ "cost_thickness": 3734.3681640625,
+ "cost_beam_compression": 2.1333301067352295,
+ "cost_non_linearity": 956.892578125,
+ "cost_distance_total_intern_reflection": 13550.5322265625
+ },
+ "weighted components": {
+ "cost_dispersion": 38.88570022583008,
+ "cost_distance_glasses": 754.9694616002789,
+ "cost_deviation": 2.066020965576172,
+ "cost_distorsion": 22.498170852661133,
+ "cost_thickness": 3734.3681640625,
+ "cost_beam_compression": 2.1333301067352295,
+ "cost_non_linearity": 956.892578125,
+ "cost_distance_total_intern_reflection": 13550.5322265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 38.88570022583008,
+ "cost_distance_glasses": 754.9694616002789,
+ "cost_deviation": 2.066020965576172,
+ "cost_distorsion": 22.498170852661133,
+ "cost_thickness": 3734.3681640625,
+ "cost_beam_compression": 2.1333301067352295,
+ "cost_non_linearity": 956.892578125,
+ "cost_distance_total_intern_reflection": 13550.5322265625
+ },
+ "weighted components": {
+ "cost_dispersion": 38.88570022583008,
+ "cost_distance_glasses": 754.9694616002789,
+ "cost_deviation": 2.066020965576172,
+ "cost_distorsion": 22.498170852661133,
+ "cost_thickness": 3734.3681640625,
+ "cost_beam_compression": 2.1333301067352295,
+ "cost_non_linearity": 956.892578125,
+ "cost_distance_total_intern_reflection": 13550.5322265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_140.json b/outputs/amici/optimization_results/step1/score_details_iteration_140.json
new file mode 100755
index 0000000..a957ab8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_140.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 258.4315185546875,
+ "cost_distance_glasses": 1870.8844880976671,
+ "cost_deviation": 47.017330169677734,
+ "cost_distorsion": 20.916179656982422,
+ "cost_thickness": 4033.57666015625,
+ "cost_beam_compression": 2.3108112812042236,
+ "cost_non_linearity": 937.8433837890625,
+ "cost_distance_total_intern_reflection": 14004.9736328125
+ },
+ "weighted components": {
+ "cost_dispersion": 258.4315185546875,
+ "cost_distance_glasses": 1870.8844880976671,
+ "cost_deviation": 47.017330169677734,
+ "cost_distorsion": 20.916179656982422,
+ "cost_thickness": 4033.57666015625,
+ "cost_beam_compression": 2.3108112812042236,
+ "cost_non_linearity": 937.8433837890625,
+ "cost_distance_total_intern_reflection": 14004.9736328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 258.4315185546875,
+ "cost_distance_glasses": 1870.8844880976671,
+ "cost_deviation": 47.017330169677734,
+ "cost_distorsion": 20.916179656982422,
+ "cost_thickness": 4033.57666015625,
+ "cost_beam_compression": 2.3108112812042236,
+ "cost_non_linearity": 937.8433837890625,
+ "cost_distance_total_intern_reflection": 14004.9736328125
+ },
+ "weighted components": {
+ "cost_dispersion": 258.4315185546875,
+ "cost_distance_glasses": 1870.8844880976671,
+ "cost_deviation": 47.017330169677734,
+ "cost_distorsion": 20.916179656982422,
+ "cost_thickness": 4033.57666015625,
+ "cost_beam_compression": 2.3108112812042236,
+ "cost_non_linearity": 937.8433837890625,
+ "cost_distance_total_intern_reflection": 14004.9736328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1400.json b/outputs/amici/optimization_results/step1/score_details_iteration_1400.json
new file mode 100755
index 0000000..3efc57c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1400.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.2186393737793,
+ "cost_distance_glasses": 753.1446615330323,
+ "cost_deviation": 2.7205517292022705,
+ "cost_distorsion": 22.317581176757812,
+ "cost_thickness": 3734.17626953125,
+ "cost_beam_compression": 2.133384943008423,
+ "cost_non_linearity": 957.1473388671875,
+ "cost_distance_total_intern_reflection": 13550.5224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 37.2186393737793,
+ "cost_distance_glasses": 753.1446615330323,
+ "cost_deviation": 2.7205517292022705,
+ "cost_distorsion": 22.317581176757812,
+ "cost_thickness": 3734.17626953125,
+ "cost_beam_compression": 2.133384943008423,
+ "cost_non_linearity": 957.1473388671875,
+ "cost_distance_total_intern_reflection": 13550.5224609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.2186393737793,
+ "cost_distance_glasses": 753.1446615330323,
+ "cost_deviation": 2.7205517292022705,
+ "cost_distorsion": 22.317581176757812,
+ "cost_thickness": 3734.17626953125,
+ "cost_beam_compression": 2.133384943008423,
+ "cost_non_linearity": 957.1473388671875,
+ "cost_distance_total_intern_reflection": 13550.5224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 37.2186393737793,
+ "cost_distance_glasses": 753.1446615330323,
+ "cost_deviation": 2.7205517292022705,
+ "cost_distorsion": 22.317581176757812,
+ "cost_thickness": 3734.17626953125,
+ "cost_beam_compression": 2.133384943008423,
+ "cost_non_linearity": 957.1473388671875,
+ "cost_distance_total_intern_reflection": 13550.5224609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1410.json b/outputs/amici/optimization_results/step1/score_details_iteration_1410.json
new file mode 100755
index 0000000..6941869
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1410.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.84486770629883,
+ "cost_distance_glasses": 752.4358911918013,
+ "cost_deviation": 4.343995571136475,
+ "cost_distorsion": 21.89817237854004,
+ "cost_thickness": 3733.87744140625,
+ "cost_beam_compression": 2.13354229927063,
+ "cost_non_linearity": 957.3038940429688,
+ "cost_distance_total_intern_reflection": 13550.9970703125
+ },
+ "weighted components": {
+ "cost_dispersion": 34.84486770629883,
+ "cost_distance_glasses": 752.4358911918013,
+ "cost_deviation": 4.343995571136475,
+ "cost_distorsion": 21.89817237854004,
+ "cost_thickness": 3733.87744140625,
+ "cost_beam_compression": 2.13354229927063,
+ "cost_non_linearity": 957.3038940429688,
+ "cost_distance_total_intern_reflection": 13550.9970703125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.84486770629883,
+ "cost_distance_glasses": 752.4358911918013,
+ "cost_deviation": 4.343995571136475,
+ "cost_distorsion": 21.89817237854004,
+ "cost_thickness": 3733.87744140625,
+ "cost_beam_compression": 2.13354229927063,
+ "cost_non_linearity": 957.3038940429688,
+ "cost_distance_total_intern_reflection": 13550.9970703125
+ },
+ "weighted components": {
+ "cost_dispersion": 34.84486770629883,
+ "cost_distance_glasses": 752.4358911918013,
+ "cost_deviation": 4.343995571136475,
+ "cost_distorsion": 21.89817237854004,
+ "cost_thickness": 3733.87744140625,
+ "cost_beam_compression": 2.13354229927063,
+ "cost_non_linearity": 957.3038940429688,
+ "cost_distance_total_intern_reflection": 13550.9970703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1420.json b/outputs/amici/optimization_results/step1/score_details_iteration_1420.json
new file mode 100755
index 0000000..3880cc6
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1420.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.152503967285156,
+ "cost_distance_glasses": 751.0597734301317,
+ "cost_deviation": 3.4766671657562256,
+ "cost_distorsion": 22.05752182006836,
+ "cost_thickness": 3733.847412109375,
+ "cost_beam_compression": 2.1333675384521484,
+ "cost_non_linearity": 957.4132690429688,
+ "cost_distance_total_intern_reflection": 13545.6494140625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.152503967285156,
+ "cost_distance_glasses": 751.0597734301317,
+ "cost_deviation": 3.4766671657562256,
+ "cost_distorsion": 22.05752182006836,
+ "cost_thickness": 3733.847412109375,
+ "cost_beam_compression": 2.1333675384521484,
+ "cost_non_linearity": 957.4132690429688,
+ "cost_distance_total_intern_reflection": 13545.6494140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.152503967285156,
+ "cost_distance_glasses": 751.0597734301317,
+ "cost_deviation": 3.4766671657562256,
+ "cost_distorsion": 22.05752182006836,
+ "cost_thickness": 3733.847412109375,
+ "cost_beam_compression": 2.1333675384521484,
+ "cost_non_linearity": 957.4132690429688,
+ "cost_distance_total_intern_reflection": 13545.6494140625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.152503967285156,
+ "cost_distance_glasses": 751.0597734301317,
+ "cost_deviation": 3.4766671657562256,
+ "cost_distorsion": 22.05752182006836,
+ "cost_thickness": 3733.847412109375,
+ "cost_beam_compression": 2.1333675384521484,
+ "cost_non_linearity": 957.4132690429688,
+ "cost_distance_total_intern_reflection": 13545.6494140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1430.json b/outputs/amici/optimization_results/step1/score_details_iteration_1430.json
new file mode 100755
index 0000000..c67ba3b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1430.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.994873046875,
+ "cost_distance_glasses": 750.41101956959,
+ "cost_deviation": 3.597731828689575,
+ "cost_distorsion": 22.06629753112793,
+ "cost_thickness": 3733.744140625,
+ "cost_beam_compression": 2.133338451385498,
+ "cost_non_linearity": 957.43017578125,
+ "cost_distance_total_intern_reflection": 13546.8349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.994873046875,
+ "cost_distance_glasses": 750.41101956959,
+ "cost_deviation": 3.597731828689575,
+ "cost_distorsion": 22.06629753112793,
+ "cost_thickness": 3733.744140625,
+ "cost_beam_compression": 2.133338451385498,
+ "cost_non_linearity": 957.43017578125,
+ "cost_distance_total_intern_reflection": 13546.8349609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.994873046875,
+ "cost_distance_glasses": 750.41101956959,
+ "cost_deviation": 3.597731828689575,
+ "cost_distorsion": 22.06629753112793,
+ "cost_thickness": 3733.744140625,
+ "cost_beam_compression": 2.133338451385498,
+ "cost_non_linearity": 957.43017578125,
+ "cost_distance_total_intern_reflection": 13546.8349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.994873046875,
+ "cost_distance_glasses": 750.41101956959,
+ "cost_deviation": 3.597731828689575,
+ "cost_distorsion": 22.06629753112793,
+ "cost_thickness": 3733.744140625,
+ "cost_beam_compression": 2.133338451385498,
+ "cost_non_linearity": 957.43017578125,
+ "cost_distance_total_intern_reflection": 13546.8349609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1440.json b/outputs/amici/optimization_results/step1/score_details_iteration_1440.json
new file mode 100755
index 0000000..0117f90
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1440.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.36272430419922,
+ "cost_distance_glasses": 749.6964564654218,
+ "cost_deviation": 3.3374991416931152,
+ "cost_distorsion": 22.02346420288086,
+ "cost_thickness": 3733.698974609375,
+ "cost_beam_compression": 2.1332688331604004,
+ "cost_non_linearity": 957.2554321289062,
+ "cost_distance_total_intern_reflection": 13545.7548828125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.36272430419922,
+ "cost_distance_glasses": 749.6964564654218,
+ "cost_deviation": 3.3374991416931152,
+ "cost_distorsion": 22.02346420288086,
+ "cost_thickness": 3733.698974609375,
+ "cost_beam_compression": 2.1332688331604004,
+ "cost_non_linearity": 957.2554321289062,
+ "cost_distance_total_intern_reflection": 13545.7548828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.36272430419922,
+ "cost_distance_glasses": 749.6964564654218,
+ "cost_deviation": 3.3374991416931152,
+ "cost_distorsion": 22.02346420288086,
+ "cost_thickness": 3733.698974609375,
+ "cost_beam_compression": 2.1332688331604004,
+ "cost_non_linearity": 957.2554321289062,
+ "cost_distance_total_intern_reflection": 13545.7548828125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.36272430419922,
+ "cost_distance_glasses": 749.6964564654218,
+ "cost_deviation": 3.3374991416931152,
+ "cost_distorsion": 22.02346420288086,
+ "cost_thickness": 3733.698974609375,
+ "cost_beam_compression": 2.1332688331604004,
+ "cost_non_linearity": 957.2554321289062,
+ "cost_distance_total_intern_reflection": 13545.7548828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1450.json b/outputs/amici/optimization_results/step1/score_details_iteration_1450.json
new file mode 100755
index 0000000..47225a8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1450.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.869747161865234,
+ "cost_distance_glasses": 749.5945177620939,
+ "cost_deviation": 3.6368420124053955,
+ "cost_distorsion": 22.027376174926758,
+ "cost_thickness": 3733.61865234375,
+ "cost_beam_compression": 2.1332902908325195,
+ "cost_non_linearity": 957.330322265625,
+ "cost_distance_total_intern_reflection": 13547.83203125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.869747161865234,
+ "cost_distance_glasses": 749.5945177620939,
+ "cost_deviation": 3.6368420124053955,
+ "cost_distorsion": 22.027376174926758,
+ "cost_thickness": 3733.61865234375,
+ "cost_beam_compression": 2.1332902908325195,
+ "cost_non_linearity": 957.330322265625,
+ "cost_distance_total_intern_reflection": 13547.83203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.869747161865234,
+ "cost_distance_glasses": 749.5945177620939,
+ "cost_deviation": 3.6368420124053955,
+ "cost_distorsion": 22.027376174926758,
+ "cost_thickness": 3733.61865234375,
+ "cost_beam_compression": 2.1332902908325195,
+ "cost_non_linearity": 957.330322265625,
+ "cost_distance_total_intern_reflection": 13547.83203125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.869747161865234,
+ "cost_distance_glasses": 749.5945177620939,
+ "cost_deviation": 3.6368420124053955,
+ "cost_distorsion": 22.027376174926758,
+ "cost_thickness": 3733.61865234375,
+ "cost_beam_compression": 2.1332902908325195,
+ "cost_non_linearity": 957.330322265625,
+ "cost_distance_total_intern_reflection": 13547.83203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1460.json b/outputs/amici/optimization_results/step1/score_details_iteration_1460.json
new file mode 100755
index 0000000..3058b63
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1460.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.275917053222656,
+ "cost_distance_glasses": 749.714944362608,
+ "cost_deviation": 3.4081032276153564,
+ "cost_distorsion": 21.97808837890625,
+ "cost_thickness": 3733.615478515625,
+ "cost_beam_compression": 2.1332497596740723,
+ "cost_non_linearity": 957.3722534179688,
+ "cost_distance_total_intern_reflection": 13545.7392578125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.275917053222656,
+ "cost_distance_glasses": 749.714944362608,
+ "cost_deviation": 3.4081032276153564,
+ "cost_distorsion": 21.97808837890625,
+ "cost_thickness": 3733.615478515625,
+ "cost_beam_compression": 2.1332497596740723,
+ "cost_non_linearity": 957.3722534179688,
+ "cost_distance_total_intern_reflection": 13545.7392578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.275917053222656,
+ "cost_distance_glasses": 749.714944362608,
+ "cost_deviation": 3.4081032276153564,
+ "cost_distorsion": 21.97808837890625,
+ "cost_thickness": 3733.615478515625,
+ "cost_beam_compression": 2.1332497596740723,
+ "cost_non_linearity": 957.3722534179688,
+ "cost_distance_total_intern_reflection": 13545.7392578125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.275917053222656,
+ "cost_distance_glasses": 749.714944362608,
+ "cost_deviation": 3.4081032276153564,
+ "cost_distorsion": 21.97808837890625,
+ "cost_thickness": 3733.615478515625,
+ "cost_beam_compression": 2.1332497596740723,
+ "cost_non_linearity": 957.3722534179688,
+ "cost_distance_total_intern_reflection": 13545.7392578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1470.json b/outputs/amici/optimization_results/step1/score_details_iteration_1470.json
new file mode 100755
index 0000000..b658473
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1470.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.32225036621094,
+ "cost_distance_glasses": 751.619113447373,
+ "cost_deviation": 3.455029010772705,
+ "cost_distorsion": 22.14361572265625,
+ "cost_thickness": 3733.591796875,
+ "cost_beam_compression": 2.1332507133483887,
+ "cost_non_linearity": 957.2869873046875,
+ "cost_distance_total_intern_reflection": 13545.92578125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.32225036621094,
+ "cost_distance_glasses": 751.619113447373,
+ "cost_deviation": 3.455029010772705,
+ "cost_distorsion": 22.14361572265625,
+ "cost_thickness": 3733.591796875,
+ "cost_beam_compression": 2.1332507133483887,
+ "cost_non_linearity": 957.2869873046875,
+ "cost_distance_total_intern_reflection": 13545.92578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.32225036621094,
+ "cost_distance_glasses": 751.619113447373,
+ "cost_deviation": 3.455029010772705,
+ "cost_distorsion": 22.14361572265625,
+ "cost_thickness": 3733.591796875,
+ "cost_beam_compression": 2.1332507133483887,
+ "cost_non_linearity": 957.2869873046875,
+ "cost_distance_total_intern_reflection": 13545.92578125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.32225036621094,
+ "cost_distance_glasses": 751.619113447373,
+ "cost_deviation": 3.455029010772705,
+ "cost_distorsion": 22.14361572265625,
+ "cost_thickness": 3733.591796875,
+ "cost_beam_compression": 2.1332507133483887,
+ "cost_non_linearity": 957.2869873046875,
+ "cost_distance_total_intern_reflection": 13545.92578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1480.json b/outputs/amici/optimization_results/step1/score_details_iteration_1480.json
new file mode 100755
index 0000000..6558af7
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1480.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.523372650146484,
+ "cost_distance_glasses": 753.9233168319405,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 22.137414932250977,
+ "cost_thickness": 3733.594482421875,
+ "cost_beam_compression": 2.1332340240478516,
+ "cost_non_linearity": 957.2107543945312,
+ "cost_distance_total_intern_reflection": 13545.5234375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.523372650146484,
+ "cost_distance_glasses": 753.9233168319405,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 22.137414932250977,
+ "cost_thickness": 3733.594482421875,
+ "cost_beam_compression": 2.1332340240478516,
+ "cost_non_linearity": 957.2107543945312,
+ "cost_distance_total_intern_reflection": 13545.5234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.523372650146484,
+ "cost_distance_glasses": 753.9233168319405,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 22.137414932250977,
+ "cost_thickness": 3733.594482421875,
+ "cost_beam_compression": 2.1332340240478516,
+ "cost_non_linearity": 957.2107543945312,
+ "cost_distance_total_intern_reflection": 13545.5234375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.523372650146484,
+ "cost_distance_glasses": 753.9233168319405,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 22.137414932250977,
+ "cost_thickness": 3733.594482421875,
+ "cost_beam_compression": 2.1332340240478516,
+ "cost_non_linearity": 957.2107543945312,
+ "cost_distance_total_intern_reflection": 13545.5234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1490.json b/outputs/amici/optimization_results/step1/score_details_iteration_1490.json
new file mode 100755
index 0000000..e6b2d26
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1490.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.49018096923828,
+ "cost_distance_glasses": 757.442756883615,
+ "cost_deviation": 3.370246410369873,
+ "cost_distorsion": 22.1257266998291,
+ "cost_thickness": 3733.585205078125,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.2996215820312,
+ "cost_distance_total_intern_reflection": 13545.35546875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.49018096923828,
+ "cost_distance_glasses": 757.442756883615,
+ "cost_deviation": 3.370246410369873,
+ "cost_distorsion": 22.1257266998291,
+ "cost_thickness": 3733.585205078125,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.2996215820312,
+ "cost_distance_total_intern_reflection": 13545.35546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.49018096923828,
+ "cost_distance_glasses": 757.442756883615,
+ "cost_deviation": 3.370246410369873,
+ "cost_distorsion": 22.1257266998291,
+ "cost_thickness": 3733.585205078125,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.2996215820312,
+ "cost_distance_total_intern_reflection": 13545.35546875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.49018096923828,
+ "cost_distance_glasses": 757.442756883615,
+ "cost_deviation": 3.370246410369873,
+ "cost_distorsion": 22.1257266998291,
+ "cost_thickness": 3733.585205078125,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.2996215820312,
+ "cost_distance_total_intern_reflection": 13545.35546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_150.json b/outputs/amici/optimization_results/step1/score_details_iteration_150.json
new file mode 100755
index 0000000..9dd1a58
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_150.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 231.48033142089844,
+ "cost_distance_glasses": 1865.9285828334437,
+ "cost_deviation": 43.662635803222656,
+ "cost_distorsion": 20.17830467224121,
+ "cost_thickness": 4045.87646484375,
+ "cost_beam_compression": 2.3182148933410645,
+ "cost_non_linearity": 939.7727661132812,
+ "cost_distance_total_intern_reflection": 14019.6103515625
+ },
+ "weighted components": {
+ "cost_dispersion": 231.48033142089844,
+ "cost_distance_glasses": 1865.9285828334437,
+ "cost_deviation": 43.662635803222656,
+ "cost_distorsion": 20.17830467224121,
+ "cost_thickness": 4045.87646484375,
+ "cost_beam_compression": 2.3182148933410645,
+ "cost_non_linearity": 939.7727661132812,
+ "cost_distance_total_intern_reflection": 14019.6103515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 231.48033142089844,
+ "cost_distance_glasses": 1865.9285828334437,
+ "cost_deviation": 43.662635803222656,
+ "cost_distorsion": 20.17830467224121,
+ "cost_thickness": 4045.87646484375,
+ "cost_beam_compression": 2.3182148933410645,
+ "cost_non_linearity": 939.7727661132812,
+ "cost_distance_total_intern_reflection": 14019.6103515625
+ },
+ "weighted components": {
+ "cost_dispersion": 231.48033142089844,
+ "cost_distance_glasses": 1865.9285828334437,
+ "cost_deviation": 43.662635803222656,
+ "cost_distorsion": 20.17830467224121,
+ "cost_thickness": 4045.87646484375,
+ "cost_beam_compression": 2.3182148933410645,
+ "cost_non_linearity": 939.7727661132812,
+ "cost_distance_total_intern_reflection": 14019.6103515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1500.json b/outputs/amici/optimization_results/step1/score_details_iteration_1500.json
new file mode 100755
index 0000000..00d4a45
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1500.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.482810974121094,
+ "cost_distance_glasses": 762.5262653190755,
+ "cost_deviation": 3.3565821647644043,
+ "cost_distorsion": 22.01242446899414,
+ "cost_thickness": 3733.586181640625,
+ "cost_beam_compression": 2.133234739303589,
+ "cost_non_linearity": 957.27099609375,
+ "cost_distance_total_intern_reflection": 13545.337890625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.482810974121094,
+ "cost_distance_glasses": 762.5262653190755,
+ "cost_deviation": 3.3565821647644043,
+ "cost_distorsion": 22.01242446899414,
+ "cost_thickness": 3733.586181640625,
+ "cost_beam_compression": 2.133234739303589,
+ "cost_non_linearity": 957.27099609375,
+ "cost_distance_total_intern_reflection": 13545.337890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.482810974121094,
+ "cost_distance_glasses": 762.5262653190755,
+ "cost_deviation": 3.3565821647644043,
+ "cost_distorsion": 22.01242446899414,
+ "cost_thickness": 3733.586181640625,
+ "cost_beam_compression": 2.133234739303589,
+ "cost_non_linearity": 957.27099609375,
+ "cost_distance_total_intern_reflection": 13545.337890625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.482810974121094,
+ "cost_distance_glasses": 762.5262653190755,
+ "cost_deviation": 3.3565821647644043,
+ "cost_distorsion": 22.01242446899414,
+ "cost_thickness": 3733.586181640625,
+ "cost_beam_compression": 2.133234739303589,
+ "cost_non_linearity": 957.27099609375,
+ "cost_distance_total_intern_reflection": 13545.337890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1510.json b/outputs/amici/optimization_results/step1/score_details_iteration_1510.json
new file mode 100755
index 0000000..f718ed5
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1510.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.44226837158203,
+ "cost_distance_glasses": 767.6097737545359,
+ "cost_deviation": 3.370793342590332,
+ "cost_distorsion": 22.129962921142578,
+ "cost_thickness": 3733.583984375,
+ "cost_beam_compression": 2.133237838745117,
+ "cost_non_linearity": 957.2208251953125,
+ "cost_distance_total_intern_reflection": 13545.3173828125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.44226837158203,
+ "cost_distance_glasses": 767.6097737545359,
+ "cost_deviation": 3.370793342590332,
+ "cost_distorsion": 22.129962921142578,
+ "cost_thickness": 3733.583984375,
+ "cost_beam_compression": 2.133237838745117,
+ "cost_non_linearity": 957.2208251953125,
+ "cost_distance_total_intern_reflection": 13545.3173828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.44226837158203,
+ "cost_distance_glasses": 767.6097737545359,
+ "cost_deviation": 3.370793342590332,
+ "cost_distorsion": 22.129962921142578,
+ "cost_thickness": 3733.583984375,
+ "cost_beam_compression": 2.133237838745117,
+ "cost_non_linearity": 957.2208251953125,
+ "cost_distance_total_intern_reflection": 13545.3173828125
+ },
+ "weighted components": {
+ "cost_dispersion": 36.44226837158203,
+ "cost_distance_glasses": 767.6097737545359,
+ "cost_deviation": 3.370793342590332,
+ "cost_distorsion": 22.129962921142578,
+ "cost_thickness": 3733.583984375,
+ "cost_beam_compression": 2.133237838745117,
+ "cost_non_linearity": 957.2208251953125,
+ "cost_distance_total_intern_reflection": 13545.3173828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1520.json b/outputs/amici/optimization_results/step1/score_details_iteration_1520.json
new file mode 100755
index 0000000..ae52a38
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1520.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.29356384277344,
+ "cost_distance_glasses": 769.5252810500751,
+ "cost_deviation": 3.365870714187622,
+ "cost_distorsion": 21.973554611206055,
+ "cost_thickness": 3733.57763671875,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.1891479492188,
+ "cost_distance_total_intern_reflection": 13545.4609375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.29356384277344,
+ "cost_distance_glasses": 769.5252810500751,
+ "cost_deviation": 3.365870714187622,
+ "cost_distorsion": 21.973554611206055,
+ "cost_thickness": 3733.57763671875,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.1891479492188,
+ "cost_distance_total_intern_reflection": 13545.4609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.29356384277344,
+ "cost_distance_glasses": 769.5252810500751,
+ "cost_deviation": 3.365870714187622,
+ "cost_distorsion": 21.973554611206055,
+ "cost_thickness": 3733.57763671875,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.1891479492188,
+ "cost_distance_total_intern_reflection": 13545.4609375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.29356384277344,
+ "cost_distance_glasses": 769.5252810500751,
+ "cost_deviation": 3.365870714187622,
+ "cost_distorsion": 21.973554611206055,
+ "cost_thickness": 3733.57763671875,
+ "cost_beam_compression": 2.13323712348938,
+ "cost_non_linearity": 957.1891479492188,
+ "cost_distance_total_intern_reflection": 13545.4609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1530.json b/outputs/amici/optimization_results/step1/score_details_iteration_1530.json
new file mode 100755
index 0000000..ac2ca30
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1530.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.42900466918945,
+ "cost_distance_glasses": 765.9446117111258,
+ "cost_deviation": 3.305995464324951,
+ "cost_distorsion": 22.03904151916504,
+ "cost_thickness": 3733.56591796875,
+ "cost_beam_compression": 2.1332311630249023,
+ "cost_non_linearity": 957.118408203125,
+ "cost_distance_total_intern_reflection": 13545.443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.42900466918945,
+ "cost_distance_glasses": 765.9446117111258,
+ "cost_deviation": 3.305995464324951,
+ "cost_distorsion": 22.03904151916504,
+ "cost_thickness": 3733.56591796875,
+ "cost_beam_compression": 2.1332311630249023,
+ "cost_non_linearity": 957.118408203125,
+ "cost_distance_total_intern_reflection": 13545.443359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.42900466918945,
+ "cost_distance_glasses": 765.9446117111258,
+ "cost_deviation": 3.305995464324951,
+ "cost_distorsion": 22.03904151916504,
+ "cost_thickness": 3733.56591796875,
+ "cost_beam_compression": 2.1332311630249023,
+ "cost_non_linearity": 957.118408203125,
+ "cost_distance_total_intern_reflection": 13545.443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.42900466918945,
+ "cost_distance_glasses": 765.9446117111258,
+ "cost_deviation": 3.305995464324951,
+ "cost_distorsion": 22.03904151916504,
+ "cost_thickness": 3733.56591796875,
+ "cost_beam_compression": 2.1332311630249023,
+ "cost_non_linearity": 957.118408203125,
+ "cost_distance_total_intern_reflection": 13545.443359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1540.json b/outputs/amici/optimization_results/step1/score_details_iteration_1540.json
new file mode 100755
index 0000000..214afbc
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1540.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.330345153808594,
+ "cost_distance_glasses": 754.0034165952645,
+ "cost_deviation": 3.382293701171875,
+ "cost_distorsion": 22.032228469848633,
+ "cost_thickness": 3733.52587890625,
+ "cost_beam_compression": 2.133249044418335,
+ "cost_non_linearity": 957.3175659179688,
+ "cost_distance_total_intern_reflection": 13546.4404296875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.330345153808594,
+ "cost_distance_glasses": 754.0034165952645,
+ "cost_deviation": 3.382293701171875,
+ "cost_distorsion": 22.032228469848633,
+ "cost_thickness": 3733.52587890625,
+ "cost_beam_compression": 2.133249044418335,
+ "cost_non_linearity": 957.3175659179688,
+ "cost_distance_total_intern_reflection": 13546.4404296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.330345153808594,
+ "cost_distance_glasses": 754.0034165952645,
+ "cost_deviation": 3.382293701171875,
+ "cost_distorsion": 22.032228469848633,
+ "cost_thickness": 3733.52587890625,
+ "cost_beam_compression": 2.133249044418335,
+ "cost_non_linearity": 957.3175659179688,
+ "cost_distance_total_intern_reflection": 13546.4404296875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.330345153808594,
+ "cost_distance_glasses": 754.0034165952645,
+ "cost_deviation": 3.382293701171875,
+ "cost_distorsion": 22.032228469848633,
+ "cost_thickness": 3733.52587890625,
+ "cost_beam_compression": 2.133249044418335,
+ "cost_non_linearity": 957.3175659179688,
+ "cost_distance_total_intern_reflection": 13546.4404296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1550.json b/outputs/amici/optimization_results/step1/score_details_iteration_1550.json
new file mode 100755
index 0000000..1fb8199
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1550.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.484283447265625,
+ "cost_distance_glasses": 737.1663215966867,
+ "cost_deviation": 3.341311454772949,
+ "cost_distorsion": 22.116939544677734,
+ "cost_thickness": 3733.492431640625,
+ "cost_beam_compression": 2.1332569122314453,
+ "cost_non_linearity": 957.212646484375,
+ "cost_distance_total_intern_reflection": 13545.9326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.484283447265625,
+ "cost_distance_glasses": 737.1663215966867,
+ "cost_deviation": 3.341311454772949,
+ "cost_distorsion": 22.116939544677734,
+ "cost_thickness": 3733.492431640625,
+ "cost_beam_compression": 2.1332569122314453,
+ "cost_non_linearity": 957.212646484375,
+ "cost_distance_total_intern_reflection": 13545.9326171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.484283447265625,
+ "cost_distance_glasses": 737.1663215966867,
+ "cost_deviation": 3.341311454772949,
+ "cost_distorsion": 22.116939544677734,
+ "cost_thickness": 3733.492431640625,
+ "cost_beam_compression": 2.1332569122314453,
+ "cost_non_linearity": 957.212646484375,
+ "cost_distance_total_intern_reflection": 13545.9326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 36.484283447265625,
+ "cost_distance_glasses": 737.1663215966867,
+ "cost_deviation": 3.341311454772949,
+ "cost_distorsion": 22.116939544677734,
+ "cost_thickness": 3733.492431640625,
+ "cost_beam_compression": 2.1332569122314453,
+ "cost_non_linearity": 957.212646484375,
+ "cost_distance_total_intern_reflection": 13545.9326171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1560.json b/outputs/amici/optimization_results/step1/score_details_iteration_1560.json
new file mode 100755
index 0000000..ae38487
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1560.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.10847854614258,
+ "cost_distance_glasses": 723.8105973045504,
+ "cost_deviation": 3.6550517082214355,
+ "cost_distorsion": 22.077346801757812,
+ "cost_thickness": 3733.421875,
+ "cost_beam_compression": 2.1333110332489014,
+ "cost_non_linearity": 957.4149780273438,
+ "cost_distance_total_intern_reflection": 13546.6015625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.10847854614258,
+ "cost_distance_glasses": 723.8105973045504,
+ "cost_deviation": 3.6550517082214355,
+ "cost_distorsion": 22.077346801757812,
+ "cost_thickness": 3733.421875,
+ "cost_beam_compression": 2.1333110332489014,
+ "cost_non_linearity": 957.4149780273438,
+ "cost_distance_total_intern_reflection": 13546.6015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.10847854614258,
+ "cost_distance_glasses": 723.8105973045504,
+ "cost_deviation": 3.6550517082214355,
+ "cost_distorsion": 22.077346801757812,
+ "cost_thickness": 3733.421875,
+ "cost_beam_compression": 2.1333110332489014,
+ "cost_non_linearity": 957.4149780273438,
+ "cost_distance_total_intern_reflection": 13546.6015625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.10847854614258,
+ "cost_distance_glasses": 723.8105973045504,
+ "cost_deviation": 3.6550517082214355,
+ "cost_distorsion": 22.077346801757812,
+ "cost_thickness": 3733.421875,
+ "cost_beam_compression": 2.1333110332489014,
+ "cost_non_linearity": 957.4149780273438,
+ "cost_distance_total_intern_reflection": 13546.6015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1570.json b/outputs/amici/optimization_results/step1/score_details_iteration_1570.json
new file mode 100755
index 0000000..c9355a5
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1570.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.858558654785156,
+ "cost_distance_glasses": 720.5492485911666,
+ "cost_deviation": 4.389457702636719,
+ "cost_distorsion": 21.785783767700195,
+ "cost_thickness": 3733.28564453125,
+ "cost_beam_compression": 2.133382558822632,
+ "cost_non_linearity": 957.3873901367188,
+ "cost_distance_total_intern_reflection": 13551.07421875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.858558654785156,
+ "cost_distance_glasses": 720.5492485911666,
+ "cost_deviation": 4.389457702636719,
+ "cost_distorsion": 21.785783767700195,
+ "cost_thickness": 3733.28564453125,
+ "cost_beam_compression": 2.133382558822632,
+ "cost_non_linearity": 957.3873901367188,
+ "cost_distance_total_intern_reflection": 13551.07421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.858558654785156,
+ "cost_distance_glasses": 720.5492485911666,
+ "cost_deviation": 4.389457702636719,
+ "cost_distorsion": 21.785783767700195,
+ "cost_thickness": 3733.28564453125,
+ "cost_beam_compression": 2.133382558822632,
+ "cost_non_linearity": 957.3873901367188,
+ "cost_distance_total_intern_reflection": 13551.07421875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.858558654785156,
+ "cost_distance_glasses": 720.5492485911666,
+ "cost_deviation": 4.389457702636719,
+ "cost_distorsion": 21.785783767700195,
+ "cost_thickness": 3733.28564453125,
+ "cost_beam_compression": 2.133382558822632,
+ "cost_non_linearity": 957.3873901367188,
+ "cost_distance_total_intern_reflection": 13551.07421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1580.json b/outputs/amici/optimization_results/step1/score_details_iteration_1580.json
new file mode 100755
index 0000000..9a9c945
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1580.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.18587875366211,
+ "cost_distance_glasses": 723.71644876203,
+ "cost_deviation": 2.923276662826538,
+ "cost_distorsion": 22.203153610229492,
+ "cost_thickness": 3733.33740234375,
+ "cost_beam_compression": 2.133124351501465,
+ "cost_non_linearity": 957.2544555664062,
+ "cost_distance_total_intern_reflection": 13546.9228515625
+ },
+ "weighted components": {
+ "cost_dispersion": 37.18587875366211,
+ "cost_distance_glasses": 723.71644876203,
+ "cost_deviation": 2.923276662826538,
+ "cost_distorsion": 22.203153610229492,
+ "cost_thickness": 3733.33740234375,
+ "cost_beam_compression": 2.133124351501465,
+ "cost_non_linearity": 957.2544555664062,
+ "cost_distance_total_intern_reflection": 13546.9228515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.18587875366211,
+ "cost_distance_glasses": 723.71644876203,
+ "cost_deviation": 2.923276662826538,
+ "cost_distorsion": 22.203153610229492,
+ "cost_thickness": 3733.33740234375,
+ "cost_beam_compression": 2.133124351501465,
+ "cost_non_linearity": 957.2544555664062,
+ "cost_distance_total_intern_reflection": 13546.9228515625
+ },
+ "weighted components": {
+ "cost_dispersion": 37.18587875366211,
+ "cost_distance_glasses": 723.71644876203,
+ "cost_deviation": 2.923276662826538,
+ "cost_distorsion": 22.203153610229492,
+ "cost_thickness": 3733.33740234375,
+ "cost_beam_compression": 2.133124351501465,
+ "cost_non_linearity": 957.2544555664062,
+ "cost_distance_total_intern_reflection": 13546.9228515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1590.json b/outputs/amici/optimization_results/step1/score_details_iteration_1590.json
new file mode 100755
index 0000000..0292a0a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1590.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.64492416381836,
+ "cost_distance_glasses": 724.1507288551667,
+ "cost_deviation": 3.9425268173217773,
+ "cost_distorsion": 22.095844268798828,
+ "cost_thickness": 3733.167236328125,
+ "cost_beam_compression": 2.133235454559326,
+ "cost_non_linearity": 957.526123046875,
+ "cost_distance_total_intern_reflection": 13545.505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.64492416381836,
+ "cost_distance_glasses": 724.1507288551667,
+ "cost_deviation": 3.9425268173217773,
+ "cost_distorsion": 22.095844268798828,
+ "cost_thickness": 3733.167236328125,
+ "cost_beam_compression": 2.133235454559326,
+ "cost_non_linearity": 957.526123046875,
+ "cost_distance_total_intern_reflection": 13545.505859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.64492416381836,
+ "cost_distance_glasses": 724.1507288551667,
+ "cost_deviation": 3.9425268173217773,
+ "cost_distorsion": 22.095844268798828,
+ "cost_thickness": 3733.167236328125,
+ "cost_beam_compression": 2.133235454559326,
+ "cost_non_linearity": 957.526123046875,
+ "cost_distance_total_intern_reflection": 13545.505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.64492416381836,
+ "cost_distance_glasses": 724.1507288551667,
+ "cost_deviation": 3.9425268173217773,
+ "cost_distorsion": 22.095844268798828,
+ "cost_thickness": 3733.167236328125,
+ "cost_beam_compression": 2.133235454559326,
+ "cost_non_linearity": 957.526123046875,
+ "cost_distance_total_intern_reflection": 13545.505859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_160.json b/outputs/amici/optimization_results/step1/score_details_iteration_160.json
new file mode 100755
index 0000000..67548c7
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_160.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 218.3338165283203,
+ "cost_distance_glasses": 1732.4009079189082,
+ "cost_deviation": 31.401798248291016,
+ "cost_distorsion": 21.055377960205078,
+ "cost_thickness": 4056.478759765625,
+ "cost_beam_compression": 2.324540138244629,
+ "cost_non_linearity": 940.3831787109375,
+ "cost_distance_total_intern_reflection": 14034.037109375
+ },
+ "weighted components": {
+ "cost_dispersion": 218.3338165283203,
+ "cost_distance_glasses": 1732.4009079189082,
+ "cost_deviation": 31.401798248291016,
+ "cost_distorsion": 21.055377960205078,
+ "cost_thickness": 4056.478759765625,
+ "cost_beam_compression": 2.324540138244629,
+ "cost_non_linearity": 940.3831787109375,
+ "cost_distance_total_intern_reflection": 14034.037109375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 218.3338165283203,
+ "cost_distance_glasses": 1732.4009079189082,
+ "cost_deviation": 31.401798248291016,
+ "cost_distorsion": 21.055377960205078,
+ "cost_thickness": 4056.478759765625,
+ "cost_beam_compression": 2.324540138244629,
+ "cost_non_linearity": 940.3831787109375,
+ "cost_distance_total_intern_reflection": 14034.037109375
+ },
+ "weighted components": {
+ "cost_dispersion": 218.3338165283203,
+ "cost_distance_glasses": 1732.4009079189082,
+ "cost_deviation": 31.401798248291016,
+ "cost_distorsion": 21.055377960205078,
+ "cost_thickness": 4056.478759765625,
+ "cost_beam_compression": 2.324540138244629,
+ "cost_non_linearity": 940.3831787109375,
+ "cost_distance_total_intern_reflection": 14034.037109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1600.json b/outputs/amici/optimization_results/step1/score_details_iteration_1600.json
new file mode 100755
index 0000000..b611dd4
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1600.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.66279983520508,
+ "cost_distance_glasses": 719.8866425047844,
+ "cost_deviation": 4.692343711853027,
+ "cost_distorsion": 21.60364532470703,
+ "cost_thickness": 3732.8935546875,
+ "cost_beam_compression": 2.133222818374634,
+ "cost_non_linearity": 957.6644287109375,
+ "cost_distance_total_intern_reflection": 13555.478515625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.66279983520508,
+ "cost_distance_glasses": 719.8866425047844,
+ "cost_deviation": 4.692343711853027,
+ "cost_distorsion": 21.60364532470703,
+ "cost_thickness": 3732.8935546875,
+ "cost_beam_compression": 2.133222818374634,
+ "cost_non_linearity": 957.6644287109375,
+ "cost_distance_total_intern_reflection": 13555.478515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.66279983520508,
+ "cost_distance_glasses": 719.8866425047844,
+ "cost_deviation": 4.692343711853027,
+ "cost_distorsion": 21.60364532470703,
+ "cost_thickness": 3732.8935546875,
+ "cost_beam_compression": 2.133222818374634,
+ "cost_non_linearity": 957.6644287109375,
+ "cost_distance_total_intern_reflection": 13555.478515625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.66279983520508,
+ "cost_distance_glasses": 719.8866425047844,
+ "cost_deviation": 4.692343711853027,
+ "cost_distorsion": 21.60364532470703,
+ "cost_thickness": 3732.8935546875,
+ "cost_beam_compression": 2.133222818374634,
+ "cost_non_linearity": 957.6644287109375,
+ "cost_distance_total_intern_reflection": 13555.478515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1610.json b/outputs/amici/optimization_results/step1/score_details_iteration_1610.json
new file mode 100755
index 0000000..22c421c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1610.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.83180046081543,
+ "cost_distance_glasses": 718.6366306703753,
+ "cost_deviation": 7.204640865325928,
+ "cost_distorsion": 21.224857330322266,
+ "cost_thickness": 3732.597412109375,
+ "cost_beam_compression": 2.133450984954834,
+ "cost_non_linearity": 958.0380859375,
+ "cost_distance_total_intern_reflection": 13562.7353515625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.83180046081543,
+ "cost_distance_glasses": 718.6366306703753,
+ "cost_deviation": 7.204640865325928,
+ "cost_distorsion": 21.224857330322266,
+ "cost_thickness": 3732.597412109375,
+ "cost_beam_compression": 2.133450984954834,
+ "cost_non_linearity": 958.0380859375,
+ "cost_distance_total_intern_reflection": 13562.7353515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.83180046081543,
+ "cost_distance_glasses": 718.6366306703753,
+ "cost_deviation": 7.204640865325928,
+ "cost_distorsion": 21.224857330322266,
+ "cost_thickness": 3732.597412109375,
+ "cost_beam_compression": 2.133450984954834,
+ "cost_non_linearity": 958.0380859375,
+ "cost_distance_total_intern_reflection": 13562.7353515625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.83180046081543,
+ "cost_distance_glasses": 718.6366306703753,
+ "cost_deviation": 7.204640865325928,
+ "cost_distorsion": 21.224857330322266,
+ "cost_thickness": 3732.597412109375,
+ "cost_beam_compression": 2.133450984954834,
+ "cost_non_linearity": 958.0380859375,
+ "cost_distance_total_intern_reflection": 13562.7353515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1620.json b/outputs/amici/optimization_results/step1/score_details_iteration_1620.json
new file mode 100755
index 0000000..b161073
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1620.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.602352142333984,
+ "cost_distance_glasses": 717.0584702834193,
+ "cost_deviation": 3.40920352935791,
+ "cost_distorsion": 22.016027450561523,
+ "cost_thickness": 3732.703369140625,
+ "cost_beam_compression": 2.132883071899414,
+ "cost_non_linearity": 957.2847900390625,
+ "cost_distance_total_intern_reflection": 13546.62890625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.602352142333984,
+ "cost_distance_glasses": 717.0584702834193,
+ "cost_deviation": 3.40920352935791,
+ "cost_distorsion": 22.016027450561523,
+ "cost_thickness": 3732.703369140625,
+ "cost_beam_compression": 2.132883071899414,
+ "cost_non_linearity": 957.2847900390625,
+ "cost_distance_total_intern_reflection": 13546.62890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.602352142333984,
+ "cost_distance_glasses": 717.0584702834193,
+ "cost_deviation": 3.40920352935791,
+ "cost_distorsion": 22.016027450561523,
+ "cost_thickness": 3732.703369140625,
+ "cost_beam_compression": 2.132883071899414,
+ "cost_non_linearity": 957.2847900390625,
+ "cost_distance_total_intern_reflection": 13546.62890625
+ },
+ "weighted components": {
+ "cost_dispersion": 36.602352142333984,
+ "cost_distance_glasses": 717.0584702834193,
+ "cost_deviation": 3.40920352935791,
+ "cost_distorsion": 22.016027450561523,
+ "cost_thickness": 3732.703369140625,
+ "cost_beam_compression": 2.132883071899414,
+ "cost_non_linearity": 957.2847900390625,
+ "cost_distance_total_intern_reflection": 13546.62890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1630.json b/outputs/amici/optimization_results/step1/score_details_iteration_1630.json
new file mode 100755
index 0000000..0ba2294
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1630.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.264780044555664,
+ "cost_distance_glasses": 716.1133850517366,
+ "cost_deviation": 7.732324123382568,
+ "cost_distorsion": 20.917007446289062,
+ "cost_thickness": 3732.165283203125,
+ "cost_beam_compression": 2.1332848072052,
+ "cost_non_linearity": 958.0315551757812,
+ "cost_distance_total_intern_reflection": 13566.2158203125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.264780044555664,
+ "cost_distance_glasses": 716.1133850517366,
+ "cost_deviation": 7.732324123382568,
+ "cost_distorsion": 20.917007446289062,
+ "cost_thickness": 3732.165283203125,
+ "cost_beam_compression": 2.1332848072052,
+ "cost_non_linearity": 958.0315551757812,
+ "cost_distance_total_intern_reflection": 13566.2158203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.264780044555664,
+ "cost_distance_glasses": 716.1133850517366,
+ "cost_deviation": 7.732324123382568,
+ "cost_distorsion": 20.917007446289062,
+ "cost_thickness": 3732.165283203125,
+ "cost_beam_compression": 2.1332848072052,
+ "cost_non_linearity": 958.0315551757812,
+ "cost_distance_total_intern_reflection": 13566.2158203125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.264780044555664,
+ "cost_distance_glasses": 716.1133850517366,
+ "cost_deviation": 7.732324123382568,
+ "cost_distorsion": 20.917007446289062,
+ "cost_thickness": 3732.165283203125,
+ "cost_beam_compression": 2.1332848072052,
+ "cost_non_linearity": 958.0315551757812,
+ "cost_distance_total_intern_reflection": 13566.2158203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1640.json b/outputs/amici/optimization_results/step1/score_details_iteration_1640.json
new file mode 100755
index 0000000..126a654
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1640.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.82288360595703,
+ "cost_distance_glasses": 714.4928935430079,
+ "cost_deviation": 6.122347831726074,
+ "cost_distorsion": 21.37723159790039,
+ "cost_thickness": 3732.07568359375,
+ "cost_beam_compression": 2.1329987049102783,
+ "cost_non_linearity": 957.8672485351562,
+ "cost_distance_total_intern_reflection": 13556.8427734375
+ },
+ "weighted components": {
+ "cost_dispersion": 32.82288360595703,
+ "cost_distance_glasses": 714.4928935430079,
+ "cost_deviation": 6.122347831726074,
+ "cost_distorsion": 21.37723159790039,
+ "cost_thickness": 3732.07568359375,
+ "cost_beam_compression": 2.1329987049102783,
+ "cost_non_linearity": 957.8672485351562,
+ "cost_distance_total_intern_reflection": 13556.8427734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.82288360595703,
+ "cost_distance_glasses": 714.4928935430079,
+ "cost_deviation": 6.122347831726074,
+ "cost_distorsion": 21.37723159790039,
+ "cost_thickness": 3732.07568359375,
+ "cost_beam_compression": 2.1329987049102783,
+ "cost_non_linearity": 957.8672485351562,
+ "cost_distance_total_intern_reflection": 13556.8427734375
+ },
+ "weighted components": {
+ "cost_dispersion": 32.82288360595703,
+ "cost_distance_glasses": 714.4928935430079,
+ "cost_deviation": 6.122347831726074,
+ "cost_distorsion": 21.37723159790039,
+ "cost_thickness": 3732.07568359375,
+ "cost_beam_compression": 2.1329987049102783,
+ "cost_non_linearity": 957.8672485351562,
+ "cost_distance_total_intern_reflection": 13556.8427734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1650.json b/outputs/amici/optimization_results/step1/score_details_iteration_1650.json
new file mode 100755
index 0000000..cebaf82
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1650.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.2894287109375,
+ "cost_distance_glasses": 712.6379143382485,
+ "cost_deviation": 4.085223197937012,
+ "cost_distorsion": 22.03481101989746,
+ "cost_thickness": 3732.048828125,
+ "cost_beam_compression": 2.132645845413208,
+ "cost_non_linearity": 957.413818359375,
+ "cost_distance_total_intern_reflection": 13545.29296875
+ },
+ "weighted components": {
+ "cost_dispersion": 35.2894287109375,
+ "cost_distance_glasses": 712.6379143382485,
+ "cost_deviation": 4.085223197937012,
+ "cost_distorsion": 22.03481101989746,
+ "cost_thickness": 3732.048828125,
+ "cost_beam_compression": 2.132645845413208,
+ "cost_non_linearity": 957.413818359375,
+ "cost_distance_total_intern_reflection": 13545.29296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.2894287109375,
+ "cost_distance_glasses": 712.6379143382485,
+ "cost_deviation": 4.085223197937012,
+ "cost_distorsion": 22.03481101989746,
+ "cost_thickness": 3732.048828125,
+ "cost_beam_compression": 2.132645845413208,
+ "cost_non_linearity": 957.413818359375,
+ "cost_distance_total_intern_reflection": 13545.29296875
+ },
+ "weighted components": {
+ "cost_dispersion": 35.2894287109375,
+ "cost_distance_glasses": 712.6379143382485,
+ "cost_deviation": 4.085223197937012,
+ "cost_distorsion": 22.03481101989746,
+ "cost_thickness": 3732.048828125,
+ "cost_beam_compression": 2.132645845413208,
+ "cost_non_linearity": 957.413818359375,
+ "cost_distance_total_intern_reflection": 13545.29296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1660.json b/outputs/amici/optimization_results/step1/score_details_iteration_1660.json
new file mode 100755
index 0000000..19ba496
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1660.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.605615615844727,
+ "cost_distance_glasses": 711.843744185932,
+ "cost_deviation": 7.5584540367126465,
+ "cost_distorsion": 20.910375595092773,
+ "cost_thickness": 3731.425048828125,
+ "cost_beam_compression": 2.132842540740967,
+ "cost_non_linearity": 957.9815063476562,
+ "cost_distance_total_intern_reflection": 13567.1708984375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.605615615844727,
+ "cost_distance_glasses": 711.843744185932,
+ "cost_deviation": 7.5584540367126465,
+ "cost_distorsion": 20.910375595092773,
+ "cost_thickness": 3731.425048828125,
+ "cost_beam_compression": 2.132842540740967,
+ "cost_non_linearity": 957.9815063476562,
+ "cost_distance_total_intern_reflection": 13567.1708984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.605615615844727,
+ "cost_distance_glasses": 711.843744185932,
+ "cost_deviation": 7.5584540367126465,
+ "cost_distorsion": 20.910375595092773,
+ "cost_thickness": 3731.425048828125,
+ "cost_beam_compression": 2.132842540740967,
+ "cost_non_linearity": 957.9815063476562,
+ "cost_distance_total_intern_reflection": 13567.1708984375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.605615615844727,
+ "cost_distance_glasses": 711.843744185932,
+ "cost_deviation": 7.5584540367126465,
+ "cost_distorsion": 20.910375595092773,
+ "cost_thickness": 3731.425048828125,
+ "cost_beam_compression": 2.132842540740967,
+ "cost_non_linearity": 957.9815063476562,
+ "cost_distance_total_intern_reflection": 13567.1708984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1670.json b/outputs/amici/optimization_results/step1/score_details_iteration_1670.json
new file mode 100755
index 0000000..aee935b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1670.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.27304458618164,
+ "cost_distance_glasses": 708.0682250388214,
+ "cost_deviation": 0.11695145070552826,
+ "cost_distorsion": 23.319034576416016,
+ "cost_thickness": 3731.936767578125,
+ "cost_beam_compression": 2.131345748901367,
+ "cost_non_linearity": 955.830322265625,
+ "cost_distance_total_intern_reflection": 13558.06640625
+ },
+ "weighted components": {
+ "cost_dispersion": 46.27304458618164,
+ "cost_distance_glasses": 708.0682250388214,
+ "cost_deviation": 0.11695145070552826,
+ "cost_distorsion": 23.319034576416016,
+ "cost_thickness": 3731.936767578125,
+ "cost_beam_compression": 2.131345748901367,
+ "cost_non_linearity": 955.830322265625,
+ "cost_distance_total_intern_reflection": 13558.06640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.27304458618164,
+ "cost_distance_glasses": 708.0682250388214,
+ "cost_deviation": 0.11695145070552826,
+ "cost_distorsion": 23.319034576416016,
+ "cost_thickness": 3731.936767578125,
+ "cost_beam_compression": 2.131345748901367,
+ "cost_non_linearity": 955.830322265625,
+ "cost_distance_total_intern_reflection": 13558.06640625
+ },
+ "weighted components": {
+ "cost_dispersion": 46.27304458618164,
+ "cost_distance_glasses": 708.0682250388214,
+ "cost_deviation": 0.11695145070552826,
+ "cost_distorsion": 23.319034576416016,
+ "cost_thickness": 3731.936767578125,
+ "cost_beam_compression": 2.131345748901367,
+ "cost_non_linearity": 955.830322265625,
+ "cost_distance_total_intern_reflection": 13558.06640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1680.json b/outputs/amici/optimization_results/step1/score_details_iteration_1680.json
new file mode 100755
index 0000000..c6957a9
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1680.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.033613204956055,
+ "cost_distance_glasses": 710.0156587213219,
+ "cost_deviation": 11.307051658630371,
+ "cost_distorsion": 20.84821128845215,
+ "cost_thickness": 3730.77978515625,
+ "cost_beam_compression": 2.132922410964966,
+ "cost_non_linearity": 958.617919921875,
+ "cost_distance_total_intern_reflection": 13563.5224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.033613204956055,
+ "cost_distance_glasses": 710.0156587213219,
+ "cost_deviation": 11.307051658630371,
+ "cost_distorsion": 20.84821128845215,
+ "cost_thickness": 3730.77978515625,
+ "cost_beam_compression": 2.132922410964966,
+ "cost_non_linearity": 958.617919921875,
+ "cost_distance_total_intern_reflection": 13563.5224609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.033613204956055,
+ "cost_distance_glasses": 710.0156587213219,
+ "cost_deviation": 11.307051658630371,
+ "cost_distorsion": 20.84821128845215,
+ "cost_thickness": 3730.77978515625,
+ "cost_beam_compression": 2.132922410964966,
+ "cost_non_linearity": 958.617919921875,
+ "cost_distance_total_intern_reflection": 13563.5224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.033613204956055,
+ "cost_distance_glasses": 710.0156587213219,
+ "cost_deviation": 11.307051658630371,
+ "cost_distorsion": 20.84821128845215,
+ "cost_thickness": 3730.77978515625,
+ "cost_beam_compression": 2.132922410964966,
+ "cost_non_linearity": 958.617919921875,
+ "cost_distance_total_intern_reflection": 13563.5224609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1690.json b/outputs/amici/optimization_results/step1/score_details_iteration_1690.json
new file mode 100755
index 0000000..e07ee63
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1690.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 48.05610275268555,
+ "cost_distance_glasses": 704.3655748035262,
+ "cost_deviation": 1.9984014443252818e-07,
+ "cost_distorsion": 24.748435974121094,
+ "cost_thickness": 3731.728759765625,
+ "cost_beam_compression": 2.131059169769287,
+ "cost_non_linearity": 955.73095703125,
+ "cost_distance_total_intern_reflection": 13586.71875
+ },
+ "weighted components": {
+ "cost_dispersion": 48.05610275268555,
+ "cost_distance_glasses": 704.3655748035262,
+ "cost_deviation": 1.9984014443252818e-07,
+ "cost_distorsion": 24.748435974121094,
+ "cost_thickness": 3731.728759765625,
+ "cost_beam_compression": 2.131059169769287,
+ "cost_non_linearity": 955.73095703125,
+ "cost_distance_total_intern_reflection": 13586.71875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 48.05610275268555,
+ "cost_distance_glasses": 704.3655748035262,
+ "cost_deviation": 1.9984014443252818e-07,
+ "cost_distorsion": 24.748435974121094,
+ "cost_thickness": 3731.728759765625,
+ "cost_beam_compression": 2.131059169769287,
+ "cost_non_linearity": 955.73095703125,
+ "cost_distance_total_intern_reflection": 13586.71875
+ },
+ "weighted components": {
+ "cost_dispersion": 48.05610275268555,
+ "cost_distance_glasses": 704.3655748035262,
+ "cost_deviation": 1.9984014443252818e-07,
+ "cost_distorsion": 24.748435974121094,
+ "cost_thickness": 3731.728759765625,
+ "cost_beam_compression": 2.131059169769287,
+ "cost_non_linearity": 955.73095703125,
+ "cost_distance_total_intern_reflection": 13586.71875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_170.json b/outputs/amici/optimization_results/step1/score_details_iteration_170.json
new file mode 100755
index 0000000..9df57fd
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_170.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 197.6577911376953,
+ "cost_distance_glasses": 1720.402355713397,
+ "cost_deviation": 33.8509635925293,
+ "cost_distorsion": 20.30599594116211,
+ "cost_thickness": 4065.141357421875,
+ "cost_beam_compression": 2.330014705657959,
+ "cost_non_linearity": 941.6937866210938,
+ "cost_distance_total_intern_reflection": 14047.1748046875
+ },
+ "weighted components": {
+ "cost_dispersion": 197.6577911376953,
+ "cost_distance_glasses": 1720.402355713397,
+ "cost_deviation": 33.8509635925293,
+ "cost_distorsion": 20.30599594116211,
+ "cost_thickness": 4065.141357421875,
+ "cost_beam_compression": 2.330014705657959,
+ "cost_non_linearity": 941.6937866210938,
+ "cost_distance_total_intern_reflection": 14047.1748046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 197.6577911376953,
+ "cost_distance_glasses": 1720.402355713397,
+ "cost_deviation": 33.8509635925293,
+ "cost_distorsion": 20.30599594116211,
+ "cost_thickness": 4065.141357421875,
+ "cost_beam_compression": 2.330014705657959,
+ "cost_non_linearity": 941.6937866210938,
+ "cost_distance_total_intern_reflection": 14047.1748046875
+ },
+ "weighted components": {
+ "cost_dispersion": 197.6577911376953,
+ "cost_distance_glasses": 1720.402355713397,
+ "cost_deviation": 33.8509635925293,
+ "cost_distorsion": 20.30599594116211,
+ "cost_thickness": 4065.141357421875,
+ "cost_beam_compression": 2.330014705657959,
+ "cost_non_linearity": 941.6937866210938,
+ "cost_distance_total_intern_reflection": 14047.1748046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1700.json b/outputs/amici/optimization_results/step1/score_details_iteration_1700.json
new file mode 100755
index 0000000..1995841
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1700.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.23796081542969,
+ "cost_distance_glasses": 706.0687555834106,
+ "cost_deviation": 4.395079135894775,
+ "cost_distorsion": 22.00952911376953,
+ "cost_thickness": 3730.553955078125,
+ "cost_beam_compression": 2.1318399906158447,
+ "cost_non_linearity": 957.44677734375,
+ "cost_distance_total_intern_reflection": 13543.02734375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.23796081542969,
+ "cost_distance_glasses": 706.0687555834106,
+ "cost_deviation": 4.395079135894775,
+ "cost_distorsion": 22.00952911376953,
+ "cost_thickness": 3730.553955078125,
+ "cost_beam_compression": 2.1318399906158447,
+ "cost_non_linearity": 957.44677734375,
+ "cost_distance_total_intern_reflection": 13543.02734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.23796081542969,
+ "cost_distance_glasses": 706.0687555834106,
+ "cost_deviation": 4.395079135894775,
+ "cost_distorsion": 22.00952911376953,
+ "cost_thickness": 3730.553955078125,
+ "cost_beam_compression": 2.1318399906158447,
+ "cost_non_linearity": 957.44677734375,
+ "cost_distance_total_intern_reflection": 13543.02734375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.23796081542969,
+ "cost_distance_glasses": 706.0687555834106,
+ "cost_deviation": 4.395079135894775,
+ "cost_distorsion": 22.00952911376953,
+ "cost_thickness": 3730.553955078125,
+ "cost_beam_compression": 2.1318399906158447,
+ "cost_non_linearity": 957.44677734375,
+ "cost_distance_total_intern_reflection": 13543.02734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1710.json b/outputs/amici/optimization_results/step1/score_details_iteration_1710.json
new file mode 100755
index 0000000..eb676c4
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1710.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.17854118347168,
+ "cost_distance_glasses": 705.83693105662,
+ "cost_deviation": 15.808002471923828,
+ "cost_distorsion": 20.072139739990234,
+ "cost_thickness": 3729.744873046875,
+ "cost_beam_compression": 2.132809638977051,
+ "cost_non_linearity": 959.24169921875,
+ "cost_distance_total_intern_reflection": 13577.1845703125
+ },
+ "weighted components": {
+ "cost_dispersion": 25.17854118347168,
+ "cost_distance_glasses": 705.83693105662,
+ "cost_deviation": 15.808002471923828,
+ "cost_distorsion": 20.072139739990234,
+ "cost_thickness": 3729.744873046875,
+ "cost_beam_compression": 2.132809638977051,
+ "cost_non_linearity": 959.24169921875,
+ "cost_distance_total_intern_reflection": 13577.1845703125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 25.17854118347168,
+ "cost_distance_glasses": 705.83693105662,
+ "cost_deviation": 15.808002471923828,
+ "cost_distorsion": 20.072139739990234,
+ "cost_thickness": 3729.744873046875,
+ "cost_beam_compression": 2.132809638977051,
+ "cost_non_linearity": 959.24169921875,
+ "cost_distance_total_intern_reflection": 13577.1845703125
+ },
+ "weighted components": {
+ "cost_dispersion": 25.17854118347168,
+ "cost_distance_glasses": 705.83693105662,
+ "cost_deviation": 15.808002471923828,
+ "cost_distorsion": 20.072139739990234,
+ "cost_thickness": 3729.744873046875,
+ "cost_beam_compression": 2.132809638977051,
+ "cost_non_linearity": 959.24169921875,
+ "cost_distance_total_intern_reflection": 13577.1845703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1720.json b/outputs/amici/optimization_results/step1/score_details_iteration_1720.json
new file mode 100755
index 0000000..fd32e82
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1720.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 54.547386169433594,
+ "cost_distance_glasses": 701.3655148523321,
+ "cost_deviation": 0.47271066904067993,
+ "cost_distorsion": 24.10448455810547,
+ "cost_thickness": 3730.72802734375,
+ "cost_beam_compression": 2.1298952102661133,
+ "cost_non_linearity": 954.7177124023438,
+ "cost_distance_total_intern_reflection": 13562.4765625
+ },
+ "weighted components": {
+ "cost_dispersion": 54.547386169433594,
+ "cost_distance_glasses": 701.3655148523321,
+ "cost_deviation": 0.47271066904067993,
+ "cost_distorsion": 24.10448455810547,
+ "cost_thickness": 3730.72802734375,
+ "cost_beam_compression": 2.1298952102661133,
+ "cost_non_linearity": 954.7177124023438,
+ "cost_distance_total_intern_reflection": 13562.4765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 54.547386169433594,
+ "cost_distance_glasses": 701.3655148523321,
+ "cost_deviation": 0.47271066904067993,
+ "cost_distorsion": 24.10448455810547,
+ "cost_thickness": 3730.72802734375,
+ "cost_beam_compression": 2.1298952102661133,
+ "cost_non_linearity": 954.7177124023438,
+ "cost_distance_total_intern_reflection": 13562.4765625
+ },
+ "weighted components": {
+ "cost_dispersion": 54.547386169433594,
+ "cost_distance_glasses": 701.3655148523321,
+ "cost_deviation": 0.47271066904067993,
+ "cost_distorsion": 24.10448455810547,
+ "cost_thickness": 3730.72802734375,
+ "cost_beam_compression": 2.1298952102661133,
+ "cost_non_linearity": 954.7177124023438,
+ "cost_distance_total_intern_reflection": 13562.4765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1730.json b/outputs/amici/optimization_results/step1/score_details_iteration_1730.json
new file mode 100755
index 0000000..733da1d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1730.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.08609962463379,
+ "cost_distance_glasses": 703.8011110951869,
+ "cost_deviation": 20.7818546295166,
+ "cost_distorsion": 20.40945053100586,
+ "cost_thickness": 3729.2314453125,
+ "cost_beam_compression": 2.13293194770813,
+ "cost_non_linearity": 960.0161743164062,
+ "cost_distance_total_intern_reflection": 13567.5283203125
+ },
+ "weighted components": {
+ "cost_dispersion": 22.08609962463379,
+ "cost_distance_glasses": 703.8011110951869,
+ "cost_deviation": 20.7818546295166,
+ "cost_distorsion": 20.40945053100586,
+ "cost_thickness": 3729.2314453125,
+ "cost_beam_compression": 2.13293194770813,
+ "cost_non_linearity": 960.0161743164062,
+ "cost_distance_total_intern_reflection": 13567.5283203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.08609962463379,
+ "cost_distance_glasses": 703.8011110951869,
+ "cost_deviation": 20.7818546295166,
+ "cost_distorsion": 20.40945053100586,
+ "cost_thickness": 3729.2314453125,
+ "cost_beam_compression": 2.13293194770813,
+ "cost_non_linearity": 960.0161743164062,
+ "cost_distance_total_intern_reflection": 13567.5283203125
+ },
+ "weighted components": {
+ "cost_dispersion": 22.08609962463379,
+ "cost_distance_glasses": 703.8011110951869,
+ "cost_deviation": 20.7818546295166,
+ "cost_distorsion": 20.40945053100586,
+ "cost_thickness": 3729.2314453125,
+ "cost_beam_compression": 2.13293194770813,
+ "cost_non_linearity": 960.0161743164062,
+ "cost_distance_total_intern_reflection": 13567.5283203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1740.json b/outputs/amici/optimization_results/step1/score_details_iteration_1740.json
new file mode 100755
index 0000000..0f52492
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1740.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.83686828613281,
+ "cost_distance_glasses": 700.2128512831675,
+ "cost_deviation": 2.2062578201293945,
+ "cost_distorsion": 21.860027313232422,
+ "cost_thickness": 3729.522705078125,
+ "cost_beam_compression": 2.130791664123535,
+ "cost_non_linearity": 956.77978515625,
+ "cost_distance_total_intern_reflection": 13546.3349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 39.83686828613281,
+ "cost_distance_glasses": 700.2128512831675,
+ "cost_deviation": 2.2062578201293945,
+ "cost_distorsion": 21.860027313232422,
+ "cost_thickness": 3729.522705078125,
+ "cost_beam_compression": 2.130791664123535,
+ "cost_non_linearity": 956.77978515625,
+ "cost_distance_total_intern_reflection": 13546.3349609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.83686828613281,
+ "cost_distance_glasses": 700.2128512831675,
+ "cost_deviation": 2.2062578201293945,
+ "cost_distorsion": 21.860027313232422,
+ "cost_thickness": 3729.522705078125,
+ "cost_beam_compression": 2.130791664123535,
+ "cost_non_linearity": 956.77978515625,
+ "cost_distance_total_intern_reflection": 13546.3349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 39.83686828613281,
+ "cost_distance_glasses": 700.2128512831675,
+ "cost_deviation": 2.2062578201293945,
+ "cost_distorsion": 21.860027313232422,
+ "cost_thickness": 3729.522705078125,
+ "cost_beam_compression": 2.130791664123535,
+ "cost_non_linearity": 956.77978515625,
+ "cost_distance_total_intern_reflection": 13546.3349609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1750.json b/outputs/amici/optimization_results/step1/score_details_iteration_1750.json
new file mode 100755
index 0000000..2817f2f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1750.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.78089904785156,
+ "cost_distance_glasses": 700.3235862371706,
+ "cost_deviation": 5.600101947784424,
+ "cost_distorsion": 21.959640502929688,
+ "cost_thickness": 3729.354248046875,
+ "cost_beam_compression": 2.1313576698303223,
+ "cost_non_linearity": 957.702880859375,
+ "cost_distance_total_intern_reflection": 13542.3447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.78089904785156,
+ "cost_distance_glasses": 700.3235862371706,
+ "cost_deviation": 5.600101947784424,
+ "cost_distorsion": 21.959640502929688,
+ "cost_thickness": 3729.354248046875,
+ "cost_beam_compression": 2.1313576698303223,
+ "cost_non_linearity": 957.702880859375,
+ "cost_distance_total_intern_reflection": 13542.3447265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.78089904785156,
+ "cost_distance_glasses": 700.3235862371706,
+ "cost_deviation": 5.600101947784424,
+ "cost_distorsion": 21.959640502929688,
+ "cost_thickness": 3729.354248046875,
+ "cost_beam_compression": 2.1313576698303223,
+ "cost_non_linearity": 957.702880859375,
+ "cost_distance_total_intern_reflection": 13542.3447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.78089904785156,
+ "cost_distance_glasses": 700.3235862371706,
+ "cost_deviation": 5.600101947784424,
+ "cost_distorsion": 21.959640502929688,
+ "cost_thickness": 3729.354248046875,
+ "cost_beam_compression": 2.1313576698303223,
+ "cost_non_linearity": 957.702880859375,
+ "cost_distance_total_intern_reflection": 13542.3447265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1760.json b/outputs/amici/optimization_results/step1/score_details_iteration_1760.json
new file mode 100755
index 0000000..9dc2d8b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1760.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 21.42281723022461,
+ "cost_distance_glasses": 699.9730520875654,
+ "cost_deviation": 20.907033920288086,
+ "cost_distorsion": 20.9132137298584,
+ "cost_thickness": 3728.8466796875,
+ "cost_beam_compression": 2.132720947265625,
+ "cost_non_linearity": 959.9085693359375,
+ "cost_distance_total_intern_reflection": 13551.4765625
+ },
+ "weighted components": {
+ "cost_dispersion": 21.42281723022461,
+ "cost_distance_glasses": 699.9730520875654,
+ "cost_deviation": 20.907033920288086,
+ "cost_distorsion": 20.9132137298584,
+ "cost_thickness": 3728.8466796875,
+ "cost_beam_compression": 2.132720947265625,
+ "cost_non_linearity": 959.9085693359375,
+ "cost_distance_total_intern_reflection": 13551.4765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 21.42281723022461,
+ "cost_distance_glasses": 699.9730520875654,
+ "cost_deviation": 20.907033920288086,
+ "cost_distorsion": 20.9132137298584,
+ "cost_thickness": 3728.8466796875,
+ "cost_beam_compression": 2.132720947265625,
+ "cost_non_linearity": 959.9085693359375,
+ "cost_distance_total_intern_reflection": 13551.4765625
+ },
+ "weighted components": {
+ "cost_dispersion": 21.42281723022461,
+ "cost_distance_glasses": 699.9730520875654,
+ "cost_deviation": 20.907033920288086,
+ "cost_distorsion": 20.9132137298584,
+ "cost_thickness": 3728.8466796875,
+ "cost_beam_compression": 2.132720947265625,
+ "cost_non_linearity": 959.9085693359375,
+ "cost_distance_total_intern_reflection": 13551.4765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1770.json b/outputs/amici/optimization_results/step1/score_details_iteration_1770.json
new file mode 100755
index 0000000..fcad232
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1770.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 74.15287017822266,
+ "cost_distance_glasses": 691.366546174434,
+ "cost_deviation": 8.58411693572998,
+ "cost_distorsion": 24.09847640991211,
+ "cost_thickness": 3729.795166015625,
+ "cost_beam_compression": 2.127674102783203,
+ "cost_non_linearity": 952.5614624023438,
+ "cost_distance_total_intern_reflection": 13542.359375
+ },
+ "weighted components": {
+ "cost_dispersion": 74.15287017822266,
+ "cost_distance_glasses": 691.366546174434,
+ "cost_deviation": 8.58411693572998,
+ "cost_distorsion": 24.09847640991211,
+ "cost_thickness": 3729.795166015625,
+ "cost_beam_compression": 2.127674102783203,
+ "cost_non_linearity": 952.5614624023438,
+ "cost_distance_total_intern_reflection": 13542.359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 74.15287017822266,
+ "cost_distance_glasses": 691.366546174434,
+ "cost_deviation": 8.58411693572998,
+ "cost_distorsion": 24.09847640991211,
+ "cost_thickness": 3729.795166015625,
+ "cost_beam_compression": 2.127674102783203,
+ "cost_non_linearity": 952.5614624023438,
+ "cost_distance_total_intern_reflection": 13542.359375
+ },
+ "weighted components": {
+ "cost_dispersion": 74.15287017822266,
+ "cost_distance_glasses": 691.366546174434,
+ "cost_deviation": 8.58411693572998,
+ "cost_distorsion": 24.09847640991211,
+ "cost_thickness": 3729.795166015625,
+ "cost_beam_compression": 2.127674102783203,
+ "cost_non_linearity": 952.5614624023438,
+ "cost_distance_total_intern_reflection": 13542.359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1780.json b/outputs/amici/optimization_results/step1/score_details_iteration_1780.json
new file mode 100755
index 0000000..75ce290
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1780.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.752927780151367,
+ "cost_distance_glasses": 698.7024325024487,
+ "cost_deviation": 9.052236557006836,
+ "cost_distorsion": 20.071823120117188,
+ "cost_thickness": 3728.401611328125,
+ "cost_beam_compression": 2.1313376426696777,
+ "cost_non_linearity": 958.3656005859375,
+ "cost_distance_total_intern_reflection": 13578.9775390625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.752927780151367,
+ "cost_distance_glasses": 698.7024325024487,
+ "cost_deviation": 9.052236557006836,
+ "cost_distorsion": 20.071823120117188,
+ "cost_thickness": 3728.401611328125,
+ "cost_beam_compression": 2.1313376426696777,
+ "cost_non_linearity": 958.3656005859375,
+ "cost_distance_total_intern_reflection": 13578.9775390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.752927780151367,
+ "cost_distance_glasses": 698.7024325024487,
+ "cost_deviation": 9.052236557006836,
+ "cost_distorsion": 20.071823120117188,
+ "cost_thickness": 3728.401611328125,
+ "cost_beam_compression": 2.1313376426696777,
+ "cost_non_linearity": 958.3656005859375,
+ "cost_distance_total_intern_reflection": 13578.9775390625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.752927780151367,
+ "cost_distance_glasses": 698.7024325024487,
+ "cost_deviation": 9.052236557006836,
+ "cost_distorsion": 20.071823120117188,
+ "cost_thickness": 3728.401611328125,
+ "cost_beam_compression": 2.1313376426696777,
+ "cost_non_linearity": 958.3656005859375,
+ "cost_distance_total_intern_reflection": 13578.9775390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1790.json b/outputs/amici/optimization_results/step1/score_details_iteration_1790.json
new file mode 100755
index 0000000..e9df7b9
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1790.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.898067474365234,
+ "cost_distance_glasses": 694.7239628624741,
+ "cost_deviation": 5.398828983306885,
+ "cost_distorsion": 22.019235610961914,
+ "cost_thickness": 3728.824951171875,
+ "cost_beam_compression": 2.1310412883758545,
+ "cost_non_linearity": 957.6389770507812,
+ "cost_distance_total_intern_reflection": 13544.66015625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.898067474365234,
+ "cost_distance_glasses": 694.7239628624741,
+ "cost_deviation": 5.398828983306885,
+ "cost_distorsion": 22.019235610961914,
+ "cost_thickness": 3728.824951171875,
+ "cost_beam_compression": 2.1310412883758545,
+ "cost_non_linearity": 957.6389770507812,
+ "cost_distance_total_intern_reflection": 13544.66015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.898067474365234,
+ "cost_distance_glasses": 694.7239628624741,
+ "cost_deviation": 5.398828983306885,
+ "cost_distorsion": 22.019235610961914,
+ "cost_thickness": 3728.824951171875,
+ "cost_beam_compression": 2.1310412883758545,
+ "cost_non_linearity": 957.6389770507812,
+ "cost_distance_total_intern_reflection": 13544.66015625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.898067474365234,
+ "cost_distance_glasses": 694.7239628624741,
+ "cost_deviation": 5.398828983306885,
+ "cost_distorsion": 22.019235610961914,
+ "cost_thickness": 3728.824951171875,
+ "cost_beam_compression": 2.1310412883758545,
+ "cost_non_linearity": 957.6389770507812,
+ "cost_distance_total_intern_reflection": 13544.66015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_180.json b/outputs/amici/optimization_results/step1/score_details_iteration_180.json
new file mode 100755
index 0000000..c741060
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_180.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 182.9791259765625,
+ "cost_distance_glasses": 1711.5601821690316,
+ "cost_deviation": 31.671253204345703,
+ "cost_distorsion": 20.343353271484375,
+ "cost_thickness": 4072.53564453125,
+ "cost_beam_compression": 2.3347127437591553,
+ "cost_non_linearity": 942.7208862304688,
+ "cost_distance_total_intern_reflection": 14058.3330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 182.9791259765625,
+ "cost_distance_glasses": 1711.5601821690316,
+ "cost_deviation": 31.671253204345703,
+ "cost_distorsion": 20.343353271484375,
+ "cost_thickness": 4072.53564453125,
+ "cost_beam_compression": 2.3347127437591553,
+ "cost_non_linearity": 942.7208862304688,
+ "cost_distance_total_intern_reflection": 14058.3330078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 182.9791259765625,
+ "cost_distance_glasses": 1711.5601821690316,
+ "cost_deviation": 31.671253204345703,
+ "cost_distorsion": 20.343353271484375,
+ "cost_thickness": 4072.53564453125,
+ "cost_beam_compression": 2.3347127437591553,
+ "cost_non_linearity": 942.7208862304688,
+ "cost_distance_total_intern_reflection": 14058.3330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 182.9791259765625,
+ "cost_distance_glasses": 1711.5601821690316,
+ "cost_deviation": 31.671253204345703,
+ "cost_distorsion": 20.343353271484375,
+ "cost_thickness": 4072.53564453125,
+ "cost_beam_compression": 2.3347127437591553,
+ "cost_non_linearity": 942.7208862304688,
+ "cost_distance_total_intern_reflection": 14058.3330078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1800.json b/outputs/amici/optimization_results/step1/score_details_iteration_1800.json
new file mode 100755
index 0000000..720dab8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1800.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.59739303588867,
+ "cost_distance_glasses": 692.8521064114242,
+ "cost_deviation": 5.52139139175415,
+ "cost_distorsion": 22.47523307800293,
+ "cost_thickness": 3728.796630859375,
+ "cost_beam_compression": 2.1310627460479736,
+ "cost_non_linearity": 957.7518310546875,
+ "cost_distance_total_intern_reflection": 13554.5166015625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.59739303588867,
+ "cost_distance_glasses": 692.8521064114242,
+ "cost_deviation": 5.52139139175415,
+ "cost_distorsion": 22.47523307800293,
+ "cost_thickness": 3728.796630859375,
+ "cost_beam_compression": 2.1310627460479736,
+ "cost_non_linearity": 957.7518310546875,
+ "cost_distance_total_intern_reflection": 13554.5166015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.59739303588867,
+ "cost_distance_glasses": 692.8521064114242,
+ "cost_deviation": 5.52139139175415,
+ "cost_distorsion": 22.47523307800293,
+ "cost_thickness": 3728.796630859375,
+ "cost_beam_compression": 2.1310627460479736,
+ "cost_non_linearity": 957.7518310546875,
+ "cost_distance_total_intern_reflection": 13554.5166015625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.59739303588867,
+ "cost_distance_glasses": 692.8521064114242,
+ "cost_deviation": 5.52139139175415,
+ "cost_distorsion": 22.47523307800293,
+ "cost_thickness": 3728.796630859375,
+ "cost_beam_compression": 2.1310627460479736,
+ "cost_non_linearity": 957.7518310546875,
+ "cost_distance_total_intern_reflection": 13554.5166015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1810.json b/outputs/amici/optimization_results/step1/score_details_iteration_1810.json
new file mode 100755
index 0000000..dcf7661
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1810.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 26.2043514251709,
+ "cost_distance_glasses": 693.6992036902553,
+ "cost_deviation": 13.816792488098145,
+ "cost_distorsion": 20.935331344604492,
+ "cost_thickness": 3728.154296875,
+ "cost_beam_compression": 2.131700038909912,
+ "cost_non_linearity": 958.8349609375,
+ "cost_distance_total_intern_reflection": 13553.880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 26.2043514251709,
+ "cost_distance_glasses": 693.6992036902553,
+ "cost_deviation": 13.816792488098145,
+ "cost_distorsion": 20.935331344604492,
+ "cost_thickness": 3728.154296875,
+ "cost_beam_compression": 2.131700038909912,
+ "cost_non_linearity": 958.8349609375,
+ "cost_distance_total_intern_reflection": 13553.880859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 26.2043514251709,
+ "cost_distance_glasses": 693.6992036902553,
+ "cost_deviation": 13.816792488098145,
+ "cost_distorsion": 20.935331344604492,
+ "cost_thickness": 3728.154296875,
+ "cost_beam_compression": 2.131700038909912,
+ "cost_non_linearity": 958.8349609375,
+ "cost_distance_total_intern_reflection": 13553.880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 26.2043514251709,
+ "cost_distance_glasses": 693.6992036902553,
+ "cost_deviation": 13.816792488098145,
+ "cost_distorsion": 20.935331344604492,
+ "cost_thickness": 3728.154296875,
+ "cost_beam_compression": 2.131700038909912,
+ "cost_non_linearity": 958.8349609375,
+ "cost_distance_total_intern_reflection": 13553.880859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1820.json b/outputs/amici/optimization_results/step1/score_details_iteration_1820.json
new file mode 100755
index 0000000..87e82de
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1820.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.884063720703125,
+ "cost_distance_glasses": 692.176809552497,
+ "cost_deviation": 11.11148738861084,
+ "cost_distorsion": 20.650039672851562,
+ "cost_thickness": 3727.90087890625,
+ "cost_beam_compression": 2.1312828063964844,
+ "cost_non_linearity": 958.4874267578125,
+ "cost_distance_total_intern_reflection": 13564.466796875
+ },
+ "weighted components": {
+ "cost_dispersion": 28.884063720703125,
+ "cost_distance_glasses": 692.176809552497,
+ "cost_deviation": 11.11148738861084,
+ "cost_distorsion": 20.650039672851562,
+ "cost_thickness": 3727.90087890625,
+ "cost_beam_compression": 2.1312828063964844,
+ "cost_non_linearity": 958.4874267578125,
+ "cost_distance_total_intern_reflection": 13564.466796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.884063720703125,
+ "cost_distance_glasses": 692.176809552497,
+ "cost_deviation": 11.11148738861084,
+ "cost_distorsion": 20.650039672851562,
+ "cost_thickness": 3727.90087890625,
+ "cost_beam_compression": 2.1312828063964844,
+ "cost_non_linearity": 958.4874267578125,
+ "cost_distance_total_intern_reflection": 13564.466796875
+ },
+ "weighted components": {
+ "cost_dispersion": 28.884063720703125,
+ "cost_distance_glasses": 692.176809552497,
+ "cost_deviation": 11.11148738861084,
+ "cost_distorsion": 20.650039672851562,
+ "cost_thickness": 3727.90087890625,
+ "cost_beam_compression": 2.1312828063964844,
+ "cost_non_linearity": 958.4874267578125,
+ "cost_distance_total_intern_reflection": 13564.466796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1830.json b/outputs/amici/optimization_results/step1/score_details_iteration_1830.json
new file mode 100755
index 0000000..7ac8ffe
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1830.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 61.7352409362793,
+ "cost_distance_glasses": 686.2489309278764,
+ "cost_deviation": 2.6323065757751465,
+ "cost_distorsion": 24.92333984375,
+ "cost_thickness": 3729.234375,
+ "cost_beam_compression": 2.128415584564209,
+ "cost_non_linearity": 953.9885864257812,
+ "cost_distance_total_intern_reflection": 13572.1513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 61.7352409362793,
+ "cost_distance_glasses": 686.2489309278764,
+ "cost_deviation": 2.6323065757751465,
+ "cost_distorsion": 24.92333984375,
+ "cost_thickness": 3729.234375,
+ "cost_beam_compression": 2.128415584564209,
+ "cost_non_linearity": 953.9885864257812,
+ "cost_distance_total_intern_reflection": 13572.1513671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 61.7352409362793,
+ "cost_distance_glasses": 686.2489309278764,
+ "cost_deviation": 2.6323065757751465,
+ "cost_distorsion": 24.92333984375,
+ "cost_thickness": 3729.234375,
+ "cost_beam_compression": 2.128415584564209,
+ "cost_non_linearity": 953.9885864257812,
+ "cost_distance_total_intern_reflection": 13572.1513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 61.7352409362793,
+ "cost_distance_glasses": 686.2489309278764,
+ "cost_deviation": 2.6323065757751465,
+ "cost_distorsion": 24.92333984375,
+ "cost_thickness": 3729.234375,
+ "cost_beam_compression": 2.128415584564209,
+ "cost_non_linearity": 953.9885864257812,
+ "cost_distance_total_intern_reflection": 13572.1513671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1840.json b/outputs/amici/optimization_results/step1/score_details_iteration_1840.json
new file mode 100755
index 0000000..fb6866f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1840.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.073960304260254,
+ "cost_distance_glasses": 694.2706148721891,
+ "cost_deviation": 57.34910202026367,
+ "cost_distorsion": 18.823728561401367,
+ "cost_thickness": 3726.886474609375,
+ "cost_beam_compression": 2.1339030265808105,
+ "cost_non_linearity": 962.9855346679688,
+ "cost_distance_total_intern_reflection": 13590.28515625
+ },
+ "weighted components": {
+ "cost_dispersion": 10.073960304260254,
+ "cost_distance_glasses": 694.2706148721891,
+ "cost_deviation": 57.34910202026367,
+ "cost_distorsion": 18.823728561401367,
+ "cost_thickness": 3726.886474609375,
+ "cost_beam_compression": 2.1339030265808105,
+ "cost_non_linearity": 962.9855346679688,
+ "cost_distance_total_intern_reflection": 13590.28515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.073960304260254,
+ "cost_distance_glasses": 694.2706148721891,
+ "cost_deviation": 57.34910202026367,
+ "cost_distorsion": 18.823728561401367,
+ "cost_thickness": 3726.886474609375,
+ "cost_beam_compression": 2.1339030265808105,
+ "cost_non_linearity": 962.9855346679688,
+ "cost_distance_total_intern_reflection": 13590.28515625
+ },
+ "weighted components": {
+ "cost_dispersion": 10.073960304260254,
+ "cost_distance_glasses": 694.2706148721891,
+ "cost_deviation": 57.34910202026367,
+ "cost_distorsion": 18.823728561401367,
+ "cost_thickness": 3726.886474609375,
+ "cost_beam_compression": 2.1339030265808105,
+ "cost_non_linearity": 962.9855346679688,
+ "cost_distance_total_intern_reflection": 13590.28515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1850.json b/outputs/amici/optimization_results/step1/score_details_iteration_1850.json
new file mode 100755
index 0000000..abf6fee
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1850.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.099294662475586,
+ "cost_distance_glasses": 688.366190929707,
+ "cost_deviation": 19.62459945678711,
+ "cost_distorsion": 21.601707458496094,
+ "cost_thickness": 3727.951171875,
+ "cost_beam_compression": 2.132153034210205,
+ "cost_non_linearity": 959.7805786132812,
+ "cost_distance_total_intern_reflection": 13552.9765625
+ },
+ "weighted components": {
+ "cost_dispersion": 22.099294662475586,
+ "cost_distance_glasses": 688.366190929707,
+ "cost_deviation": 19.62459945678711,
+ "cost_distorsion": 21.601707458496094,
+ "cost_thickness": 3727.951171875,
+ "cost_beam_compression": 2.132153034210205,
+ "cost_non_linearity": 959.7805786132812,
+ "cost_distance_total_intern_reflection": 13552.9765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.099294662475586,
+ "cost_distance_glasses": 688.366190929707,
+ "cost_deviation": 19.62459945678711,
+ "cost_distorsion": 21.601707458496094,
+ "cost_thickness": 3727.951171875,
+ "cost_beam_compression": 2.132153034210205,
+ "cost_non_linearity": 959.7805786132812,
+ "cost_distance_total_intern_reflection": 13552.9765625
+ },
+ "weighted components": {
+ "cost_dispersion": 22.099294662475586,
+ "cost_distance_glasses": 688.366190929707,
+ "cost_deviation": 19.62459945678711,
+ "cost_distorsion": 21.601707458496094,
+ "cost_thickness": 3727.951171875,
+ "cost_beam_compression": 2.132153034210205,
+ "cost_non_linearity": 959.7805786132812,
+ "cost_distance_total_intern_reflection": 13552.9765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1860.json b/outputs/amici/optimization_results/step1/score_details_iteration_1860.json
new file mode 100755
index 0000000..0cf9994
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1860.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.626625061035156,
+ "cost_distance_glasses": 686.798608829701,
+ "cost_deviation": 11.899869918823242,
+ "cost_distorsion": 20.97896385192871,
+ "cost_thickness": 3727.92724609375,
+ "cost_beam_compression": 2.1314096450805664,
+ "cost_non_linearity": 958.67138671875,
+ "cost_distance_total_intern_reflection": 13554.6767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 27.626625061035156,
+ "cost_distance_glasses": 686.798608829701,
+ "cost_deviation": 11.899869918823242,
+ "cost_distorsion": 20.97896385192871,
+ "cost_thickness": 3727.92724609375,
+ "cost_beam_compression": 2.1314096450805664,
+ "cost_non_linearity": 958.67138671875,
+ "cost_distance_total_intern_reflection": 13554.6767578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.626625061035156,
+ "cost_distance_glasses": 686.798608829701,
+ "cost_deviation": 11.899869918823242,
+ "cost_distorsion": 20.97896385192871,
+ "cost_thickness": 3727.92724609375,
+ "cost_beam_compression": 2.1314096450805664,
+ "cost_non_linearity": 958.67138671875,
+ "cost_distance_total_intern_reflection": 13554.6767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 27.626625061035156,
+ "cost_distance_glasses": 686.798608829701,
+ "cost_deviation": 11.899869918823242,
+ "cost_distorsion": 20.97896385192871,
+ "cost_thickness": 3727.92724609375,
+ "cost_beam_compression": 2.1314096450805664,
+ "cost_non_linearity": 958.67138671875,
+ "cost_distance_total_intern_reflection": 13554.6767578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1870.json b/outputs/amici/optimization_results/step1/score_details_iteration_1870.json
new file mode 100755
index 0000000..a11a574
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1870.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 41.31576919555664,
+ "cost_distance_glasses": 684.6448856580902,
+ "cost_deviation": 1.6606251001358032,
+ "cost_distorsion": 21.40984344482422,
+ "cost_thickness": 3728.14208984375,
+ "cost_beam_compression": 2.1299314498901367,
+ "cost_non_linearity": 956.4981079101562,
+ "cost_distance_total_intern_reflection": 13557.3681640625
+ },
+ "weighted components": {
+ "cost_dispersion": 41.31576919555664,
+ "cost_distance_glasses": 684.6448856580902,
+ "cost_deviation": 1.6606251001358032,
+ "cost_distorsion": 21.40984344482422,
+ "cost_thickness": 3728.14208984375,
+ "cost_beam_compression": 2.1299314498901367,
+ "cost_non_linearity": 956.4981079101562,
+ "cost_distance_total_intern_reflection": 13557.3681640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 41.31576919555664,
+ "cost_distance_glasses": 684.6448856580902,
+ "cost_deviation": 1.6606251001358032,
+ "cost_distorsion": 21.40984344482422,
+ "cost_thickness": 3728.14208984375,
+ "cost_beam_compression": 2.1299314498901367,
+ "cost_non_linearity": 956.4981079101562,
+ "cost_distance_total_intern_reflection": 13557.3681640625
+ },
+ "weighted components": {
+ "cost_dispersion": 41.31576919555664,
+ "cost_distance_glasses": 684.6448856580902,
+ "cost_deviation": 1.6606251001358032,
+ "cost_distorsion": 21.40984344482422,
+ "cost_thickness": 3728.14208984375,
+ "cost_beam_compression": 2.1299314498901367,
+ "cost_non_linearity": 956.4981079101562,
+ "cost_distance_total_intern_reflection": 13557.3681640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1880.json b/outputs/amici/optimization_results/step1/score_details_iteration_1880.json
new file mode 100755
index 0000000..ce4029b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1880.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.576839447021484,
+ "cost_distance_glasses": 684.1568923087076,
+ "cost_deviation": 1.9060359001159668,
+ "cost_distorsion": 21.702028274536133,
+ "cost_thickness": 3728.131591796875,
+ "cost_beam_compression": 2.12998628616333,
+ "cost_non_linearity": 956.6640014648438,
+ "cost_distance_total_intern_reflection": 13546.9580078125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.576839447021484,
+ "cost_distance_glasses": 684.1568923087076,
+ "cost_deviation": 1.9060359001159668,
+ "cost_distorsion": 21.702028274536133,
+ "cost_thickness": 3728.131591796875,
+ "cost_beam_compression": 2.12998628616333,
+ "cost_non_linearity": 956.6640014648438,
+ "cost_distance_total_intern_reflection": 13546.9580078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.576839447021484,
+ "cost_distance_glasses": 684.1568923087076,
+ "cost_deviation": 1.9060359001159668,
+ "cost_distorsion": 21.702028274536133,
+ "cost_thickness": 3728.131591796875,
+ "cost_beam_compression": 2.12998628616333,
+ "cost_non_linearity": 956.6640014648438,
+ "cost_distance_total_intern_reflection": 13546.9580078125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.576839447021484,
+ "cost_distance_glasses": 684.1568923087076,
+ "cost_deviation": 1.9060359001159668,
+ "cost_distorsion": 21.702028274536133,
+ "cost_thickness": 3728.131591796875,
+ "cost_beam_compression": 2.12998628616333,
+ "cost_non_linearity": 956.6640014648438,
+ "cost_distance_total_intern_reflection": 13546.9580078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1890.json b/outputs/amici/optimization_results/step1/score_details_iteration_1890.json
new file mode 100755
index 0000000..f3a027d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1890.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.87778854370117,
+ "cost_distance_glasses": 682.9343935508035,
+ "cost_deviation": 4.75192403793335,
+ "cost_distorsion": 21.36989974975586,
+ "cost_thickness": 3727.79833984375,
+ "cost_beam_compression": 2.1304006576538086,
+ "cost_non_linearity": 957.401611328125,
+ "cost_distance_total_intern_reflection": 13554.099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.87778854370117,
+ "cost_distance_glasses": 682.9343935508035,
+ "cost_deviation": 4.75192403793335,
+ "cost_distorsion": 21.36989974975586,
+ "cost_thickness": 3727.79833984375,
+ "cost_beam_compression": 2.1304006576538086,
+ "cost_non_linearity": 957.401611328125,
+ "cost_distance_total_intern_reflection": 13554.099609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.87778854370117,
+ "cost_distance_glasses": 682.9343935508035,
+ "cost_deviation": 4.75192403793335,
+ "cost_distorsion": 21.36989974975586,
+ "cost_thickness": 3727.79833984375,
+ "cost_beam_compression": 2.1304006576538086,
+ "cost_non_linearity": 957.401611328125,
+ "cost_distance_total_intern_reflection": 13554.099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.87778854370117,
+ "cost_distance_glasses": 682.9343935508035,
+ "cost_deviation": 4.75192403793335,
+ "cost_distorsion": 21.36989974975586,
+ "cost_thickness": 3727.79833984375,
+ "cost_beam_compression": 2.1304006576538086,
+ "cost_non_linearity": 957.401611328125,
+ "cost_distance_total_intern_reflection": 13554.099609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_190.json b/outputs/amici/optimization_results/step1/score_details_iteration_190.json
new file mode 100755
index 0000000..139e28f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_190.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 178.01168823242188,
+ "cost_distance_glasses": 1612.6025631737439,
+ "cost_deviation": 26.153799057006836,
+ "cost_distorsion": 21.01165008544922,
+ "cost_thickness": 4078.738037109375,
+ "cost_beam_compression": 2.338440418243408,
+ "cost_non_linearity": 942.9739379882812,
+ "cost_distance_total_intern_reflection": 14059.56640625
+ },
+ "weighted components": {
+ "cost_dispersion": 178.01168823242188,
+ "cost_distance_glasses": 1612.6025631737439,
+ "cost_deviation": 26.153799057006836,
+ "cost_distorsion": 21.01165008544922,
+ "cost_thickness": 4078.738037109375,
+ "cost_beam_compression": 2.338440418243408,
+ "cost_non_linearity": 942.9739379882812,
+ "cost_distance_total_intern_reflection": 14059.56640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 178.01168823242188,
+ "cost_distance_glasses": 1612.6025631737439,
+ "cost_deviation": 26.153799057006836,
+ "cost_distorsion": 21.01165008544922,
+ "cost_thickness": 4078.738037109375,
+ "cost_beam_compression": 2.338440418243408,
+ "cost_non_linearity": 942.9739379882812,
+ "cost_distance_total_intern_reflection": 14059.56640625
+ },
+ "weighted components": {
+ "cost_dispersion": 178.01168823242188,
+ "cost_distance_glasses": 1612.6025631737439,
+ "cost_deviation": 26.153799057006836,
+ "cost_distorsion": 21.01165008544922,
+ "cost_thickness": 4078.738037109375,
+ "cost_beam_compression": 2.338440418243408,
+ "cost_non_linearity": 942.9739379882812,
+ "cost_distance_total_intern_reflection": 14059.56640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1900.json b/outputs/amici/optimization_results/step1/score_details_iteration_1900.json
new file mode 100755
index 0000000..603b33c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1900.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.018470764160156,
+ "cost_distance_glasses": 679.1591850527504,
+ "cost_deviation": 0.16926728188991547,
+ "cost_distorsion": 24.149974822998047,
+ "cost_thickness": 3728.73779296875,
+ "cost_beam_compression": 2.129693031311035,
+ "cost_non_linearity": 955.9776611328125,
+ "cost_distance_total_intern_reflection": 13571.1884765625
+ },
+ "weighted components": {
+ "cost_dispersion": 46.018470764160156,
+ "cost_distance_glasses": 679.1591850527504,
+ "cost_deviation": 0.16926728188991547,
+ "cost_distorsion": 24.149974822998047,
+ "cost_thickness": 3728.73779296875,
+ "cost_beam_compression": 2.129693031311035,
+ "cost_non_linearity": 955.9776611328125,
+ "cost_distance_total_intern_reflection": 13571.1884765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.018470764160156,
+ "cost_distance_glasses": 679.1591850527504,
+ "cost_deviation": 0.16926728188991547,
+ "cost_distorsion": 24.149974822998047,
+ "cost_thickness": 3728.73779296875,
+ "cost_beam_compression": 2.129693031311035,
+ "cost_non_linearity": 955.9776611328125,
+ "cost_distance_total_intern_reflection": 13571.1884765625
+ },
+ "weighted components": {
+ "cost_dispersion": 46.018470764160156,
+ "cost_distance_glasses": 679.1591850527504,
+ "cost_deviation": 0.16926728188991547,
+ "cost_distorsion": 24.149974822998047,
+ "cost_thickness": 3728.73779296875,
+ "cost_beam_compression": 2.129693031311035,
+ "cost_non_linearity": 955.9776611328125,
+ "cost_distance_total_intern_reflection": 13571.1884765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1910.json b/outputs/amici/optimization_results/step1/score_details_iteration_1910.json
new file mode 100755
index 0000000..f28a9ab
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1910.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 21.00619888305664,
+ "cost_distance_glasses": 682.8115756780107,
+ "cost_deviation": 23.273399353027344,
+ "cost_distorsion": 20.147069931030273,
+ "cost_thickness": 3727.392822265625,
+ "cost_beam_compression": 2.1321706771850586,
+ "cost_non_linearity": 960.0198974609375,
+ "cost_distance_total_intern_reflection": 13569.5869140625
+ },
+ "weighted components": {
+ "cost_dispersion": 21.00619888305664,
+ "cost_distance_glasses": 682.8115756780107,
+ "cost_deviation": 23.273399353027344,
+ "cost_distorsion": 20.147069931030273,
+ "cost_thickness": 3727.392822265625,
+ "cost_beam_compression": 2.1321706771850586,
+ "cost_non_linearity": 960.0198974609375,
+ "cost_distance_total_intern_reflection": 13569.5869140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 21.00619888305664,
+ "cost_distance_glasses": 682.8115756780107,
+ "cost_deviation": 23.273399353027344,
+ "cost_distorsion": 20.147069931030273,
+ "cost_thickness": 3727.392822265625,
+ "cost_beam_compression": 2.1321706771850586,
+ "cost_non_linearity": 960.0198974609375,
+ "cost_distance_total_intern_reflection": 13569.5869140625
+ },
+ "weighted components": {
+ "cost_dispersion": 21.00619888305664,
+ "cost_distance_glasses": 682.8115756780107,
+ "cost_deviation": 23.273399353027344,
+ "cost_distorsion": 20.147069931030273,
+ "cost_thickness": 3727.392822265625,
+ "cost_beam_compression": 2.1321706771850586,
+ "cost_non_linearity": 960.0198974609375,
+ "cost_distance_total_intern_reflection": 13569.5869140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1920.json b/outputs/amici/optimization_results/step1/score_details_iteration_1920.json
new file mode 100755
index 0000000..3700472
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1920.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 45.59299087524414,
+ "cost_distance_glasses": 677.9043297054026,
+ "cost_deviation": 0.2518745958805084,
+ "cost_distorsion": 23.129058837890625,
+ "cost_thickness": 3728.4921875,
+ "cost_beam_compression": 2.1295886039733887,
+ "cost_non_linearity": 956.031982421875,
+ "cost_distance_total_intern_reflection": 13553.330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 45.59299087524414,
+ "cost_distance_glasses": 677.9043297054026,
+ "cost_deviation": 0.2518745958805084,
+ "cost_distorsion": 23.129058837890625,
+ "cost_thickness": 3728.4921875,
+ "cost_beam_compression": 2.1295886039733887,
+ "cost_non_linearity": 956.031982421875,
+ "cost_distance_total_intern_reflection": 13553.330078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 45.59299087524414,
+ "cost_distance_glasses": 677.9043297054026,
+ "cost_deviation": 0.2518745958805084,
+ "cost_distorsion": 23.129058837890625,
+ "cost_thickness": 3728.4921875,
+ "cost_beam_compression": 2.1295886039733887,
+ "cost_non_linearity": 956.031982421875,
+ "cost_distance_total_intern_reflection": 13553.330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 45.59299087524414,
+ "cost_distance_glasses": 677.9043297054026,
+ "cost_deviation": 0.2518745958805084,
+ "cost_distorsion": 23.129058837890625,
+ "cost_thickness": 3728.4921875,
+ "cost_beam_compression": 2.1295886039733887,
+ "cost_non_linearity": 956.031982421875,
+ "cost_distance_total_intern_reflection": 13553.330078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1930.json b/outputs/amici/optimization_results/step1/score_details_iteration_1930.json
new file mode 100755
index 0000000..23679c2
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1930.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.61103439331055,
+ "cost_distance_glasses": 676.3222433429431,
+ "cost_deviation": 0.03133813291788101,
+ "cost_distorsion": 22.630836486816406,
+ "cost_thickness": 3728.2998046875,
+ "cost_beam_compression": 2.128958225250244,
+ "cost_non_linearity": 955.0667114257812,
+ "cost_distance_total_intern_reflection": 13535.21875
+ },
+ "weighted components": {
+ "cost_dispersion": 51.61103439331055,
+ "cost_distance_glasses": 676.3222433429431,
+ "cost_deviation": 0.03133813291788101,
+ "cost_distorsion": 22.630836486816406,
+ "cost_thickness": 3728.2998046875,
+ "cost_beam_compression": 2.128958225250244,
+ "cost_non_linearity": 955.0667114257812,
+ "cost_distance_total_intern_reflection": 13535.21875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.61103439331055,
+ "cost_distance_glasses": 676.3222433429431,
+ "cost_deviation": 0.03133813291788101,
+ "cost_distorsion": 22.630836486816406,
+ "cost_thickness": 3728.2998046875,
+ "cost_beam_compression": 2.128958225250244,
+ "cost_non_linearity": 955.0667114257812,
+ "cost_distance_total_intern_reflection": 13535.21875
+ },
+ "weighted components": {
+ "cost_dispersion": 51.61103439331055,
+ "cost_distance_glasses": 676.3222433429431,
+ "cost_deviation": 0.03133813291788101,
+ "cost_distorsion": 22.630836486816406,
+ "cost_thickness": 3728.2998046875,
+ "cost_beam_compression": 2.128958225250244,
+ "cost_non_linearity": 955.0667114257812,
+ "cost_distance_total_intern_reflection": 13535.21875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1940.json b/outputs/amici/optimization_results/step1/score_details_iteration_1940.json
new file mode 100755
index 0000000..676717f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1940.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.710994720458984,
+ "cost_distance_glasses": 677.1327581918738,
+ "cost_deviation": 3.524620532989502,
+ "cost_distorsion": 22.25820541381836,
+ "cost_thickness": 3728.10205078125,
+ "cost_beam_compression": 2.1303915977478027,
+ "cost_non_linearity": 957.3604125976562,
+ "cost_distance_total_intern_reflection": 13546.083984375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.710994720458984,
+ "cost_distance_glasses": 677.1327581918738,
+ "cost_deviation": 3.524620532989502,
+ "cost_distorsion": 22.25820541381836,
+ "cost_thickness": 3728.10205078125,
+ "cost_beam_compression": 2.1303915977478027,
+ "cost_non_linearity": 957.3604125976562,
+ "cost_distance_total_intern_reflection": 13546.083984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 36.710994720458984,
+ "cost_distance_glasses": 677.1327581918738,
+ "cost_deviation": 3.524620532989502,
+ "cost_distorsion": 22.25820541381836,
+ "cost_thickness": 3728.10205078125,
+ "cost_beam_compression": 2.1303915977478027,
+ "cost_non_linearity": 957.3604125976562,
+ "cost_distance_total_intern_reflection": 13546.083984375
+ },
+ "weighted components": {
+ "cost_dispersion": 36.710994720458984,
+ "cost_distance_glasses": 677.1327581918738,
+ "cost_deviation": 3.524620532989502,
+ "cost_distorsion": 22.25820541381836,
+ "cost_thickness": 3728.10205078125,
+ "cost_beam_compression": 2.1303915977478027,
+ "cost_non_linearity": 957.3604125976562,
+ "cost_distance_total_intern_reflection": 13546.083984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1950.json b/outputs/amici/optimization_results/step1/score_details_iteration_1950.json
new file mode 100755
index 0000000..73d6306
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1950.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.839637756347656,
+ "cost_distance_glasses": 675.6943912835228,
+ "cost_deviation": 8.107196807861328,
+ "cost_distorsion": 21.94893455505371,
+ "cost_thickness": 3727.978759765625,
+ "cost_beam_compression": 2.1310555934906006,
+ "cost_non_linearity": 958.3282470703125,
+ "cost_distance_total_intern_reflection": 13546.3623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.839637756347656,
+ "cost_distance_glasses": 675.6943912835228,
+ "cost_deviation": 8.107196807861328,
+ "cost_distorsion": 21.94893455505371,
+ "cost_thickness": 3727.978759765625,
+ "cost_beam_compression": 2.1310555934906006,
+ "cost_non_linearity": 958.3282470703125,
+ "cost_distance_total_intern_reflection": 13546.3623046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.839637756347656,
+ "cost_distance_glasses": 675.6943912835228,
+ "cost_deviation": 8.107196807861328,
+ "cost_distorsion": 21.94893455505371,
+ "cost_thickness": 3727.978759765625,
+ "cost_beam_compression": 2.1310555934906006,
+ "cost_non_linearity": 958.3282470703125,
+ "cost_distance_total_intern_reflection": 13546.3623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.839637756347656,
+ "cost_distance_glasses": 675.6943912835228,
+ "cost_deviation": 8.107196807861328,
+ "cost_distorsion": 21.94893455505371,
+ "cost_thickness": 3727.978759765625,
+ "cost_beam_compression": 2.1310555934906006,
+ "cost_non_linearity": 958.3282470703125,
+ "cost_distance_total_intern_reflection": 13546.3623046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1960.json b/outputs/amici/optimization_results/step1/score_details_iteration_1960.json
new file mode 100755
index 0000000..b59e2ae
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1960.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 53.984466552734375,
+ "cost_distance_glasses": 672.6153911338423,
+ "cost_deviation": 0.3703494369983673,
+ "cost_distorsion": 23.772293090820312,
+ "cost_thickness": 3728.671630859375,
+ "cost_beam_compression": 2.1289010047912598,
+ "cost_non_linearity": 954.882080078125,
+ "cost_distance_total_intern_reflection": 13556.443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 53.984466552734375,
+ "cost_distance_glasses": 672.6153911338423,
+ "cost_deviation": 0.3703494369983673,
+ "cost_distorsion": 23.772293090820312,
+ "cost_thickness": 3728.671630859375,
+ "cost_beam_compression": 2.1289010047912598,
+ "cost_non_linearity": 954.882080078125,
+ "cost_distance_total_intern_reflection": 13556.443359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 53.984466552734375,
+ "cost_distance_glasses": 672.6153911338423,
+ "cost_deviation": 0.3703494369983673,
+ "cost_distorsion": 23.772293090820312,
+ "cost_thickness": 3728.671630859375,
+ "cost_beam_compression": 2.1289010047912598,
+ "cost_non_linearity": 954.882080078125,
+ "cost_distance_total_intern_reflection": 13556.443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 53.984466552734375,
+ "cost_distance_glasses": 672.6153911338423,
+ "cost_deviation": 0.3703494369983673,
+ "cost_distorsion": 23.772293090820312,
+ "cost_thickness": 3728.671630859375,
+ "cost_beam_compression": 2.1289010047912598,
+ "cost_non_linearity": 954.882080078125,
+ "cost_distance_total_intern_reflection": 13556.443359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1970.json b/outputs/amici/optimization_results/step1/score_details_iteration_1970.json
new file mode 100755
index 0000000..cf64a2d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1970.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.383493423461914,
+ "cost_distance_glasses": 675.0361659613349,
+ "cost_deviation": 10.388509750366211,
+ "cost_distorsion": 20.848526000976562,
+ "cost_thickness": 3727.588134765625,
+ "cost_beam_compression": 2.13112473487854,
+ "cost_non_linearity": 958.326416015625,
+ "cost_distance_total_intern_reflection": 13560.365234375
+ },
+ "weighted components": {
+ "cost_dispersion": 29.383493423461914,
+ "cost_distance_glasses": 675.0361659613349,
+ "cost_deviation": 10.388509750366211,
+ "cost_distorsion": 20.848526000976562,
+ "cost_thickness": 3727.588134765625,
+ "cost_beam_compression": 2.13112473487854,
+ "cost_non_linearity": 958.326416015625,
+ "cost_distance_total_intern_reflection": 13560.365234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.383493423461914,
+ "cost_distance_glasses": 675.0361659613349,
+ "cost_deviation": 10.388509750366211,
+ "cost_distorsion": 20.848526000976562,
+ "cost_thickness": 3727.588134765625,
+ "cost_beam_compression": 2.13112473487854,
+ "cost_non_linearity": 958.326416015625,
+ "cost_distance_total_intern_reflection": 13560.365234375
+ },
+ "weighted components": {
+ "cost_dispersion": 29.383493423461914,
+ "cost_distance_glasses": 675.0361659613349,
+ "cost_deviation": 10.388509750366211,
+ "cost_distorsion": 20.848526000976562,
+ "cost_thickness": 3727.588134765625,
+ "cost_beam_compression": 2.13112473487854,
+ "cost_non_linearity": 958.326416015625,
+ "cost_distance_total_intern_reflection": 13560.365234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1980.json b/outputs/amici/optimization_results/step1/score_details_iteration_1980.json
new file mode 100755
index 0000000..ad9fecd
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1980.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.91441345214844,
+ "cost_distance_glasses": 672.5471713398542,
+ "cost_deviation": 5.8496623039245605,
+ "cost_distorsion": 21.51095962524414,
+ "cost_thickness": 3727.867919921875,
+ "cost_beam_compression": 2.1306891441345215,
+ "cost_non_linearity": 957.6744384765625,
+ "cost_distance_total_intern_reflection": 13548.0380859375
+ },
+ "weighted components": {
+ "cost_dispersion": 33.91441345214844,
+ "cost_distance_glasses": 672.5471713398542,
+ "cost_deviation": 5.8496623039245605,
+ "cost_distorsion": 21.51095962524414,
+ "cost_thickness": 3727.867919921875,
+ "cost_beam_compression": 2.1306891441345215,
+ "cost_non_linearity": 957.6744384765625,
+ "cost_distance_total_intern_reflection": 13548.0380859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.91441345214844,
+ "cost_distance_glasses": 672.5471713398542,
+ "cost_deviation": 5.8496623039245605,
+ "cost_distorsion": 21.51095962524414,
+ "cost_thickness": 3727.867919921875,
+ "cost_beam_compression": 2.1306891441345215,
+ "cost_non_linearity": 957.6744384765625,
+ "cost_distance_total_intern_reflection": 13548.0380859375
+ },
+ "weighted components": {
+ "cost_dispersion": 33.91441345214844,
+ "cost_distance_glasses": 672.5471713398542,
+ "cost_deviation": 5.8496623039245605,
+ "cost_distorsion": 21.51095962524414,
+ "cost_thickness": 3727.867919921875,
+ "cost_beam_compression": 2.1306891441345215,
+ "cost_non_linearity": 957.6744384765625,
+ "cost_distance_total_intern_reflection": 13548.0380859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_1990.json b/outputs/amici/optimization_results/step1/score_details_iteration_1990.json
new file mode 100755
index 0000000..ea8996a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_1990.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.710018157958984,
+ "cost_distance_glasses": 670.0210132002484,
+ "cost_deviation": 0.13273881375789642,
+ "cost_distorsion": 23.47916603088379,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.1295948028564453,
+ "cost_non_linearity": 955.8282470703125,
+ "cost_distance_total_intern_reflection": 13557.626953125
+ },
+ "weighted components": {
+ "cost_dispersion": 46.710018157958984,
+ "cost_distance_glasses": 670.0210132002484,
+ "cost_deviation": 0.13273881375789642,
+ "cost_distorsion": 23.47916603088379,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.1295948028564453,
+ "cost_non_linearity": 955.8282470703125,
+ "cost_distance_total_intern_reflection": 13557.626953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 46.710018157958984,
+ "cost_distance_glasses": 670.0210132002484,
+ "cost_deviation": 0.13273881375789642,
+ "cost_distorsion": 23.47916603088379,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.1295948028564453,
+ "cost_non_linearity": 955.8282470703125,
+ "cost_distance_total_intern_reflection": 13557.626953125
+ },
+ "weighted components": {
+ "cost_dispersion": 46.710018157958984,
+ "cost_distance_glasses": 670.0210132002484,
+ "cost_deviation": 0.13273881375789642,
+ "cost_distorsion": 23.47916603088379,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.1295948028564453,
+ "cost_non_linearity": 955.8282470703125,
+ "cost_distance_total_intern_reflection": 13557.626953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_20.json b/outputs/amici/optimization_results/step1/score_details_iteration_20.json
new file mode 100755
index 0000000..b6a453a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_20.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8061.6591796875,
+ "cost_distance_glasses": 15982.186804873552,
+ "cost_deviation": 3124.900634765625,
+ "cost_distorsion": 590.53564453125,
+ "cost_thickness": 3674.0927734375,
+ "cost_beam_compression": 2.263540029525757,
+ "cost_non_linearity": 804.945068359375,
+ "cost_distance_total_intern_reflection": 16103.7880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 8061.6591796875,
+ "cost_distance_glasses": 15982.186804873552,
+ "cost_deviation": 3124.900634765625,
+ "cost_distorsion": 590.53564453125,
+ "cost_thickness": 3674.0927734375,
+ "cost_beam_compression": 2.263540029525757,
+ "cost_non_linearity": 804.945068359375,
+ "cost_distance_total_intern_reflection": 16103.7880859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8061.6591796875,
+ "cost_distance_glasses": 15982.186804873552,
+ "cost_deviation": 3124.900634765625,
+ "cost_distorsion": 590.53564453125,
+ "cost_thickness": 3674.0927734375,
+ "cost_beam_compression": 2.263540029525757,
+ "cost_non_linearity": 804.945068359375,
+ "cost_distance_total_intern_reflection": 16103.7880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 8061.6591796875,
+ "cost_distance_glasses": 15982.186804873552,
+ "cost_deviation": 3124.900634765625,
+ "cost_distorsion": 590.53564453125,
+ "cost_thickness": 3674.0927734375,
+ "cost_beam_compression": 2.263540029525757,
+ "cost_non_linearity": 804.945068359375,
+ "cost_distance_total_intern_reflection": 16103.7880859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_200.json b/outputs/amici/optimization_results/step1/score_details_iteration_200.json
new file mode 100755
index 0000000..5c22f36
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_200.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 166.6910400390625,
+ "cost_distance_glasses": 1640.520516009343,
+ "cost_deviation": 26.963176727294922,
+ "cost_distorsion": 20.82840347290039,
+ "cost_thickness": 4083.780029296875,
+ "cost_beam_compression": 2.3417181968688965,
+ "cost_non_linearity": 944.03076171875,
+ "cost_distance_total_intern_reflection": 14069.716796875
+ },
+ "weighted components": {
+ "cost_dispersion": 166.6910400390625,
+ "cost_distance_glasses": 1640.520516009343,
+ "cost_deviation": 26.963176727294922,
+ "cost_distorsion": 20.82840347290039,
+ "cost_thickness": 4083.780029296875,
+ "cost_beam_compression": 2.3417181968688965,
+ "cost_non_linearity": 944.03076171875,
+ "cost_distance_total_intern_reflection": 14069.716796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 166.6910400390625,
+ "cost_distance_glasses": 1640.520516009343,
+ "cost_deviation": 26.963176727294922,
+ "cost_distorsion": 20.82840347290039,
+ "cost_thickness": 4083.780029296875,
+ "cost_beam_compression": 2.3417181968688965,
+ "cost_non_linearity": 944.03076171875,
+ "cost_distance_total_intern_reflection": 14069.716796875
+ },
+ "weighted components": {
+ "cost_dispersion": 166.6910400390625,
+ "cost_distance_glasses": 1640.520516009343,
+ "cost_deviation": 26.963176727294922,
+ "cost_distorsion": 20.82840347290039,
+ "cost_thickness": 4083.780029296875,
+ "cost_beam_compression": 2.3417181968688965,
+ "cost_non_linearity": 944.03076171875,
+ "cost_distance_total_intern_reflection": 14069.716796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_210.json b/outputs/amici/optimization_results/step1/score_details_iteration_210.json
new file mode 100755
index 0000000..a30ff25
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_210.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 159.60800170898438,
+ "cost_distance_glasses": 1640.2887082707068,
+ "cost_deviation": 26.77008056640625,
+ "cost_distorsion": 20.80004119873047,
+ "cost_thickness": 4087.888671875,
+ "cost_beam_compression": 2.3443329334259033,
+ "cost_non_linearity": 944.4220581054688,
+ "cost_distance_total_intern_reflection": 14079.744140625
+ },
+ "weighted components": {
+ "cost_dispersion": 159.60800170898438,
+ "cost_distance_glasses": 1640.2887082707068,
+ "cost_deviation": 26.77008056640625,
+ "cost_distorsion": 20.80004119873047,
+ "cost_thickness": 4087.888671875,
+ "cost_beam_compression": 2.3443329334259033,
+ "cost_non_linearity": 944.4220581054688,
+ "cost_distance_total_intern_reflection": 14079.744140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 159.60800170898438,
+ "cost_distance_glasses": 1640.2887082707068,
+ "cost_deviation": 26.77008056640625,
+ "cost_distorsion": 20.80004119873047,
+ "cost_thickness": 4087.888671875,
+ "cost_beam_compression": 2.3443329334259033,
+ "cost_non_linearity": 944.4220581054688,
+ "cost_distance_total_intern_reflection": 14079.744140625
+ },
+ "weighted components": {
+ "cost_dispersion": 159.60800170898438,
+ "cost_distance_glasses": 1640.2887082707068,
+ "cost_deviation": 26.77008056640625,
+ "cost_distorsion": 20.80004119873047,
+ "cost_thickness": 4087.888671875,
+ "cost_beam_compression": 2.3443329334259033,
+ "cost_non_linearity": 944.4220581054688,
+ "cost_distance_total_intern_reflection": 14079.744140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_220.json b/outputs/amici/optimization_results/step1/score_details_iteration_220.json
new file mode 100755
index 0000000..8087031
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_220.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.9405059814453,
+ "cost_distance_glasses": 1633.4759565952827,
+ "cost_deviation": 25.852895736694336,
+ "cost_distorsion": 20.89116859436035,
+ "cost_thickness": 4091.2109375,
+ "cost_beam_compression": 2.3464155197143555,
+ "cost_non_linearity": 944.7781372070312,
+ "cost_distance_total_intern_reflection": 14080.58203125
+ },
+ "weighted components": {
+ "cost_dispersion": 154.9405059814453,
+ "cost_distance_glasses": 1633.4759565952827,
+ "cost_deviation": 25.852895736694336,
+ "cost_distorsion": 20.89116859436035,
+ "cost_thickness": 4091.2109375,
+ "cost_beam_compression": 2.3464155197143555,
+ "cost_non_linearity": 944.7781372070312,
+ "cost_distance_total_intern_reflection": 14080.58203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.9405059814453,
+ "cost_distance_glasses": 1633.4759565952827,
+ "cost_deviation": 25.852895736694336,
+ "cost_distorsion": 20.89116859436035,
+ "cost_thickness": 4091.2109375,
+ "cost_beam_compression": 2.3464155197143555,
+ "cost_non_linearity": 944.7781372070312,
+ "cost_distance_total_intern_reflection": 14080.58203125
+ },
+ "weighted components": {
+ "cost_dispersion": 154.9405059814453,
+ "cost_distance_glasses": 1633.4759565952827,
+ "cost_deviation": 25.852895736694336,
+ "cost_distorsion": 20.89116859436035,
+ "cost_thickness": 4091.2109375,
+ "cost_beam_compression": 2.3464155197143555,
+ "cost_non_linearity": 944.7781372070312,
+ "cost_distance_total_intern_reflection": 14080.58203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_230.json b/outputs/amici/optimization_results/step1/score_details_iteration_230.json
new file mode 100755
index 0000000..606c53f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_230.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.6477508544922,
+ "cost_distance_glasses": 1617.6255374986586,
+ "cost_deviation": 25.6004581451416,
+ "cost_distorsion": 20.83754539489746,
+ "cost_thickness": 4093.771484375,
+ "cost_beam_compression": 2.3481321334838867,
+ "cost_non_linearity": 944.99267578125,
+ "cost_distance_total_intern_reflection": 14086.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 150.6477508544922,
+ "cost_distance_glasses": 1617.6255374986586,
+ "cost_deviation": 25.6004581451416,
+ "cost_distorsion": 20.83754539489746,
+ "cost_thickness": 4093.771484375,
+ "cost_beam_compression": 2.3481321334838867,
+ "cost_non_linearity": 944.99267578125,
+ "cost_distance_total_intern_reflection": 14086.203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.6477508544922,
+ "cost_distance_glasses": 1617.6255374986586,
+ "cost_deviation": 25.6004581451416,
+ "cost_distorsion": 20.83754539489746,
+ "cost_thickness": 4093.771484375,
+ "cost_beam_compression": 2.3481321334838867,
+ "cost_non_linearity": 944.99267578125,
+ "cost_distance_total_intern_reflection": 14086.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 150.6477508544922,
+ "cost_distance_glasses": 1617.6255374986586,
+ "cost_deviation": 25.6004581451416,
+ "cost_distorsion": 20.83754539489746,
+ "cost_thickness": 4093.771484375,
+ "cost_beam_compression": 2.3481321334838867,
+ "cost_non_linearity": 944.99267578125,
+ "cost_distance_total_intern_reflection": 14086.203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_240.json b/outputs/amici/optimization_results/step1/score_details_iteration_240.json
new file mode 100755
index 0000000..1b4af30
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_240.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 149.4351043701172,
+ "cost_distance_glasses": 1577.62304032406,
+ "cost_deviation": 23.669002532958984,
+ "cost_distorsion": 20.820514678955078,
+ "cost_thickness": 4095.735595703125,
+ "cost_beam_compression": 2.3494248390197754,
+ "cost_non_linearity": 945.35009765625,
+ "cost_distance_total_intern_reflection": 14087.51953125
+ },
+ "weighted components": {
+ "cost_dispersion": 149.4351043701172,
+ "cost_distance_glasses": 1577.62304032406,
+ "cost_deviation": 23.669002532958984,
+ "cost_distorsion": 20.820514678955078,
+ "cost_thickness": 4095.735595703125,
+ "cost_beam_compression": 2.3494248390197754,
+ "cost_non_linearity": 945.35009765625,
+ "cost_distance_total_intern_reflection": 14087.51953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 149.4351043701172,
+ "cost_distance_glasses": 1577.62304032406,
+ "cost_deviation": 23.669002532958984,
+ "cost_distorsion": 20.820514678955078,
+ "cost_thickness": 4095.735595703125,
+ "cost_beam_compression": 2.3494248390197754,
+ "cost_non_linearity": 945.35009765625,
+ "cost_distance_total_intern_reflection": 14087.51953125
+ },
+ "weighted components": {
+ "cost_dispersion": 149.4351043701172,
+ "cost_distance_glasses": 1577.62304032406,
+ "cost_deviation": 23.669002532958984,
+ "cost_distorsion": 20.820514678955078,
+ "cost_thickness": 4095.735595703125,
+ "cost_beam_compression": 2.3494248390197754,
+ "cost_non_linearity": 945.35009765625,
+ "cost_distance_total_intern_reflection": 14087.51953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_250.json b/outputs/amici/optimization_results/step1/score_details_iteration_250.json
new file mode 100755
index 0000000..f74d3b5
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_250.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 151.00906372070312,
+ "cost_distance_glasses": 1518.3709436732315,
+ "cost_deviation": 20.93975257873535,
+ "cost_distorsion": 21.206802368164062,
+ "cost_thickness": 4097.17333984375,
+ "cost_beam_compression": 2.3502612113952637,
+ "cost_non_linearity": 945.424072265625,
+ "cost_distance_total_intern_reflection": 14088.0625
+ },
+ "weighted components": {
+ "cost_dispersion": 151.00906372070312,
+ "cost_distance_glasses": 1518.3709436732315,
+ "cost_deviation": 20.93975257873535,
+ "cost_distorsion": 21.206802368164062,
+ "cost_thickness": 4097.17333984375,
+ "cost_beam_compression": 2.3502612113952637,
+ "cost_non_linearity": 945.424072265625,
+ "cost_distance_total_intern_reflection": 14088.0625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 151.00906372070312,
+ "cost_distance_glasses": 1518.3709436732315,
+ "cost_deviation": 20.93975257873535,
+ "cost_distorsion": 21.206802368164062,
+ "cost_thickness": 4097.17333984375,
+ "cost_beam_compression": 2.3502612113952637,
+ "cost_non_linearity": 945.424072265625,
+ "cost_distance_total_intern_reflection": 14088.0625
+ },
+ "weighted components": {
+ "cost_dispersion": 151.00906372070312,
+ "cost_distance_glasses": 1518.3709436732315,
+ "cost_deviation": 20.93975257873535,
+ "cost_distorsion": 21.206802368164062,
+ "cost_thickness": 4097.17333984375,
+ "cost_beam_compression": 2.3502612113952637,
+ "cost_non_linearity": 945.424072265625,
+ "cost_distance_total_intern_reflection": 14088.0625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_260.json b/outputs/amici/optimization_results/step1/score_details_iteration_260.json
new file mode 100755
index 0000000..b69fd01
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_260.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.97605895996094,
+ "cost_distance_glasses": 1500.0309357418478,
+ "cost_deviation": 20.287586212158203,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4098.1181640625,
+ "cost_beam_compression": 2.3508501052856445,
+ "cost_non_linearity": 945.1419067382812,
+ "cost_distance_total_intern_reflection": 14089.3603515625
+ },
+ "weighted components": {
+ "cost_dispersion": 150.97605895996094,
+ "cost_distance_glasses": 1500.0309357418478,
+ "cost_deviation": 20.287586212158203,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4098.1181640625,
+ "cost_beam_compression": 2.3508501052856445,
+ "cost_non_linearity": 945.1419067382812,
+ "cost_distance_total_intern_reflection": 14089.3603515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.97605895996094,
+ "cost_distance_glasses": 1500.0309357418478,
+ "cost_deviation": 20.287586212158203,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4098.1181640625,
+ "cost_beam_compression": 2.3508501052856445,
+ "cost_non_linearity": 945.1419067382812,
+ "cost_distance_total_intern_reflection": 14089.3603515625
+ },
+ "weighted components": {
+ "cost_dispersion": 150.97605895996094,
+ "cost_distance_glasses": 1500.0309357418478,
+ "cost_deviation": 20.287586212158203,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4098.1181640625,
+ "cost_beam_compression": 2.3508501052856445,
+ "cost_non_linearity": 945.1419067382812,
+ "cost_distance_total_intern_reflection": 14089.3603515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_270.json b/outputs/amici/optimization_results/step1/score_details_iteration_270.json
new file mode 100755
index 0000000..519a905
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_270.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.18215942382812,
+ "cost_distance_glasses": 1496.6390788373167,
+ "cost_deviation": 19.699926376342773,
+ "cost_distorsion": 21.168651580810547,
+ "cost_thickness": 4098.70556640625,
+ "cost_beam_compression": 2.351306676864624,
+ "cost_non_linearity": 945.1861572265625,
+ "cost_distance_total_intern_reflection": 14090.9462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 150.18215942382812,
+ "cost_distance_glasses": 1496.6390788373167,
+ "cost_deviation": 19.699926376342773,
+ "cost_distorsion": 21.168651580810547,
+ "cost_thickness": 4098.70556640625,
+ "cost_beam_compression": 2.351306676864624,
+ "cost_non_linearity": 945.1861572265625,
+ "cost_distance_total_intern_reflection": 14090.9462890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 150.18215942382812,
+ "cost_distance_glasses": 1496.6390788373167,
+ "cost_deviation": 19.699926376342773,
+ "cost_distorsion": 21.168651580810547,
+ "cost_thickness": 4098.70556640625,
+ "cost_beam_compression": 2.351306676864624,
+ "cost_non_linearity": 945.1861572265625,
+ "cost_distance_total_intern_reflection": 14090.9462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 150.18215942382812,
+ "cost_distance_glasses": 1496.6390788373167,
+ "cost_deviation": 19.699926376342773,
+ "cost_distorsion": 21.168651580810547,
+ "cost_thickness": 4098.70556640625,
+ "cost_beam_compression": 2.351306676864624,
+ "cost_non_linearity": 945.1861572265625,
+ "cost_distance_total_intern_reflection": 14090.9462890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_280.json b/outputs/amici/optimization_results/step1/score_details_iteration_280.json
new file mode 100755
index 0000000..af6015c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_280.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 152.01878356933594,
+ "cost_distance_glasses": 1485.9991533680584,
+ "cost_deviation": 18.49408531188965,
+ "cost_distorsion": 21.165491104125977,
+ "cost_thickness": 4099.01953125,
+ "cost_beam_compression": 2.3514819145202637,
+ "cost_non_linearity": 945.0440673828125,
+ "cost_distance_total_intern_reflection": 14090.548828125
+ },
+ "weighted components": {
+ "cost_dispersion": 152.01878356933594,
+ "cost_distance_glasses": 1485.9991533680584,
+ "cost_deviation": 18.49408531188965,
+ "cost_distorsion": 21.165491104125977,
+ "cost_thickness": 4099.01953125,
+ "cost_beam_compression": 2.3514819145202637,
+ "cost_non_linearity": 945.0440673828125,
+ "cost_distance_total_intern_reflection": 14090.548828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 152.01878356933594,
+ "cost_distance_glasses": 1485.9991533680584,
+ "cost_deviation": 18.49408531188965,
+ "cost_distorsion": 21.165491104125977,
+ "cost_thickness": 4099.01953125,
+ "cost_beam_compression": 2.3514819145202637,
+ "cost_non_linearity": 945.0440673828125,
+ "cost_distance_total_intern_reflection": 14090.548828125
+ },
+ "weighted components": {
+ "cost_dispersion": 152.01878356933594,
+ "cost_distance_glasses": 1485.9991533680584,
+ "cost_deviation": 18.49408531188965,
+ "cost_distorsion": 21.165491104125977,
+ "cost_thickness": 4099.01953125,
+ "cost_beam_compression": 2.3514819145202637,
+ "cost_non_linearity": 945.0440673828125,
+ "cost_distance_total_intern_reflection": 14090.548828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_290.json b/outputs/amici/optimization_results/step1/score_details_iteration_290.json
new file mode 100755
index 0000000..3e1e3e3
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_290.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 152.6229248046875,
+ "cost_distance_glasses": 1498.4410482980325,
+ "cost_deviation": 17.711769104003906,
+ "cost_distorsion": 21.190902709960938,
+ "cost_thickness": 4099.138671875,
+ "cost_beam_compression": 2.351548194885254,
+ "cost_non_linearity": 944.9462280273438,
+ "cost_distance_total_intern_reflection": 14090.318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 152.6229248046875,
+ "cost_distance_glasses": 1498.4410482980325,
+ "cost_deviation": 17.711769104003906,
+ "cost_distorsion": 21.190902709960938,
+ "cost_thickness": 4099.138671875,
+ "cost_beam_compression": 2.351548194885254,
+ "cost_non_linearity": 944.9462280273438,
+ "cost_distance_total_intern_reflection": 14090.318359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 152.6229248046875,
+ "cost_distance_glasses": 1498.4410482980325,
+ "cost_deviation": 17.711769104003906,
+ "cost_distorsion": 21.190902709960938,
+ "cost_thickness": 4099.138671875,
+ "cost_beam_compression": 2.351548194885254,
+ "cost_non_linearity": 944.9462280273438,
+ "cost_distance_total_intern_reflection": 14090.318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 152.6229248046875,
+ "cost_distance_glasses": 1498.4410482980325,
+ "cost_deviation": 17.711769104003906,
+ "cost_distorsion": 21.190902709960938,
+ "cost_thickness": 4099.138671875,
+ "cost_beam_compression": 2.351548194885254,
+ "cost_non_linearity": 944.9462280273438,
+ "cost_distance_total_intern_reflection": 14090.318359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_30.json b/outputs/amici/optimization_results/step1/score_details_iteration_30.json
new file mode 100755
index 0000000..6fa18f9
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_30.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.529973030090332,
+ "cost_distance_glasses": 2227.9414520997498,
+ "cost_deviation": 16925.10546875,
+ "cost_distorsion": 25.93008041381836,
+ "cost_thickness": 3666.287109375,
+ "cost_beam_compression": 2.2205376625061035,
+ "cost_non_linearity": 974.9569091796875,
+ "cost_distance_total_intern_reflection": 14666.0224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 7.529973030090332,
+ "cost_distance_glasses": 2227.9414520997498,
+ "cost_deviation": 16925.10546875,
+ "cost_distorsion": 25.93008041381836,
+ "cost_thickness": 3666.287109375,
+ "cost_beam_compression": 2.2205376625061035,
+ "cost_non_linearity": 974.9569091796875,
+ "cost_distance_total_intern_reflection": 14666.0224609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.529973030090332,
+ "cost_distance_glasses": 2227.9414520997498,
+ "cost_deviation": 16925.10546875,
+ "cost_distorsion": 25.93008041381836,
+ "cost_thickness": 3666.287109375,
+ "cost_beam_compression": 2.2205376625061035,
+ "cost_non_linearity": 974.9569091796875,
+ "cost_distance_total_intern_reflection": 14666.0224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 7.529973030090332,
+ "cost_distance_glasses": 2227.9414520997498,
+ "cost_deviation": 16925.10546875,
+ "cost_distorsion": 25.93008041381836,
+ "cost_thickness": 3666.287109375,
+ "cost_beam_compression": 2.2205376625061035,
+ "cost_non_linearity": 974.9569091796875,
+ "cost_distance_total_intern_reflection": 14666.0224609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_300.json b/outputs/amici/optimization_results/step1/score_details_iteration_300.json
new file mode 100755
index 0000000..fb17a2e
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_300.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 153.35520935058594,
+ "cost_distance_glasses": 1536.5523699376101,
+ "cost_deviation": 17.3759822845459,
+ "cost_distorsion": 21.226533889770508,
+ "cost_thickness": 4099.16064453125,
+ "cost_beam_compression": 2.351550579071045,
+ "cost_non_linearity": 944.7726440429688,
+ "cost_distance_total_intern_reflection": 14090.208984375
+ },
+ "weighted components": {
+ "cost_dispersion": 153.35520935058594,
+ "cost_distance_glasses": 1536.5523699376101,
+ "cost_deviation": 17.3759822845459,
+ "cost_distorsion": 21.226533889770508,
+ "cost_thickness": 4099.16064453125,
+ "cost_beam_compression": 2.351550579071045,
+ "cost_non_linearity": 944.7726440429688,
+ "cost_distance_total_intern_reflection": 14090.208984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 153.35520935058594,
+ "cost_distance_glasses": 1536.5523699376101,
+ "cost_deviation": 17.3759822845459,
+ "cost_distorsion": 21.226533889770508,
+ "cost_thickness": 4099.16064453125,
+ "cost_beam_compression": 2.351550579071045,
+ "cost_non_linearity": 944.7726440429688,
+ "cost_distance_total_intern_reflection": 14090.208984375
+ },
+ "weighted components": {
+ "cost_dispersion": 153.35520935058594,
+ "cost_distance_glasses": 1536.5523699376101,
+ "cost_deviation": 17.3759822845459,
+ "cost_distorsion": 21.226533889770508,
+ "cost_thickness": 4099.16064453125,
+ "cost_beam_compression": 2.351550579071045,
+ "cost_non_linearity": 944.7726440429688,
+ "cost_distance_total_intern_reflection": 14090.208984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_310.json b/outputs/amici/optimization_results/step1/score_details_iteration_310.json
new file mode 100755
index 0000000..ea05220
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_310.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.36819458007812,
+ "cost_distance_glasses": 1561.6511582728717,
+ "cost_deviation": 16.832447052001953,
+ "cost_distorsion": 21.27241325378418,
+ "cost_thickness": 4099.17333984375,
+ "cost_beam_compression": 2.351543426513672,
+ "cost_non_linearity": 944.7771606445312,
+ "cost_distance_total_intern_reflection": 14090.15234375
+ },
+ "weighted components": {
+ "cost_dispersion": 154.36819458007812,
+ "cost_distance_glasses": 1561.6511582728717,
+ "cost_deviation": 16.832447052001953,
+ "cost_distorsion": 21.27241325378418,
+ "cost_thickness": 4099.17333984375,
+ "cost_beam_compression": 2.351543426513672,
+ "cost_non_linearity": 944.7771606445312,
+ "cost_distance_total_intern_reflection": 14090.15234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.36819458007812,
+ "cost_distance_glasses": 1561.6511582728717,
+ "cost_deviation": 16.832447052001953,
+ "cost_distorsion": 21.27241325378418,
+ "cost_thickness": 4099.17333984375,
+ "cost_beam_compression": 2.351543426513672,
+ "cost_non_linearity": 944.7771606445312,
+ "cost_distance_total_intern_reflection": 14090.15234375
+ },
+ "weighted components": {
+ "cost_dispersion": 154.36819458007812,
+ "cost_distance_glasses": 1561.6511582728717,
+ "cost_deviation": 16.832447052001953,
+ "cost_distorsion": 21.27241325378418,
+ "cost_thickness": 4099.17333984375,
+ "cost_beam_compression": 2.351543426513672,
+ "cost_non_linearity": 944.7771606445312,
+ "cost_distance_total_intern_reflection": 14090.15234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_320.json b/outputs/amici/optimization_results/step1/score_details_iteration_320.json
new file mode 100755
index 0000000..c6ba69e
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_320.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 161.9094696044922,
+ "cost_distance_glasses": 1410.9235829432284,
+ "cost_deviation": 12.628278732299805,
+ "cost_distorsion": 21.38725471496582,
+ "cost_thickness": 4099.2734375,
+ "cost_beam_compression": 2.3514719009399414,
+ "cost_non_linearity": 944.1911010742188,
+ "cost_distance_total_intern_reflection": 14089.83203125
+ },
+ "weighted components": {
+ "cost_dispersion": 161.9094696044922,
+ "cost_distance_glasses": 1410.9235829432284,
+ "cost_deviation": 12.628278732299805,
+ "cost_distorsion": 21.38725471496582,
+ "cost_thickness": 4099.2734375,
+ "cost_beam_compression": 2.3514719009399414,
+ "cost_non_linearity": 944.1911010742188,
+ "cost_distance_total_intern_reflection": 14089.83203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 161.9094696044922,
+ "cost_distance_glasses": 1410.9235829432284,
+ "cost_deviation": 12.628278732299805,
+ "cost_distorsion": 21.38725471496582,
+ "cost_thickness": 4099.2734375,
+ "cost_beam_compression": 2.3514719009399414,
+ "cost_non_linearity": 944.1911010742188,
+ "cost_distance_total_intern_reflection": 14089.83203125
+ },
+ "weighted components": {
+ "cost_dispersion": 161.9094696044922,
+ "cost_distance_glasses": 1410.9235829432284,
+ "cost_deviation": 12.628278732299805,
+ "cost_distorsion": 21.38725471496582,
+ "cost_thickness": 4099.2734375,
+ "cost_beam_compression": 2.3514719009399414,
+ "cost_non_linearity": 944.1911010742188,
+ "cost_distance_total_intern_reflection": 14089.83203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_330.json b/outputs/amici/optimization_results/step1/score_details_iteration_330.json
new file mode 100755
index 0000000..07d556f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_330.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 162.7804718017578,
+ "cost_distance_glasses": 1326.276066001516,
+ "cost_deviation": 11.571134567260742,
+ "cost_distorsion": 21.40614128112793,
+ "cost_thickness": 4099.54833984375,
+ "cost_beam_compression": 2.351832389831543,
+ "cost_non_linearity": 944.2504272460938,
+ "cost_distance_total_intern_reflection": 14091.3330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 162.7804718017578,
+ "cost_distance_glasses": 1326.276066001516,
+ "cost_deviation": 11.571134567260742,
+ "cost_distorsion": 21.40614128112793,
+ "cost_thickness": 4099.54833984375,
+ "cost_beam_compression": 2.351832389831543,
+ "cost_non_linearity": 944.2504272460938,
+ "cost_distance_total_intern_reflection": 14091.3330078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 162.7804718017578,
+ "cost_distance_glasses": 1326.276066001516,
+ "cost_deviation": 11.571134567260742,
+ "cost_distorsion": 21.40614128112793,
+ "cost_thickness": 4099.54833984375,
+ "cost_beam_compression": 2.351832389831543,
+ "cost_non_linearity": 944.2504272460938,
+ "cost_distance_total_intern_reflection": 14091.3330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 162.7804718017578,
+ "cost_distance_glasses": 1326.276066001516,
+ "cost_deviation": 11.571134567260742,
+ "cost_distorsion": 21.40614128112793,
+ "cost_thickness": 4099.54833984375,
+ "cost_beam_compression": 2.351832389831543,
+ "cost_non_linearity": 944.2504272460938,
+ "cost_distance_total_intern_reflection": 14091.3330078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_340.json b/outputs/amici/optimization_results/step1/score_details_iteration_340.json
new file mode 100755
index 0000000..4af702d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_340.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.13015747070312,
+ "cost_distance_glasses": 1415.480827616771,
+ "cost_deviation": 16.44949722290039,
+ "cost_distorsion": 21.29534912109375,
+ "cost_thickness": 4100.1240234375,
+ "cost_beam_compression": 2.352522611618042,
+ "cost_non_linearity": 944.9943237304688,
+ "cost_distance_total_intern_reflection": 14093.2470703125
+ },
+ "weighted components": {
+ "cost_dispersion": 154.13015747070312,
+ "cost_distance_glasses": 1415.480827616771,
+ "cost_deviation": 16.44949722290039,
+ "cost_distorsion": 21.29534912109375,
+ "cost_thickness": 4100.1240234375,
+ "cost_beam_compression": 2.352522611618042,
+ "cost_non_linearity": 944.9943237304688,
+ "cost_distance_total_intern_reflection": 14093.2470703125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.13015747070312,
+ "cost_distance_glasses": 1415.480827616771,
+ "cost_deviation": 16.44949722290039,
+ "cost_distorsion": 21.29534912109375,
+ "cost_thickness": 4100.1240234375,
+ "cost_beam_compression": 2.352522611618042,
+ "cost_non_linearity": 944.9943237304688,
+ "cost_distance_total_intern_reflection": 14093.2470703125
+ },
+ "weighted components": {
+ "cost_dispersion": 154.13015747070312,
+ "cost_distance_glasses": 1415.480827616771,
+ "cost_deviation": 16.44949722290039,
+ "cost_distorsion": 21.29534912109375,
+ "cost_thickness": 4100.1240234375,
+ "cost_beam_compression": 2.352522611618042,
+ "cost_non_linearity": 944.9943237304688,
+ "cost_distance_total_intern_reflection": 14093.2470703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_350.json b/outputs/amici/optimization_results/step1/score_details_iteration_350.json
new file mode 100755
index 0000000..92a910d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_350.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 147.2762451171875,
+ "cost_distance_glasses": 1361.934847981683,
+ "cost_deviation": 19.685380935668945,
+ "cost_distorsion": 21.219539642333984,
+ "cost_thickness": 4101.0849609375,
+ "cost_beam_compression": 2.353696823120117,
+ "cost_non_linearity": 945.4645385742188,
+ "cost_distance_total_intern_reflection": 14096.376953125
+ },
+ "weighted components": {
+ "cost_dispersion": 147.2762451171875,
+ "cost_distance_glasses": 1361.934847981683,
+ "cost_deviation": 19.685380935668945,
+ "cost_distorsion": 21.219539642333984,
+ "cost_thickness": 4101.0849609375,
+ "cost_beam_compression": 2.353696823120117,
+ "cost_non_linearity": 945.4645385742188,
+ "cost_distance_total_intern_reflection": 14096.376953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 147.2762451171875,
+ "cost_distance_glasses": 1361.934847981683,
+ "cost_deviation": 19.685380935668945,
+ "cost_distorsion": 21.219539642333984,
+ "cost_thickness": 4101.0849609375,
+ "cost_beam_compression": 2.353696823120117,
+ "cost_non_linearity": 945.4645385742188,
+ "cost_distance_total_intern_reflection": 14096.376953125
+ },
+ "weighted components": {
+ "cost_dispersion": 147.2762451171875,
+ "cost_distance_glasses": 1361.934847981683,
+ "cost_deviation": 19.685380935668945,
+ "cost_distorsion": 21.219539642333984,
+ "cost_thickness": 4101.0849609375,
+ "cost_beam_compression": 2.353696823120117,
+ "cost_non_linearity": 945.4645385742188,
+ "cost_distance_total_intern_reflection": 14096.376953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_360.json b/outputs/amici/optimization_results/step1/score_details_iteration_360.json
new file mode 100755
index 0000000..7159f3a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_360.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 142.2985076904297,
+ "cost_distance_glasses": 1322.400472297816,
+ "cost_deviation": 21.696537017822266,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4102.65576171875,
+ "cost_beam_compression": 2.354952812194824,
+ "cost_non_linearity": 945.8408203125,
+ "cost_distance_total_intern_reflection": 14102.6318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 142.2985076904297,
+ "cost_distance_glasses": 1322.400472297816,
+ "cost_deviation": 21.696537017822266,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4102.65576171875,
+ "cost_beam_compression": 2.354952812194824,
+ "cost_non_linearity": 945.8408203125,
+ "cost_distance_total_intern_reflection": 14102.6318359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 142.2985076904297,
+ "cost_distance_glasses": 1322.400472297816,
+ "cost_deviation": 21.696537017822266,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4102.65576171875,
+ "cost_beam_compression": 2.354952812194824,
+ "cost_non_linearity": 945.8408203125,
+ "cost_distance_total_intern_reflection": 14102.6318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 142.2985076904297,
+ "cost_distance_glasses": 1322.400472297816,
+ "cost_deviation": 21.696537017822266,
+ "cost_distorsion": 21.161977767944336,
+ "cost_thickness": 4102.65576171875,
+ "cost_beam_compression": 2.354952812194824,
+ "cost_non_linearity": 945.8408203125,
+ "cost_distance_total_intern_reflection": 14102.6318359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_370.json b/outputs/amici/optimization_results/step1/score_details_iteration_370.json
new file mode 100755
index 0000000..3e21bb1
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_370.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 137.03172302246094,
+ "cost_distance_glasses": 1345.0207807765128,
+ "cost_deviation": 23.683507919311523,
+ "cost_distorsion": 20.955617904663086,
+ "cost_thickness": 4104.8603515625,
+ "cost_beam_compression": 2.35650897026062,
+ "cost_non_linearity": 946.3310546875,
+ "cost_distance_total_intern_reflection": 14103.5087890625
+ },
+ "weighted components": {
+ "cost_dispersion": 137.03172302246094,
+ "cost_distance_glasses": 1345.0207807765128,
+ "cost_deviation": 23.683507919311523,
+ "cost_distorsion": 20.955617904663086,
+ "cost_thickness": 4104.8603515625,
+ "cost_beam_compression": 2.35650897026062,
+ "cost_non_linearity": 946.3310546875,
+ "cost_distance_total_intern_reflection": 14103.5087890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 137.03172302246094,
+ "cost_distance_glasses": 1345.0207807765128,
+ "cost_deviation": 23.683507919311523,
+ "cost_distorsion": 20.955617904663086,
+ "cost_thickness": 4104.8603515625,
+ "cost_beam_compression": 2.35650897026062,
+ "cost_non_linearity": 946.3310546875,
+ "cost_distance_total_intern_reflection": 14103.5087890625
+ },
+ "weighted components": {
+ "cost_dispersion": 137.03172302246094,
+ "cost_distance_glasses": 1345.0207807765128,
+ "cost_deviation": 23.683507919311523,
+ "cost_distorsion": 20.955617904663086,
+ "cost_thickness": 4104.8603515625,
+ "cost_beam_compression": 2.35650897026062,
+ "cost_non_linearity": 946.3310546875,
+ "cost_distance_total_intern_reflection": 14103.5087890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_380.json b/outputs/amici/optimization_results/step1/score_details_iteration_380.json
new file mode 100755
index 0000000..fc93b17
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_380.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 136.19419860839844,
+ "cost_distance_glasses": 1345.7042800512938,
+ "cost_deviation": 21.896896362304688,
+ "cost_distorsion": 21.002439498901367,
+ "cost_thickness": 4107.8671875,
+ "cost_beam_compression": 2.3582510948181152,
+ "cost_non_linearity": 946.2177734375,
+ "cost_distance_total_intern_reflection": 14107.2421875
+ },
+ "weighted components": {
+ "cost_dispersion": 136.19419860839844,
+ "cost_distance_glasses": 1345.7042800512938,
+ "cost_deviation": 21.896896362304688,
+ "cost_distorsion": 21.002439498901367,
+ "cost_thickness": 4107.8671875,
+ "cost_beam_compression": 2.3582510948181152,
+ "cost_non_linearity": 946.2177734375,
+ "cost_distance_total_intern_reflection": 14107.2421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 136.19419860839844,
+ "cost_distance_glasses": 1345.7042800512938,
+ "cost_deviation": 21.896896362304688,
+ "cost_distorsion": 21.002439498901367,
+ "cost_thickness": 4107.8671875,
+ "cost_beam_compression": 2.3582510948181152,
+ "cost_non_linearity": 946.2177734375,
+ "cost_distance_total_intern_reflection": 14107.2421875
+ },
+ "weighted components": {
+ "cost_dispersion": 136.19419860839844,
+ "cost_distance_glasses": 1345.7042800512938,
+ "cost_deviation": 21.896896362304688,
+ "cost_distorsion": 21.002439498901367,
+ "cost_thickness": 4107.8671875,
+ "cost_beam_compression": 2.3582510948181152,
+ "cost_non_linearity": 946.2177734375,
+ "cost_distance_total_intern_reflection": 14107.2421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_390.json b/outputs/amici/optimization_results/step1/score_details_iteration_390.json
new file mode 100755
index 0000000..1db6681
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_390.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 136.47499084472656,
+ "cost_distance_glasses": 1279.7297664962134,
+ "cost_deviation": 18.421106338500977,
+ "cost_distorsion": 21.345094680786133,
+ "cost_thickness": 4111.66748046875,
+ "cost_beam_compression": 2.3604023456573486,
+ "cost_non_linearity": 946.2086791992188,
+ "cost_distance_total_intern_reflection": 14116.8583984375
+ },
+ "weighted components": {
+ "cost_dispersion": 136.47499084472656,
+ "cost_distance_glasses": 1279.7297664962134,
+ "cost_deviation": 18.421106338500977,
+ "cost_distorsion": 21.345094680786133,
+ "cost_thickness": 4111.66748046875,
+ "cost_beam_compression": 2.3604023456573486,
+ "cost_non_linearity": 946.2086791992188,
+ "cost_distance_total_intern_reflection": 14116.8583984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 136.47499084472656,
+ "cost_distance_glasses": 1279.7297664962134,
+ "cost_deviation": 18.421106338500977,
+ "cost_distorsion": 21.345094680786133,
+ "cost_thickness": 4111.66748046875,
+ "cost_beam_compression": 2.3604023456573486,
+ "cost_non_linearity": 946.2086791992188,
+ "cost_distance_total_intern_reflection": 14116.8583984375
+ },
+ "weighted components": {
+ "cost_dispersion": 136.47499084472656,
+ "cost_distance_glasses": 1279.7297664962134,
+ "cost_deviation": 18.421106338500977,
+ "cost_distorsion": 21.345094680786133,
+ "cost_thickness": 4111.66748046875,
+ "cost_beam_compression": 2.3604023456573486,
+ "cost_non_linearity": 946.2086791992188,
+ "cost_distance_total_intern_reflection": 14116.8583984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_40.json b/outputs/amici/optimization_results/step1/score_details_iteration_40.json
new file mode 100755
index 0000000..41d49f4
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_40.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3456.376220703125,
+ "cost_distance_glasses": 2012.046367390626,
+ "cost_deviation": 12.899784088134766,
+ "cost_distorsion": 67.45287322998047,
+ "cost_thickness": 3729.073486328125,
+ "cost_beam_compression": 2.1412010192871094,
+ "cost_non_linearity": 858.7999877929688,
+ "cost_distance_total_intern_reflection": 14305.3623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 3456.376220703125,
+ "cost_distance_glasses": 2012.046367390626,
+ "cost_deviation": 12.899784088134766,
+ "cost_distorsion": 67.45287322998047,
+ "cost_thickness": 3729.073486328125,
+ "cost_beam_compression": 2.1412010192871094,
+ "cost_non_linearity": 858.7999877929688,
+ "cost_distance_total_intern_reflection": 14305.3623046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3456.376220703125,
+ "cost_distance_glasses": 2012.046367390626,
+ "cost_deviation": 12.899784088134766,
+ "cost_distorsion": 67.45287322998047,
+ "cost_thickness": 3729.073486328125,
+ "cost_beam_compression": 2.1412010192871094,
+ "cost_non_linearity": 858.7999877929688,
+ "cost_distance_total_intern_reflection": 14305.3623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 3456.376220703125,
+ "cost_distance_glasses": 2012.046367390626,
+ "cost_deviation": 12.899784088134766,
+ "cost_distorsion": 67.45287322998047,
+ "cost_thickness": 3729.073486328125,
+ "cost_beam_compression": 2.1412010192871094,
+ "cost_non_linearity": 858.7999877929688,
+ "cost_distance_total_intern_reflection": 14305.3623046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_400.json b/outputs/amici/optimization_results/step1/score_details_iteration_400.json
new file mode 100755
index 0000000..a4c1de7
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_400.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 130.75079345703125,
+ "cost_distance_glasses": 1234.9946209564519,
+ "cost_deviation": 18.87410545349121,
+ "cost_distorsion": 20.920223236083984,
+ "cost_thickness": 4116.12109375,
+ "cost_beam_compression": 2.363250732421875,
+ "cost_non_linearity": 946.738037109375,
+ "cost_distance_total_intern_reflection": 14126.2080078125
+ },
+ "weighted components": {
+ "cost_dispersion": 130.75079345703125,
+ "cost_distance_glasses": 1234.9946209564519,
+ "cost_deviation": 18.87410545349121,
+ "cost_distorsion": 20.920223236083984,
+ "cost_thickness": 4116.12109375,
+ "cost_beam_compression": 2.363250732421875,
+ "cost_non_linearity": 946.738037109375,
+ "cost_distance_total_intern_reflection": 14126.2080078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 130.75079345703125,
+ "cost_distance_glasses": 1234.9946209564519,
+ "cost_deviation": 18.87410545349121,
+ "cost_distorsion": 20.920223236083984,
+ "cost_thickness": 4116.12109375,
+ "cost_beam_compression": 2.363250732421875,
+ "cost_non_linearity": 946.738037109375,
+ "cost_distance_total_intern_reflection": 14126.2080078125
+ },
+ "weighted components": {
+ "cost_dispersion": 130.75079345703125,
+ "cost_distance_glasses": 1234.9946209564519,
+ "cost_deviation": 18.87410545349121,
+ "cost_distorsion": 20.920223236083984,
+ "cost_thickness": 4116.12109375,
+ "cost_beam_compression": 2.363250732421875,
+ "cost_non_linearity": 946.738037109375,
+ "cost_distance_total_intern_reflection": 14126.2080078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_410.json b/outputs/amici/optimization_results/step1/score_details_iteration_410.json
new file mode 100755
index 0000000..ec0464b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_410.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 124.27133178710938,
+ "cost_distance_glasses": 1214.3685385886126,
+ "cost_deviation": 18.352094650268555,
+ "cost_distorsion": 20.713186264038086,
+ "cost_thickness": 4121.4296875,
+ "cost_beam_compression": 2.3665432929992676,
+ "cost_non_linearity": 947.2091674804688,
+ "cost_distance_total_intern_reflection": 14137.892578125
+ },
+ "weighted components": {
+ "cost_dispersion": 124.27133178710938,
+ "cost_distance_glasses": 1214.3685385886126,
+ "cost_deviation": 18.352094650268555,
+ "cost_distorsion": 20.713186264038086,
+ "cost_thickness": 4121.4296875,
+ "cost_beam_compression": 2.3665432929992676,
+ "cost_non_linearity": 947.2091674804688,
+ "cost_distance_total_intern_reflection": 14137.892578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 124.27133178710938,
+ "cost_distance_glasses": 1214.3685385886126,
+ "cost_deviation": 18.352094650268555,
+ "cost_distorsion": 20.713186264038086,
+ "cost_thickness": 4121.4296875,
+ "cost_beam_compression": 2.3665432929992676,
+ "cost_non_linearity": 947.2091674804688,
+ "cost_distance_total_intern_reflection": 14137.892578125
+ },
+ "weighted components": {
+ "cost_dispersion": 124.27133178710938,
+ "cost_distance_glasses": 1214.3685385886126,
+ "cost_deviation": 18.352094650268555,
+ "cost_distorsion": 20.713186264038086,
+ "cost_thickness": 4121.4296875,
+ "cost_beam_compression": 2.3665432929992676,
+ "cost_non_linearity": 947.2091674804688,
+ "cost_distance_total_intern_reflection": 14137.892578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_420.json b/outputs/amici/optimization_results/step1/score_details_iteration_420.json
new file mode 100755
index 0000000..22ec508
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_420.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 118.74667358398438,
+ "cost_distance_glasses": 1237.2341464601907,
+ "cost_deviation": 15.311920166015625,
+ "cost_distorsion": 21.770112991333008,
+ "cost_thickness": 4127.65380859375,
+ "cost_beam_compression": 2.3701186180114746,
+ "cost_non_linearity": 947.9149169921875,
+ "cost_distance_total_intern_reflection": 14147.4443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 118.74667358398438,
+ "cost_distance_glasses": 1237.2341464601907,
+ "cost_deviation": 15.311920166015625,
+ "cost_distorsion": 21.770112991333008,
+ "cost_thickness": 4127.65380859375,
+ "cost_beam_compression": 2.3701186180114746,
+ "cost_non_linearity": 947.9149169921875,
+ "cost_distance_total_intern_reflection": 14147.4443359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 118.74667358398438,
+ "cost_distance_glasses": 1237.2341464601907,
+ "cost_deviation": 15.311920166015625,
+ "cost_distorsion": 21.770112991333008,
+ "cost_thickness": 4127.65380859375,
+ "cost_beam_compression": 2.3701186180114746,
+ "cost_non_linearity": 947.9149169921875,
+ "cost_distance_total_intern_reflection": 14147.4443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 118.74667358398438,
+ "cost_distance_glasses": 1237.2341464601907,
+ "cost_deviation": 15.311920166015625,
+ "cost_distorsion": 21.770112991333008,
+ "cost_thickness": 4127.65380859375,
+ "cost_beam_compression": 2.3701186180114746,
+ "cost_non_linearity": 947.9149169921875,
+ "cost_distance_total_intern_reflection": 14147.4443359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_430.json b/outputs/amici/optimization_results/step1/score_details_iteration_430.json
new file mode 100755
index 0000000..241f647
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_430.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 108.3218002319336,
+ "cost_distance_glasses": 1289.50711096001,
+ "cost_deviation": 14.98251724243164,
+ "cost_distorsion": 21.84722328186035,
+ "cost_thickness": 4134.2822265625,
+ "cost_beam_compression": 2.374255657196045,
+ "cost_non_linearity": 948.9953002929688,
+ "cost_distance_total_intern_reflection": 14155.0869140625
+ },
+ "weighted components": {
+ "cost_dispersion": 108.3218002319336,
+ "cost_distance_glasses": 1289.50711096001,
+ "cost_deviation": 14.98251724243164,
+ "cost_distorsion": 21.84722328186035,
+ "cost_thickness": 4134.2822265625,
+ "cost_beam_compression": 2.374255657196045,
+ "cost_non_linearity": 948.9953002929688,
+ "cost_distance_total_intern_reflection": 14155.0869140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 108.3218002319336,
+ "cost_distance_glasses": 1289.50711096001,
+ "cost_deviation": 14.98251724243164,
+ "cost_distorsion": 21.84722328186035,
+ "cost_thickness": 4134.2822265625,
+ "cost_beam_compression": 2.374255657196045,
+ "cost_non_linearity": 948.9953002929688,
+ "cost_distance_total_intern_reflection": 14155.0869140625
+ },
+ "weighted components": {
+ "cost_dispersion": 108.3218002319336,
+ "cost_distance_glasses": 1289.50711096001,
+ "cost_deviation": 14.98251724243164,
+ "cost_distorsion": 21.84722328186035,
+ "cost_thickness": 4134.2822265625,
+ "cost_beam_compression": 2.374255657196045,
+ "cost_non_linearity": 948.9953002929688,
+ "cost_distance_total_intern_reflection": 14155.0869140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_440.json b/outputs/amici/optimization_results/step1/score_details_iteration_440.json
new file mode 100755
index 0000000..09c084d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_440.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 101.6424331665039,
+ "cost_distance_glasses": 1217.9377677415478,
+ "cost_deviation": 12.398457527160645,
+ "cost_distorsion": 21.866252899169922,
+ "cost_thickness": 4141.28076171875,
+ "cost_beam_compression": 2.378385543823242,
+ "cost_non_linearity": 949.514892578125,
+ "cost_distance_total_intern_reflection": 14165.7734375
+ },
+ "weighted components": {
+ "cost_dispersion": 101.6424331665039,
+ "cost_distance_glasses": 1217.9377677415478,
+ "cost_deviation": 12.398457527160645,
+ "cost_distorsion": 21.866252899169922,
+ "cost_thickness": 4141.28076171875,
+ "cost_beam_compression": 2.378385543823242,
+ "cost_non_linearity": 949.514892578125,
+ "cost_distance_total_intern_reflection": 14165.7734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 101.6424331665039,
+ "cost_distance_glasses": 1217.9377677415478,
+ "cost_deviation": 12.398457527160645,
+ "cost_distorsion": 21.866252899169922,
+ "cost_thickness": 4141.28076171875,
+ "cost_beam_compression": 2.378385543823242,
+ "cost_non_linearity": 949.514892578125,
+ "cost_distance_total_intern_reflection": 14165.7734375
+ },
+ "weighted components": {
+ "cost_dispersion": 101.6424331665039,
+ "cost_distance_glasses": 1217.9377677415478,
+ "cost_deviation": 12.398457527160645,
+ "cost_distorsion": 21.866252899169922,
+ "cost_thickness": 4141.28076171875,
+ "cost_beam_compression": 2.378385543823242,
+ "cost_non_linearity": 949.514892578125,
+ "cost_distance_total_intern_reflection": 14165.7734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_450.json b/outputs/amici/optimization_results/step1/score_details_iteration_450.json
new file mode 100755
index 0000000..ec9b8f2
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_450.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 89.16551208496094,
+ "cost_distance_glasses": 1162.0699434256594,
+ "cost_deviation": 13.428513526916504,
+ "cost_distorsion": 20.880722045898438,
+ "cost_thickness": 4148.1767578125,
+ "cost_beam_compression": 2.3828978538513184,
+ "cost_non_linearity": 950.4234008789062,
+ "cost_distance_total_intern_reflection": 14184.3076171875
+ },
+ "weighted components": {
+ "cost_dispersion": 89.16551208496094,
+ "cost_distance_glasses": 1162.0699434256594,
+ "cost_deviation": 13.428513526916504,
+ "cost_distorsion": 20.880722045898438,
+ "cost_thickness": 4148.1767578125,
+ "cost_beam_compression": 2.3828978538513184,
+ "cost_non_linearity": 950.4234008789062,
+ "cost_distance_total_intern_reflection": 14184.3076171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 89.16551208496094,
+ "cost_distance_glasses": 1162.0699434256594,
+ "cost_deviation": 13.428513526916504,
+ "cost_distorsion": 20.880722045898438,
+ "cost_thickness": 4148.1767578125,
+ "cost_beam_compression": 2.3828978538513184,
+ "cost_non_linearity": 950.4234008789062,
+ "cost_distance_total_intern_reflection": 14184.3076171875
+ },
+ "weighted components": {
+ "cost_dispersion": 89.16551208496094,
+ "cost_distance_glasses": 1162.0699434256594,
+ "cost_deviation": 13.428513526916504,
+ "cost_distorsion": 20.880722045898438,
+ "cost_thickness": 4148.1767578125,
+ "cost_beam_compression": 2.3828978538513184,
+ "cost_non_linearity": 950.4234008789062,
+ "cost_distance_total_intern_reflection": 14184.3076171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_460.json b/outputs/amici/optimization_results/step1/score_details_iteration_460.json
new file mode 100755
index 0000000..8a3ac40
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_460.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 81.37616729736328,
+ "cost_distance_glasses": 1215.388552115499,
+ "cost_deviation": 10.83310604095459,
+ "cost_distorsion": 21.52415657043457,
+ "cost_thickness": 4155.30908203125,
+ "cost_beam_compression": 2.3869128227233887,
+ "cost_non_linearity": 951.4036254882812,
+ "cost_distance_total_intern_reflection": 14177.1513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 81.37616729736328,
+ "cost_distance_glasses": 1215.388552115499,
+ "cost_deviation": 10.83310604095459,
+ "cost_distorsion": 21.52415657043457,
+ "cost_thickness": 4155.30908203125,
+ "cost_beam_compression": 2.3869128227233887,
+ "cost_non_linearity": 951.4036254882812,
+ "cost_distance_total_intern_reflection": 14177.1513671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 81.37616729736328,
+ "cost_distance_glasses": 1215.388552115499,
+ "cost_deviation": 10.83310604095459,
+ "cost_distorsion": 21.52415657043457,
+ "cost_thickness": 4155.30908203125,
+ "cost_beam_compression": 2.3869128227233887,
+ "cost_non_linearity": 951.4036254882812,
+ "cost_distance_total_intern_reflection": 14177.1513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 81.37616729736328,
+ "cost_distance_glasses": 1215.388552115499,
+ "cost_deviation": 10.83310604095459,
+ "cost_distorsion": 21.52415657043457,
+ "cost_thickness": 4155.30908203125,
+ "cost_beam_compression": 2.3869128227233887,
+ "cost_non_linearity": 951.4036254882812,
+ "cost_distance_total_intern_reflection": 14177.1513671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_470.json b/outputs/amici/optimization_results/step1/score_details_iteration_470.json
new file mode 100755
index 0000000..c447483
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_470.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 70.48147583007812,
+ "cost_distance_glasses": 1239.2050266890838,
+ "cost_deviation": 11.198083877563477,
+ "cost_distorsion": 21.071779251098633,
+ "cost_thickness": 4161.76806640625,
+ "cost_beam_compression": 2.391049385070801,
+ "cost_non_linearity": 952.620361328125,
+ "cost_distance_total_intern_reflection": 14197.384765625
+ },
+ "weighted components": {
+ "cost_dispersion": 70.48147583007812,
+ "cost_distance_glasses": 1239.2050266890838,
+ "cost_deviation": 11.198083877563477,
+ "cost_distorsion": 21.071779251098633,
+ "cost_thickness": 4161.76806640625,
+ "cost_beam_compression": 2.391049385070801,
+ "cost_non_linearity": 952.620361328125,
+ "cost_distance_total_intern_reflection": 14197.384765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 70.48147583007812,
+ "cost_distance_glasses": 1239.2050266890838,
+ "cost_deviation": 11.198083877563477,
+ "cost_distorsion": 21.071779251098633,
+ "cost_thickness": 4161.76806640625,
+ "cost_beam_compression": 2.391049385070801,
+ "cost_non_linearity": 952.620361328125,
+ "cost_distance_total_intern_reflection": 14197.384765625
+ },
+ "weighted components": {
+ "cost_dispersion": 70.48147583007812,
+ "cost_distance_glasses": 1239.2050266890838,
+ "cost_deviation": 11.198083877563477,
+ "cost_distorsion": 21.071779251098633,
+ "cost_thickness": 4161.76806640625,
+ "cost_beam_compression": 2.391049385070801,
+ "cost_non_linearity": 952.620361328125,
+ "cost_distance_total_intern_reflection": 14197.384765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_480.json b/outputs/amici/optimization_results/step1/score_details_iteration_480.json
new file mode 100755
index 0000000..b579a81
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_480.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 65.09546661376953,
+ "cost_distance_glasses": 1334.229205765754,
+ "cost_deviation": 7.9896745681762695,
+ "cost_distorsion": 22.901996612548828,
+ "cost_thickness": 4167.96484375,
+ "cost_beam_compression": 2.3944215774536133,
+ "cost_non_linearity": 953.3370361328125,
+ "cost_distance_total_intern_reflection": 14222.75390625
+ },
+ "weighted components": {
+ "cost_dispersion": 65.09546661376953,
+ "cost_distance_glasses": 1334.229205765754,
+ "cost_deviation": 7.9896745681762695,
+ "cost_distorsion": 22.901996612548828,
+ "cost_thickness": 4167.96484375,
+ "cost_beam_compression": 2.3944215774536133,
+ "cost_non_linearity": 953.3370361328125,
+ "cost_distance_total_intern_reflection": 14222.75390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 65.09546661376953,
+ "cost_distance_glasses": 1334.229205765754,
+ "cost_deviation": 7.9896745681762695,
+ "cost_distorsion": 22.901996612548828,
+ "cost_thickness": 4167.96484375,
+ "cost_beam_compression": 2.3944215774536133,
+ "cost_non_linearity": 953.3370361328125,
+ "cost_distance_total_intern_reflection": 14222.75390625
+ },
+ "weighted components": {
+ "cost_dispersion": 65.09546661376953,
+ "cost_distance_glasses": 1334.229205765754,
+ "cost_deviation": 7.9896745681762695,
+ "cost_distorsion": 22.901996612548828,
+ "cost_thickness": 4167.96484375,
+ "cost_beam_compression": 2.3944215774536133,
+ "cost_non_linearity": 953.3370361328125,
+ "cost_distance_total_intern_reflection": 14222.75390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_490.json b/outputs/amici/optimization_results/step1/score_details_iteration_490.json
new file mode 100755
index 0000000..6e5ede8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_490.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 55.99576950073242,
+ "cost_distance_glasses": 1237.2385867417831,
+ "cost_deviation": 9.970160484313965,
+ "cost_distorsion": 21.266260147094727,
+ "cost_thickness": 4172.6201171875,
+ "cost_beam_compression": 2.397754192352295,
+ "cost_non_linearity": 954.2322387695312,
+ "cost_distance_total_intern_reflection": 14213.68359375
+ },
+ "weighted components": {
+ "cost_dispersion": 55.99576950073242,
+ "cost_distance_glasses": 1237.2385867417831,
+ "cost_deviation": 9.970160484313965,
+ "cost_distorsion": 21.266260147094727,
+ "cost_thickness": 4172.6201171875,
+ "cost_beam_compression": 2.397754192352295,
+ "cost_non_linearity": 954.2322387695312,
+ "cost_distance_total_intern_reflection": 14213.68359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 55.99576950073242,
+ "cost_distance_glasses": 1237.2385867417831,
+ "cost_deviation": 9.970160484313965,
+ "cost_distorsion": 21.266260147094727,
+ "cost_thickness": 4172.6201171875,
+ "cost_beam_compression": 2.397754192352295,
+ "cost_non_linearity": 954.2322387695312,
+ "cost_distance_total_intern_reflection": 14213.68359375
+ },
+ "weighted components": {
+ "cost_dispersion": 55.99576950073242,
+ "cost_distance_glasses": 1237.2385867417831,
+ "cost_deviation": 9.970160484313965,
+ "cost_distorsion": 21.266260147094727,
+ "cost_thickness": 4172.6201171875,
+ "cost_beam_compression": 2.397754192352295,
+ "cost_non_linearity": 954.2322387695312,
+ "cost_distance_total_intern_reflection": 14213.68359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_50.json b/outputs/amici/optimization_results/step1/score_details_iteration_50.json
new file mode 100755
index 0000000..d8f1688
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_50.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2733.80126953125,
+ "cost_distance_glasses": 3542.8095053467987,
+ "cost_deviation": 1.185221552848816,
+ "cost_distorsion": 20.82959747314453,
+ "cost_thickness": 3772.63818359375,
+ "cost_beam_compression": 2.1444058418273926,
+ "cost_non_linearity": 870.4175415039062,
+ "cost_distance_total_intern_reflection": 13596.771484375
+ },
+ "weighted components": {
+ "cost_dispersion": 2733.80126953125,
+ "cost_distance_glasses": 3542.8095053467987,
+ "cost_deviation": 1.185221552848816,
+ "cost_distorsion": 20.82959747314453,
+ "cost_thickness": 3772.63818359375,
+ "cost_beam_compression": 2.1444058418273926,
+ "cost_non_linearity": 870.4175415039062,
+ "cost_distance_total_intern_reflection": 13596.771484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2733.80126953125,
+ "cost_distance_glasses": 3542.8095053467987,
+ "cost_deviation": 1.185221552848816,
+ "cost_distorsion": 20.82959747314453,
+ "cost_thickness": 3772.63818359375,
+ "cost_beam_compression": 2.1444058418273926,
+ "cost_non_linearity": 870.4175415039062,
+ "cost_distance_total_intern_reflection": 13596.771484375
+ },
+ "weighted components": {
+ "cost_dispersion": 2733.80126953125,
+ "cost_distance_glasses": 3542.8095053467987,
+ "cost_deviation": 1.185221552848816,
+ "cost_distorsion": 20.82959747314453,
+ "cost_thickness": 3772.63818359375,
+ "cost_beam_compression": 2.1444058418273926,
+ "cost_non_linearity": 870.4175415039062,
+ "cost_distance_total_intern_reflection": 13596.771484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_500.json b/outputs/amici/optimization_results/step1/score_details_iteration_500.json
new file mode 100755
index 0000000..df98a24
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_500.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.72510528564453,
+ "cost_distance_glasses": 1593.102631846401,
+ "cost_deviation": 11.944117546081543,
+ "cost_distorsion": 22.307809829711914,
+ "cost_thickness": 4176.98193359375,
+ "cost_beam_compression": 2.400888204574585,
+ "cost_non_linearity": 955.75927734375,
+ "cost_distance_total_intern_reflection": 14225.4169921875
+ },
+ "weighted components": {
+ "cost_dispersion": 44.72510528564453,
+ "cost_distance_glasses": 1593.102631846401,
+ "cost_deviation": 11.944117546081543,
+ "cost_distorsion": 22.307809829711914,
+ "cost_thickness": 4176.98193359375,
+ "cost_beam_compression": 2.400888204574585,
+ "cost_non_linearity": 955.75927734375,
+ "cost_distance_total_intern_reflection": 14225.4169921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.72510528564453,
+ "cost_distance_glasses": 1593.102631846401,
+ "cost_deviation": 11.944117546081543,
+ "cost_distorsion": 22.307809829711914,
+ "cost_thickness": 4176.98193359375,
+ "cost_beam_compression": 2.400888204574585,
+ "cost_non_linearity": 955.75927734375,
+ "cost_distance_total_intern_reflection": 14225.4169921875
+ },
+ "weighted components": {
+ "cost_dispersion": 44.72510528564453,
+ "cost_distance_glasses": 1593.102631846401,
+ "cost_deviation": 11.944117546081543,
+ "cost_distorsion": 22.307809829711914,
+ "cost_thickness": 4176.98193359375,
+ "cost_beam_compression": 2.400888204574585,
+ "cost_non_linearity": 955.75927734375,
+ "cost_distance_total_intern_reflection": 14225.4169921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_510.json b/outputs/amici/optimization_results/step1/score_details_iteration_510.json
new file mode 100755
index 0000000..fa6e65a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_510.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.29015350341797,
+ "cost_distance_glasses": 1589.1689647208261,
+ "cost_deviation": 19.921443939208984,
+ "cost_distorsion": 19.98748016357422,
+ "cost_thickness": 4179.77880859375,
+ "cost_beam_compression": 2.403390884399414,
+ "cost_non_linearity": 957.3882446289062,
+ "cost_distance_total_intern_reflection": 14255.8505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.29015350341797,
+ "cost_distance_glasses": 1589.1689647208261,
+ "cost_deviation": 19.921443939208984,
+ "cost_distorsion": 19.98748016357422,
+ "cost_thickness": 4179.77880859375,
+ "cost_beam_compression": 2.403390884399414,
+ "cost_non_linearity": 957.3882446289062,
+ "cost_distance_total_intern_reflection": 14255.8505859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 35.29015350341797,
+ "cost_distance_glasses": 1589.1689647208261,
+ "cost_deviation": 19.921443939208984,
+ "cost_distorsion": 19.98748016357422,
+ "cost_thickness": 4179.77880859375,
+ "cost_beam_compression": 2.403390884399414,
+ "cost_non_linearity": 957.3882446289062,
+ "cost_distance_total_intern_reflection": 14255.8505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 35.29015350341797,
+ "cost_distance_glasses": 1589.1689647208261,
+ "cost_deviation": 19.921443939208984,
+ "cost_distorsion": 19.98748016357422,
+ "cost_thickness": 4179.77880859375,
+ "cost_beam_compression": 2.403390884399414,
+ "cost_non_linearity": 957.3882446289062,
+ "cost_distance_total_intern_reflection": 14255.8505859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_520.json b/outputs/amici/optimization_results/step1/score_details_iteration_520.json
new file mode 100755
index 0000000..e6a06cc
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_520.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 411.0419616699219,
+ "cost_distance_glasses": 6665.100424903532,
+ "cost_deviation": 242.01904296875,
+ "cost_distorsion": 29.714069366455078,
+ "cost_thickness": 4182.689453125,
+ "cost_beam_compression": 2.3863327503204346,
+ "cost_non_linearity": 930.1221313476562,
+ "cost_distance_total_intern_reflection": 14237.8310546875
+ },
+ "weighted components": {
+ "cost_dispersion": 411.0419616699219,
+ "cost_distance_glasses": 6665.100424903532,
+ "cost_deviation": 242.01904296875,
+ "cost_distorsion": 29.714069366455078,
+ "cost_thickness": 4182.689453125,
+ "cost_beam_compression": 2.3863327503204346,
+ "cost_non_linearity": 930.1221313476562,
+ "cost_distance_total_intern_reflection": 14237.8310546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 411.0419616699219,
+ "cost_distance_glasses": 6665.100424903532,
+ "cost_deviation": 242.01904296875,
+ "cost_distorsion": 29.714069366455078,
+ "cost_thickness": 4182.689453125,
+ "cost_beam_compression": 2.3863327503204346,
+ "cost_non_linearity": 930.1221313476562,
+ "cost_distance_total_intern_reflection": 14237.8310546875
+ },
+ "weighted components": {
+ "cost_dispersion": 411.0419616699219,
+ "cost_distance_glasses": 6665.100424903532,
+ "cost_deviation": 242.01904296875,
+ "cost_distorsion": 29.714069366455078,
+ "cost_thickness": 4182.689453125,
+ "cost_beam_compression": 2.3863327503204346,
+ "cost_non_linearity": 930.1221313476562,
+ "cost_distance_total_intern_reflection": 14237.8310546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_530.json b/outputs/amici/optimization_results/step1/score_details_iteration_530.json
new file mode 100755
index 0000000..976df00
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_530.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1811.659912109375,
+ "cost_distance_glasses": 1656138.9219650617,
+ "cost_deviation": 3709.13671875,
+ "cost_distorsion": 8.63352108001709,
+ "cost_thickness": 4181.45654296875,
+ "cost_beam_compression": 2.465196132659912,
+ "cost_non_linearity": 1052.7576904296875,
+ "cost_distance_total_intern_reflection": 14461.6416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 1811.659912109375,
+ "cost_distance_glasses": 1656138.9219650617,
+ "cost_deviation": 3709.13671875,
+ "cost_distorsion": 8.63352108001709,
+ "cost_thickness": 4181.45654296875,
+ "cost_beam_compression": 2.465196132659912,
+ "cost_non_linearity": 1052.7576904296875,
+ "cost_distance_total_intern_reflection": 14461.6416015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1811.659912109375,
+ "cost_distance_glasses": 1656138.9219650617,
+ "cost_deviation": 3709.13671875,
+ "cost_distorsion": 8.63352108001709,
+ "cost_thickness": 4181.45654296875,
+ "cost_beam_compression": 2.465196132659912,
+ "cost_non_linearity": 1052.7576904296875,
+ "cost_distance_total_intern_reflection": 14461.6416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 1811.659912109375,
+ "cost_distance_glasses": 1656138.9219650617,
+ "cost_deviation": 3709.13671875,
+ "cost_distorsion": 8.63352108001709,
+ "cost_thickness": 4181.45654296875,
+ "cost_beam_compression": 2.465196132659912,
+ "cost_non_linearity": 1052.7576904296875,
+ "cost_distance_total_intern_reflection": 14461.6416015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_540.json b/outputs/amici/optimization_results/step1/score_details_iteration_540.json
new file mode 100755
index 0000000..cb20d60
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_540.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.89031219482422,
+ "cost_distance_glasses": 1522825.1251026774,
+ "cost_deviation": 1262.7113037109375,
+ "cost_distorsion": 36.869930267333984,
+ "cost_thickness": 4157.89501953125,
+ "cost_beam_compression": 2.43353009223938,
+ "cost_non_linearity": 979.1199951171875,
+ "cost_distance_total_intern_reflection": 14276.3154296875
+ },
+ "weighted components": {
+ "cost_dispersion": 27.89031219482422,
+ "cost_distance_glasses": 1522825.1251026774,
+ "cost_deviation": 1262.7113037109375,
+ "cost_distorsion": 36.869930267333984,
+ "cost_thickness": 4157.89501953125,
+ "cost_beam_compression": 2.43353009223938,
+ "cost_non_linearity": 979.1199951171875,
+ "cost_distance_total_intern_reflection": 14276.3154296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.89031219482422,
+ "cost_distance_glasses": 1522825.1251026774,
+ "cost_deviation": 1262.7113037109375,
+ "cost_distorsion": 36.869930267333984,
+ "cost_thickness": 4157.89501953125,
+ "cost_beam_compression": 2.43353009223938,
+ "cost_non_linearity": 979.1199951171875,
+ "cost_distance_total_intern_reflection": 14276.3154296875
+ },
+ "weighted components": {
+ "cost_dispersion": 27.89031219482422,
+ "cost_distance_glasses": 1522825.1251026774,
+ "cost_deviation": 1262.7113037109375,
+ "cost_distorsion": 36.869930267333984,
+ "cost_thickness": 4157.89501953125,
+ "cost_beam_compression": 2.43353009223938,
+ "cost_non_linearity": 979.1199951171875,
+ "cost_distance_total_intern_reflection": 14276.3154296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_550.json b/outputs/amici/optimization_results/step1/score_details_iteration_550.json
new file mode 100755
index 0000000..563b481
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_550.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 406.20306396484375,
+ "cost_distance_glasses": 447274.35937395925,
+ "cost_deviation": 143.6260223388672,
+ "cost_distorsion": 16.691373825073242,
+ "cost_thickness": 4090.960693359375,
+ "cost_beam_compression": 2.412531852722168,
+ "cost_non_linearity": 1008.191650390625,
+ "cost_distance_total_intern_reflection": 14550.462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 406.20306396484375,
+ "cost_distance_glasses": 447274.35937395925,
+ "cost_deviation": 143.6260223388672,
+ "cost_distorsion": 16.691373825073242,
+ "cost_thickness": 4090.960693359375,
+ "cost_beam_compression": 2.412531852722168,
+ "cost_non_linearity": 1008.191650390625,
+ "cost_distance_total_intern_reflection": 14550.462890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 406.20306396484375,
+ "cost_distance_glasses": 447274.35937395925,
+ "cost_deviation": 143.6260223388672,
+ "cost_distorsion": 16.691373825073242,
+ "cost_thickness": 4090.960693359375,
+ "cost_beam_compression": 2.412531852722168,
+ "cost_non_linearity": 1008.191650390625,
+ "cost_distance_total_intern_reflection": 14550.462890625
+ },
+ "weighted components": {
+ "cost_dispersion": 406.20306396484375,
+ "cost_distance_glasses": 447274.35937395925,
+ "cost_deviation": 143.6260223388672,
+ "cost_distorsion": 16.691373825073242,
+ "cost_thickness": 4090.960693359375,
+ "cost_beam_compression": 2.412531852722168,
+ "cost_non_linearity": 1008.191650390625,
+ "cost_distance_total_intern_reflection": 14550.462890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_560.json b/outputs/amici/optimization_results/step1/score_details_iteration_560.json
new file mode 100755
index 0000000..08154b0
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_560.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2936.2587890625,
+ "cost_distance_glasses": 8373.583406590902,
+ "cost_deviation": 15881.8701171875,
+ "cost_distorsion": 377.1319580078125,
+ "cost_thickness": 4073.366455078125,
+ "cost_beam_compression": 2.2919650077819824,
+ "cost_non_linearity": 867.55126953125,
+ "cost_distance_total_intern_reflection": 14947.5546875
+ },
+ "weighted components": {
+ "cost_dispersion": 2936.2587890625,
+ "cost_distance_glasses": 8373.583406590902,
+ "cost_deviation": 15881.8701171875,
+ "cost_distorsion": 377.1319580078125,
+ "cost_thickness": 4073.366455078125,
+ "cost_beam_compression": 2.2919650077819824,
+ "cost_non_linearity": 867.55126953125,
+ "cost_distance_total_intern_reflection": 14947.5546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2936.2587890625,
+ "cost_distance_glasses": 8373.583406590902,
+ "cost_deviation": 15881.8701171875,
+ "cost_distorsion": 377.1319580078125,
+ "cost_thickness": 4073.366455078125,
+ "cost_beam_compression": 2.2919650077819824,
+ "cost_non_linearity": 867.55126953125,
+ "cost_distance_total_intern_reflection": 14947.5546875
+ },
+ "weighted components": {
+ "cost_dispersion": 2936.2587890625,
+ "cost_distance_glasses": 8373.583406590902,
+ "cost_deviation": 15881.8701171875,
+ "cost_distorsion": 377.1319580078125,
+ "cost_thickness": 4073.366455078125,
+ "cost_beam_compression": 2.2919650077819824,
+ "cost_non_linearity": 867.55126953125,
+ "cost_distance_total_intern_reflection": 14947.5546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_570.json b/outputs/amici/optimization_results/step1/score_details_iteration_570.json
new file mode 100755
index 0000000..caa94ec
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_570.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 113.40741729736328,
+ "cost_distance_glasses": 4751.867837360133,
+ "cost_deviation": 278.025634765625,
+ "cost_distorsion": 23.938304901123047,
+ "cost_thickness": 3984.070068359375,
+ "cost_beam_compression": 2.2973971366882324,
+ "cost_non_linearity": 989.5894165039062,
+ "cost_distance_total_intern_reflection": 14110.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 113.40741729736328,
+ "cost_distance_glasses": 4751.867837360133,
+ "cost_deviation": 278.025634765625,
+ "cost_distorsion": 23.938304901123047,
+ "cost_thickness": 3984.070068359375,
+ "cost_beam_compression": 2.2973971366882324,
+ "cost_non_linearity": 989.5894165039062,
+ "cost_distance_total_intern_reflection": 14110.3828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 113.40741729736328,
+ "cost_distance_glasses": 4751.867837360133,
+ "cost_deviation": 278.025634765625,
+ "cost_distorsion": 23.938304901123047,
+ "cost_thickness": 3984.070068359375,
+ "cost_beam_compression": 2.2973971366882324,
+ "cost_non_linearity": 989.5894165039062,
+ "cost_distance_total_intern_reflection": 14110.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 113.40741729736328,
+ "cost_distance_glasses": 4751.867837360133,
+ "cost_deviation": 278.025634765625,
+ "cost_distorsion": 23.938304901123047,
+ "cost_thickness": 3984.070068359375,
+ "cost_beam_compression": 2.2973971366882324,
+ "cost_non_linearity": 989.5894165039062,
+ "cost_distance_total_intern_reflection": 14110.3828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_580.json b/outputs/amici/optimization_results/step1/score_details_iteration_580.json
new file mode 100755
index 0000000..f2a48fc
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_580.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 513.178466796875,
+ "cost_distance_glasses": 3080.8485909937076,
+ "cost_deviation": 1822.9737548828125,
+ "cost_distorsion": 11.684146881103516,
+ "cost_thickness": 3933.130126953125,
+ "cost_beam_compression": 2.292329788208008,
+ "cost_non_linearity": 1012.8348999023438,
+ "cost_distance_total_intern_reflection": 14311.732421875
+ },
+ "weighted components": {
+ "cost_dispersion": 513.178466796875,
+ "cost_distance_glasses": 3080.8485909937076,
+ "cost_deviation": 1822.9737548828125,
+ "cost_distorsion": 11.684146881103516,
+ "cost_thickness": 3933.130126953125,
+ "cost_beam_compression": 2.292329788208008,
+ "cost_non_linearity": 1012.8348999023438,
+ "cost_distance_total_intern_reflection": 14311.732421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 513.178466796875,
+ "cost_distance_glasses": 3080.8485909937076,
+ "cost_deviation": 1822.9737548828125,
+ "cost_distorsion": 11.684146881103516,
+ "cost_thickness": 3933.130126953125,
+ "cost_beam_compression": 2.292329788208008,
+ "cost_non_linearity": 1012.8348999023438,
+ "cost_distance_total_intern_reflection": 14311.732421875
+ },
+ "weighted components": {
+ "cost_dispersion": 513.178466796875,
+ "cost_distance_glasses": 3080.8485909937076,
+ "cost_deviation": 1822.9737548828125,
+ "cost_distorsion": 11.684146881103516,
+ "cost_thickness": 3933.130126953125,
+ "cost_beam_compression": 2.292329788208008,
+ "cost_non_linearity": 1012.8348999023438,
+ "cost_distance_total_intern_reflection": 14311.732421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_590.json b/outputs/amici/optimization_results/step1/score_details_iteration_590.json
new file mode 100755
index 0000000..34e2698
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_590.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 128.59481811523438,
+ "cost_distance_glasses": 1537.9485095628354,
+ "cost_deviation": 425.45806884765625,
+ "cost_distorsion": 39.09634017944336,
+ "cost_thickness": 3909.3525390625,
+ "cost_beam_compression": 2.235480546951294,
+ "cost_non_linearity": 947.3287353515625,
+ "cost_distance_total_intern_reflection": 13947.8251953125
+ },
+ "weighted components": {
+ "cost_dispersion": 128.59481811523438,
+ "cost_distance_glasses": 1537.9485095628354,
+ "cost_deviation": 425.45806884765625,
+ "cost_distorsion": 39.09634017944336,
+ "cost_thickness": 3909.3525390625,
+ "cost_beam_compression": 2.235480546951294,
+ "cost_non_linearity": 947.3287353515625,
+ "cost_distance_total_intern_reflection": 13947.8251953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 128.59481811523438,
+ "cost_distance_glasses": 1537.9485095628354,
+ "cost_deviation": 425.45806884765625,
+ "cost_distorsion": 39.09634017944336,
+ "cost_thickness": 3909.3525390625,
+ "cost_beam_compression": 2.235480546951294,
+ "cost_non_linearity": 947.3287353515625,
+ "cost_distance_total_intern_reflection": 13947.8251953125
+ },
+ "weighted components": {
+ "cost_dispersion": 128.59481811523438,
+ "cost_distance_glasses": 1537.9485095628354,
+ "cost_deviation": 425.45806884765625,
+ "cost_distorsion": 39.09634017944336,
+ "cost_thickness": 3909.3525390625,
+ "cost_beam_compression": 2.235480546951294,
+ "cost_non_linearity": 947.3287353515625,
+ "cost_distance_total_intern_reflection": 13947.8251953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_60.json b/outputs/amici/optimization_results/step1/score_details_iteration_60.json
new file mode 100755
index 0000000..fee29f2
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_60.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 695.9948120117188,
+ "cost_distance_glasses": 2654.0489247391083,
+ "cost_deviation": 1462.1915283203125,
+ "cost_distorsion": 10.814776420593262,
+ "cost_thickness": 3809.657958984375,
+ "cost_beam_compression": 2.1977596282958984,
+ "cost_non_linearity": 918.2887573242188,
+ "cost_distance_total_intern_reflection": 14019.306640625
+ },
+ "weighted components": {
+ "cost_dispersion": 695.9948120117188,
+ "cost_distance_glasses": 2654.0489247391083,
+ "cost_deviation": 1462.1915283203125,
+ "cost_distorsion": 10.814776420593262,
+ "cost_thickness": 3809.657958984375,
+ "cost_beam_compression": 2.1977596282958984,
+ "cost_non_linearity": 918.2887573242188,
+ "cost_distance_total_intern_reflection": 14019.306640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 695.9948120117188,
+ "cost_distance_glasses": 2654.0489247391083,
+ "cost_deviation": 1462.1915283203125,
+ "cost_distorsion": 10.814776420593262,
+ "cost_thickness": 3809.657958984375,
+ "cost_beam_compression": 2.1977596282958984,
+ "cost_non_linearity": 918.2887573242188,
+ "cost_distance_total_intern_reflection": 14019.306640625
+ },
+ "weighted components": {
+ "cost_dispersion": 695.9948120117188,
+ "cost_distance_glasses": 2654.0489247391083,
+ "cost_deviation": 1462.1915283203125,
+ "cost_distorsion": 10.814776420593262,
+ "cost_thickness": 3809.657958984375,
+ "cost_beam_compression": 2.1977596282958984,
+ "cost_non_linearity": 918.2887573242188,
+ "cost_distance_total_intern_reflection": 14019.306640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_600.json b/outputs/amici/optimization_results/step1/score_details_iteration_600.json
new file mode 100755
index 0000000..15ea333
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_600.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 89.43544006347656,
+ "cost_distance_glasses": 1553.0691332318072,
+ "cost_deviation": 172.84352111816406,
+ "cost_distorsion": 39.21643829345703,
+ "cost_thickness": 3882.104736328125,
+ "cost_beam_compression": 2.2196900844573975,
+ "cost_non_linearity": 950.8988037109375,
+ "cost_distance_total_intern_reflection": 13959.533203125
+ },
+ "weighted components": {
+ "cost_dispersion": 89.43544006347656,
+ "cost_distance_glasses": 1553.0691332318072,
+ "cost_deviation": 172.84352111816406,
+ "cost_distorsion": 39.21643829345703,
+ "cost_thickness": 3882.104736328125,
+ "cost_beam_compression": 2.2196900844573975,
+ "cost_non_linearity": 950.8988037109375,
+ "cost_distance_total_intern_reflection": 13959.533203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 89.43544006347656,
+ "cost_distance_glasses": 1553.0691332318072,
+ "cost_deviation": 172.84352111816406,
+ "cost_distorsion": 39.21643829345703,
+ "cost_thickness": 3882.104736328125,
+ "cost_beam_compression": 2.2196900844573975,
+ "cost_non_linearity": 950.8988037109375,
+ "cost_distance_total_intern_reflection": 13959.533203125
+ },
+ "weighted components": {
+ "cost_dispersion": 89.43544006347656,
+ "cost_distance_glasses": 1553.0691332318072,
+ "cost_deviation": 172.84352111816406,
+ "cost_distorsion": 39.21643829345703,
+ "cost_thickness": 3882.104736328125,
+ "cost_beam_compression": 2.2196900844573975,
+ "cost_non_linearity": 950.8988037109375,
+ "cost_distance_total_intern_reflection": 13959.533203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_610.json b/outputs/amici/optimization_results/step1/score_details_iteration_610.json
new file mode 100755
index 0000000..b275ed3
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_610.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.05382251739502,
+ "cost_distance_glasses": 2594.6948497025933,
+ "cost_deviation": 32.23729705810547,
+ "cost_distorsion": 17.6959228515625,
+ "cost_thickness": 3858.580078125,
+ "cost_beam_compression": 2.209063768386841,
+ "cost_non_linearity": 962.6596069335938,
+ "cost_distance_total_intern_reflection": 13830.9111328125
+ },
+ "weighted components": {
+ "cost_dispersion": 10.05382251739502,
+ "cost_distance_glasses": 2594.6948497025933,
+ "cost_deviation": 32.23729705810547,
+ "cost_distorsion": 17.6959228515625,
+ "cost_thickness": 3858.580078125,
+ "cost_beam_compression": 2.209063768386841,
+ "cost_non_linearity": 962.6596069335938,
+ "cost_distance_total_intern_reflection": 13830.9111328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.05382251739502,
+ "cost_distance_glasses": 2594.6948497025933,
+ "cost_deviation": 32.23729705810547,
+ "cost_distorsion": 17.6959228515625,
+ "cost_thickness": 3858.580078125,
+ "cost_beam_compression": 2.209063768386841,
+ "cost_non_linearity": 962.6596069335938,
+ "cost_distance_total_intern_reflection": 13830.9111328125
+ },
+ "weighted components": {
+ "cost_dispersion": 10.05382251739502,
+ "cost_distance_glasses": 2594.6948497025933,
+ "cost_deviation": 32.23729705810547,
+ "cost_distorsion": 17.6959228515625,
+ "cost_thickness": 3858.580078125,
+ "cost_beam_compression": 2.209063768386841,
+ "cost_non_linearity": 962.6596069335938,
+ "cost_distance_total_intern_reflection": 13830.9111328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_620.json b/outputs/amici/optimization_results/step1/score_details_iteration_620.json
new file mode 100755
index 0000000..4f2e8f8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_620.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.616306304931641,
+ "cost_distance_glasses": 1399.9022057676837,
+ "cost_deviation": 55.58000946044922,
+ "cost_distorsion": 19.09592056274414,
+ "cost_thickness": 3847.572998046875,
+ "cost_beam_compression": 2.204986810684204,
+ "cost_non_linearity": 963.5311279296875,
+ "cost_distance_total_intern_reflection": 13768.4140625
+ },
+ "weighted components": {
+ "cost_dispersion": 7.616306304931641,
+ "cost_distance_glasses": 1399.9022057676837,
+ "cost_deviation": 55.58000946044922,
+ "cost_distorsion": 19.09592056274414,
+ "cost_thickness": 3847.572998046875,
+ "cost_beam_compression": 2.204986810684204,
+ "cost_non_linearity": 963.5311279296875,
+ "cost_distance_total_intern_reflection": 13768.4140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.616306304931641,
+ "cost_distance_glasses": 1399.9022057676837,
+ "cost_deviation": 55.58000946044922,
+ "cost_distorsion": 19.09592056274414,
+ "cost_thickness": 3847.572998046875,
+ "cost_beam_compression": 2.204986810684204,
+ "cost_non_linearity": 963.5311279296875,
+ "cost_distance_total_intern_reflection": 13768.4140625
+ },
+ "weighted components": {
+ "cost_dispersion": 7.616306304931641,
+ "cost_distance_glasses": 1399.9022057676837,
+ "cost_deviation": 55.58000946044922,
+ "cost_distorsion": 19.09592056274414,
+ "cost_thickness": 3847.572998046875,
+ "cost_beam_compression": 2.204986810684204,
+ "cost_non_linearity": 963.5311279296875,
+ "cost_distance_total_intern_reflection": 13768.4140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_630.json b/outputs/amici/optimization_results/step1/score_details_iteration_630.json
new file mode 100755
index 0000000..60837b6
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_630.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.236801147460938,
+ "cost_distance_glasses": 1214.6793179871777,
+ "cost_deviation": 1.4857537746429443,
+ "cost_distorsion": 21.221345901489258,
+ "cost_thickness": 3842.925537109375,
+ "cost_beam_compression": 2.1987926959991455,
+ "cost_non_linearity": 958.0001220703125,
+ "cost_distance_total_intern_reflection": 13737.201171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.236801147460938,
+ "cost_distance_glasses": 1214.6793179871777,
+ "cost_deviation": 1.4857537746429443,
+ "cost_distorsion": 21.221345901489258,
+ "cost_thickness": 3842.925537109375,
+ "cost_beam_compression": 2.1987926959991455,
+ "cost_non_linearity": 958.0001220703125,
+ "cost_distance_total_intern_reflection": 13737.201171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.236801147460938,
+ "cost_distance_glasses": 1214.6793179871777,
+ "cost_deviation": 1.4857537746429443,
+ "cost_distorsion": 21.221345901489258,
+ "cost_thickness": 3842.925537109375,
+ "cost_beam_compression": 2.1987926959991455,
+ "cost_non_linearity": 958.0001220703125,
+ "cost_distance_total_intern_reflection": 13737.201171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.236801147460938,
+ "cost_distance_glasses": 1214.6793179871777,
+ "cost_deviation": 1.4857537746429443,
+ "cost_distorsion": 21.221345901489258,
+ "cost_thickness": 3842.925537109375,
+ "cost_beam_compression": 2.1987926959991455,
+ "cost_non_linearity": 958.0001220703125,
+ "cost_distance_total_intern_reflection": 13737.201171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_640.json b/outputs/amici/optimization_results/step1/score_details_iteration_640.json
new file mode 100755
index 0000000..8b76007
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_640.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.425857543945312,
+ "cost_distance_glasses": 1618.2752646088986,
+ "cost_deviation": 2.1872642040252686,
+ "cost_distorsion": 22.9326171875,
+ "cost_thickness": 3838.821533203125,
+ "cost_beam_compression": 2.194693088531494,
+ "cost_non_linearity": 958.3987426757812,
+ "cost_distance_total_intern_reflection": 13702.96484375
+ },
+ "weighted components": {
+ "cost_dispersion": 29.425857543945312,
+ "cost_distance_glasses": 1618.2752646088986,
+ "cost_deviation": 2.1872642040252686,
+ "cost_distorsion": 22.9326171875,
+ "cost_thickness": 3838.821533203125,
+ "cost_beam_compression": 2.194693088531494,
+ "cost_non_linearity": 958.3987426757812,
+ "cost_distance_total_intern_reflection": 13702.96484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.425857543945312,
+ "cost_distance_glasses": 1618.2752646088986,
+ "cost_deviation": 2.1872642040252686,
+ "cost_distorsion": 22.9326171875,
+ "cost_thickness": 3838.821533203125,
+ "cost_beam_compression": 2.194693088531494,
+ "cost_non_linearity": 958.3987426757812,
+ "cost_distance_total_intern_reflection": 13702.96484375
+ },
+ "weighted components": {
+ "cost_dispersion": 29.425857543945312,
+ "cost_distance_glasses": 1618.2752646088986,
+ "cost_deviation": 2.1872642040252686,
+ "cost_distorsion": 22.9326171875,
+ "cost_thickness": 3838.821533203125,
+ "cost_beam_compression": 2.194693088531494,
+ "cost_non_linearity": 958.3987426757812,
+ "cost_distance_total_intern_reflection": 13702.96484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_650.json b/outputs/amici/optimization_results/step1/score_details_iteration_650.json
new file mode 100755
index 0000000..1ce9bda
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_650.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 23.453044891357422,
+ "cost_distance_glasses": 1262.0938223066091,
+ "cost_deviation": 4.190706729888916,
+ "cost_distorsion": 23.18153953552246,
+ "cost_thickness": 3834.426025390625,
+ "cost_beam_compression": 2.1931302547454834,
+ "cost_non_linearity": 959.5939331054688,
+ "cost_distance_total_intern_reflection": 13711.693359375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.453044891357422,
+ "cost_distance_glasses": 1262.0938223066091,
+ "cost_deviation": 4.190706729888916,
+ "cost_distorsion": 23.18153953552246,
+ "cost_thickness": 3834.426025390625,
+ "cost_beam_compression": 2.1931302547454834,
+ "cost_non_linearity": 959.5939331054688,
+ "cost_distance_total_intern_reflection": 13711.693359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 23.453044891357422,
+ "cost_distance_glasses": 1262.0938223066091,
+ "cost_deviation": 4.190706729888916,
+ "cost_distorsion": 23.18153953552246,
+ "cost_thickness": 3834.426025390625,
+ "cost_beam_compression": 2.1931302547454834,
+ "cost_non_linearity": 959.5939331054688,
+ "cost_distance_total_intern_reflection": 13711.693359375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.453044891357422,
+ "cost_distance_glasses": 1262.0938223066091,
+ "cost_deviation": 4.190706729888916,
+ "cost_distorsion": 23.18153953552246,
+ "cost_thickness": 3834.426025390625,
+ "cost_beam_compression": 2.1931302547454834,
+ "cost_non_linearity": 959.5939331054688,
+ "cost_distance_total_intern_reflection": 13711.693359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_660.json b/outputs/amici/optimization_results/step1/score_details_iteration_660.json
new file mode 100755
index 0000000..91a927c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_660.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.526744842529297,
+ "cost_distance_glasses": 1217.7168997445974,
+ "cost_deviation": 0.20886601507663727,
+ "cost_distorsion": 23.44728660583496,
+ "cost_thickness": 3830.11962890625,
+ "cost_beam_compression": 2.189497947692871,
+ "cost_non_linearity": 957.9852905273438,
+ "cost_distance_total_intern_reflection": 13694.9150390625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.526744842529297,
+ "cost_distance_glasses": 1217.7168997445974,
+ "cost_deviation": 0.20886601507663727,
+ "cost_distorsion": 23.44728660583496,
+ "cost_thickness": 3830.11962890625,
+ "cost_beam_compression": 2.189497947692871,
+ "cost_non_linearity": 957.9852905273438,
+ "cost_distance_total_intern_reflection": 13694.9150390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.526744842529297,
+ "cost_distance_glasses": 1217.7168997445974,
+ "cost_deviation": 0.20886601507663727,
+ "cost_distorsion": 23.44728660583496,
+ "cost_thickness": 3830.11962890625,
+ "cost_beam_compression": 2.189497947692871,
+ "cost_non_linearity": 957.9852905273438,
+ "cost_distance_total_intern_reflection": 13694.9150390625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.526744842529297,
+ "cost_distance_glasses": 1217.7168997445974,
+ "cost_deviation": 0.20886601507663727,
+ "cost_distorsion": 23.44728660583496,
+ "cost_thickness": 3830.11962890625,
+ "cost_beam_compression": 2.189497947692871,
+ "cost_non_linearity": 957.9852905273438,
+ "cost_distance_total_intern_reflection": 13694.9150390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_670.json b/outputs/amici/optimization_results/step1/score_details_iteration_670.json
new file mode 100755
index 0000000..4781810
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_670.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.37590980529785,
+ "cost_distance_glasses": 1277.080332771635,
+ "cost_deviation": 1.5440741777420044,
+ "cost_distorsion": 22.911453247070312,
+ "cost_thickness": 3825.343505859375,
+ "cost_beam_compression": 2.186889171600342,
+ "cost_non_linearity": 958.6268310546875,
+ "cost_distance_total_intern_reflection": 13681.7138671875
+ },
+ "weighted components": {
+ "cost_dispersion": 28.37590980529785,
+ "cost_distance_glasses": 1277.080332771635,
+ "cost_deviation": 1.5440741777420044,
+ "cost_distorsion": 22.911453247070312,
+ "cost_thickness": 3825.343505859375,
+ "cost_beam_compression": 2.186889171600342,
+ "cost_non_linearity": 958.6268310546875,
+ "cost_distance_total_intern_reflection": 13681.7138671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.37590980529785,
+ "cost_distance_glasses": 1277.080332771635,
+ "cost_deviation": 1.5440741777420044,
+ "cost_distorsion": 22.911453247070312,
+ "cost_thickness": 3825.343505859375,
+ "cost_beam_compression": 2.186889171600342,
+ "cost_non_linearity": 958.6268310546875,
+ "cost_distance_total_intern_reflection": 13681.7138671875
+ },
+ "weighted components": {
+ "cost_dispersion": 28.37590980529785,
+ "cost_distance_glasses": 1277.080332771635,
+ "cost_deviation": 1.5440741777420044,
+ "cost_distorsion": 22.911453247070312,
+ "cost_thickness": 3825.343505859375,
+ "cost_beam_compression": 2.186889171600342,
+ "cost_non_linearity": 958.6268310546875,
+ "cost_distance_total_intern_reflection": 13681.7138671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_680.json b/outputs/amici/optimization_results/step1/score_details_iteration_680.json
new file mode 100755
index 0000000..4804047
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_680.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 24.10004425048828,
+ "cost_distance_glasses": 1177.6920000693613,
+ "cost_deviation": 4.926965713500977,
+ "cost_distorsion": 22.076955795288086,
+ "cost_thickness": 3820.730224609375,
+ "cost_beam_compression": 2.1850199699401855,
+ "cost_non_linearity": 959.4478149414062,
+ "cost_distance_total_intern_reflection": 13674.9853515625
+ },
+ "weighted components": {
+ "cost_dispersion": 24.10004425048828,
+ "cost_distance_glasses": 1177.6920000693613,
+ "cost_deviation": 4.926965713500977,
+ "cost_distorsion": 22.076955795288086,
+ "cost_thickness": 3820.730224609375,
+ "cost_beam_compression": 2.1850199699401855,
+ "cost_non_linearity": 959.4478149414062,
+ "cost_distance_total_intern_reflection": 13674.9853515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 24.10004425048828,
+ "cost_distance_glasses": 1177.6920000693613,
+ "cost_deviation": 4.926965713500977,
+ "cost_distorsion": 22.076955795288086,
+ "cost_thickness": 3820.730224609375,
+ "cost_beam_compression": 2.1850199699401855,
+ "cost_non_linearity": 959.4478149414062,
+ "cost_distance_total_intern_reflection": 13674.9853515625
+ },
+ "weighted components": {
+ "cost_dispersion": 24.10004425048828,
+ "cost_distance_glasses": 1177.6920000693613,
+ "cost_deviation": 4.926965713500977,
+ "cost_distorsion": 22.076955795288086,
+ "cost_thickness": 3820.730224609375,
+ "cost_beam_compression": 2.1850199699401855,
+ "cost_non_linearity": 959.4478149414062,
+ "cost_distance_total_intern_reflection": 13674.9853515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_690.json b/outputs/amici/optimization_results/step1/score_details_iteration_690.json
new file mode 100755
index 0000000..d0de51e
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_690.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.35640525817871,
+ "cost_distance_glasses": 1154.2874499740046,
+ "cost_deviation": 2.6400485038757324,
+ "cost_distorsion": 21.245853424072266,
+ "cost_thickness": 3816.675048828125,
+ "cost_beam_compression": 2.182185649871826,
+ "cost_non_linearity": 958.6664428710938,
+ "cost_distance_total_intern_reflection": 13693.74609375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.35640525817871,
+ "cost_distance_glasses": 1154.2874499740046,
+ "cost_deviation": 2.6400485038757324,
+ "cost_distorsion": 21.245853424072266,
+ "cost_thickness": 3816.675048828125,
+ "cost_beam_compression": 2.182185649871826,
+ "cost_non_linearity": 958.6664428710938,
+ "cost_distance_total_intern_reflection": 13693.74609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.35640525817871,
+ "cost_distance_glasses": 1154.2874499740046,
+ "cost_deviation": 2.6400485038757324,
+ "cost_distorsion": 21.245853424072266,
+ "cost_thickness": 3816.675048828125,
+ "cost_beam_compression": 2.182185649871826,
+ "cost_non_linearity": 958.6664428710938,
+ "cost_distance_total_intern_reflection": 13693.74609375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.35640525817871,
+ "cost_distance_glasses": 1154.2874499740046,
+ "cost_deviation": 2.6400485038757324,
+ "cost_distorsion": 21.245853424072266,
+ "cost_thickness": 3816.675048828125,
+ "cost_beam_compression": 2.182185649871826,
+ "cost_non_linearity": 958.6664428710938,
+ "cost_distance_total_intern_reflection": 13693.74609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_70.json b/outputs/amici/optimization_results/step1/score_details_iteration_70.json
new file mode 100755
index 0000000..8af1e79
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_70.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1311.267333984375,
+ "cost_distance_glasses": 3290.243805992231,
+ "cost_deviation": 42.708866119384766,
+ "cost_distorsion": 30.2740535736084,
+ "cost_thickness": 3859.410888671875,
+ "cost_beam_compression": 2.203139066696167,
+ "cost_non_linearity": 900.2094116210938,
+ "cost_distance_total_intern_reflection": 13974.796875
+ },
+ "weighted components": {
+ "cost_dispersion": 1311.267333984375,
+ "cost_distance_glasses": 3290.243805992231,
+ "cost_deviation": 42.708866119384766,
+ "cost_distorsion": 30.2740535736084,
+ "cost_thickness": 3859.410888671875,
+ "cost_beam_compression": 2.203139066696167,
+ "cost_non_linearity": 900.2094116210938,
+ "cost_distance_total_intern_reflection": 13974.796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1311.267333984375,
+ "cost_distance_glasses": 3290.243805992231,
+ "cost_deviation": 42.708866119384766,
+ "cost_distorsion": 30.2740535736084,
+ "cost_thickness": 3859.410888671875,
+ "cost_beam_compression": 2.203139066696167,
+ "cost_non_linearity": 900.2094116210938,
+ "cost_distance_total_intern_reflection": 13974.796875
+ },
+ "weighted components": {
+ "cost_dispersion": 1311.267333984375,
+ "cost_distance_glasses": 3290.243805992231,
+ "cost_deviation": 42.708866119384766,
+ "cost_distorsion": 30.2740535736084,
+ "cost_thickness": 3859.410888671875,
+ "cost_beam_compression": 2.203139066696167,
+ "cost_non_linearity": 900.2094116210938,
+ "cost_distance_total_intern_reflection": 13974.796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_700.json b/outputs/amici/optimization_results/step1/score_details_iteration_700.json
new file mode 100755
index 0000000..342c982
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_700.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.07749366760254,
+ "cost_distance_glasses": 1150.00306863925,
+ "cost_deviation": 8.696246147155762,
+ "cost_distorsion": 20.171566009521484,
+ "cost_thickness": 3812.816162109375,
+ "cost_beam_compression": 2.1808571815490723,
+ "cost_non_linearity": 959.883544921875,
+ "cost_distance_total_intern_reflection": 13704.8623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 22.07749366760254,
+ "cost_distance_glasses": 1150.00306863925,
+ "cost_deviation": 8.696246147155762,
+ "cost_distorsion": 20.171566009521484,
+ "cost_thickness": 3812.816162109375,
+ "cost_beam_compression": 2.1808571815490723,
+ "cost_non_linearity": 959.883544921875,
+ "cost_distance_total_intern_reflection": 13704.8623046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.07749366760254,
+ "cost_distance_glasses": 1150.00306863925,
+ "cost_deviation": 8.696246147155762,
+ "cost_distorsion": 20.171566009521484,
+ "cost_thickness": 3812.816162109375,
+ "cost_beam_compression": 2.1808571815490723,
+ "cost_non_linearity": 959.883544921875,
+ "cost_distance_total_intern_reflection": 13704.8623046875
+ },
+ "weighted components": {
+ "cost_dispersion": 22.07749366760254,
+ "cost_distance_glasses": 1150.00306863925,
+ "cost_deviation": 8.696246147155762,
+ "cost_distorsion": 20.171566009521484,
+ "cost_thickness": 3812.816162109375,
+ "cost_beam_compression": 2.1808571815490723,
+ "cost_non_linearity": 959.883544921875,
+ "cost_distance_total_intern_reflection": 13704.8623046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_710.json b/outputs/amici/optimization_results/step1/score_details_iteration_710.json
new file mode 100755
index 0000000..6e4386f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_710.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.68334197998047,
+ "cost_distance_glasses": 1114.794266286829,
+ "cost_deviation": 2.06516432762146,
+ "cost_distorsion": 22.9418888092041,
+ "cost_thickness": 3810.21826171875,
+ "cost_beam_compression": 2.1781225204467773,
+ "cost_non_linearity": 958.4166870117188,
+ "cost_distance_total_intern_reflection": 13663.576171875
+ },
+ "weighted components": {
+ "cost_dispersion": 29.68334197998047,
+ "cost_distance_glasses": 1114.794266286829,
+ "cost_deviation": 2.06516432762146,
+ "cost_distorsion": 22.9418888092041,
+ "cost_thickness": 3810.21826171875,
+ "cost_beam_compression": 2.1781225204467773,
+ "cost_non_linearity": 958.4166870117188,
+ "cost_distance_total_intern_reflection": 13663.576171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.68334197998047,
+ "cost_distance_glasses": 1114.794266286829,
+ "cost_deviation": 2.06516432762146,
+ "cost_distorsion": 22.9418888092041,
+ "cost_thickness": 3810.21826171875,
+ "cost_beam_compression": 2.1781225204467773,
+ "cost_non_linearity": 958.4166870117188,
+ "cost_distance_total_intern_reflection": 13663.576171875
+ },
+ "weighted components": {
+ "cost_dispersion": 29.68334197998047,
+ "cost_distance_glasses": 1114.794266286829,
+ "cost_deviation": 2.06516432762146,
+ "cost_distorsion": 22.9418888092041,
+ "cost_thickness": 3810.21826171875,
+ "cost_beam_compression": 2.1781225204467773,
+ "cost_non_linearity": 958.4166870117188,
+ "cost_distance_total_intern_reflection": 13663.576171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_720.json b/outputs/amici/optimization_results/step1/score_details_iteration_720.json
new file mode 100755
index 0000000..cdf0bed
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_720.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.94048309326172,
+ "cost_distance_glasses": 1095.6322244082646,
+ "cost_deviation": 0.9171847701072693,
+ "cost_distorsion": 23.043659210205078,
+ "cost_thickness": 3807.44970703125,
+ "cost_beam_compression": 2.1761136054992676,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 13657.8408203125
+ },
+ "weighted components": {
+ "cost_dispersion": 32.94048309326172,
+ "cost_distance_glasses": 1095.6322244082646,
+ "cost_deviation": 0.9171847701072693,
+ "cost_distorsion": 23.043659210205078,
+ "cost_thickness": 3807.44970703125,
+ "cost_beam_compression": 2.1761136054992676,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 13657.8408203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.94048309326172,
+ "cost_distance_glasses": 1095.6322244082646,
+ "cost_deviation": 0.9171847701072693,
+ "cost_distorsion": 23.043659210205078,
+ "cost_thickness": 3807.44970703125,
+ "cost_beam_compression": 2.1761136054992676,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 13657.8408203125
+ },
+ "weighted components": {
+ "cost_dispersion": 32.94048309326172,
+ "cost_distance_glasses": 1095.6322244082646,
+ "cost_deviation": 0.9171847701072693,
+ "cost_distorsion": 23.043659210205078,
+ "cost_thickness": 3807.44970703125,
+ "cost_beam_compression": 2.1761136054992676,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 13657.8408203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_730.json b/outputs/amici/optimization_results/step1/score_details_iteration_730.json
new file mode 100755
index 0000000..d00feed
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_730.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.07676315307617,
+ "cost_distance_glasses": 1083.8838416805218,
+ "cost_deviation": 1.2707440853118896,
+ "cost_distorsion": 23.7741756439209,
+ "cost_thickness": 3805.007568359375,
+ "cost_beam_compression": 2.1748046875,
+ "cost_non_linearity": 957.9181518554688,
+ "cost_distance_total_intern_reflection": 13672.9013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.07676315307617,
+ "cost_distance_glasses": 1083.8838416805218,
+ "cost_deviation": 1.2707440853118896,
+ "cost_distorsion": 23.7741756439209,
+ "cost_thickness": 3805.007568359375,
+ "cost_beam_compression": 2.1748046875,
+ "cost_non_linearity": 957.9181518554688,
+ "cost_distance_total_intern_reflection": 13672.9013671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.07676315307617,
+ "cost_distance_glasses": 1083.8838416805218,
+ "cost_deviation": 1.2707440853118896,
+ "cost_distorsion": 23.7741756439209,
+ "cost_thickness": 3805.007568359375,
+ "cost_beam_compression": 2.1748046875,
+ "cost_non_linearity": 957.9181518554688,
+ "cost_distance_total_intern_reflection": 13672.9013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.07676315307617,
+ "cost_distance_glasses": 1083.8838416805218,
+ "cost_deviation": 1.2707440853118896,
+ "cost_distorsion": 23.7741756439209,
+ "cost_thickness": 3805.007568359375,
+ "cost_beam_compression": 2.1748046875,
+ "cost_non_linearity": 957.9181518554688,
+ "cost_distance_total_intern_reflection": 13672.9013671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_740.json b/outputs/amici/optimization_results/step1/score_details_iteration_740.json
new file mode 100755
index 0000000..0b52cae
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_740.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.217529296875,
+ "cost_distance_glasses": 1067.6473183874255,
+ "cost_deviation": 0.00012159162724856287,
+ "cost_distorsion": 24.593374252319336,
+ "cost_thickness": 3803.00341796875,
+ "cost_beam_compression": 2.17279314994812,
+ "cost_non_linearity": 956.6871337890625,
+ "cost_distance_total_intern_reflection": 13677.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 39.217529296875,
+ "cost_distance_glasses": 1067.6473183874255,
+ "cost_deviation": 0.00012159162724856287,
+ "cost_distorsion": 24.593374252319336,
+ "cost_thickness": 3803.00341796875,
+ "cost_beam_compression": 2.17279314994812,
+ "cost_non_linearity": 956.6871337890625,
+ "cost_distance_total_intern_reflection": 13677.3828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 39.217529296875,
+ "cost_distance_glasses": 1067.6473183874255,
+ "cost_deviation": 0.00012159162724856287,
+ "cost_distorsion": 24.593374252319336,
+ "cost_thickness": 3803.00341796875,
+ "cost_beam_compression": 2.17279314994812,
+ "cost_non_linearity": 956.6871337890625,
+ "cost_distance_total_intern_reflection": 13677.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 39.217529296875,
+ "cost_distance_glasses": 1067.6473183874255,
+ "cost_deviation": 0.00012159162724856287,
+ "cost_distorsion": 24.593374252319336,
+ "cost_thickness": 3803.00341796875,
+ "cost_beam_compression": 2.17279314994812,
+ "cost_non_linearity": 956.6871337890625,
+ "cost_distance_total_intern_reflection": 13677.3828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_750.json b/outputs/amici/optimization_results/step1/score_details_iteration_750.json
new file mode 100755
index 0000000..c0f202c
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_750.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.137142181396484,
+ "cost_distance_glasses": 1053.8075025272683,
+ "cost_deviation": 0.0211081150919199,
+ "cost_distorsion": 25.240812301635742,
+ "cost_thickness": 3801.123291015625,
+ "cost_beam_compression": 2.1716089248657227,
+ "cost_non_linearity": 956.547119140625,
+ "cost_distance_total_intern_reflection": 13687.4267578125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.137142181396484,
+ "cost_distance_glasses": 1053.8075025272683,
+ "cost_deviation": 0.0211081150919199,
+ "cost_distorsion": 25.240812301635742,
+ "cost_thickness": 3801.123291015625,
+ "cost_beam_compression": 2.1716089248657227,
+ "cost_non_linearity": 956.547119140625,
+ "cost_distance_total_intern_reflection": 13687.4267578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.137142181396484,
+ "cost_distance_glasses": 1053.8075025272683,
+ "cost_deviation": 0.0211081150919199,
+ "cost_distorsion": 25.240812301635742,
+ "cost_thickness": 3801.123291015625,
+ "cost_beam_compression": 2.1716089248657227,
+ "cost_non_linearity": 956.547119140625,
+ "cost_distance_total_intern_reflection": 13687.4267578125
+ },
+ "weighted components": {
+ "cost_dispersion": 40.137142181396484,
+ "cost_distance_glasses": 1053.8075025272683,
+ "cost_deviation": 0.0211081150919199,
+ "cost_distorsion": 25.240812301635742,
+ "cost_thickness": 3801.123291015625,
+ "cost_beam_compression": 2.1716089248657227,
+ "cost_non_linearity": 956.547119140625,
+ "cost_distance_total_intern_reflection": 13687.4267578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_760.json b/outputs/amici/optimization_results/step1/score_details_iteration_760.json
new file mode 100755
index 0000000..5b9acb7
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_760.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.33599853515625,
+ "cost_distance_glasses": 1046.245150551269,
+ "cost_deviation": 2.9248054027557373,
+ "cost_distorsion": 21.736780166625977,
+ "cost_thickness": 3798.580078125,
+ "cost_beam_compression": 2.171415090560913,
+ "cost_non_linearity": 958.07275390625,
+ "cost_distance_total_intern_reflection": 13655.8134765625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.33599853515625,
+ "cost_distance_glasses": 1046.245150551269,
+ "cost_deviation": 2.9248054027557373,
+ "cost_distorsion": 21.736780166625977,
+ "cost_thickness": 3798.580078125,
+ "cost_beam_compression": 2.171415090560913,
+ "cost_non_linearity": 958.07275390625,
+ "cost_distance_total_intern_reflection": 13655.8134765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.33599853515625,
+ "cost_distance_glasses": 1046.245150551269,
+ "cost_deviation": 2.9248054027557373,
+ "cost_distorsion": 21.736780166625977,
+ "cost_thickness": 3798.580078125,
+ "cost_beam_compression": 2.171415090560913,
+ "cost_non_linearity": 958.07275390625,
+ "cost_distance_total_intern_reflection": 13655.8134765625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.33599853515625,
+ "cost_distance_glasses": 1046.245150551269,
+ "cost_deviation": 2.9248054027557373,
+ "cost_distorsion": 21.736780166625977,
+ "cost_thickness": 3798.580078125,
+ "cost_beam_compression": 2.171415090560913,
+ "cost_non_linearity": 958.07275390625,
+ "cost_distance_total_intern_reflection": 13655.8134765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_770.json b/outputs/amici/optimization_results/step1/score_details_iteration_770.json
new file mode 100755
index 0000000..4ee131f
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_770.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.40467071533203,
+ "cost_distance_glasses": 1037.1716857293163,
+ "cost_deviation": 3.6022555828094482,
+ "cost_distorsion": 21.610702514648438,
+ "cost_thickness": 3797.030517578125,
+ "cost_beam_compression": 2.1706409454345703,
+ "cost_non_linearity": 958.4492797851562,
+ "cost_distance_total_intern_reflection": 13651.53515625
+ },
+ "weighted components": {
+ "cost_dispersion": 29.40467071533203,
+ "cost_distance_glasses": 1037.1716857293163,
+ "cost_deviation": 3.6022555828094482,
+ "cost_distorsion": 21.610702514648438,
+ "cost_thickness": 3797.030517578125,
+ "cost_beam_compression": 2.1706409454345703,
+ "cost_non_linearity": 958.4492797851562,
+ "cost_distance_total_intern_reflection": 13651.53515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 29.40467071533203,
+ "cost_distance_glasses": 1037.1716857293163,
+ "cost_deviation": 3.6022555828094482,
+ "cost_distorsion": 21.610702514648438,
+ "cost_thickness": 3797.030517578125,
+ "cost_beam_compression": 2.1706409454345703,
+ "cost_non_linearity": 958.4492797851562,
+ "cost_distance_total_intern_reflection": 13651.53515625
+ },
+ "weighted components": {
+ "cost_dispersion": 29.40467071533203,
+ "cost_distance_glasses": 1037.1716857293163,
+ "cost_deviation": 3.6022555828094482,
+ "cost_distorsion": 21.610702514648438,
+ "cost_thickness": 3797.030517578125,
+ "cost_beam_compression": 2.1706409454345703,
+ "cost_non_linearity": 958.4492797851562,
+ "cost_distance_total_intern_reflection": 13651.53515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_780.json b/outputs/amici/optimization_results/step1/score_details_iteration_780.json
new file mode 100755
index 0000000..79bbd54
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_780.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.990943908691406,
+ "cost_distance_glasses": 1027.7379556850085,
+ "cost_deviation": 1.5167917013168335,
+ "cost_distorsion": 23.13433837890625,
+ "cost_thickness": 3796.028076171875,
+ "cost_beam_compression": 2.1695523262023926,
+ "cost_non_linearity": 957.904541015625,
+ "cost_distance_total_intern_reflection": 13648.3427734375
+ },
+ "weighted components": {
+ "cost_dispersion": 32.990943908691406,
+ "cost_distance_glasses": 1027.7379556850085,
+ "cost_deviation": 1.5167917013168335,
+ "cost_distorsion": 23.13433837890625,
+ "cost_thickness": 3796.028076171875,
+ "cost_beam_compression": 2.1695523262023926,
+ "cost_non_linearity": 957.904541015625,
+ "cost_distance_total_intern_reflection": 13648.3427734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.990943908691406,
+ "cost_distance_glasses": 1027.7379556850085,
+ "cost_deviation": 1.5167917013168335,
+ "cost_distorsion": 23.13433837890625,
+ "cost_thickness": 3796.028076171875,
+ "cost_beam_compression": 2.1695523262023926,
+ "cost_non_linearity": 957.904541015625,
+ "cost_distance_total_intern_reflection": 13648.3427734375
+ },
+ "weighted components": {
+ "cost_dispersion": 32.990943908691406,
+ "cost_distance_glasses": 1027.7379556850085,
+ "cost_deviation": 1.5167917013168335,
+ "cost_distorsion": 23.13433837890625,
+ "cost_thickness": 3796.028076171875,
+ "cost_beam_compression": 2.1695523262023926,
+ "cost_non_linearity": 957.904541015625,
+ "cost_distance_total_intern_reflection": 13648.3427734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_790.json b/outputs/amici/optimization_results/step1/score_details_iteration_790.json
new file mode 100755
index 0000000..84dcc67
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_790.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.51988983154297,
+ "cost_distance_glasses": 1021.0102261994649,
+ "cost_deviation": 2.4104175567626953,
+ "cost_distorsion": 22.121803283691406,
+ "cost_thickness": 3794.70166015625,
+ "cost_beam_compression": 2.1690101623535156,
+ "cost_non_linearity": 957.9191284179688,
+ "cost_distance_total_intern_reflection": 13639.4326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.51988983154297,
+ "cost_distance_glasses": 1021.0102261994649,
+ "cost_deviation": 2.4104175567626953,
+ "cost_distorsion": 22.121803283691406,
+ "cost_thickness": 3794.70166015625,
+ "cost_beam_compression": 2.1690101623535156,
+ "cost_non_linearity": 957.9191284179688,
+ "cost_distance_total_intern_reflection": 13639.4326171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.51988983154297,
+ "cost_distance_glasses": 1021.0102261994649,
+ "cost_deviation": 2.4104175567626953,
+ "cost_distorsion": 22.121803283691406,
+ "cost_thickness": 3794.70166015625,
+ "cost_beam_compression": 2.1690101623535156,
+ "cost_non_linearity": 957.9191284179688,
+ "cost_distance_total_intern_reflection": 13639.4326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.51988983154297,
+ "cost_distance_glasses": 1021.0102261994649,
+ "cost_deviation": 2.4104175567626953,
+ "cost_distorsion": 22.121803283691406,
+ "cost_thickness": 3794.70166015625,
+ "cost_beam_compression": 2.1690101623535156,
+ "cost_non_linearity": 957.9191284179688,
+ "cost_distance_total_intern_reflection": 13639.4326171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_80.json b/outputs/amici/optimization_results/step1/score_details_iteration_80.json
new file mode 100755
index 0000000..e9a02aa
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_80.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 714.243896484375,
+ "cost_distance_glasses": 2191.30902329035,
+ "cost_deviation": 254.15232849121094,
+ "cost_distorsion": 14.481828689575195,
+ "cost_thickness": 3893.78076171875,
+ "cost_beam_compression": 2.231113910675049,
+ "cost_non_linearity": 917.6574096679688,
+ "cost_distance_total_intern_reflection": 13895.330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 714.243896484375,
+ "cost_distance_glasses": 2191.30902329035,
+ "cost_deviation": 254.15232849121094,
+ "cost_distorsion": 14.481828689575195,
+ "cost_thickness": 3893.78076171875,
+ "cost_beam_compression": 2.231113910675049,
+ "cost_non_linearity": 917.6574096679688,
+ "cost_distance_total_intern_reflection": 13895.330078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 714.243896484375,
+ "cost_distance_glasses": 2191.30902329035,
+ "cost_deviation": 254.15232849121094,
+ "cost_distorsion": 14.481828689575195,
+ "cost_thickness": 3893.78076171875,
+ "cost_beam_compression": 2.231113910675049,
+ "cost_non_linearity": 917.6574096679688,
+ "cost_distance_total_intern_reflection": 13895.330078125
+ },
+ "weighted components": {
+ "cost_dispersion": 714.243896484375,
+ "cost_distance_glasses": 2191.30902329035,
+ "cost_deviation": 254.15232849121094,
+ "cost_distorsion": 14.481828689575195,
+ "cost_thickness": 3893.78076171875,
+ "cost_beam_compression": 2.231113910675049,
+ "cost_non_linearity": 917.6574096679688,
+ "cost_distance_total_intern_reflection": 13895.330078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_800.json b/outputs/amici/optimization_results/step1/score_details_iteration_800.json
new file mode 100755
index 0000000..91b97c0
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_800.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.42963409423828,
+ "cost_distance_glasses": 1015.1222956275792,
+ "cost_deviation": 1.8238292932510376,
+ "cost_distorsion": 22.844026565551758,
+ "cost_thickness": 3793.907958984375,
+ "cost_beam_compression": 2.168400287628174,
+ "cost_non_linearity": 957.908203125,
+ "cost_distance_total_intern_reflection": 13640.3369140625
+ },
+ "weighted components": {
+ "cost_dispersion": 32.42963409423828,
+ "cost_distance_glasses": 1015.1222956275792,
+ "cost_deviation": 1.8238292932510376,
+ "cost_distorsion": 22.844026565551758,
+ "cost_thickness": 3793.907958984375,
+ "cost_beam_compression": 2.168400287628174,
+ "cost_non_linearity": 957.908203125,
+ "cost_distance_total_intern_reflection": 13640.3369140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.42963409423828,
+ "cost_distance_glasses": 1015.1222956275792,
+ "cost_deviation": 1.8238292932510376,
+ "cost_distorsion": 22.844026565551758,
+ "cost_thickness": 3793.907958984375,
+ "cost_beam_compression": 2.168400287628174,
+ "cost_non_linearity": 957.908203125,
+ "cost_distance_total_intern_reflection": 13640.3369140625
+ },
+ "weighted components": {
+ "cost_dispersion": 32.42963409423828,
+ "cost_distance_glasses": 1015.1222956275792,
+ "cost_deviation": 1.8238292932510376,
+ "cost_distorsion": 22.844026565551758,
+ "cost_thickness": 3793.907958984375,
+ "cost_beam_compression": 2.168400287628174,
+ "cost_non_linearity": 957.908203125,
+ "cost_distance_total_intern_reflection": 13640.3369140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_810.json b/outputs/amici/optimization_results/step1/score_details_iteration_810.json
new file mode 100755
index 0000000..a255d3d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_810.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.421279907226562,
+ "cost_distance_glasses": 1010.3090821932249,
+ "cost_deviation": 2.36482834815979,
+ "cost_distorsion": 22.72655487060547,
+ "cost_thickness": 3793.072998046875,
+ "cost_beam_compression": 2.1680593490600586,
+ "cost_non_linearity": 958.0042724609375,
+ "cost_distance_total_intern_reflection": 13637.61328125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.421279907226562,
+ "cost_distance_glasses": 1010.3090821932249,
+ "cost_deviation": 2.36482834815979,
+ "cost_distorsion": 22.72655487060547,
+ "cost_thickness": 3793.072998046875,
+ "cost_beam_compression": 2.1680593490600586,
+ "cost_non_linearity": 958.0042724609375,
+ "cost_distance_total_intern_reflection": 13637.61328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.421279907226562,
+ "cost_distance_glasses": 1010.3090821932249,
+ "cost_deviation": 2.36482834815979,
+ "cost_distorsion": 22.72655487060547,
+ "cost_thickness": 3793.072998046875,
+ "cost_beam_compression": 2.1680593490600586,
+ "cost_non_linearity": 958.0042724609375,
+ "cost_distance_total_intern_reflection": 13637.61328125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.421279907226562,
+ "cost_distance_glasses": 1010.3090821932249,
+ "cost_deviation": 2.36482834815979,
+ "cost_distorsion": 22.72655487060547,
+ "cost_thickness": 3793.072998046875,
+ "cost_beam_compression": 2.1680593490600586,
+ "cost_non_linearity": 958.0042724609375,
+ "cost_distance_total_intern_reflection": 13637.61328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_820.json b/outputs/amici/optimization_results/step1/score_details_iteration_820.json
new file mode 100755
index 0000000..68f9ffe
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_820.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.045658111572266,
+ "cost_distance_glasses": 1006.5321084343976,
+ "cost_deviation": 1.6171320676803589,
+ "cost_distorsion": 22.929670333862305,
+ "cost_thickness": 3792.4951171875,
+ "cost_beam_compression": 2.167529582977295,
+ "cost_non_linearity": 957.94921875,
+ "cost_distance_total_intern_reflection": 13639.4072265625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.045658111572266,
+ "cost_distance_glasses": 1006.5321084343976,
+ "cost_deviation": 1.6171320676803589,
+ "cost_distorsion": 22.929670333862305,
+ "cost_thickness": 3792.4951171875,
+ "cost_beam_compression": 2.167529582977295,
+ "cost_non_linearity": 957.94921875,
+ "cost_distance_total_intern_reflection": 13639.4072265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 33.045658111572266,
+ "cost_distance_glasses": 1006.5321084343976,
+ "cost_deviation": 1.6171320676803589,
+ "cost_distorsion": 22.929670333862305,
+ "cost_thickness": 3792.4951171875,
+ "cost_beam_compression": 2.167529582977295,
+ "cost_non_linearity": 957.94921875,
+ "cost_distance_total_intern_reflection": 13639.4072265625
+ },
+ "weighted components": {
+ "cost_dispersion": 33.045658111572266,
+ "cost_distance_glasses": 1006.5321084343976,
+ "cost_deviation": 1.6171320676803589,
+ "cost_distorsion": 22.929670333862305,
+ "cost_thickness": 3792.4951171875,
+ "cost_beam_compression": 2.167529582977295,
+ "cost_non_linearity": 957.94921875,
+ "cost_distance_total_intern_reflection": 13639.4072265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_830.json b/outputs/amici/optimization_results/step1/score_details_iteration_830.json
new file mode 100755
index 0000000..0e1044b
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_830.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.772598266601562,
+ "cost_distance_glasses": 1004.3490216348796,
+ "cost_deviation": 2.3251242637634277,
+ "cost_distorsion": 22.496505737304688,
+ "cost_thickness": 3791.8857421875,
+ "cost_beam_compression": 2.167367458343506,
+ "cost_non_linearity": 958.1712036132812,
+ "cost_distance_total_intern_reflection": 13630.7421875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.772598266601562,
+ "cost_distance_glasses": 1004.3490216348796,
+ "cost_deviation": 2.3251242637634277,
+ "cost_distorsion": 22.496505737304688,
+ "cost_thickness": 3791.8857421875,
+ "cost_beam_compression": 2.167367458343506,
+ "cost_non_linearity": 958.1712036132812,
+ "cost_distance_total_intern_reflection": 13630.7421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.772598266601562,
+ "cost_distance_glasses": 1004.3490216348796,
+ "cost_deviation": 2.3251242637634277,
+ "cost_distorsion": 22.496505737304688,
+ "cost_thickness": 3791.8857421875,
+ "cost_beam_compression": 2.167367458343506,
+ "cost_non_linearity": 958.1712036132812,
+ "cost_distance_total_intern_reflection": 13630.7421875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.772598266601562,
+ "cost_distance_glasses": 1004.3490216348796,
+ "cost_deviation": 2.3251242637634277,
+ "cost_distorsion": 22.496505737304688,
+ "cost_thickness": 3791.8857421875,
+ "cost_beam_compression": 2.167367458343506,
+ "cost_non_linearity": 958.1712036132812,
+ "cost_distance_total_intern_reflection": 13630.7421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_840.json b/outputs/amici/optimization_results/step1/score_details_iteration_840.json
new file mode 100755
index 0000000..a9608d8
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_840.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.682565689086914,
+ "cost_distance_glasses": 1003.1825871890808,
+ "cost_deviation": 3.0791852474212646,
+ "cost_distorsion": 22.035123825073242,
+ "cost_thickness": 3791.397705078125,
+ "cost_beam_compression": 2.167266607284546,
+ "cost_non_linearity": 958.2438354492188,
+ "cost_distance_total_intern_reflection": 13634.1806640625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.682565689086914,
+ "cost_distance_glasses": 1003.1825871890808,
+ "cost_deviation": 3.0791852474212646,
+ "cost_distorsion": 22.035123825073242,
+ "cost_thickness": 3791.397705078125,
+ "cost_beam_compression": 2.167266607284546,
+ "cost_non_linearity": 958.2438354492188,
+ "cost_distance_total_intern_reflection": 13634.1806640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.682565689086914,
+ "cost_distance_glasses": 1003.1825871890808,
+ "cost_deviation": 3.0791852474212646,
+ "cost_distorsion": 22.035123825073242,
+ "cost_thickness": 3791.397705078125,
+ "cost_beam_compression": 2.167266607284546,
+ "cost_non_linearity": 958.2438354492188,
+ "cost_distance_total_intern_reflection": 13634.1806640625
+ },
+ "weighted components": {
+ "cost_dispersion": 30.682565689086914,
+ "cost_distance_glasses": 1003.1825871890808,
+ "cost_deviation": 3.0791852474212646,
+ "cost_distorsion": 22.035123825073242,
+ "cost_thickness": 3791.397705078125,
+ "cost_beam_compression": 2.167266607284546,
+ "cost_non_linearity": 958.2438354492188,
+ "cost_distance_total_intern_reflection": 13634.1806640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_850.json b/outputs/amici/optimization_results/step1/score_details_iteration_850.json
new file mode 100755
index 0000000..4fc0136
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_850.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.04062271118164,
+ "cost_distance_glasses": 1003.6666678788456,
+ "cost_deviation": 2.9186925888061523,
+ "cost_distorsion": 22.224613189697266,
+ "cost_thickness": 3791.134765625,
+ "cost_beam_compression": 2.1670870780944824,
+ "cost_non_linearity": 958.2079467773438,
+ "cost_distance_total_intern_reflection": 13631.8349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.04062271118164,
+ "cost_distance_glasses": 1003.6666678788456,
+ "cost_deviation": 2.9186925888061523,
+ "cost_distorsion": 22.224613189697266,
+ "cost_thickness": 3791.134765625,
+ "cost_beam_compression": 2.1670870780944824,
+ "cost_non_linearity": 958.2079467773438,
+ "cost_distance_total_intern_reflection": 13631.8349609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.04062271118164,
+ "cost_distance_glasses": 1003.6666678788456,
+ "cost_deviation": 2.9186925888061523,
+ "cost_distorsion": 22.224613189697266,
+ "cost_thickness": 3791.134765625,
+ "cost_beam_compression": 2.1670870780944824,
+ "cost_non_linearity": 958.2079467773438,
+ "cost_distance_total_intern_reflection": 13631.8349609375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.04062271118164,
+ "cost_distance_glasses": 1003.6666678788456,
+ "cost_deviation": 2.9186925888061523,
+ "cost_distorsion": 22.224613189697266,
+ "cost_thickness": 3791.134765625,
+ "cost_beam_compression": 2.1670870780944824,
+ "cost_non_linearity": 958.2079467773438,
+ "cost_distance_total_intern_reflection": 13631.8349609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_860.json b/outputs/amici/optimization_results/step1/score_details_iteration_860.json
new file mode 100755
index 0000000..e71b833
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_860.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.33512306213379,
+ "cost_distance_glasses": 1006.0036142485924,
+ "cost_deviation": 2.6989660263061523,
+ "cost_distorsion": 22.283628463745117,
+ "cost_thickness": 3790.96923828125,
+ "cost_beam_compression": 2.166951894760132,
+ "cost_non_linearity": 957.9442749023438,
+ "cost_distance_total_intern_reflection": 13628.998046875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.33512306213379,
+ "cost_distance_glasses": 1006.0036142485924,
+ "cost_deviation": 2.6989660263061523,
+ "cost_distorsion": 22.283628463745117,
+ "cost_thickness": 3790.96923828125,
+ "cost_beam_compression": 2.166951894760132,
+ "cost_non_linearity": 957.9442749023438,
+ "cost_distance_total_intern_reflection": 13628.998046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.33512306213379,
+ "cost_distance_glasses": 1006.0036142485924,
+ "cost_deviation": 2.6989660263061523,
+ "cost_distorsion": 22.283628463745117,
+ "cost_thickness": 3790.96923828125,
+ "cost_beam_compression": 2.166951894760132,
+ "cost_non_linearity": 957.9442749023438,
+ "cost_distance_total_intern_reflection": 13628.998046875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.33512306213379,
+ "cost_distance_glasses": 1006.0036142485924,
+ "cost_deviation": 2.6989660263061523,
+ "cost_distorsion": 22.283628463745117,
+ "cost_thickness": 3790.96923828125,
+ "cost_beam_compression": 2.166951894760132,
+ "cost_non_linearity": 957.9442749023438,
+ "cost_distance_total_intern_reflection": 13628.998046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_870.json b/outputs/amici/optimization_results/step1/score_details_iteration_870.json
new file mode 100755
index 0000000..8aafab7
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_870.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.495908737182617,
+ "cost_distance_glasses": 1010.304213424048,
+ "cost_deviation": 2.5755598545074463,
+ "cost_distorsion": 22.42511749267578,
+ "cost_thickness": 3790.865234375,
+ "cost_beam_compression": 2.166869640350342,
+ "cost_non_linearity": 958.1655883789062,
+ "cost_distance_total_intern_reflection": 13627.431640625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.495908737182617,
+ "cost_distance_glasses": 1010.304213424048,
+ "cost_deviation": 2.5755598545074463,
+ "cost_distorsion": 22.42511749267578,
+ "cost_thickness": 3790.865234375,
+ "cost_beam_compression": 2.166869640350342,
+ "cost_non_linearity": 958.1655883789062,
+ "cost_distance_total_intern_reflection": 13627.431640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.495908737182617,
+ "cost_distance_glasses": 1010.304213424048,
+ "cost_deviation": 2.5755598545074463,
+ "cost_distorsion": 22.42511749267578,
+ "cost_thickness": 3790.865234375,
+ "cost_beam_compression": 2.166869640350342,
+ "cost_non_linearity": 958.1655883789062,
+ "cost_distance_total_intern_reflection": 13627.431640625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.495908737182617,
+ "cost_distance_glasses": 1010.304213424048,
+ "cost_deviation": 2.5755598545074463,
+ "cost_distorsion": 22.42511749267578,
+ "cost_thickness": 3790.865234375,
+ "cost_beam_compression": 2.166869640350342,
+ "cost_non_linearity": 958.1655883789062,
+ "cost_distance_total_intern_reflection": 13627.431640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_880.json b/outputs/amici/optimization_results/step1/score_details_iteration_880.json
new file mode 100755
index 0000000..75881fd
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_880.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.577486038208008,
+ "cost_distance_glasses": 1017.3442348054743,
+ "cost_deviation": 2.5674352645874023,
+ "cost_distorsion": 22.365596771240234,
+ "cost_thickness": 3790.80126953125,
+ "cost_beam_compression": 2.1668357849121094,
+ "cost_non_linearity": 958.1021728515625,
+ "cost_distance_total_intern_reflection": 13627.4013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.577486038208008,
+ "cost_distance_glasses": 1017.3442348054743,
+ "cost_deviation": 2.5674352645874023,
+ "cost_distorsion": 22.365596771240234,
+ "cost_thickness": 3790.80126953125,
+ "cost_beam_compression": 2.1668357849121094,
+ "cost_non_linearity": 958.1021728515625,
+ "cost_distance_total_intern_reflection": 13627.4013671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.577486038208008,
+ "cost_distance_glasses": 1017.3442348054743,
+ "cost_deviation": 2.5674352645874023,
+ "cost_distorsion": 22.365596771240234,
+ "cost_thickness": 3790.80126953125,
+ "cost_beam_compression": 2.1668357849121094,
+ "cost_non_linearity": 958.1021728515625,
+ "cost_distance_total_intern_reflection": 13627.4013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.577486038208008,
+ "cost_distance_glasses": 1017.3442348054743,
+ "cost_deviation": 2.5674352645874023,
+ "cost_distorsion": 22.365596771240234,
+ "cost_thickness": 3790.80126953125,
+ "cost_beam_compression": 2.1668357849121094,
+ "cost_non_linearity": 958.1021728515625,
+ "cost_distance_total_intern_reflection": 13627.4013671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_890.json b/outputs/amici/optimization_results/step1/score_details_iteration_890.json
new file mode 100755
index 0000000..19b0288
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_890.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.676340103149414,
+ "cost_distance_glasses": 1026.1723032884229,
+ "cost_deviation": 2.504788398742676,
+ "cost_distorsion": 22.429384231567383,
+ "cost_thickness": 3790.783935546875,
+ "cost_beam_compression": 2.166813611984253,
+ "cost_non_linearity": 957.8215942382812,
+ "cost_distance_total_intern_reflection": 13626.998046875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.676340103149414,
+ "cost_distance_glasses": 1026.1723032884229,
+ "cost_deviation": 2.504788398742676,
+ "cost_distorsion": 22.429384231567383,
+ "cost_thickness": 3790.783935546875,
+ "cost_beam_compression": 2.166813611984253,
+ "cost_non_linearity": 957.8215942382812,
+ "cost_distance_total_intern_reflection": 13626.998046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.676340103149414,
+ "cost_distance_glasses": 1026.1723032884229,
+ "cost_deviation": 2.504788398742676,
+ "cost_distorsion": 22.429384231567383,
+ "cost_thickness": 3790.783935546875,
+ "cost_beam_compression": 2.166813611984253,
+ "cost_non_linearity": 957.8215942382812,
+ "cost_distance_total_intern_reflection": 13626.998046875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.676340103149414,
+ "cost_distance_glasses": 1026.1723032884229,
+ "cost_deviation": 2.504788398742676,
+ "cost_distorsion": 22.429384231567383,
+ "cost_thickness": 3790.783935546875,
+ "cost_beam_compression": 2.166813611984253,
+ "cost_non_linearity": 957.8215942382812,
+ "cost_distance_total_intern_reflection": 13626.998046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_90.json b/outputs/amici/optimization_results/step1/score_details_iteration_90.json
new file mode 100755
index 0000000..e75a577
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_90.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 617.16943359375,
+ "cost_distance_glasses": 2137.3219461661433,
+ "cost_deviation": 129.41661071777344,
+ "cost_distorsion": 19.579816818237305,
+ "cost_thickness": 3928.0107421875,
+ "cost_beam_compression": 2.2483019828796387,
+ "cost_non_linearity": 921.511474609375,
+ "cost_distance_total_intern_reflection": 13864.333984375
+ },
+ "weighted components": {
+ "cost_dispersion": 617.16943359375,
+ "cost_distance_glasses": 2137.3219461661433,
+ "cost_deviation": 129.41661071777344,
+ "cost_distorsion": 19.579816818237305,
+ "cost_thickness": 3928.0107421875,
+ "cost_beam_compression": 2.2483019828796387,
+ "cost_non_linearity": 921.511474609375,
+ "cost_distance_total_intern_reflection": 13864.333984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 617.16943359375,
+ "cost_distance_glasses": 2137.3219461661433,
+ "cost_deviation": 129.41661071777344,
+ "cost_distorsion": 19.579816818237305,
+ "cost_thickness": 3928.0107421875,
+ "cost_beam_compression": 2.2483019828796387,
+ "cost_non_linearity": 921.511474609375,
+ "cost_distance_total_intern_reflection": 13864.333984375
+ },
+ "weighted components": {
+ "cost_dispersion": 617.16943359375,
+ "cost_distance_glasses": 2137.3219461661433,
+ "cost_deviation": 129.41661071777344,
+ "cost_distorsion": 19.579816818237305,
+ "cost_thickness": 3928.0107421875,
+ "cost_beam_compression": 2.2483019828796387,
+ "cost_non_linearity": 921.511474609375,
+ "cost_distance_total_intern_reflection": 13864.333984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_900.json b/outputs/amici/optimization_results/step1/score_details_iteration_900.json
new file mode 100755
index 0000000..efcc975
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_900.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.62002944946289,
+ "cost_distance_glasses": 1037.6623777353898,
+ "cost_deviation": 2.523690700531006,
+ "cost_distorsion": 22.3747501373291,
+ "cost_thickness": 3790.777587890625,
+ "cost_beam_compression": 2.1668152809143066,
+ "cost_non_linearity": 958.0421752929688,
+ "cost_distance_total_intern_reflection": 13626.875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.62002944946289,
+ "cost_distance_glasses": 1037.6623777353898,
+ "cost_deviation": 2.523690700531006,
+ "cost_distorsion": 22.3747501373291,
+ "cost_thickness": 3790.777587890625,
+ "cost_beam_compression": 2.1668152809143066,
+ "cost_non_linearity": 958.0421752929688,
+ "cost_distance_total_intern_reflection": 13626.875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.62002944946289,
+ "cost_distance_glasses": 1037.6623777353898,
+ "cost_deviation": 2.523690700531006,
+ "cost_distorsion": 22.3747501373291,
+ "cost_thickness": 3790.777587890625,
+ "cost_beam_compression": 2.1668152809143066,
+ "cost_non_linearity": 958.0421752929688,
+ "cost_distance_total_intern_reflection": 13626.875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.62002944946289,
+ "cost_distance_glasses": 1037.6623777353898,
+ "cost_deviation": 2.523690700531006,
+ "cost_distorsion": 22.3747501373291,
+ "cost_thickness": 3790.777587890625,
+ "cost_beam_compression": 2.1668152809143066,
+ "cost_non_linearity": 958.0421752929688,
+ "cost_distance_total_intern_reflection": 13626.875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_910.json b/outputs/amici/optimization_results/step1/score_details_iteration_910.json
new file mode 100755
index 0000000..9e1d681
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_910.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.790491104125977,
+ "cost_distance_glasses": 1049.1616663864195,
+ "cost_deviation": 2.527005910873413,
+ "cost_distorsion": 22.505367279052734,
+ "cost_thickness": 3790.7744140625,
+ "cost_beam_compression": 2.1668124198913574,
+ "cost_non_linearity": 958.1502685546875,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.790491104125977,
+ "cost_distance_glasses": 1049.1616663864195,
+ "cost_deviation": 2.527005910873413,
+ "cost_distorsion": 22.505367279052734,
+ "cost_thickness": 3790.7744140625,
+ "cost_beam_compression": 2.1668124198913574,
+ "cost_non_linearity": 958.1502685546875,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.790491104125977,
+ "cost_distance_glasses": 1049.1616663864195,
+ "cost_deviation": 2.527005910873413,
+ "cost_distorsion": 22.505367279052734,
+ "cost_thickness": 3790.7744140625,
+ "cost_beam_compression": 2.1668124198913574,
+ "cost_non_linearity": 958.1502685546875,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.790491104125977,
+ "cost_distance_glasses": 1049.1616663864195,
+ "cost_deviation": 2.527005910873413,
+ "cost_distorsion": 22.505367279052734,
+ "cost_thickness": 3790.7744140625,
+ "cost_beam_compression": 2.1668124198913574,
+ "cost_non_linearity": 958.1502685546875,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_920.json b/outputs/amici/optimization_results/step1/score_details_iteration_920.json
new file mode 100755
index 0000000..b31fc9d
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_920.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.71413803100586,
+ "cost_distance_glasses": 1056.3772539670308,
+ "cost_deviation": 2.5019590854644775,
+ "cost_distorsion": 22.388479232788086,
+ "cost_thickness": 3790.75146484375,
+ "cost_beam_compression": 2.1668004989624023,
+ "cost_non_linearity": 957.801025390625,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.71413803100586,
+ "cost_distance_glasses": 1056.3772539670308,
+ "cost_deviation": 2.5019590854644775,
+ "cost_distorsion": 22.388479232788086,
+ "cost_thickness": 3790.75146484375,
+ "cost_beam_compression": 2.1668004989624023,
+ "cost_non_linearity": 957.801025390625,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.71413803100586,
+ "cost_distance_glasses": 1056.3772539670308,
+ "cost_deviation": 2.5019590854644775,
+ "cost_distorsion": 22.388479232788086,
+ "cost_thickness": 3790.75146484375,
+ "cost_beam_compression": 2.1668004989624023,
+ "cost_non_linearity": 957.801025390625,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.71413803100586,
+ "cost_distance_glasses": 1056.3772539670308,
+ "cost_deviation": 2.5019590854644775,
+ "cost_distorsion": 22.388479232788086,
+ "cost_thickness": 3790.75146484375,
+ "cost_beam_compression": 2.1668004989624023,
+ "cost_non_linearity": 957.801025390625,
+ "cost_distance_total_intern_reflection": 13626.8544921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_930.json b/outputs/amici/optimization_results/step1/score_details_iteration_930.json
new file mode 100755
index 0000000..695ed10
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_930.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.66397476196289,
+ "cost_distance_glasses": 1054.9071065477117,
+ "cost_deviation": 2.441983699798584,
+ "cost_distorsion": 22.29276466369629,
+ "cost_thickness": 3790.688232421875,
+ "cost_beam_compression": 2.16676664352417,
+ "cost_non_linearity": 958.0682373046875,
+ "cost_distance_total_intern_reflection": 13626.7763671875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.66397476196289,
+ "cost_distance_glasses": 1054.9071065477117,
+ "cost_deviation": 2.441983699798584,
+ "cost_distorsion": 22.29276466369629,
+ "cost_thickness": 3790.688232421875,
+ "cost_beam_compression": 2.16676664352417,
+ "cost_non_linearity": 958.0682373046875,
+ "cost_distance_total_intern_reflection": 13626.7763671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.66397476196289,
+ "cost_distance_glasses": 1054.9071065477117,
+ "cost_deviation": 2.441983699798584,
+ "cost_distorsion": 22.29276466369629,
+ "cost_thickness": 3790.688232421875,
+ "cost_beam_compression": 2.16676664352417,
+ "cost_non_linearity": 958.0682373046875,
+ "cost_distance_total_intern_reflection": 13626.7763671875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.66397476196289,
+ "cost_distance_glasses": 1054.9071065477117,
+ "cost_deviation": 2.441983699798584,
+ "cost_distorsion": 22.29276466369629,
+ "cost_thickness": 3790.688232421875,
+ "cost_beam_compression": 2.16676664352417,
+ "cost_non_linearity": 958.0682373046875,
+ "cost_distance_total_intern_reflection": 13626.7763671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_940.json b/outputs/amici/optimization_results/step1/score_details_iteration_940.json
new file mode 100755
index 0000000..7a86625
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_940.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.773975372314453,
+ "cost_distance_glasses": 1040.118285748136,
+ "cost_deviation": 2.4508402347564697,
+ "cost_distorsion": 22.324434280395508,
+ "cost_thickness": 3790.547607421875,
+ "cost_beam_compression": 2.1667230129241943,
+ "cost_non_linearity": 958.273193359375,
+ "cost_distance_total_intern_reflection": 13627.9326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.773975372314453,
+ "cost_distance_glasses": 1040.118285748136,
+ "cost_deviation": 2.4508402347564697,
+ "cost_distorsion": 22.324434280395508,
+ "cost_thickness": 3790.547607421875,
+ "cost_beam_compression": 2.1667230129241943,
+ "cost_non_linearity": 958.273193359375,
+ "cost_distance_total_intern_reflection": 13627.9326171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.773975372314453,
+ "cost_distance_glasses": 1040.118285748136,
+ "cost_deviation": 2.4508402347564697,
+ "cost_distorsion": 22.324434280395508,
+ "cost_thickness": 3790.547607421875,
+ "cost_beam_compression": 2.1667230129241943,
+ "cost_non_linearity": 958.273193359375,
+ "cost_distance_total_intern_reflection": 13627.9326171875
+ },
+ "weighted components": {
+ "cost_dispersion": 31.773975372314453,
+ "cost_distance_glasses": 1040.118285748136,
+ "cost_deviation": 2.4508402347564697,
+ "cost_distorsion": 22.324434280395508,
+ "cost_thickness": 3790.547607421875,
+ "cost_beam_compression": 2.1667230129241943,
+ "cost_non_linearity": 958.273193359375,
+ "cost_distance_total_intern_reflection": 13627.9326171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_950.json b/outputs/amici/optimization_results/step1/score_details_iteration_950.json
new file mode 100755
index 0000000..01e9d3a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_950.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.992473602294922,
+ "cost_distance_glasses": 1011.8597636734463,
+ "cost_deviation": 2.3675789833068848,
+ "cost_distorsion": 22.308752059936523,
+ "cost_thickness": 3790.34130859375,
+ "cost_beam_compression": 2.1666371822357178,
+ "cost_non_linearity": 958.1241455078125,
+ "cost_distance_total_intern_reflection": 13627.205078125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.992473602294922,
+ "cost_distance_glasses": 1011.8597636734463,
+ "cost_deviation": 2.3675789833068848,
+ "cost_distorsion": 22.308752059936523,
+ "cost_thickness": 3790.34130859375,
+ "cost_beam_compression": 2.1666371822357178,
+ "cost_non_linearity": 958.1241455078125,
+ "cost_distance_total_intern_reflection": 13627.205078125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.992473602294922,
+ "cost_distance_glasses": 1011.8597636734463,
+ "cost_deviation": 2.3675789833068848,
+ "cost_distorsion": 22.308752059936523,
+ "cost_thickness": 3790.34130859375,
+ "cost_beam_compression": 2.1666371822357178,
+ "cost_non_linearity": 958.1241455078125,
+ "cost_distance_total_intern_reflection": 13627.205078125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.992473602294922,
+ "cost_distance_glasses": 1011.8597636734463,
+ "cost_deviation": 2.3675789833068848,
+ "cost_distorsion": 22.308752059936523,
+ "cost_thickness": 3790.34130859375,
+ "cost_beam_compression": 2.1666371822357178,
+ "cost_non_linearity": 958.1241455078125,
+ "cost_distance_total_intern_reflection": 13627.205078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_960.json b/outputs/amici/optimization_results/step1/score_details_iteration_960.json
new file mode 100755
index 0000000..189e2bb
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_960.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.683212280273438,
+ "cost_distance_glasses": 976.4902373831128,
+ "cost_deviation": 2.471411943435669,
+ "cost_distorsion": 22.215181350708008,
+ "cost_thickness": 3790.02490234375,
+ "cost_beam_compression": 2.1665425300598145,
+ "cost_non_linearity": 957.9120483398438,
+ "cost_distance_total_intern_reflection": 13626.6962890625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.683212280273438,
+ "cost_distance_glasses": 976.4902373831128,
+ "cost_deviation": 2.471411943435669,
+ "cost_distorsion": 22.215181350708008,
+ "cost_thickness": 3790.02490234375,
+ "cost_beam_compression": 2.1665425300598145,
+ "cost_non_linearity": 957.9120483398438,
+ "cost_distance_total_intern_reflection": 13626.6962890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.683212280273438,
+ "cost_distance_glasses": 976.4902373831128,
+ "cost_deviation": 2.471411943435669,
+ "cost_distorsion": 22.215181350708008,
+ "cost_thickness": 3790.02490234375,
+ "cost_beam_compression": 2.1665425300598145,
+ "cost_non_linearity": 957.9120483398438,
+ "cost_distance_total_intern_reflection": 13626.6962890625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.683212280273438,
+ "cost_distance_glasses": 976.4902373831128,
+ "cost_deviation": 2.471411943435669,
+ "cost_distorsion": 22.215181350708008,
+ "cost_thickness": 3790.02490234375,
+ "cost_beam_compression": 2.1665425300598145,
+ "cost_non_linearity": 957.9120483398438,
+ "cost_distance_total_intern_reflection": 13626.6962890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_970.json b/outputs/amici/optimization_results/step1/score_details_iteration_970.json
new file mode 100755
index 0000000..29d66a6
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_970.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.64886474609375,
+ "cost_distance_glasses": 946.5539174074277,
+ "cost_deviation": 2.6057798862457275,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3789.607177734375,
+ "cost_beam_compression": 2.166383743286133,
+ "cost_non_linearity": 958.1961669921875,
+ "cost_distance_total_intern_reflection": 13626.9130859375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.64886474609375,
+ "cost_distance_glasses": 946.5539174074277,
+ "cost_deviation": 2.6057798862457275,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3789.607177734375,
+ "cost_beam_compression": 2.166383743286133,
+ "cost_non_linearity": 958.1961669921875,
+ "cost_distance_total_intern_reflection": 13626.9130859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.64886474609375,
+ "cost_distance_glasses": 946.5539174074277,
+ "cost_deviation": 2.6057798862457275,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3789.607177734375,
+ "cost_beam_compression": 2.166383743286133,
+ "cost_non_linearity": 958.1961669921875,
+ "cost_distance_total_intern_reflection": 13626.9130859375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.64886474609375,
+ "cost_distance_glasses": 946.5539174074277,
+ "cost_deviation": 2.6057798862457275,
+ "cost_distorsion": 22.38619041442871,
+ "cost_thickness": 3789.607177734375,
+ "cost_beam_compression": 2.166383743286133,
+ "cost_non_linearity": 958.1961669921875,
+ "cost_distance_total_intern_reflection": 13626.9130859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_980.json b/outputs/amici/optimization_results/step1/score_details_iteration_980.json
new file mode 100755
index 0000000..b07c5bd
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_980.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.017501831054688,
+ "cost_distance_glasses": 931.7677062454702,
+ "cost_deviation": 2.9416491985321045,
+ "cost_distorsion": 22.1562557220459,
+ "cost_thickness": 3789.02197265625,
+ "cost_beam_compression": 2.1661412715911865,
+ "cost_non_linearity": 958.1528930664062,
+ "cost_distance_total_intern_reflection": 13627.9130859375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.017501831054688,
+ "cost_distance_glasses": 931.7677062454702,
+ "cost_deviation": 2.9416491985321045,
+ "cost_distorsion": 22.1562557220459,
+ "cost_thickness": 3789.02197265625,
+ "cost_beam_compression": 2.1661412715911865,
+ "cost_non_linearity": 958.1528930664062,
+ "cost_distance_total_intern_reflection": 13627.9130859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 31.017501831054688,
+ "cost_distance_glasses": 931.7677062454702,
+ "cost_deviation": 2.9416491985321045,
+ "cost_distorsion": 22.1562557220459,
+ "cost_thickness": 3789.02197265625,
+ "cost_beam_compression": 2.1661412715911865,
+ "cost_non_linearity": 958.1528930664062,
+ "cost_distance_total_intern_reflection": 13627.9130859375
+ },
+ "weighted components": {
+ "cost_dispersion": 31.017501831054688,
+ "cost_distance_glasses": 931.7677062454702,
+ "cost_deviation": 2.9416491985321045,
+ "cost_distorsion": 22.1562557220459,
+ "cost_thickness": 3789.02197265625,
+ "cost_beam_compression": 2.1661412715911865,
+ "cost_non_linearity": 958.1528930664062,
+ "cost_distance_total_intern_reflection": 13627.9130859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step1/score_details_iteration_990.json b/outputs/amici/optimization_results/step1/score_details_iteration_990.json
new file mode 100755
index 0000000..0af634a
--- /dev/null
+++ b/outputs/amici/optimization_results/step1/score_details_iteration_990.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.03460693359375,
+ "cost_distance_glasses": 930.2456565917106,
+ "cost_deviation": 2.308793306350708,
+ "cost_distorsion": 22.4575138092041,
+ "cost_thickness": 3788.42236328125,
+ "cost_beam_compression": 2.1656441688537598,
+ "cost_non_linearity": 957.848876953125,
+ "cost_distance_total_intern_reflection": 13627.4921875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.03460693359375,
+ "cost_distance_glasses": 930.2456565917106,
+ "cost_deviation": 2.308793306350708,
+ "cost_distorsion": 22.4575138092041,
+ "cost_thickness": 3788.42236328125,
+ "cost_beam_compression": 2.1656441688537598,
+ "cost_non_linearity": 957.848876953125,
+ "cost_distance_total_intern_reflection": 13627.4921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 1.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 32.03460693359375,
+ "cost_distance_glasses": 930.2456565917106,
+ "cost_deviation": 2.308793306350708,
+ "cost_distorsion": 22.4575138092041,
+ "cost_thickness": 3788.42236328125,
+ "cost_beam_compression": 2.1656441688537598,
+ "cost_non_linearity": 957.848876953125,
+ "cost_distance_total_intern_reflection": 13627.4921875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.03460693359375,
+ "cost_distance_glasses": 930.2456565917106,
+ "cost_deviation": 2.308793306350708,
+ "cost_distorsion": 22.4575138092041,
+ "cost_thickness": 3788.42236328125,
+ "cost_beam_compression": 2.1656441688537598,
+ "cost_non_linearity": 957.848876953125,
+ "cost_distance_total_intern_reflection": 13627.4921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/optimization_details.json b/outputs/amici/optimization_results/step2/optimization_details.json
new file mode 100755
index 0000000..2060c78
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/optimization_details.json
@@ -0,0 +1,1997 @@
+[
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 0,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 24.33140144638986,
+ "A2": 35.55279436588468,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.308127075897412,
+ "delta_alpha_c": 0.0,
+ "A3": 24.33140144638986
+ },
+ "optical system values": {
+ "dispersion [um]": 1051.659912109375,
+ "deviation [deg]": 6.273587663038303,
+ "max distortion [um]": 5.154808044433594,
+ "mean distortion [um]": 1.127838134765625,
+ "beam_compression [no units]": 0.7870163917541504
+ },
+ "current_loss": 23446.462890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 10,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.555211918920445,
+ "A2": 34.13577941501174,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.395074103371204,
+ "delta_alpha_c": 0.0,
+ "A3": 23.555211918920445
+ },
+ "optical system values": {
+ "dispersion [um]": 998.51953125,
+ "deviation [deg]": 20.12285232323957,
+ "max distortion [um]": 5.634846210479736,
+ "mean distortion [um]": 1.3060555458068848,
+ "beam_compression [no units]": 0.8045390248298645
+ },
+ "current_loss": 18189.498046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 20,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.76255822045671,
+ "A2": 33.46359659312869,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.311494900513123,
+ "delta_alpha_c": 0.0,
+ "A3": 22.76255822045671
+ },
+ "optical system values": {
+ "dispersion [um]": 987.5653076171875,
+ "deviation [deg]": -1.5567545381541716,
+ "max distortion [um]": 5.085597515106201,
+ "mean distortion [um]": 0.9875859022140503,
+ "beam_compression [no units]": 0.8130146861076355
+ },
+ "current_loss": 17307.126953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 30,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.702858952016214,
+ "A2": 33.485029726744195,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.963685331808723,
+ "delta_alpha_c": 0.0,
+ "A3": 22.702858952016214
+ },
+ "optical system values": {
+ "dispersion [um]": 990.442138671875,
+ "deviation [deg]": -6.509076790807887,
+ "max distortion [um]": 3.740971326828003,
+ "mean distortion [um]": 0.8839882612228394,
+ "beam_compression [no units]": 0.8129552006721497
+ },
+ "current_loss": 17185.357421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 40,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.95234527182927,
+ "A2": 33.79937552291569,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.042784898812994,
+ "delta_alpha_c": 0.0,
+ "A3": 22.95234527182927
+ },
+ "optical system values": {
+ "dispersion [um]": 999.5855712890625,
+ "deviation [deg]": -4.419707409549001,
+ "max distortion [um]": 3.9143898487091064,
+ "mean distortion [um]": 0.9221357703208923,
+ "beam_compression [no units]": 0.8091400265693665
+ },
+ "current_loss": 17112.1015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 50,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.10756132071781,
+ "A2": 33.878189075748466,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.871191336955233,
+ "delta_alpha_c": 0.0,
+ "A3": 23.10756132071781
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9478759765625,
+ "deviation [deg]": 2.254613215066063,
+ "max distortion [um]": 4.756382942199707,
+ "mean distortion [um]": 1.0294955968856812,
+ "beam_compression [no units]": 0.808061420917511
+ },
+ "current_loss": 17102.693359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 60,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.026763597931144,
+ "A2": 33.80720291970452,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.892077628550309,
+ "delta_alpha_c": 0.0,
+ "A3": 23.026763597931144
+ },
+ "optical system values": {
+ "dispersion [um]": 997.6258544921875,
+ "deviation [deg]": 0.1591779454733306,
+ "max distortion [um]": 4.524998188018799,
+ "mean distortion [um]": 0.993888258934021,
+ "beam_compression [no units]": 0.8089701533317566
+ },
+ "current_loss": 17029.751953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 70,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.96069517808961,
+ "A2": 33.75170763269817,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.887905663627901,
+ "delta_alpha_c": 0.0,
+ "A3": 22.96069517808961
+ },
+ "optical system values": {
+ "dispersion [um]": 996.7281494140625,
+ "deviation [deg]": -1.671319542258617,
+ "max distortion [um]": 4.342216968536377,
+ "mean distortion [um]": 0.9648770689964294,
+ "beam_compression [no units]": 0.8096792697906494
+ },
+ "current_loss": 17007.931640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 80,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.983144302344147,
+ "A2": 33.75533104805286,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.919147802665186,
+ "delta_alpha_c": 0.0,
+ "A3": 22.983144302344147
+ },
+ "optical system values": {
+ "dispersion [um]": 996.1979370117188,
+ "deviation [deg]": -0.3484891647804501,
+ "max distortion [um]": 4.410593032836914,
+ "mean distortion [um]": 0.9824711680412292,
+ "beam_compression [no units]": 0.8096080422401428
+ },
+ "current_loss": 17013.3046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 90,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.016171682075747,
+ "A2": 33.7680317848145,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.962706053436472,
+ "delta_alpha_c": 0.0,
+ "A3": 23.016171682075747
+ },
+ "optical system values": {
+ "dispersion [um]": 995.811767578125,
+ "deviation [deg]": 1.2590418534372427,
+ "max distortion [um]": 4.4845075607299805,
+ "mean distortion [um]": 1.0110962390899658,
+ "beam_compression [no units]": 0.8094210624694824
+ },
+ "current_loss": 17033.2421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 100,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.990999019889664,
+ "A2": 33.78613861630421,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.068521051605602,
+ "delta_alpha_c": 0.0,
+ "A3": 22.990999019889664
+ },
+ "optical system values": {
+ "dispersion [um]": 997.5994262695312,
+ "deviation [deg]": -1.2456383542430332,
+ "max distortion [um]": 4.1210036277771,
+ "mean distortion [um]": 0.9684383869171143,
+ "beam_compression [no units]": 0.8092406392097473
+ },
+ "current_loss": 17065.142578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 110,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.008798492866717,
+ "A2": 33.766368633751604,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.843173047206195,
+ "delta_alpha_c": 0.0,
+ "A3": 23.008798492866717
+ },
+ "optical system values": {
+ "dispersion [um]": 995.994873046875,
+ "deviation [deg]": 0.8473510806368134,
+ "max distortion [um]": 4.635261058807373,
+ "mean distortion [um]": 1.0035594701766968,
+ "beam_compression [no units]": 0.8094462752342224
+ },
+ "current_loss": 17050.849609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 120,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.97472267909752,
+ "A2": 33.79438948482158,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.9253632748098966,
+ "delta_alpha_c": 0.0,
+ "A3": 22.97472267909752
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6153564453125,
+ "deviation [deg]": -2.705829385458857,
+ "max distortion [um]": 4.2146196365356445,
+ "mean distortion [um]": 0.9505915641784668,
+ "beam_compression [no units]": 0.809183657169342
+ },
+ "current_loss": 17038.62890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 130,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.998006793978096,
+ "A2": 33.77616654011599,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.869655825052449,
+ "delta_alpha_c": 0.0,
+ "A3": 22.998006793978096
+ },
+ "optical system values": {
+ "dispersion [um]": 996.8770751953125,
+ "deviation [deg]": -0.3206061181130631,
+ "max distortion [um]": 4.49225378036499,
+ "mean distortion [um]": 0.9854212999343872,
+ "beam_compression [no units]": 0.8093551397323608
+ },
+ "current_loss": 17022.28515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 140,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98362241558605,
+ "A2": 33.79100854118242,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.903532709562066,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98362241558605
+ },
+ "optical system values": {
+ "dispersion [um]": 998.1434936523438,
+ "deviation [deg]": -1.9587595157421411,
+ "max distortion [um]": 4.316948413848877,
+ "mean distortion [um]": 0.957931637763977,
+ "beam_compression [no units]": 0.809210479259491
+ },
+ "current_loss": 17021.0390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 150,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991996227508483,
+ "A2": 33.78198244619425,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.910397476564753,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991996227508483
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3704833984375,
+ "deviation [deg]": -0.9872554995926242,
+ "max distortion [um]": 4.37708854675293,
+ "mean distortion [um]": 0.9719693660736084,
+ "beam_compression [no units]": 0.8092995882034302
+ },
+ "current_loss": 17013.59375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 160,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98762149134509,
+ "A2": 33.784898936969846,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.917095330819596,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98762149134509
+ },
+ "optical system values": {
+ "dispersion [um]": 997.6746826171875,
+ "deviation [deg]": -1.4124474753089058,
+ "max distortion [um]": 4.3403472900390625,
+ "mean distortion [um]": 0.9691932797431946,
+ "beam_compression [no units]": 0.809272825717926
+ },
+ "current_loss": 17018.9453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 170,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98622130256524,
+ "A2": 33.787600276786584,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.893028732392233,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98622130256524
+ },
+ "optical system values": {
+ "dispersion [um]": 997.8828125,
+ "deviation [deg]": -1.6289568947571995,
+ "max distortion [um]": 4.349056243896484,
+ "mean distortion [um]": 0.9640633463859558,
+ "beam_compression [no units]": 0.8092451095581055
+ },
+ "current_loss": 17013.47265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 180,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.997916293971592,
+ "A2": 33.77751891757165,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.863493286873806,
+ "delta_alpha_c": 0.0,
+ "A3": 22.997916293971592
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9561767578125,
+ "deviation [deg]": -0.38909079741476776,
+ "max distortion [um]": 4.505630970001221,
+ "mean distortion [um]": 0.9856259822845459,
+ "beam_compression [no units]": 0.8093400597572327
+ },
+ "current_loss": 17023.80859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 190,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98726461396096,
+ "A2": 33.784806729416054,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.911369070974187,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98726461396096
+ },
+ "optical system values": {
+ "dispersion [um]": 997.68115234375,
+ "deviation [deg]": -1.4322102007855146,
+ "max distortion [um]": 4.335508823394775,
+ "mean distortion [um]": 0.9687976241111755,
+ "beam_compression [no units]": 0.8092743754386902
+ },
+ "current_loss": 17017.201171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 200,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.002707671674358,
+ "A2": 33.773137351219084,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.860239555507941,
+ "delta_alpha_c": 0.0,
+ "A3": 23.002707671674358
+ },
+ "optical system values": {
+ "dispersion [um]": 996.5634765625,
+ "deviation [deg]": 0.1312948988059436,
+ "max distortion [um]": 4.546271324157715,
+ "mean distortion [um]": 0.9914421439170837,
+ "beam_compression [no units]": 0.8093815445899963
+ },
+ "current_loss": 17032.0234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 210,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99631802970581,
+ "A2": 33.77737206850449,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.896608605290966,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99631802970581
+ },
+ "optical system values": {
+ "dispersion [um]": 996.99365234375,
+ "deviation [deg]": -0.4883935837362609,
+ "max distortion [um]": 4.439730644226074,
+ "mean distortion [um]": 0.981073796749115,
+ "beam_compression [no units]": 0.8093447089195251
+ },
+ "current_loss": 17011.23828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 220,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.988362566870038,
+ "A2": 33.78672259747824,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890034548214829,
+ "delta_alpha_c": 0.0,
+ "A3": 22.988362566870038
+ },
+ "optical system values": {
+ "dispersion [um]": 997.7513427734375,
+ "deviation [deg]": -1.4468855025475218,
+ "max distortion [um]": 4.37497615814209,
+ "mean distortion [um]": 0.9676714539527893,
+ "beam_compression [no units]": 0.8092518448829651
+ },
+ "current_loss": 17011.0625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 230,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.984173953361527,
+ "A2": 33.78795203152884,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.9214500033023025,
+ "delta_alpha_c": 0.0,
+ "A3": 22.984173953361527
+ },
+ "optical system values": {
+ "dispersion [um]": 997.95703125,
+ "deviation [deg]": -1.7818734110512664,
+ "max distortion [um]": 4.296047687530518,
+ "mean distortion [um]": 0.9621866941452026,
+ "beam_compression [no units]": 0.8092432022094727
+ },
+ "current_loss": 17024.05859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 240,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.988982406537218,
+ "A2": 33.78322212552861,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.9178522011569985,
+ "delta_alpha_c": 0.0,
+ "A3": 22.988982406537218
+ },
+ "optical system values": {
+ "dispersion [um]": 997.529052734375,
+ "deviation [deg]": -1.2452470057479326,
+ "max distortion [um]": 4.348055839538574,
+ "mean distortion [um]": 0.9751681685447693,
+ "beam_compression [no units]": 0.8092897534370422
+ },
+ "current_loss": 17017.796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 250,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.990502123627547,
+ "A2": 33.78443789920087,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.887236731976063,
+ "delta_alpha_c": 0.0,
+ "A3": 22.990502123627547
+ },
+ "optical system values": {
+ "dispersion [um]": 997.5679931640625,
+ "deviation [deg]": -1.1997536770074164,
+ "max distortion [um]": 4.392332077026367,
+ "mean distortion [um]": 0.9714061617851257,
+ "beam_compression [no units]": 0.8092742562294006
+ },
+ "current_loss": 17008.173828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 260,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991825472779237,
+ "A2": 33.78247080471991,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.893494465916263,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991825472779237
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4144287109375,
+ "deviation [deg]": -1.021400042140341,
+ "max distortion [um]": 4.401736736297607,
+ "mean distortion [um]": 0.9736135005950928,
+ "beam_compression [no units]": 0.8092944025993347
+ },
+ "current_loss": 17008.62109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 270,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99252556716916,
+ "A2": 33.78192097449172,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890992482245923,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99252556716916
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3575439453125,
+ "deviation [deg]": -0.9493933064240105,
+ "max distortion [um]": 4.416804313659668,
+ "mean distortion [um]": 0.976030707359314,
+ "beam_compression [no units]": 0.8092994689941406
+ },
+ "current_loss": 17008.779296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 280,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99161715200955,
+ "A2": 33.78265863492208,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.893185826743143,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99161715200955
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4304809570312,
+ "deviation [deg]": -1.0438042365567464,
+ "max distortion [um]": 4.399623870849609,
+ "mean distortion [um]": 0.973770260810852,
+ "beam_compression [no units]": 0.8092926144599915
+ },
+ "current_loss": 17008.625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 290,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991902312407397,
+ "A2": 33.782518616044094,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.891431321900097,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991902312407397
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4222412109375,
+ "deviation [deg]": -1.0185627388704355,
+ "max distortion [um]": 4.39841365814209,
+ "mean distortion [um]": 0.9727734327316284,
+ "beam_compression [no units]": 0.8092936873435974
+ },
+ "current_loss": 17007.91796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 300,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991880114292595,
+ "A2": 33.78253569151702,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.891451385580783,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991880114292595
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4194946289062,
+ "deviation [deg]": -1.0208129660368372,
+ "max distortion [um]": 4.3938164710998535,
+ "mean distortion [um]": 0.9739224910736084,
+ "beam_compression [no units]": 0.8092936277389526
+ },
+ "current_loss": 17007.896484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 310,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991905727501983,
+ "A2": 33.78252203113868,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.891308378495037,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991905727501983
+ },
+ "optical system values": {
+ "dispersion [um]": 997.40673828125,
+ "deviation [deg]": -1.0187584664788385,
+ "max distortion [um]": 4.404221534729004,
+ "mean distortion [um]": 0.9730973839759827,
+ "beam_compression [no units]": 0.8092934489250183
+ },
+ "current_loss": 17008.154296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 320,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99196036901534,
+ "A2": 33.782501540571175,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890913508183645,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99196036901534
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4077758789062,
+ "deviation [deg]": -1.0138666636509344,
+ "max distortion [um]": 4.407334804534912,
+ "mean distortion [um]": 0.9749488830566406,
+ "beam_compression [no units]": 0.8092939257621765
+ },
+ "current_loss": 17008.20703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 330,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99203208600163,
+ "A2": 33.78245714434156,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890387583617554,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99203208600163
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4077758789062,
+ "deviation [deg]": -1.0068224974608297,
+ "max distortion [um]": 4.405608654022217,
+ "mean distortion [um]": 0.9775387048721313,
+ "beam_compression [no units]": 0.8092942237854004
+ },
+ "current_loss": 17008.322265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 340,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991381510483183,
+ "A2": 33.782866955691766,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.892717531898175,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991381510483183
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4561767578125,
+ "deviation [deg]": -1.0687522495521584,
+ "max distortion [um]": 4.399865627288818,
+ "mean distortion [um]": 0.9734199643135071,
+ "beam_compression [no units]": 0.8092905879020691
+ },
+ "current_loss": 17008.599609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 350,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991868161461547,
+ "A2": 33.78226248395022,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.893449642799835,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991868161461547
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3936157226562,
+ "deviation [deg]": -1.0088771037405342,
+ "max distortion [um]": 4.407544136047363,
+ "mean distortion [um]": 0.97734135389328,
+ "beam_compression [no units]": 0.809296727180481
+ },
+ "current_loss": 17008.58984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 360,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.994111878603896,
+ "A2": 33.781118427264246,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.881730318844562,
+ "delta_alpha_c": 0.0,
+ "A3": 22.994111878603896
+ },
+ "optical system values": {
+ "dispersion [um]": 997.2711181640625,
+ "deviation [deg]": -0.8071407964975963,
+ "max distortion [um]": 4.426419734954834,
+ "mean distortion [um]": 0.978771448135376,
+ "beam_compression [no units]": 0.8093060255050659
+ },
+ "current_loss": 17012.98828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 370,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.988154246100354,
+ "A2": 33.78537363511716,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.897829928491929,
+ "delta_alpha_c": 0.0,
+ "A3": 22.988154246100354
+ },
+ "optical system values": {
+ "dispersion [um]": 997.67236328125,
+ "deviation [deg]": -1.3992397037230995,
+ "max distortion [um]": 4.371137619018555,
+ "mean distortion [um]": 0.9703831076622009,
+ "beam_compression [no units]": 0.8092671036720276
+ },
+ "current_loss": 17013.138671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 380,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99202696335975,
+ "A2": 33.78087937064329,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.901120372124582,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99202696335975
+ },
+ "optical system values": {
+ "dispersion [um]": 997.311279296875,
+ "deviation [deg]": -0.9346201408578019,
+ "max distortion [um]": 4.402737140655518,
+ "mean distortion [um]": 0.975534200668335,
+ "beam_compression [no units]": 0.8093118071556091
+ },
+ "current_loss": 17010.375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 390,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.988779208409408,
+ "A2": 33.784892106780674,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.900307579613351,
+ "delta_alpha_c": 0.0,
+ "A3": 22.988779208409408
+ },
+ "optical system values": {
+ "dispersion [um]": 997.6375732421875,
+ "deviation [deg]": -1.3347663464961756,
+ "max distortion [um]": 4.366717338562012,
+ "mean distortion [um]": 0.9694674015045166,
+ "beam_compression [no units]": 0.8092716336250305
+ },
+ "current_loss": 17013.11328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 400,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.999070595941326,
+ "A2": 33.77721497415358,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.869286567950446,
+ "delta_alpha_c": 0.0,
+ "A3": 22.999070595941326
+ },
+ "optical system values": {
+ "dispersion [um]": 996.8995361328125,
+ "deviation [deg]": -0.2982996807791535,
+ "max distortion [um]": 4.4988532066345215,
+ "mean distortion [um]": 0.9834317564964294,
+ "beam_compression [no units]": 0.8093419671058655
+ },
+ "current_loss": 17023.0546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 410,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991367850104844,
+ "A2": 33.78429105013372,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.875937891541569,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991367850104844
+ },
+ "optical system values": {
+ "dispersion [um]": 997.53515625,
+ "deviation [deg]": -1.1350845921720893,
+ "max distortion [um]": 4.413174629211426,
+ "mean distortion [um]": 0.9737062454223633,
+ "beam_compression [no units]": 0.8092744946479797
+ },
+ "current_loss": 17012.35546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 420,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98477501000849,
+ "A2": 33.78672601257283,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.91467445564565,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98477501000849
+ },
+ "optical system values": {
+ "dispersion [um]": 997.87451171875,
+ "deviation [deg]": -1.6852121470304229,
+ "max distortion [um]": 4.312946319580078,
+ "mean distortion [um]": 0.9648999571800232,
+ "beam_compression [no units]": 0.809256374835968
+ },
+ "current_loss": 17020.591796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 430,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99728620902066,
+ "A2": 33.777850181746395,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.871545226131604,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99728620902066
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9857788085938,
+ "deviation [deg]": -0.4460309095544171,
+ "max distortion [um]": 4.479182720184326,
+ "mean distortion [um]": 0.9821062088012695,
+ "beam_compression [no units]": 0.8093376755714417
+ },
+ "current_loss": 17020.412109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 440,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.008093275834913,
+ "A2": 33.76272131273482,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.912532764454028,
+ "delta_alpha_c": 0.0,
+ "A3": 23.008093275834913
+ },
+ "optical system values": {
+ "dispersion [um]": 995.8010864257812,
+ "deviation [deg]": 0.9679819864153175,
+ "max distortion [um]": 4.533524990081787,
+ "mean distortion [um]": 1.0034860372543335,
+ "beam_compression [no units]": 0.8094912171363831
+ },
+ "current_loss": 17030.205078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 450,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.004048096298973,
+ "A2": 33.774499973958505,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.859155262977201,
+ "delta_alpha_c": 0.0,
+ "A3": 23.004048096298973
+ },
+ "optical system values": {
+ "dispersion [um]": 996.591064453125,
+ "deviation [deg]": 0.15712340589469226,
+ "max distortion [um]": 4.5493879318237305,
+ "mean distortion [um]": 0.9968239068984985,
+ "beam_compression [no units]": 0.8093644976615906
+ },
+ "current_loss": 17033.064453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 460,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.008468936239264,
+ "A2": 33.75841829355771,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.904148707247837,
+ "delta_alpha_c": 0.0,
+ "A3": 23.008468936239264
+ },
+ "optical system values": {
+ "dispersion [um]": 995.55322265625,
+ "deviation [deg]": 1.1908506321460104,
+ "max distortion [um]": 4.562642574310303,
+ "mean distortion [um]": 1.003346562385559,
+ "beam_compression [no units]": 0.8095382452011108
+ },
+ "current_loss": 17038.15234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 470,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.002209067864946,
+ "A2": 33.78054810646855,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.872017789844804,
+ "delta_alpha_c": 0.0,
+ "A3": 23.002209067864946
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9827880859375,
+ "deviation [deg]": -0.2434140948779293,
+ "max distortion [um]": 4.510683059692383,
+ "mean distortion [um]": 0.9886239767074585,
+ "beam_compression [no units]": 0.8093006014823914
+ },
+ "current_loss": 17023.59765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 480,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.97745646231282,
+ "A2": 33.79266827715074,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.927813605174639,
+ "delta_alpha_c": 0.0,
+ "A3": 22.97745646231282
+ },
+ "optical system values": {
+ "dispersion [um]": 998.429931640625,
+ "deviation [deg]": -2.445000682755349,
+ "max distortion [um]": 4.2416672706604,
+ "mean distortion [um]": 0.9555607438087463,
+ "beam_compression [no units]": 0.8091992139816284
+ },
+ "current_loss": 17035.068359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 490,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.997984595863294,
+ "A2": 33.7778023704222,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.8709416081637045,
+ "delta_alpha_c": 0.0,
+ "A3": 22.997984595863294
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9752197265625,
+ "deviation [deg]": -0.3971132814817709,
+ "max distortion [um]": 4.475373268127441,
+ "mean distortion [um]": 0.9841933250427246,
+ "beam_compression [no units]": 0.8093372583389282
+ },
+ "current_loss": 17020.8515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 500,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99213624638647,
+ "A2": 33.76993399249835,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.965060761152834,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99213624638647
+ },
+ "optical system values": {
+ "dispersion [um]": 996.6878662109375,
+ "deviation [deg]": -0.4241157940351816,
+ "max distortion [um]": 4.344570159912109,
+ "mean distortion [um]": 0.9880271553993225,
+ "beam_compression [no units]": 0.8094317317008972
+ },
+ "current_loss": 17027.9296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 510,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.017713597280874,
+ "A2": 33.74990787785187,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.930591357732719,
+ "delta_alpha_c": 0.0,
+ "A3": 23.017713597280874
+ },
+ "optical system values": {
+ "dispersion [um]": 994.79541015625,
+ "deviation [deg]": 2.196009978543942,
+ "max distortion [um]": 4.608800888061523,
+ "mean distortion [um]": 1.0235567092895508,
+ "beam_compression [no units]": 0.8096201419830322
+ },
+ "current_loss": 17056.640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 520,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991361019915676,
+ "A2": 33.78964591844301,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.901820039627686,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991361019915676
+ },
+ "optical system values": {
+ "dispersion [um]": 997.8247680664062,
+ "deviation [deg]": -1.3828033870939926,
+ "max distortion [um]": 4.35849142074585,
+ "mean distortion [um]": 0.9714526534080505,
+ "beam_compression [no units]": 0.8092151284217834
+ },
+ "current_loss": 17014.810546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 530,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.973255895973264,
+ "A2": 33.780339785698864,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.992355477736674,
+ "delta_alpha_c": 0.0,
+ "A3": 22.973255895973264
+ },
+ "optical system values": {
+ "dispersion [um]": 997.8690185546875,
+ "deviation [deg]": -2.1563867705082287,
+ "max distortion [um]": 4.163991928100586,
+ "mean distortion [um]": 0.9575426578521729,
+ "beam_compression [no units]": 0.8093372583389282
+ },
+ "current_loss": 17048.720703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 540,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.017679446335027,
+ "A2": 33.76146114283295,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.84131096688372,
+ "delta_alpha_c": 0.0,
+ "A3": 23.017679446335027
+ },
+ "optical system values": {
+ "dispersion [um]": 995.440673828125,
+ "deviation [deg]": 1.663003573500715,
+ "max distortion [um]": 4.710352420806885,
+ "mean distortion [um]": 1.0160080194473267,
+ "beam_compression [no units]": 0.8094870448112488
+ },
+ "current_loss": 17070.94140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 550,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.01308272902361,
+ "A2": 33.78204391789678,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.7339950346444795,
+ "delta_alpha_c": 0.0,
+ "A3": 23.01308272902361
+ },
+ "optical system values": {
+ "dispersion [um]": 996.759033203125,
+ "deviation [deg]": 0.41061453775847623,
+ "max distortion [um]": 4.767378330230713,
+ "mean distortion [um]": 1.0017132759094238,
+ "beam_compression [no units]": 0.8092526197433472
+ },
+ "current_loss": 17080.537109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 560,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.982765226845213,
+ "A2": 33.80510263653474,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.815103531038381,
+ "delta_alpha_c": 0.0,
+ "A3": 22.982765226845213
+ },
+ "optical system values": {
+ "dispersion [um]": 998.978515625,
+ "deviation [deg]": -2.6640538140609435,
+ "max distortion [um]": 4.382993221282959,
+ "mean distortion [um]": 0.9522976279258728,
+ "beam_compression [no units]": 0.8090535402297974
+ },
+ "current_loss": 17033.701171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 570,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.040560580054567,
+ "A2": 33.737282273171104,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.917665651615293,
+ "delta_alpha_c": 0.0,
+ "A3": 23.040560580054567
+ },
+ "optical system values": {
+ "dispersion [um]": 993.356689453125,
+ "deviation [deg]": 4.294967237850234,
+ "max distortion [um]": 4.812969207763672,
+ "mean distortion [um]": 1.055098056793213,
+ "beam_compression [no units]": 0.809725821018219
+ },
+ "current_loss": 17139.921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 580,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.983560943883518,
+ "A2": 33.769998879295464,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.941587108522793,
+ "delta_alpha_c": 0.0,
+ "A3": 22.983560943883518
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9824829101562,
+ "deviation [deg]": -0.9958649530414252,
+ "max distortion [um]": 4.322556018829346,
+ "mean distortion [um]": 0.9745326042175293,
+ "beam_compression [no units]": 0.8094435334205627
+ },
+ "current_loss": 17022.048828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 590,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.9714937071674,
+ "A2": 33.80292039109492,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.986993779238214,
+ "delta_alpha_c": 0.0,
+ "A3": 22.9714937071674
+ },
+ "optical system values": {
+ "dispersion [um]": 999.169189453125,
+ "deviation [deg]": -3.3125057840030188,
+ "max distortion [um]": 4.08272123336792,
+ "mean distortion [um]": 0.941062331199646,
+ "beam_compression [no units]": 0.809086799621582
+ },
+ "current_loss": 17071.3125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 600,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.995221784344025,
+ "A2": 33.76943538868894,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.973035433895647,
+ "delta_alpha_c": 0.0,
+ "A3": 22.995221784344025
+ },
+ "optical system values": {
+ "dispersion [um]": 996.5676879882812,
+ "deviation [deg]": -0.1961596712290341,
+ "max distortion [um]": 4.349650859832764,
+ "mean distortion [um]": 0.9856070280075073,
+ "beam_compression [no units]": 0.809432864189148
+ },
+ "current_loss": 17030.15625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 610,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.015399870699532,
+ "A2": 33.755990161307764,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.837454471323602,
+ "delta_alpha_c": 0.0,
+ "A3": 23.015399870699532
+ },
+ "optical system values": {
+ "dispersion [um]": 995.2217407226562,
+ "deviation [deg]": 1.7633824881424554,
+ "max distortion [um]": 4.718347072601318,
+ "mean distortion [um]": 1.0203526020050049,
+ "beam_compression [no units]": 0.8095504641532898
+ },
+ "current_loss": 17074.810546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 620,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.002263709378308,
+ "A2": 33.78202001223469,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.875773967001488,
+ "delta_alpha_c": 0.0,
+ "A3": 23.002263709378308
+ },
+ "optical system values": {
+ "dispersion [um]": 997.053955078125,
+ "deviation [deg]": -0.3074961836510319,
+ "max distortion [um]": 4.495884895324707,
+ "mean distortion [um]": 0.9885810613632202,
+ "beam_compression [no units]": 0.8092844486236572
+ },
+ "current_loss": 17021.703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 630,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.976264594302652,
+ "A2": 33.795547201885896,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.887499267372285,
+ "delta_alpha_c": 0.0,
+ "A3": 22.976264594302652
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6209716796875,
+ "deviation [deg]": -2.65603132999394,
+ "max distortion [um]": 4.281635761260986,
+ "mean distortion [um]": 0.9483039379119873,
+ "beam_compression [no units]": 0.8091700077056885
+ },
+ "current_loss": 17026.5703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 640,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991601784083915,
+ "A2": 33.790899258155704,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.841607653225792,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991601784083915
+ },
+ "optical system values": {
+ "dispersion [um]": 997.89501953125,
+ "deviation [deg]": -1.4236985044192094,
+ "max distortion [um]": 4.44611930847168,
+ "mean distortion [um]": 0.9702924489974976,
+ "beam_compression [no units]": 0.8091996908187866
+ },
+ "current_loss": 17023.501953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 650,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.990240868891792,
+ "A2": 33.79266144696157,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.862014124031675,
+ "delta_alpha_c": 0.0,
+ "A3": 22.990240868891792
+ },
+ "optical system values": {
+ "dispersion [um]": 998.024169921875,
+ "deviation [deg]": -1.595301564508785,
+ "max distortion [um]": 4.412513256072998,
+ "mean distortion [um]": 0.9678369164466858,
+ "beam_compression [no units]": 0.8091828227043152
+ },
+ "current_loss": 17016.203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 660,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.96448934817355,
+ "A2": 33.83514180850446,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.736630633890458,
+ "delta_alpha_c": 0.0,
+ "A3": 22.96448934817355
+ },
+ "optical system values": {
+ "dispersion [um]": 1001.22998046875,
+ "deviation [deg]": -5.259818543026453,
+ "max distortion [um]": 4.289400100708008,
+ "mean distortion [um]": 0.9149852991104126,
+ "beam_compression [no units]": 0.8087413311004639
+ },
+ "current_loss": 17101.203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 670,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.9717669147342,
+ "A2": 33.84301701661749,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.729068760705608,
+ "delta_alpha_c": 0.0,
+ "A3": 22.9717669147342
+ },
+ "optical system values": {
+ "dispersion [um]": 1001.4285888671875,
+ "deviation [deg]": -5.138600614505298,
+ "max distortion [um]": 4.318873882293701,
+ "mean distortion [um]": 0.9169857501983643,
+ "beam_compression [no units]": 0.808642566204071
+ },
+ "current_loss": 17107.72265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 680,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98814570836389,
+ "A2": 33.80452207045529,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.758717331232164,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98814570836389
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7904663085938,
+ "deviation [deg]": -2.280148304164979,
+ "max distortion [um]": 4.494591236114502,
+ "mean distortion [um]": 0.9576850533485413,
+ "beam_compression [no units]": 0.8090474009513855
+ },
+ "current_loss": 17052.5625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 690,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.968385971095042,
+ "A2": 33.80011318334605,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.943961453033018,
+ "delta_alpha_c": 0.0,
+ "A3": 22.968385971095042
+ },
+ "optical system values": {
+ "dispersion [um]": 999.1119995117188,
+ "deviation [deg]": -3.3893065654647576,
+ "max distortion [um]": 4.139716625213623,
+ "mean distortion [um]": 0.9376972913742065,
+ "beam_compression [no units]": 0.8091264367103577
+ },
+ "current_loss": 17058.453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 700,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.023100908988724,
+ "A2": 33.75348689697696,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.93623053266621,
+ "delta_alpha_c": 0.0,
+ "A3": 23.023100908988724
+ },
+ "optical system values": {
+ "dispersion [um]": 994.8021240234375,
+ "deviation [deg]": 2.388843294286327,
+ "max distortion [um]": 4.6235432624816895,
+ "mean distortion [um]": 1.026623010635376,
+ "beam_compression [no units]": 0.8095728754997253
+ },
+ "current_loss": 17060.716796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 710,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 23.03295687196105,
+ "A2": 33.75193302894078,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.8145186960906985,
+ "delta_alpha_c": 0.0,
+ "A3": 23.03295687196105
+ },
+ "optical system values": {
+ "dispersion [um]": 994.44677734375,
+ "deviation [deg]": 3.115954924361443,
+ "max distortion [um]": 4.867802619934082,
+ "mean distortion [um]": 1.0400309562683105,
+ "beam_compression [no units]": 0.8095647692680359
+ },
+ "current_loss": 17124.908203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 720,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.983318472167984,
+ "A2": 33.76850648296182,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.952439425340296,
+ "delta_alpha_c": 0.0,
+ "A3": 22.983318472167984
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9027099609375,
+ "deviation [deg]": -0.9433274581108045,
+ "max distortion [um]": 4.313429832458496,
+ "mean distortion [um]": 0.9740102887153625,
+ "beam_compression [no units]": 0.8094600439071655
+ },
+ "current_loss": 17025.12890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 730,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.997323775061094,
+ "A2": 33.76413857698759,
+ "delta_beta_c": 0.0,
+ "alpha_c": 6.0193189301457695,
+ "delta_alpha_c": 0.0,
+ "A3": 22.997323775061094
+ },
+ "optical system values": {
+ "dispersion [um]": 996.1909790039062,
+ "deviation [deg]": 0.1869631550169425,
+ "max distortion [um]": 4.3116374015808105,
+ "mean distortion [um]": 0.9883836507797241,
+ "beam_compression [no units]": 0.809485912322998
+ },
+ "current_loss": 17045.3046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 740,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.987778585696002,
+ "A2": 33.77952016299846,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.976783927089515,
+ "delta_alpha_c": 0.0,
+ "A3": 22.987778585696002
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3619384765625,
+ "deviation [deg]": -1.1548473176486982,
+ "max distortion [um]": 4.25973653793335,
+ "mean distortion [um]": 0.9717413783073425,
+ "beam_compression [no units]": 0.809329628944397
+ },
+ "current_loss": 17034.857421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 750,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.980485651209722,
+ "A2": 33.779479181863444,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.979544604174669,
+ "delta_alpha_c": 0.0,
+ "A3": 22.980485651209722
+ },
+ "optical system values": {
+ "dispersion [um]": 997.597900390625,
+ "deviation [deg]": -1.636588030329102,
+ "max distortion [um]": 4.215176105499268,
+ "mean distortion [um]": 0.967353105545044,
+ "beam_compression [no units]": 0.8093390464782715
+ },
+ "current_loss": 17039.056640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 760,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.989656887717757,
+ "A2": 33.773813539946914,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.969948615277624,
+ "delta_alpha_c": 0.0,
+ "A3": 22.989656887717757
+ },
+ "optical system values": {
+ "dispersion [um]": 996.989013671875,
+ "deviation [deg]": -0.7673218608534798,
+ "max distortion [um]": 4.3100433349609375,
+ "mean distortion [um]": 0.9786861538887024,
+ "beam_compression [no units]": 0.809391438961029
+ },
+ "current_loss": 17030.4140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 770,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99961701107493,
+ "A2": 33.76768003007224,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.942715370396314,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99961701107493
+ },
+ "optical system values": {
+ "dispersion [um]": 996.3318481445312,
+ "deviation [deg]": 0.17688613137130105,
+ "max distortion [um]": 4.4306793212890625,
+ "mean distortion [um]": 0.9902316927909851,
+ "beam_compression [no units]": 0.8094478845596313
+ },
+ "current_loss": 17021.244140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 780,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.973640094114074,
+ "A2": 33.80154069288258,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.88436976007195,
+ "delta_alpha_c": 0.0,
+ "A3": 22.973640094114074
+ },
+ "optical system values": {
+ "dispersion [um]": 999.0430908203125,
+ "deviation [deg]": -3.1062690757881297,
+ "max distortion [um]": 4.251648426055908,
+ "mean distortion [um]": 0.9445837140083313,
+ "beam_compression [no units]": 0.8091067671775818
+ },
+ "current_loss": 17034.978515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 790,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.98712117998839,
+ "A2": 33.78712557863927,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.896521520379048,
+ "delta_alpha_c": 0.0,
+ "A3": 22.98712117998839
+ },
+ "optical system values": {
+ "dispersion [um]": 997.8223876953125,
+ "deviation [deg]": -1.5478514932927658,
+ "max distortion [um]": 4.355313301086426,
+ "mean distortion [um]": 0.9648458361625671,
+ "beam_compression [no units]": 0.8092490434646606
+ },
+ "current_loss": 17013.9140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 800,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.988687000855613,
+ "A2": 33.78260399340872,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.924336612000279,
+ "delta_alpha_c": 0.0,
+ "A3": 22.988687000855613
+ },
+ "optical system values": {
+ "dispersion [um]": 997.515380859375,
+ "deviation [deg]": -1.2359527191131319,
+ "max distortion [um]": 4.329219341278076,
+ "mean distortion [um]": 0.9703884124755859,
+ "beam_compression [no units]": 0.8092968463897705
+ },
+ "current_loss": 17019.43359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 810,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99719741656145,
+ "A2": 33.77950308752553,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.878178620476156,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99719741656145
+ },
+ "optical system values": {
+ "dispersion [um]": 997.073974609375,
+ "deviation [deg]": -0.5282125193803774,
+ "max distortion [um]": 4.468354225158691,
+ "mean distortion [um]": 0.9840258955955505,
+ "beam_compression [no units]": 0.8093195557594299
+ },
+ "current_loss": 17017.45703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 820,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.989545897143742,
+ "A2": 33.7823581065986,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.9043215964112035,
+ "delta_alpha_c": 0.0,
+ "A3": 22.989545897143742
+ },
+ "optical system values": {
+ "dispersion [um]": 997.46728515625,
+ "deviation [deg]": -1.1677614978218998,
+ "max distortion [um]": 4.371314525604248,
+ "mean distortion [um]": 0.9712873101234436,
+ "beam_compression [no units]": 0.8092986941337585
+ },
+ "current_loss": 17012.880859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 830,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99463951071728,
+ "A2": 33.78028855928009,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.882260085392062,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99463951071728
+ },
+ "optical system values": {
+ "dispersion [um]": 997.20751953125,
+ "deviation [deg]": -0.7340578791001656,
+ "max distortion [um]": 4.434680461883545,
+ "mean distortion [um]": 0.978645920753479,
+ "beam_compression [no units]": 0.8093146085739136
+ },
+ "current_loss": 17013.515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 840,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99192280297491,
+ "A2": 33.78264497454374,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.888496048104283,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99192280297491
+ },
+ "optical system values": {
+ "dispersion [um]": 997.420166015625,
+ "deviation [deg]": -1.0227697085123402,
+ "max distortion [um]": 4.40902853012085,
+ "mean distortion [um]": 0.9734587073326111,
+ "beam_compression [no units]": 0.8092923164367676
+ },
+ "current_loss": 17009.03125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 850,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.9868223592122,
+ "A2": 33.78645280500602,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.900064681010993,
+ "delta_alpha_c": 0.0,
+ "A3": 22.9868223592122
+ },
+ "optical system values": {
+ "dispersion [um]": 997.791015625,
+ "deviation [deg]": -1.5365026003782607,
+ "max distortion [um]": 4.3405561447143555,
+ "mean distortion [um]": 0.9664195775985718,
+ "beam_compression [no units]": 0.809256911277771
+ },
+ "current_loss": 17014.734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 860,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.992317246399477,
+ "A2": 33.78074618195448,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.898607289396841,
+ "delta_alpha_c": 0.0,
+ "A3": 22.992317246399477
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3131103515625,
+ "deviation [deg]": -0.9093786431714908,
+ "max distortion [um]": 4.401559352874756,
+ "mean distortion [um]": 0.9783271551132202,
+ "beam_compression [no units]": 0.8093129992485046
+ },
+ "current_loss": 17009.25
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 870,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.992228453940264,
+ "A2": 33.78246055943615,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.888855913696179,
+ "delta_alpha_c": 0.0,
+ "A3": 22.992228453940264
+ },
+ "optical system values": {
+ "dispersion [um]": 997.411865234375,
+ "deviation [deg]": -0.9942018019785271,
+ "max distortion [um]": 4.411722660064697,
+ "mean distortion [um]": 0.976618230342865,
+ "beam_compression [no units]": 0.8092938661575317
+ },
+ "current_loss": 17008.9609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 880,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99133711425358,
+ "A2": 33.78328701232572,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.889725909041709,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99133711425358
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4713745117188,
+ "deviation [deg]": -1.0917435200720678,
+ "max distortion [um]": 4.405640602111816,
+ "mean distortion [um]": 0.9747766852378845,
+ "beam_compression [no units]": 0.8092859983444214
+ },
+ "current_loss": 17008.181640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 890,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991354189726504,
+ "A2": 33.783109427407304,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890608710991933,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991354189726504
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4685668945312,
+ "deviation [deg]": -1.081960021137965,
+ "max distortion [um]": 4.407576560974121,
+ "mean distortion [um]": 0.9749071002006531,
+ "beam_compression [no units]": 0.8092879056930542
+ },
+ "current_loss": 17008.15625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 900,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.991516406719292,
+ "A2": 33.78296257834015,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890389291164847,
+ "delta_alpha_c": 0.0,
+ "A3": 22.991516406719292
+ },
+ "optical system values": {
+ "dispersion [um]": 997.451904296875,
+ "deviation [deg]": -1.0643496590235564,
+ "max distortion [um]": 4.399800777435303,
+ "mean distortion [um]": 0.972686767578125,
+ "beam_compression [no units]": 0.8092893362045288
+ },
+ "current_loss": 17007.962890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 910,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99160349163121,
+ "A2": 33.78288061607011,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890320562386323,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99160349163121
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4356689453125,
+ "deviation [deg]": -1.0548596447803527,
+ "max distortion [um]": 4.40615701675415,
+ "mean distortion [um]": 0.9752267003059387,
+ "beam_compression [no units]": 0.8092900514602661
+ },
+ "current_loss": 17008.18359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 920,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.99195695392076,
+ "A2": 33.782491295287414,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890259517570616,
+ "delta_alpha_c": 0.0,
+ "A3": 22.99195695392076
+ },
+ "optical system values": {
+ "dispersion [um]": 997.424560546875,
+ "deviation [deg]": -1.0136710427642368,
+ "max distortion [um]": 4.3933000564575195,
+ "mean distortion [um]": 0.9728338718414307,
+ "beam_compression [no units]": 0.8092939853668213
+ },
+ "current_loss": 17008.240234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 930,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.992050869021845,
+ "A2": 33.782245408477294,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.890941255827149,
+ "delta_alpha_c": 0.0,
+ "A3": 22.992050869021845
+ },
+ "optical system values": {
+ "dispersion [um]": 997.3931274414062,
+ "deviation [deg]": -0.9957671959589294,
+ "max distortion [um]": 4.409722328186035,
+ "mean distortion [um]": 0.9767735600471497,
+ "beam_compression [no units]": 0.8092964887619019
+ },
+ "current_loss": 17008.322265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 940,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 22.990923887808794,
+ "A2": 33.78312991797481,
+ "delta_beta_c": 0.0,
+ "alpha_c": 5.892854562568398,
+ "delta_alpha_c": 0.0,
+ "A3": 22.990923887808794
+ },
+ "optical system values": {
+ "dispersion [um]": 997.4718017578125,
+ "deviation [deg]": -1.1114083817444749,
+ "max distortion [um]": 4.3903961181640625,
+ "mean distortion [um]": 0.9715368747711182,
+ "beam_compression [no units]": 0.8092882633209229
+ },
+ "current_loss": 17009.068359375
+ }
+]
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_0.json b/outputs/amici/optimization_results/step2/score_details_iteration_0.json
new file mode 100755
index 0000000..9bd75b6
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_0.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2668.74658203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 91.30223846435547,
+ "cost_distorsion": 26.572046279907227,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.129836082458496,
+ "cost_non_linearity": 687.5110473632812,
+ "cost_distance_total_intern_reflection": 13572.8828125
+ },
+ "weighted components": {
+ "cost_dispersion": 5337.4931640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 91.30223846435547,
+ "cost_distorsion": 26.572046279907227,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.129836082458496,
+ "cost_non_linearity": 687.5110473632812,
+ "cost_distance_total_intern_reflection": 13572.8828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2668.74658203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 91.30223846435547,
+ "cost_distorsion": 26.572046279907227,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.129836082458496,
+ "cost_non_linearity": 687.5110473632812,
+ "cost_distance_total_intern_reflection": 13572.8828125
+ },
+ "weighted components": {
+ "cost_dispersion": 5337.4931640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 91.30223846435547,
+ "cost_distorsion": 26.572046279907227,
+ "cost_thickness": 3728.5712890625,
+ "cost_beam_compression": 2.129836082458496,
+ "cost_non_linearity": 687.5110473632812,
+ "cost_distance_total_intern_reflection": 13572.8828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_10.json b/outputs/amici/optimization_results/step2/score_details_iteration_10.json
new file mode 100755
index 0000000..c62455c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_10.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.1917877197265625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 939.3524169921875,
+ "cost_distorsion": 31.75149154663086,
+ "cost_thickness": 3464.943115234375,
+ "cost_beam_compression": 1.954609751701355,
+ "cost_non_linearity": 618.0802612304688,
+ "cost_distance_total_intern_reflection": 13129.033203125
+ },
+ "weighted components": {
+ "cost_dispersion": 4.383575439453125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 939.3524169921875,
+ "cost_distorsion": 31.75149154663086,
+ "cost_thickness": 3464.943115234375,
+ "cost_beam_compression": 1.954609751701355,
+ "cost_non_linearity": 618.0802612304688,
+ "cost_distance_total_intern_reflection": 13129.033203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.1917877197265625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 939.3524169921875,
+ "cost_distorsion": 31.75149154663086,
+ "cost_thickness": 3464.943115234375,
+ "cost_beam_compression": 1.954609751701355,
+ "cost_non_linearity": 618.0802612304688,
+ "cost_distance_total_intern_reflection": 13129.033203125
+ },
+ "weighted components": {
+ "cost_dispersion": 4.383575439453125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 939.3524169921875,
+ "cost_distorsion": 31.75149154663086,
+ "cost_thickness": 3464.943115234375,
+ "cost_beam_compression": 1.954609751701355,
+ "cost_non_linearity": 618.0802612304688,
+ "cost_distance_total_intern_reflection": 13129.033203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_100.json b/outputs/amici/optimization_results/step2/score_details_iteration_100.json
new file mode 100755
index 0000000..77823fd
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_100.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.762754440307617,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5994279384613037,
+ "cost_distorsion": 16.9826717376709,
+ "cost_thickness": 3348.77392578125,
+ "cost_beam_compression": 1.9075936079025269,
+ "cost_non_linearity": 619.5450439453125,
+ "cost_distance_total_intern_reflection": 13062.8076171875
+ },
+ "weighted components": {
+ "cost_dispersion": 11.525508880615234,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5994279384613037,
+ "cost_distorsion": 16.9826717376709,
+ "cost_thickness": 3348.77392578125,
+ "cost_beam_compression": 1.9075936079025269,
+ "cost_non_linearity": 619.5450439453125,
+ "cost_distance_total_intern_reflection": 13062.8076171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.762754440307617,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5994279384613037,
+ "cost_distorsion": 16.9826717376709,
+ "cost_thickness": 3348.77392578125,
+ "cost_beam_compression": 1.9075936079025269,
+ "cost_non_linearity": 619.5450439453125,
+ "cost_distance_total_intern_reflection": 13062.8076171875
+ },
+ "weighted components": {
+ "cost_dispersion": 11.525508880615234,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5994279384613037,
+ "cost_distorsion": 16.9826717376709,
+ "cost_thickness": 3348.77392578125,
+ "cost_beam_compression": 1.9075936079025269,
+ "cost_non_linearity": 619.5450439453125,
+ "cost_distance_total_intern_reflection": 13062.8076171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_110.json b/outputs/amici/optimization_results/step2/score_details_iteration_110.json
new file mode 100755
index 0000000..1df7312
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_110.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 16.04104232788086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.6656213998794556,
+ "cost_distorsion": 21.485645294189453,
+ "cost_thickness": 3349.23388671875,
+ "cost_beam_compression": 1.9055372476577759,
+ "cost_non_linearity": 617.2265625,
+ "cost_distance_total_intern_reflection": 13027.25
+ },
+ "weighted components": {
+ "cost_dispersion": 32.08208465576172,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.6656213998794556,
+ "cost_distorsion": 21.485645294189453,
+ "cost_thickness": 3349.23388671875,
+ "cost_beam_compression": 1.9055372476577759,
+ "cost_non_linearity": 617.2265625,
+ "cost_distance_total_intern_reflection": 13027.25
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 16.04104232788086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.6656213998794556,
+ "cost_distorsion": 21.485645294189453,
+ "cost_thickness": 3349.23388671875,
+ "cost_beam_compression": 1.9055372476577759,
+ "cost_non_linearity": 617.2265625,
+ "cost_distance_total_intern_reflection": 13027.25
+ },
+ "weighted components": {
+ "cost_dispersion": 32.08208465576172,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.6656213998794556,
+ "cost_distorsion": 21.485645294189453,
+ "cost_thickness": 3349.23388671875,
+ "cost_beam_compression": 1.9055372476577759,
+ "cost_non_linearity": 617.2265625,
+ "cost_distance_total_intern_reflection": 13027.25
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_120.json b/outputs/amici/optimization_results/step2/score_details_iteration_120.json
new file mode 100755
index 0000000..ac877b4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_120.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.9172377586364746,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.984403610229492,
+ "cost_distorsion": 17.763019561767578,
+ "cost_thickness": 3347.343994140625,
+ "cost_beam_compression": 1.9081634283065796,
+ "cost_non_linearity": 621.0339965820312,
+ "cost_distance_total_intern_reflection": 13029.76171875
+ },
+ "weighted components": {
+ "cost_dispersion": 3.834475517272949,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.984403610229492,
+ "cost_distorsion": 17.763019561767578,
+ "cost_thickness": 3347.343994140625,
+ "cost_beam_compression": 1.9081634283065796,
+ "cost_non_linearity": 621.0339965820312,
+ "cost_distance_total_intern_reflection": 13029.76171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.9172377586364746,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.984403610229492,
+ "cost_distorsion": 17.763019561767578,
+ "cost_thickness": 3347.343994140625,
+ "cost_beam_compression": 1.9081634283065796,
+ "cost_non_linearity": 621.0339965820312,
+ "cost_distance_total_intern_reflection": 13029.76171875
+ },
+ "weighted components": {
+ "cost_dispersion": 3.834475517272949,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.984403610229492,
+ "cost_distorsion": 17.763019561767578,
+ "cost_thickness": 3347.343994140625,
+ "cost_beam_compression": 1.9081634283065796,
+ "cost_non_linearity": 621.0339965820312,
+ "cost_distance_total_intern_reflection": 13029.76171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_130.json b/outputs/amici/optimization_results/step2/score_details_iteration_130.json
new file mode 100755
index 0000000..7924e74
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_130.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.752659797668457,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.23844768106937408,
+ "cost_distorsion": 20.180343627929688,
+ "cost_thickness": 3348.7294921875,
+ "cost_beam_compression": 1.9064486026763916,
+ "cost_non_linearity": 618.515625,
+ "cost_distance_total_intern_reflection": 13013.2099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 19.505319595336914,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.23844768106937408,
+ "cost_distorsion": 20.180343627929688,
+ "cost_thickness": 3348.7294921875,
+ "cost_beam_compression": 1.9064486026763916,
+ "cost_non_linearity": 618.515625,
+ "cost_distance_total_intern_reflection": 13013.2099609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.752659797668457,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.23844768106937408,
+ "cost_distorsion": 20.180343627929688,
+ "cost_thickness": 3348.7294921875,
+ "cost_beam_compression": 1.9064486026763916,
+ "cost_non_linearity": 618.515625,
+ "cost_distance_total_intern_reflection": 13013.2099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 19.505319595336914,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.23844768106937408,
+ "cost_distorsion": 20.180343627929688,
+ "cost_thickness": 3348.7294921875,
+ "cost_beam_compression": 1.9064486026763916,
+ "cost_non_linearity": 618.515625,
+ "cost_distance_total_intern_reflection": 13013.2099609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_140.json b/outputs/amici/optimization_results/step2/score_details_iteration_140.json
new file mode 100755
index 0000000..95632b8
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_140.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.4466159343719482,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8.900445938110352,
+ "cost_distorsion": 18.636043548583984,
+ "cost_thickness": 3348.242431640625,
+ "cost_beam_compression": 1.9078952074050903,
+ "cost_non_linearity": 620.2941284179688,
+ "cost_distance_total_intern_reflection": 13016.1640625
+ },
+ "weighted components": {
+ "cost_dispersion": 6.8932318687438965,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8.900445938110352,
+ "cost_distorsion": 18.636043548583984,
+ "cost_thickness": 3348.242431640625,
+ "cost_beam_compression": 1.9078952074050903,
+ "cost_non_linearity": 620.2941284179688,
+ "cost_distance_total_intern_reflection": 13016.1640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.4466159343719482,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8.900445938110352,
+ "cost_distorsion": 18.636043548583984,
+ "cost_thickness": 3348.242431640625,
+ "cost_beam_compression": 1.9078952074050903,
+ "cost_non_linearity": 620.2941284179688,
+ "cost_distance_total_intern_reflection": 13016.1640625
+ },
+ "weighted components": {
+ "cost_dispersion": 6.8932318687438965,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8.900445938110352,
+ "cost_distorsion": 18.636043548583984,
+ "cost_thickness": 3348.242431640625,
+ "cost_beam_compression": 1.9078952074050903,
+ "cost_non_linearity": 620.2941284179688,
+ "cost_distance_total_intern_reflection": 13016.1640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_150.json b/outputs/amici/optimization_results/step2/score_details_iteration_150.json
new file mode 100755
index 0000000..e3d9689
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_150.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.914357662200928,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.2610421180725098,
+ "cost_distorsion": 19.158905029296875,
+ "cost_thickness": 3348.48583984375,
+ "cost_beam_compression": 1.9070041179656982,
+ "cost_non_linearity": 619.1631469726562,
+ "cost_distance_total_intern_reflection": 13008.7890625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.828715324401855,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.2610421180725098,
+ "cost_distorsion": 19.158905029296875,
+ "cost_thickness": 3348.48583984375,
+ "cost_beam_compression": 1.9070041179656982,
+ "cost_non_linearity": 619.1631469726562,
+ "cost_distance_total_intern_reflection": 13008.7890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.914357662200928,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.2610421180725098,
+ "cost_distorsion": 19.158905029296875,
+ "cost_thickness": 3348.48583984375,
+ "cost_beam_compression": 1.9070041179656982,
+ "cost_non_linearity": 619.1631469726562,
+ "cost_distance_total_intern_reflection": 13008.7890625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.828715324401855,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.2610421180725098,
+ "cost_distorsion": 19.158905029296875,
+ "cost_thickness": 3348.48583984375,
+ "cost_beam_compression": 1.9070041179656982,
+ "cost_non_linearity": 619.1631469726562,
+ "cost_distance_total_intern_reflection": 13008.7890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_160.json b/outputs/amici/optimization_results/step2/score_details_iteration_160.json
new file mode 100755
index 0000000..6ddcf1d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_160.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.407101154327393,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.6280083656311035,
+ "cost_distorsion": 18.83861541748047,
+ "cost_thickness": 3348.173095703125,
+ "cost_beam_compression": 1.9072717428207397,
+ "cost_non_linearity": 619.695556640625,
+ "cost_distance_total_intern_reflection": 13014.888671875
+ },
+ "weighted components": {
+ "cost_dispersion": 10.814202308654785,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.6280083656311035,
+ "cost_distorsion": 18.83861541748047,
+ "cost_thickness": 3348.173095703125,
+ "cost_beam_compression": 1.9072717428207397,
+ "cost_non_linearity": 619.695556640625,
+ "cost_distance_total_intern_reflection": 13014.888671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.407101154327393,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.6280083656311035,
+ "cost_distorsion": 18.83861541748047,
+ "cost_thickness": 3348.173095703125,
+ "cost_beam_compression": 1.9072717428207397,
+ "cost_non_linearity": 619.695556640625,
+ "cost_distance_total_intern_reflection": 13014.888671875
+ },
+ "weighted components": {
+ "cost_dispersion": 10.814202308654785,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.6280083656311035,
+ "cost_distorsion": 18.83861541748047,
+ "cost_thickness": 3348.173095703125,
+ "cost_beam_compression": 1.9072717428207397,
+ "cost_non_linearity": 619.695556640625,
+ "cost_distance_total_intern_reflection": 13014.888671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_170.json b/outputs/amici/optimization_results/step2/score_details_iteration_170.json
new file mode 100755
index 0000000..cf5e3f9
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_170.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.48248291015625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.155576229095459,
+ "cost_distorsion": 18.914289474487305,
+ "cost_thickness": 3348.255126953125,
+ "cost_beam_compression": 1.9075489044189453,
+ "cost_non_linearity": 619.8148193359375,
+ "cost_distance_total_intern_reflection": 13009.4609375
+ },
+ "weighted components": {
+ "cost_dispersion": 8.9649658203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.155576229095459,
+ "cost_distorsion": 18.914289474487305,
+ "cost_thickness": 3348.255126953125,
+ "cost_beam_compression": 1.9075489044189453,
+ "cost_non_linearity": 619.8148193359375,
+ "cost_distance_total_intern_reflection": 13009.4609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.48248291015625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.155576229095459,
+ "cost_distorsion": 18.914289474487305,
+ "cost_thickness": 3348.255126953125,
+ "cost_beam_compression": 1.9075489044189453,
+ "cost_non_linearity": 619.8148193359375,
+ "cost_distance_total_intern_reflection": 13009.4609375
+ },
+ "weighted components": {
+ "cost_dispersion": 8.9649658203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.155576229095459,
+ "cost_distorsion": 18.914289474487305,
+ "cost_thickness": 3348.255126953125,
+ "cost_beam_compression": 1.9075489044189453,
+ "cost_non_linearity": 619.8148193359375,
+ "cost_distance_total_intern_reflection": 13009.4609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_180.json b/outputs/amici/optimization_results/step2/score_details_iteration_180.json
new file mode 100755
index 0000000..80829d1
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_180.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.264860153198242,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3511974811553955,
+ "cost_distorsion": 20.300710678100586,
+ "cost_thickness": 3348.85595703125,
+ "cost_beam_compression": 1.9065994024276733,
+ "cost_non_linearity": 618.7160034179688,
+ "cost_distance_total_intern_reflection": 13015.1474609375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.529720306396484,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3511974811553955,
+ "cost_distorsion": 20.300710678100586,
+ "cost_thickness": 3348.85595703125,
+ "cost_beam_compression": 1.9065994024276733,
+ "cost_non_linearity": 618.7160034179688,
+ "cost_distance_total_intern_reflection": 13015.1474609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.264860153198242,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3511974811553955,
+ "cost_distorsion": 20.300710678100586,
+ "cost_thickness": 3348.85595703125,
+ "cost_beam_compression": 1.9065994024276733,
+ "cost_non_linearity": 618.7160034179688,
+ "cost_distance_total_intern_reflection": 13015.1474609375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.529720306396484,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3511974811553955,
+ "cost_distorsion": 20.300710678100586,
+ "cost_thickness": 3348.85595703125,
+ "cost_beam_compression": 1.9065994024276733,
+ "cost_non_linearity": 618.7160034179688,
+ "cost_distance_total_intern_reflection": 13015.1474609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_190.json b/outputs/amici/optimization_results/step2/score_details_iteration_190.json
new file mode 100755
index 0000000..db30ca6
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_190.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.377054214477539,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.7584228515625,
+ "cost_distorsion": 18.7966365814209,
+ "cost_thickness": 3348.113525390625,
+ "cost_beam_compression": 1.9072562456130981,
+ "cost_non_linearity": 619.6880493164062,
+ "cost_distance_total_intern_reflection": 13013.1826171875
+ },
+ "weighted components": {
+ "cost_dispersion": 10.754108428955078,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.7584228515625,
+ "cost_distorsion": 18.7966365814209,
+ "cost_thickness": 3348.113525390625,
+ "cost_beam_compression": 1.9072562456130981,
+ "cost_non_linearity": 619.6880493164062,
+ "cost_distance_total_intern_reflection": 13013.1826171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.377054214477539,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.7584228515625,
+ "cost_distorsion": 18.7966365814209,
+ "cost_thickness": 3348.113525390625,
+ "cost_beam_compression": 1.9072562456130981,
+ "cost_non_linearity": 619.6880493164062,
+ "cost_distance_total_intern_reflection": 13013.1826171875
+ },
+ "weighted components": {
+ "cost_dispersion": 10.754108428955078,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.7584228515625,
+ "cost_distorsion": 18.7966365814209,
+ "cost_thickness": 3348.113525390625,
+ "cost_beam_compression": 1.9072562456130981,
+ "cost_non_linearity": 619.6880493164062,
+ "cost_distance_total_intern_reflection": 13013.1826171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_20.json b/outputs/amici/optimization_results/step2/score_details_iteration_20.json
new file mode 100755
index 0000000..91c2cce
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_20.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.62158203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.621985912322998,
+ "cost_distorsion": 25.86330223083496,
+ "cost_thickness": 3283.898193359375,
+ "cost_beam_compression": 1.869853138923645,
+ "cost_non_linearity": 607.4274291992188,
+ "cost_distance_total_intern_reflection": 13073.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 309.2431640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.621985912322998,
+ "cost_distorsion": 25.86330223083496,
+ "cost_thickness": 3283.898193359375,
+ "cost_beam_compression": 1.869853138923645,
+ "cost_non_linearity": 607.4274291992188,
+ "cost_distance_total_intern_reflection": 13073.203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 154.62158203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.621985912322998,
+ "cost_distorsion": 25.86330223083496,
+ "cost_thickness": 3283.898193359375,
+ "cost_beam_compression": 1.869853138923645,
+ "cost_non_linearity": 607.4274291992188,
+ "cost_distance_total_intern_reflection": 13073.203125
+ },
+ "weighted components": {
+ "cost_dispersion": 309.2431640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.621985912322998,
+ "cost_distorsion": 25.86330223083496,
+ "cost_thickness": 3283.898193359375,
+ "cost_beam_compression": 1.869853138923645,
+ "cost_non_linearity": 607.4274291992188,
+ "cost_distance_total_intern_reflection": 13073.203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_200.json b/outputs/amici/optimization_results/step2/score_details_iteration_200.json
new file mode 100755
index 0000000..8ab5d69
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_200.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.809693336486816,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.03998943418264389,
+ "cost_distorsion": 20.668582916259766,
+ "cost_thickness": 3349.076416015625,
+ "cost_beam_compression": 1.9061845541000366,
+ "cost_non_linearity": 618.0823364257812,
+ "cost_distance_total_intern_reflection": 13018.630859375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.619386672973633,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.03998943418264389,
+ "cost_distorsion": 20.668582916259766,
+ "cost_thickness": 3349.076416015625,
+ "cost_beam_compression": 1.9061845541000366,
+ "cost_non_linearity": 618.0823364257812,
+ "cost_distance_total_intern_reflection": 13018.630859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.809693336486816,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.03998943418264389,
+ "cost_distorsion": 20.668582916259766,
+ "cost_thickness": 3349.076416015625,
+ "cost_beam_compression": 1.9061845541000366,
+ "cost_non_linearity": 618.0823364257812,
+ "cost_distance_total_intern_reflection": 13018.630859375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.619386672973633,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.03998943418264389,
+ "cost_distorsion": 20.668582916259766,
+ "cost_thickness": 3349.076416015625,
+ "cost_beam_compression": 1.9061845541000366,
+ "cost_non_linearity": 618.0823364257812,
+ "cost_distance_total_intern_reflection": 13018.630859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_210.json b/outputs/amici/optimization_results/step2/score_details_iteration_210.json
new file mode 100755
index 0000000..4830be4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_210.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.038125991821289,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.5533365607261658,
+ "cost_distorsion": 19.71120834350586,
+ "cost_thickness": 3348.616943359375,
+ "cost_beam_compression": 1.9065529108047485,
+ "cost_non_linearity": 618.7017211914062,
+ "cost_distance_total_intern_reflection": 13003.6728515625
+ },
+ "weighted components": {
+ "cost_dispersion": 18.076251983642578,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.5533365607261658,
+ "cost_distorsion": 19.71120834350586,
+ "cost_thickness": 3348.616943359375,
+ "cost_beam_compression": 1.9065529108047485,
+ "cost_non_linearity": 618.7017211914062,
+ "cost_distance_total_intern_reflection": 13003.6728515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.038125991821289,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.5533365607261658,
+ "cost_distorsion": 19.71120834350586,
+ "cost_thickness": 3348.616943359375,
+ "cost_beam_compression": 1.9065529108047485,
+ "cost_non_linearity": 618.7017211914062,
+ "cost_distance_total_intern_reflection": 13003.6728515625
+ },
+ "weighted components": {
+ "cost_dispersion": 18.076251983642578,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.5533365607261658,
+ "cost_distorsion": 19.71120834350586,
+ "cost_thickness": 3348.616943359375,
+ "cost_beam_compression": 1.9065529108047485,
+ "cost_non_linearity": 618.7017211914062,
+ "cost_distance_total_intern_reflection": 13003.6728515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_220.json b/outputs/amici/optimization_results/step2/score_details_iteration_220.json
new file mode 100755
index 0000000..2d2aa29
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_220.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.056459426879883,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.856438159942627,
+ "cost_distorsion": 19.140417098999023,
+ "cost_thickness": 3348.464599609375,
+ "cost_beam_compression": 1.9074815511703491,
+ "cost_non_linearity": 619.6972045898438,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 10.112918853759766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.856438159942627,
+ "cost_distorsion": 19.140417098999023,
+ "cost_thickness": 3348.464599609375,
+ "cost_beam_compression": 1.9074815511703491,
+ "cost_non_linearity": 619.6972045898438,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.056459426879883,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.856438159942627,
+ "cost_distorsion": 19.140417098999023,
+ "cost_thickness": 3348.464599609375,
+ "cost_beam_compression": 1.9074815511703491,
+ "cost_non_linearity": 619.6972045898438,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 10.112918853759766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.856438159942627,
+ "cost_distorsion": 19.140417098999023,
+ "cost_thickness": 3348.464599609375,
+ "cost_beam_compression": 1.9074815511703491,
+ "cost_non_linearity": 619.6972045898438,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_230.json b/outputs/amici/optimization_results/step2/score_details_iteration_230.json
new file mode 100755
index 0000000..c399deb
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_230.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.1737213134765625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.365516185760498,
+ "cost_distorsion": 18.456026077270508,
+ "cost_thickness": 3348.004638671875,
+ "cost_beam_compression": 1.9075679779052734,
+ "cost_non_linearity": 620.1239624023438,
+ "cost_distance_total_intern_reflection": 13019.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 8.347442626953125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.365516185760498,
+ "cost_distorsion": 18.456026077270508,
+ "cost_thickness": 3348.004638671875,
+ "cost_beam_compression": 1.9075679779052734,
+ "cost_non_linearity": 620.1239624023438,
+ "cost_distance_total_intern_reflection": 13019.8544921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.1737213134765625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.365516185760498,
+ "cost_distorsion": 18.456026077270508,
+ "cost_thickness": 3348.004638671875,
+ "cost_beam_compression": 1.9075679779052734,
+ "cost_non_linearity": 620.1239624023438,
+ "cost_distance_total_intern_reflection": 13019.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 8.347442626953125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.365516185760498,
+ "cost_distorsion": 18.456026077270508,
+ "cost_thickness": 3348.004638671875,
+ "cost_beam_compression": 1.9075679779052734,
+ "cost_non_linearity": 620.1239624023438,
+ "cost_distance_total_intern_reflection": 13019.8544921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_240.json b/outputs/amici/optimization_results/step2/score_details_iteration_240.json
new file mode 100755
index 0000000..a16489c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_240.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.1055803298950195,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5971665382385254,
+ "cost_distorsion": 18.905590057373047,
+ "cost_thickness": 3348.191162109375,
+ "cost_beam_compression": 1.9071024656295776,
+ "cost_non_linearity": 619.5172729492188,
+ "cost_distance_total_intern_reflection": 13013.4677734375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.211160659790039,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5971665382385254,
+ "cost_distorsion": 18.905590057373047,
+ "cost_thickness": 3348.191162109375,
+ "cost_beam_compression": 1.9071024656295776,
+ "cost_non_linearity": 619.5172729492188,
+ "cost_distance_total_intern_reflection": 13013.4677734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.1055803298950195,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5971665382385254,
+ "cost_distorsion": 18.905590057373047,
+ "cost_thickness": 3348.191162109375,
+ "cost_beam_compression": 1.9071024656295776,
+ "cost_non_linearity": 619.5172729492188,
+ "cost_distance_total_intern_reflection": 13013.4677734375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.211160659790039,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5971665382385254,
+ "cost_distorsion": 18.905590057373047,
+ "cost_thickness": 3348.191162109375,
+ "cost_beam_compression": 1.9071024656295776,
+ "cost_non_linearity": 619.5172729492188,
+ "cost_distance_total_intern_reflection": 13013.4677734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_250.json b/outputs/amici/optimization_results/step2/score_details_iteration_250.json
new file mode 100755
index 0000000..0f7cec9
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_250.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.914657115936279,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 19.29258155822754,
+ "cost_thickness": 3348.529296875,
+ "cost_beam_compression": 1.9072574377059937,
+ "cost_non_linearity": 619.5421752929688,
+ "cost_distance_total_intern_reflection": 13003.734375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.829314231872559,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 19.29258155822754,
+ "cost_thickness": 3348.529296875,
+ "cost_beam_compression": 1.9072574377059937,
+ "cost_non_linearity": 619.5421752929688,
+ "cost_distance_total_intern_reflection": 13003.734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.914657115936279,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 19.29258155822754,
+ "cost_thickness": 3348.529296875,
+ "cost_beam_compression": 1.9072574377059937,
+ "cost_non_linearity": 619.5421752929688,
+ "cost_distance_total_intern_reflection": 13003.734375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.829314231872559,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.339132785797119,
+ "cost_distorsion": 19.29258155822754,
+ "cost_thickness": 3348.529296875,
+ "cost_beam_compression": 1.9072574377059937,
+ "cost_non_linearity": 619.5421752929688,
+ "cost_distance_total_intern_reflection": 13003.734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_260.json b/outputs/amici/optimization_results/step2/score_details_iteration_260.json
new file mode 100755
index 0000000..36de976
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_260.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.685178756713867,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4201440811157227,
+ "cost_distorsion": 19.375286102294922,
+ "cost_thickness": 3348.512451171875,
+ "cost_beam_compression": 1.9070559740066528,
+ "cost_non_linearity": 619.301025390625,
+ "cost_distance_total_intern_reflection": 13003.734375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.370357513427734,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4201440811157227,
+ "cost_distorsion": 19.375286102294922,
+ "cost_thickness": 3348.512451171875,
+ "cost_beam_compression": 1.9070559740066528,
+ "cost_non_linearity": 619.301025390625,
+ "cost_distance_total_intern_reflection": 13003.734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.685178756713867,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4201440811157227,
+ "cost_distorsion": 19.375286102294922,
+ "cost_thickness": 3348.512451171875,
+ "cost_beam_compression": 1.9070559740066528,
+ "cost_non_linearity": 619.301025390625,
+ "cost_distance_total_intern_reflection": 13003.734375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.370357513427734,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4201440811157227,
+ "cost_distorsion": 19.375286102294922,
+ "cost_thickness": 3348.512451171875,
+ "cost_beam_compression": 1.9070559740066528,
+ "cost_non_linearity": 619.301025390625,
+ "cost_distance_total_intern_reflection": 13003.734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_270.json b/outputs/amici/optimization_results/step2/score_details_iteration_270.json
new file mode 100755
index 0000000..d3097f2
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_270.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.982573986053467,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0909411907196045,
+ "cost_distorsion": 19.508159637451172,
+ "cost_thickness": 3348.5537109375,
+ "cost_beam_compression": 1.9070053100585938,
+ "cost_non_linearity": 619.2023315429688,
+ "cost_distance_total_intern_reflection": 13003.5517578125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.965147972106934,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0909411907196045,
+ "cost_distorsion": 19.508159637451172,
+ "cost_thickness": 3348.5537109375,
+ "cost_beam_compression": 1.9070053100585938,
+ "cost_non_linearity": 619.2023315429688,
+ "cost_distance_total_intern_reflection": 13003.5517578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.982573986053467,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0909411907196045,
+ "cost_distorsion": 19.508159637451172,
+ "cost_thickness": 3348.5537109375,
+ "cost_beam_compression": 1.9070053100585938,
+ "cost_non_linearity": 619.2023315429688,
+ "cost_distance_total_intern_reflection": 13003.5517578125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.965147972106934,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0909411907196045,
+ "cost_distorsion": 19.508159637451172,
+ "cost_thickness": 3348.5537109375,
+ "cost_beam_compression": 1.9070053100585938,
+ "cost_non_linearity": 619.2023315429688,
+ "cost_distance_total_intern_reflection": 13003.5517578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_280.json b/outputs/amici/optimization_results/step2/score_details_iteration_280.json
new file mode 100755
index 0000000..a76196e
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_280.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.602427959442139,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.527479648590088,
+ "cost_distorsion": 19.356689453125,
+ "cost_thickness": 3348.502197265625,
+ "cost_beam_compression": 1.9070738554000854,
+ "cost_non_linearity": 619.2724609375,
+ "cost_distance_total_intern_reflection": 13003.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.204855918884277,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.527479648590088,
+ "cost_distorsion": 19.356689453125,
+ "cost_thickness": 3348.502197265625,
+ "cost_beam_compression": 1.9070738554000854,
+ "cost_non_linearity": 619.2724609375,
+ "cost_distance_total_intern_reflection": 13003.8544921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.602427959442139,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.527479648590088,
+ "cost_distorsion": 19.356689453125,
+ "cost_thickness": 3348.502197265625,
+ "cost_beam_compression": 1.9070738554000854,
+ "cost_non_linearity": 619.2724609375,
+ "cost_distance_total_intern_reflection": 13003.8544921875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.204855918884277,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.527479648590088,
+ "cost_distorsion": 19.356689453125,
+ "cost_thickness": 3348.502197265625,
+ "cost_beam_compression": 1.9070738554000854,
+ "cost_non_linearity": 619.2724609375,
+ "cost_distance_total_intern_reflection": 13003.8544921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_290.json b/outputs/amici/optimization_results/step2/score_details_iteration_290.json
new file mode 100755
index 0000000..838e4d4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_290.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.644840240478516,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.406717538833618,
+ "cost_distorsion": 19.34604263305664,
+ "cost_thickness": 3348.52783203125,
+ "cost_beam_compression": 1.9070631265640259,
+ "cost_non_linearity": 619.34326171875,
+ "cost_distance_total_intern_reflection": 13003.0966796875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.289680480957031,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.406717538833618,
+ "cost_distorsion": 19.34604263305664,
+ "cost_thickness": 3348.52783203125,
+ "cost_beam_compression": 1.9070631265640259,
+ "cost_non_linearity": 619.34326171875,
+ "cost_distance_total_intern_reflection": 13003.0966796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.644840240478516,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.406717538833618,
+ "cost_distorsion": 19.34604263305664,
+ "cost_thickness": 3348.52783203125,
+ "cost_beam_compression": 1.9070631265640259,
+ "cost_non_linearity": 619.34326171875,
+ "cost_distance_total_intern_reflection": 13003.0966796875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.289680480957031,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.406717538833618,
+ "cost_distorsion": 19.34604263305664,
+ "cost_thickness": 3348.52783203125,
+ "cost_beam_compression": 1.9070631265640259,
+ "cost_non_linearity": 619.34326171875,
+ "cost_distance_total_intern_reflection": 13003.0966796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_30.json b/outputs/amici/optimization_results/step2/score_details_iteration_30.json
new file mode 100755
index 0000000..657c87f
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_30.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 91.35271453857422,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 98.28524780273438,
+ "cost_distorsion": 13.994866371154785,
+ "cost_thickness": 3277.815673828125,
+ "cost_beam_compression": 1.8704479932785034,
+ "cost_non_linearity": 611.3717041015625,
+ "cost_distance_total_intern_reflection": 12999.314453125
+ },
+ "weighted components": {
+ "cost_dispersion": 182.70542907714844,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 98.28524780273438,
+ "cost_distorsion": 13.994866371154785,
+ "cost_thickness": 3277.815673828125,
+ "cost_beam_compression": 1.8704479932785034,
+ "cost_non_linearity": 611.3717041015625,
+ "cost_distance_total_intern_reflection": 12999.314453125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 91.35271453857422,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 98.28524780273438,
+ "cost_distorsion": 13.994866371154785,
+ "cost_thickness": 3277.815673828125,
+ "cost_beam_compression": 1.8704479932785034,
+ "cost_non_linearity": 611.3717041015625,
+ "cost_distance_total_intern_reflection": 12999.314453125
+ },
+ "weighted components": {
+ "cost_dispersion": 182.70542907714844,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 98.28524780273438,
+ "cost_distorsion": 13.994866371154785,
+ "cost_thickness": 3277.815673828125,
+ "cost_beam_compression": 1.8704479932785034,
+ "cost_non_linearity": 611.3717041015625,
+ "cost_distance_total_intern_reflection": 12999.314453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_300.json b/outputs/amici/optimization_results/step2/score_details_iteration_300.json
new file mode 100755
index 0000000..693399c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_300.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.659008026123047,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.417363166809082,
+ "cost_distorsion": 19.30562400817871,
+ "cost_thickness": 3348.5263671875,
+ "cost_beam_compression": 1.9070637226104736,
+ "cost_non_linearity": 619.3333740234375,
+ "cost_distance_total_intern_reflection": 13003.0888671875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.318016052246094,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.417363166809082,
+ "cost_distorsion": 19.30562400817871,
+ "cost_thickness": 3348.5263671875,
+ "cost_beam_compression": 1.9070637226104736,
+ "cost_non_linearity": 619.3333740234375,
+ "cost_distance_total_intern_reflection": 13003.0888671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.659008026123047,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.417363166809082,
+ "cost_distorsion": 19.30562400817871,
+ "cost_thickness": 3348.5263671875,
+ "cost_beam_compression": 1.9070637226104736,
+ "cost_non_linearity": 619.3333740234375,
+ "cost_distance_total_intern_reflection": 13003.0888671875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.318016052246094,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.417363166809082,
+ "cost_distorsion": 19.30562400817871,
+ "cost_thickness": 3348.5263671875,
+ "cost_beam_compression": 1.9070637226104736,
+ "cost_non_linearity": 619.3333740234375,
+ "cost_distance_total_intern_reflection": 13003.0888671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_310.json b/outputs/amici/optimization_results/step2/score_details_iteration_310.json
new file mode 100755
index 0000000..ff1dae3
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_310.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.725006103515625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.407642364501953,
+ "cost_distorsion": 19.397167205810547,
+ "cost_thickness": 3348.52880859375,
+ "cost_beam_compression": 1.907065510749817,
+ "cost_non_linearity": 619.3348388671875,
+ "cost_distance_total_intern_reflection": 13003.12890625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.45001220703125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.407642364501953,
+ "cost_distorsion": 19.397167205810547,
+ "cost_thickness": 3348.52880859375,
+ "cost_beam_compression": 1.907065510749817,
+ "cost_non_linearity": 619.3348388671875,
+ "cost_distance_total_intern_reflection": 13003.12890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.725006103515625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.407642364501953,
+ "cost_distorsion": 19.397167205810547,
+ "cost_thickness": 3348.52880859375,
+ "cost_beam_compression": 1.907065510749817,
+ "cost_non_linearity": 619.3348388671875,
+ "cost_distance_total_intern_reflection": 13003.12890625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.45001220703125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.407642364501953,
+ "cost_distorsion": 19.397167205810547,
+ "cost_thickness": 3348.52880859375,
+ "cost_beam_compression": 1.907065510749817,
+ "cost_non_linearity": 619.3348388671875,
+ "cost_distance_total_intern_reflection": 13003.12890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_320.json b/outputs/amici/optimization_results/step2/score_details_iteration_320.json
new file mode 100755
index 0000000..4b077af
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_320.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.719625949859619,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3845763206481934,
+ "cost_distorsion": 19.42460060119629,
+ "cost_thickness": 3348.534423828125,
+ "cost_beam_compression": 1.9070607423782349,
+ "cost_non_linearity": 619.2343139648438,
+ "cost_distance_total_intern_reflection": 13003.283203125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.439251899719238,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3845763206481934,
+ "cost_distorsion": 19.42460060119629,
+ "cost_thickness": 3348.534423828125,
+ "cost_beam_compression": 1.9070607423782349,
+ "cost_non_linearity": 619.2343139648438,
+ "cost_distance_total_intern_reflection": 13003.283203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.719625949859619,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3845763206481934,
+ "cost_distorsion": 19.42460060119629,
+ "cost_thickness": 3348.534423828125,
+ "cost_beam_compression": 1.9070607423782349,
+ "cost_non_linearity": 619.2343139648438,
+ "cost_distance_total_intern_reflection": 13003.283203125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.439251899719238,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3845763206481934,
+ "cost_distorsion": 19.42460060119629,
+ "cost_thickness": 3348.534423828125,
+ "cost_beam_compression": 1.9070607423782349,
+ "cost_non_linearity": 619.2343139648438,
+ "cost_distance_total_intern_reflection": 13003.283203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_330.json b/outputs/amici/optimization_results/step2/score_details_iteration_330.json
new file mode 100755
index 0000000..46a809b
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_330.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.719625949859619,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3515563011169434,
+ "cost_distorsion": 19.409387588500977,
+ "cost_thickness": 3348.53955078125,
+ "cost_beam_compression": 1.907057762145996,
+ "cost_non_linearity": 619.1824951171875,
+ "cost_distance_total_intern_reflection": 13003.4931640625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.439251899719238,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3515563011169434,
+ "cost_distorsion": 19.409387588500977,
+ "cost_thickness": 3348.53955078125,
+ "cost_beam_compression": 1.907057762145996,
+ "cost_non_linearity": 619.1824951171875,
+ "cost_distance_total_intern_reflection": 13003.4931640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.719625949859619,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3515563011169434,
+ "cost_distorsion": 19.409387588500977,
+ "cost_thickness": 3348.53955078125,
+ "cost_beam_compression": 1.907057762145996,
+ "cost_non_linearity": 619.1824951171875,
+ "cost_distance_total_intern_reflection": 13003.4931640625
+ },
+ "weighted components": {
+ "cost_dispersion": 13.439251899719238,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3515563011169434,
+ "cost_distorsion": 19.409387588500977,
+ "cost_thickness": 3348.53955078125,
+ "cost_beam_compression": 1.907057762145996,
+ "cost_non_linearity": 619.1824951171875,
+ "cost_distance_total_intern_reflection": 13003.4931640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_340.json b/outputs/amici/optimization_results/step2/score_details_iteration_340.json
new file mode 100755
index 0000000..d5310bf
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_340.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.471036911010742,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6497421264648438,
+ "cost_distorsion": 19.35881805419922,
+ "cost_thickness": 3348.490966796875,
+ "cost_beam_compression": 1.907094120979309,
+ "cost_non_linearity": 619.3132934570312,
+ "cost_distance_total_intern_reflection": 13003.9384765625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.942073822021484,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6497421264648438,
+ "cost_distorsion": 19.35881805419922,
+ "cost_thickness": 3348.490966796875,
+ "cost_beam_compression": 1.907094120979309,
+ "cost_non_linearity": 619.3132934570312,
+ "cost_distance_total_intern_reflection": 13003.9384765625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.471036911010742,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6497421264648438,
+ "cost_distorsion": 19.35881805419922,
+ "cost_thickness": 3348.490966796875,
+ "cost_beam_compression": 1.907094120979309,
+ "cost_non_linearity": 619.3132934570312,
+ "cost_distance_total_intern_reflection": 13003.9384765625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.942073822021484,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6497421264648438,
+ "cost_distorsion": 19.35881805419922,
+ "cost_thickness": 3348.490966796875,
+ "cost_beam_compression": 1.907094120979309,
+ "cost_non_linearity": 619.3132934570312,
+ "cost_distance_total_intern_reflection": 13003.9384765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_350.json b/outputs/amici/optimization_results/step2/score_details_iteration_350.json
new file mode 100755
index 0000000..a55c3a2
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_350.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.793239116668701,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.361163377761841,
+ "cost_distorsion": 19.42644500732422,
+ "cost_thickness": 3348.496826171875,
+ "cost_beam_compression": 1.9070327281951904,
+ "cost_non_linearity": 619.2435913085938,
+ "cost_distance_total_intern_reflection": 13003.5693359375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.586478233337402,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.361163377761841,
+ "cost_distorsion": 19.42644500732422,
+ "cost_thickness": 3348.496826171875,
+ "cost_beam_compression": 1.9070327281951904,
+ "cost_non_linearity": 619.2435913085938,
+ "cost_distance_total_intern_reflection": 13003.5693359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.793239116668701,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.361163377761841,
+ "cost_distorsion": 19.42644500732422,
+ "cost_thickness": 3348.496826171875,
+ "cost_beam_compression": 1.9070327281951904,
+ "cost_non_linearity": 619.2435913085938,
+ "cost_distance_total_intern_reflection": 13003.5693359375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.586478233337402,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.361163377761841,
+ "cost_distorsion": 19.42644500732422,
+ "cost_thickness": 3348.496826171875,
+ "cost_beam_compression": 1.9070327281951904,
+ "cost_non_linearity": 619.2435913085938,
+ "cost_distance_total_intern_reflection": 13003.5693359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_360.json b/outputs/amici/optimization_results/step2/score_details_iteration_360.json
new file mode 100755
index 0000000..419b70f
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_360.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.44679594039917,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.5112911462783813,
+ "cost_distorsion": 19.593191146850586,
+ "cost_thickness": 3348.693359375,
+ "cost_beam_compression": 1.9069397449493408,
+ "cost_non_linearity": 619.0582275390625,
+ "cost_distance_total_intern_reflection": 13007.33203125
+ },
+ "weighted components": {
+ "cost_dispersion": 14.89359188079834,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.5112911462783813,
+ "cost_distorsion": 19.593191146850586,
+ "cost_thickness": 3348.693359375,
+ "cost_beam_compression": 1.9069397449493408,
+ "cost_non_linearity": 619.0582275390625,
+ "cost_distance_total_intern_reflection": 13007.33203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.44679594039917,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.5112911462783813,
+ "cost_distorsion": 19.593191146850586,
+ "cost_thickness": 3348.693359375,
+ "cost_beam_compression": 1.9069397449493408,
+ "cost_non_linearity": 619.0582275390625,
+ "cost_distance_total_intern_reflection": 13007.33203125
+ },
+ "weighted components": {
+ "cost_dispersion": 14.89359188079834,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.5112911462783813,
+ "cost_distorsion": 19.593191146850586,
+ "cost_thickness": 3348.693359375,
+ "cost_beam_compression": 1.9069397449493408,
+ "cost_non_linearity": 619.0582275390625,
+ "cost_distance_total_intern_reflection": 13007.33203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_370.json b/outputs/amici/optimization_results/step2/score_details_iteration_370.json
new file mode 100755
index 0000000..7ab179d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_370.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.4178924560546875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.541860103607178,
+ "cost_distorsion": 19.106843948364258,
+ "cost_thickness": 3348.296630859375,
+ "cost_beam_compression": 1.9073289632797241,
+ "cost_non_linearity": 619.740478515625,
+ "cost_distance_total_intern_reflection": 13008.7099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 10.835784912109375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.541860103607178,
+ "cost_distorsion": 19.106843948364258,
+ "cost_thickness": 3348.296630859375,
+ "cost_beam_compression": 1.9073289632797241,
+ "cost_non_linearity": 619.740478515625,
+ "cost_distance_total_intern_reflection": 13008.7099609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.4178924560546875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.541860103607178,
+ "cost_distorsion": 19.106843948364258,
+ "cost_thickness": 3348.296630859375,
+ "cost_beam_compression": 1.9073289632797241,
+ "cost_non_linearity": 619.740478515625,
+ "cost_distance_total_intern_reflection": 13008.7099609375
+ },
+ "weighted components": {
+ "cost_dispersion": 10.835784912109375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.541860103607178,
+ "cost_distorsion": 19.106843948364258,
+ "cost_thickness": 3348.296630859375,
+ "cost_beam_compression": 1.9073289632797241,
+ "cost_non_linearity": 619.740478515625,
+ "cost_distance_total_intern_reflection": 13008.7099609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_380.json b/outputs/amici/optimization_results/step2/score_details_iteration_380.json
new file mode 100755
index 0000000..df7d97d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_380.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.22921895980835,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0263748168945312,
+ "cost_distorsion": 19.38409423828125,
+ "cost_thickness": 3348.376708984375,
+ "cost_beam_compression": 1.9068819284439087,
+ "cost_non_linearity": 619.0750732421875,
+ "cost_distance_total_intern_reflection": 13005.146484375
+ },
+ "weighted components": {
+ "cost_dispersion": 14.4584379196167,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0263748168945312,
+ "cost_distorsion": 19.38409423828125,
+ "cost_thickness": 3348.376708984375,
+ "cost_beam_compression": 1.9068819284439087,
+ "cost_non_linearity": 619.0750732421875,
+ "cost_distance_total_intern_reflection": 13005.146484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.22921895980835,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0263748168945312,
+ "cost_distorsion": 19.38409423828125,
+ "cost_thickness": 3348.376708984375,
+ "cost_beam_compression": 1.9068819284439087,
+ "cost_non_linearity": 619.0750732421875,
+ "cost_distance_total_intern_reflection": 13005.146484375
+ },
+ "weighted components": {
+ "cost_dispersion": 14.4584379196167,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.0263748168945312,
+ "cost_distorsion": 19.38409423828125,
+ "cost_thickness": 3348.376708984375,
+ "cost_beam_compression": 1.9068819284439087,
+ "cost_non_linearity": 619.0750732421875,
+ "cost_distance_total_intern_reflection": 13005.146484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_390.json b/outputs/amici/optimization_results/step2/score_details_iteration_390.json
new file mode 100755
index 0000000..ab03613
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_390.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.581060409545898,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.132948398590088,
+ "cost_distorsion": 19.068220138549805,
+ "cost_thickness": 3348.334716796875,
+ "cost_beam_compression": 1.9072836637496948,
+ "cost_non_linearity": 619.6052856445312,
+ "cost_distance_total_intern_reflection": 13008.90234375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.162120819091797,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.132948398590088,
+ "cost_distorsion": 19.068220138549805,
+ "cost_thickness": 3348.334716796875,
+ "cost_beam_compression": 1.9072836637496948,
+ "cost_non_linearity": 619.6052856445312,
+ "cost_distance_total_intern_reflection": 13008.90234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.581060409545898,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.132948398590088,
+ "cost_distorsion": 19.068220138549805,
+ "cost_thickness": 3348.334716796875,
+ "cost_beam_compression": 1.9072836637496948,
+ "cost_non_linearity": 619.6052856445312,
+ "cost_distance_total_intern_reflection": 13008.90234375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.162120819091797,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.132948398590088,
+ "cost_distorsion": 19.068220138549805,
+ "cost_thickness": 3348.334716796875,
+ "cost_beam_compression": 1.9072836637496948,
+ "cost_non_linearity": 619.6052856445312,
+ "cost_distance_total_intern_reflection": 13008.90234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_40.json b/outputs/amici/optimization_results/step2/score_details_iteration_40.json
new file mode 100755
index 0000000..40744b1
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_40.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.17175115644931793,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 45.31443786621094,
+ "cost_distorsion": 15.322447776794434,
+ "cost_thickness": 3344.726806640625,
+ "cost_beam_compression": 1.9085997343063354,
+ "cost_non_linearity": 622.2444458007812,
+ "cost_distance_total_intern_reflection": 13082.2421875
+ },
+ "weighted components": {
+ "cost_dispersion": 0.34350231289863586,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 45.31443786621094,
+ "cost_distorsion": 15.322447776794434,
+ "cost_thickness": 3344.726806640625,
+ "cost_beam_compression": 1.9085997343063354,
+ "cost_non_linearity": 622.2444458007812,
+ "cost_distance_total_intern_reflection": 13082.2421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.17175115644931793,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 45.31443786621094,
+ "cost_distorsion": 15.322447776794434,
+ "cost_thickness": 3344.726806640625,
+ "cost_beam_compression": 1.9085997343063354,
+ "cost_non_linearity": 622.2444458007812,
+ "cost_distance_total_intern_reflection": 13082.2421875
+ },
+ "weighted components": {
+ "cost_dispersion": 0.34350231289863586,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 45.31443786621094,
+ "cost_distorsion": 15.322447776794434,
+ "cost_thickness": 3344.726806640625,
+ "cost_beam_compression": 1.9085997343063354,
+ "cost_non_linearity": 622.2444458007812,
+ "cost_distance_total_intern_reflection": 13082.2421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_400.json b/outputs/amici/optimization_results/step2/score_details_iteration_400.json
new file mode 100755
index 0000000..de15a43
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_400.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.612875938415527,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.20642156898975372,
+ "cost_distorsion": 20.23967933654785,
+ "cost_thickness": 3348.986572265625,
+ "cost_beam_compression": 1.9065803289413452,
+ "cost_non_linearity": 618.6175537109375,
+ "cost_distance_total_intern_reflection": 13013.8720703125
+ },
+ "weighted components": {
+ "cost_dispersion": 19.225751876831055,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.20642156898975372,
+ "cost_distorsion": 20.23967933654785,
+ "cost_thickness": 3348.986572265625,
+ "cost_beam_compression": 1.9065803289413452,
+ "cost_non_linearity": 618.6175537109375,
+ "cost_distance_total_intern_reflection": 13013.8720703125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.612875938415527,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.20642156898975372,
+ "cost_distorsion": 20.23967933654785,
+ "cost_thickness": 3348.986572265625,
+ "cost_beam_compression": 1.9065803289413452,
+ "cost_non_linearity": 618.6175537109375,
+ "cost_distance_total_intern_reflection": 13013.8720703125
+ },
+ "weighted components": {
+ "cost_dispersion": 19.225751876831055,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.20642156898975372,
+ "cost_distorsion": 20.23967933654785,
+ "cost_thickness": 3348.986572265625,
+ "cost_beam_compression": 1.9065803289413452,
+ "cost_non_linearity": 618.6175537109375,
+ "cost_distance_total_intern_reflection": 13013.8720703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_410.json b/outputs/amici/optimization_results/step2/score_details_iteration_410.json
new file mode 100755
index 0000000..9a4cf22
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_410.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.0754547119140625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.9888625144958496,
+ "cost_distorsion": 19.476110458374023,
+ "cost_thickness": 3348.635498046875,
+ "cost_beam_compression": 1.9072550535202026,
+ "cost_non_linearity": 619.3992919921875,
+ "cost_distance_total_intern_reflection": 13007.796875
+ },
+ "weighted components": {
+ "cost_dispersion": 12.150909423828125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.9888625144958496,
+ "cost_distorsion": 19.476110458374023,
+ "cost_thickness": 3348.635498046875,
+ "cost_beam_compression": 1.9072550535202026,
+ "cost_non_linearity": 619.3992919921875,
+ "cost_distance_total_intern_reflection": 13007.796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.0754547119140625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.9888625144958496,
+ "cost_distorsion": 19.476110458374023,
+ "cost_thickness": 3348.635498046875,
+ "cost_beam_compression": 1.9072550535202026,
+ "cost_non_linearity": 619.3992919921875,
+ "cost_distance_total_intern_reflection": 13007.796875
+ },
+ "weighted components": {
+ "cost_dispersion": 12.150909423828125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.9888625144958496,
+ "cost_distorsion": 19.476110458374023,
+ "cost_thickness": 3348.635498046875,
+ "cost_beam_compression": 1.9072550535202026,
+ "cost_non_linearity": 619.3992919921875,
+ "cost_distance_total_intern_reflection": 13007.796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_420.json b/outputs/amici/optimization_results/step2/score_details_iteration_420.json
new file mode 100755
index 0000000..0e55fe9
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_420.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.5177001953125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.588077068328857,
+ "cost_distorsion": 18.601505279541016,
+ "cost_thickness": 3347.96240234375,
+ "cost_beam_compression": 1.9074362516403198,
+ "cost_non_linearity": 619.8397827148438,
+ "cost_distance_total_intern_reflection": 13016.65625
+ },
+ "weighted components": {
+ "cost_dispersion": 9.035400390625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.588077068328857,
+ "cost_distorsion": 18.601505279541016,
+ "cost_thickness": 3347.96240234375,
+ "cost_beam_compression": 1.9074362516403198,
+ "cost_non_linearity": 619.8397827148438,
+ "cost_distance_total_intern_reflection": 13016.65625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.5177001953125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.588077068328857,
+ "cost_distorsion": 18.601505279541016,
+ "cost_thickness": 3347.96240234375,
+ "cost_beam_compression": 1.9074362516403198,
+ "cost_non_linearity": 619.8397827148438,
+ "cost_distance_total_intern_reflection": 13016.65625
+ },
+ "weighted components": {
+ "cost_dispersion": 9.035400390625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.588077068328857,
+ "cost_distorsion": 18.601505279541016,
+ "cost_thickness": 3347.96240234375,
+ "cost_beam_compression": 1.9074362516403198,
+ "cost_non_linearity": 619.8397827148438,
+ "cost_distance_total_intern_reflection": 13016.65625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_430.json b/outputs/amici/optimization_results/step2/score_details_iteration_430.json
new file mode 100755
index 0000000..eef421c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_430.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.085529327392578,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.461508184671402,
+ "cost_distorsion": 20.063077926635742,
+ "cost_thickness": 3348.8017578125,
+ "cost_beam_compression": 1.9066232442855835,
+ "cost_non_linearity": 618.7807006835938,
+ "cost_distance_total_intern_reflection": 13012.2275390625
+ },
+ "weighted components": {
+ "cost_dispersion": 18.171058654785156,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.461508184671402,
+ "cost_distorsion": 20.063077926635742,
+ "cost_thickness": 3348.8017578125,
+ "cost_beam_compression": 1.9066232442855835,
+ "cost_non_linearity": 618.7807006835938,
+ "cost_distance_total_intern_reflection": 13012.2275390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.085529327392578,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.461508184671402,
+ "cost_distorsion": 20.063077926635742,
+ "cost_thickness": 3348.8017578125,
+ "cost_beam_compression": 1.9066232442855835,
+ "cost_non_linearity": 618.7807006835938,
+ "cost_distance_total_intern_reflection": 13012.2275390625
+ },
+ "weighted components": {
+ "cost_dispersion": 18.171058654785156,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.461508184671402,
+ "cost_distorsion": 20.063077926635742,
+ "cost_thickness": 3348.8017578125,
+ "cost_beam_compression": 1.9066232442855835,
+ "cost_non_linearity": 618.7807006835938,
+ "cost_distance_total_intern_reflection": 13012.2275390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_440.json b/outputs/amici/optimization_results/step2/score_details_iteration_440.json
new file mode 100755
index 0000000..1fc3850
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_440.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.630874633789062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.1736221313476562,
+ "cost_distorsion": 20.55284881591797,
+ "cost_thickness": 3348.760009765625,
+ "cost_beam_compression": 1.9050878286361694,
+ "cost_non_linearity": 617.0073852539062,
+ "cost_distance_total_intern_reflection": 13004.5439453125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.261749267578125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.1736221313476562,
+ "cost_distorsion": 20.55284881591797,
+ "cost_thickness": 3348.760009765625,
+ "cost_beam_compression": 1.9050878286361694,
+ "cost_non_linearity": 617.0073852539062,
+ "cost_distance_total_intern_reflection": 13004.5439453125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.630874633789062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.1736221313476562,
+ "cost_distorsion": 20.55284881591797,
+ "cost_thickness": 3348.760009765625,
+ "cost_beam_compression": 1.9050878286361694,
+ "cost_non_linearity": 617.0073852539062,
+ "cost_distance_total_intern_reflection": 13004.5439453125
+ },
+ "weighted components": {
+ "cost_dispersion": 35.261749267578125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.1736221313476562,
+ "cost_distorsion": 20.55284881591797,
+ "cost_thickness": 3348.760009765625,
+ "cost_beam_compression": 1.9050878286361694,
+ "cost_non_linearity": 617.0073852539062,
+ "cost_distance_total_intern_reflection": 13004.5439453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_450.json b/outputs/amici/optimization_results/step2/score_details_iteration_450.json
new file mode 100755
index 0000000..5eb93aa
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_450.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.620841979980469,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.05727054551243782,
+ "cost_distorsion": 20.696929931640625,
+ "cost_thickness": 3349.404541015625,
+ "cost_beam_compression": 1.9063550233840942,
+ "cost_non_linearity": 618.0863037109375,
+ "cost_distance_total_intern_reflection": 13019.671875
+ },
+ "weighted components": {
+ "cost_dispersion": 23.241683959960938,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.05727054551243782,
+ "cost_distorsion": 20.696929931640625,
+ "cost_thickness": 3349.404541015625,
+ "cost_beam_compression": 1.9063550233840942,
+ "cost_non_linearity": 618.0863037109375,
+ "cost_distance_total_intern_reflection": 13019.671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.620841979980469,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.05727054551243782,
+ "cost_distorsion": 20.696929931640625,
+ "cost_thickness": 3349.404541015625,
+ "cost_beam_compression": 1.9063550233840942,
+ "cost_non_linearity": 618.0863037109375,
+ "cost_distance_total_intern_reflection": 13019.671875
+ },
+ "weighted components": {
+ "cost_dispersion": 23.241683959960938,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.05727054551243782,
+ "cost_distorsion": 20.696929931640625,
+ "cost_thickness": 3349.404541015625,
+ "cost_beam_compression": 1.9063550233840942,
+ "cost_non_linearity": 618.0863037109375,
+ "cost_distance_total_intern_reflection": 13019.671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_460.json b/outputs/amici/optimization_results/step2/score_details_iteration_460.json
new file mode 100755
index 0000000..8ec6c89
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_460.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 19.773828506469727,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.2897591590881348,
+ "cost_distorsion": 20.817707061767578,
+ "cost_thickness": 3348.3701171875,
+ "cost_beam_compression": 1.9046175479888916,
+ "cost_non_linearity": 616.7861938476562,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ },
+ "weighted components": {
+ "cost_dispersion": 39.54765701293945,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.2897591590881348,
+ "cost_distorsion": 20.817707061767578,
+ "cost_thickness": 3348.3701171875,
+ "cost_beam_compression": 1.9046175479888916,
+ "cost_non_linearity": 616.7861938476562,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 19.773828506469727,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.2897591590881348,
+ "cost_distorsion": 20.817707061767578,
+ "cost_thickness": 3348.3701171875,
+ "cost_beam_compression": 1.9046175479888916,
+ "cost_non_linearity": 616.7861938476562,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ },
+ "weighted components": {
+ "cost_dispersion": 39.54765701293945,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.2897591590881348,
+ "cost_distorsion": 20.817707061767578,
+ "cost_thickness": 3348.3701171875,
+ "cost_beam_compression": 1.9046175479888916,
+ "cost_non_linearity": 616.7861938476562,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_470.json b/outputs/amici/optimization_results/step2/score_details_iteration_470.json
new file mode 100755
index 0000000..46941e4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_470.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.103568077087402,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.13744880259037018,
+ "cost_distorsion": 20.346261978149414,
+ "cost_thickness": 3349.76904296875,
+ "cost_beam_compression": 1.9069939851760864,
+ "cost_non_linearity": 618.6454467773438,
+ "cost_distance_total_intern_reflection": 13014.5859375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.207136154174805,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.13744880259037018,
+ "cost_distorsion": 20.346261978149414,
+ "cost_thickness": 3349.76904296875,
+ "cost_beam_compression": 1.9069939851760864,
+ "cost_non_linearity": 618.6454467773438,
+ "cost_distance_total_intern_reflection": 13014.5859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.103568077087402,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.13744880259037018,
+ "cost_distorsion": 20.346261978149414,
+ "cost_thickness": 3349.76904296875,
+ "cost_beam_compression": 1.9069939851760864,
+ "cost_non_linearity": 618.6454467773438,
+ "cost_distance_total_intern_reflection": 13014.5859375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.207136154174805,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.13744880259037018,
+ "cost_distorsion": 20.346261978149414,
+ "cost_thickness": 3349.76904296875,
+ "cost_beam_compression": 1.9069939851760864,
+ "cost_non_linearity": 618.6454467773438,
+ "cost_distance_total_intern_reflection": 13014.5859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_480.json b/outputs/amici/optimization_results/step2/score_details_iteration_480.json
new file mode 100755
index 0000000..32f2889
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_480.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.4651145935058594,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.8677978515625,
+ "cost_distorsion": 17.991741180419922,
+ "cost_thickness": 3347.54931640625,
+ "cost_beam_compression": 1.9080078601837158,
+ "cost_non_linearity": 620.68896484375,
+ "cost_distance_total_intern_reflection": 13028.1318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 4.930229187011719,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.8677978515625,
+ "cost_distorsion": 17.991741180419922,
+ "cost_thickness": 3347.54931640625,
+ "cost_beam_compression": 1.9080078601837158,
+ "cost_non_linearity": 620.68896484375,
+ "cost_distance_total_intern_reflection": 13028.1318359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.4651145935058594,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.8677978515625,
+ "cost_distorsion": 17.991741180419922,
+ "cost_thickness": 3347.54931640625,
+ "cost_beam_compression": 1.9080078601837158,
+ "cost_non_linearity": 620.68896484375,
+ "cost_distance_total_intern_reflection": 13028.1318359375
+ },
+ "weighted components": {
+ "cost_dispersion": 4.930229187011719,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.8677978515625,
+ "cost_distorsion": 17.991741180419922,
+ "cost_thickness": 3347.54931640625,
+ "cost_beam_compression": 1.9080078601837158,
+ "cost_non_linearity": 620.68896484375,
+ "cost_distance_total_intern_reflection": 13028.1318359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_490.json b/outputs/amici/optimization_results/step2/score_details_iteration_490.json
new file mode 100755
index 0000000..ab060e5
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_490.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.149295806884766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3658291697502136,
+ "cost_distorsion": 20.02896499633789,
+ "cost_thickness": 3348.894775390625,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 618.5778198242188,
+ "cost_distance_total_intern_reflection": 13012.779296875
+ },
+ "weighted components": {
+ "cost_dispersion": 18.29859161376953,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3658291697502136,
+ "cost_distorsion": 20.02896499633789,
+ "cost_thickness": 3348.894775390625,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 618.5778198242188,
+ "cost_distance_total_intern_reflection": 13012.779296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.149295806884766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3658291697502136,
+ "cost_distorsion": 20.02896499633789,
+ "cost_thickness": 3348.894775390625,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 618.5778198242188,
+ "cost_distance_total_intern_reflection": 13012.779296875
+ },
+ "weighted components": {
+ "cost_dispersion": 18.29859161376953,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3658291697502136,
+ "cost_distorsion": 20.02896499633789,
+ "cost_thickness": 3348.894775390625,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 618.5778198242188,
+ "cost_distance_total_intern_reflection": 13012.779296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_50.json b/outputs/amici/optimization_results/step2/score_details_iteration_50.json
new file mode 100755
index 0000000..37823f5
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_50.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1069649457931519,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.792167663574219,
+ "cost_distorsion": 22.623178482055664,
+ "cost_thickness": 3374.62841796875,
+ "cost_beam_compression": 1.9193857908248901,
+ "cost_non_linearity": 620.7413330078125,
+ "cost_distance_total_intern_reflection": 13068.7744140625
+ },
+ "weighted components": {
+ "cost_dispersion": 2.2139298915863037,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.792167663574219,
+ "cost_distorsion": 22.623178482055664,
+ "cost_thickness": 3374.62841796875,
+ "cost_beam_compression": 1.9193857908248901,
+ "cost_non_linearity": 620.7413330078125,
+ "cost_distance_total_intern_reflection": 13068.7744140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1069649457931519,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.792167663574219,
+ "cost_distorsion": 22.623178482055664,
+ "cost_thickness": 3374.62841796875,
+ "cost_beam_compression": 1.9193857908248901,
+ "cost_non_linearity": 620.7413330078125,
+ "cost_distance_total_intern_reflection": 13068.7744140625
+ },
+ "weighted components": {
+ "cost_dispersion": 2.2139298915863037,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.792167663574219,
+ "cost_distorsion": 22.623178482055664,
+ "cost_thickness": 3374.62841796875,
+ "cost_beam_compression": 1.9193857908248901,
+ "cost_non_linearity": 620.7413330078125,
+ "cost_distance_total_intern_reflection": 13068.7744140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_500.json b/outputs/amici/optimization_results/step2/score_details_iteration_500.json
new file mode 100755
index 0000000..1685edd
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_500.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.970230102539062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.417271226644516,
+ "cost_distorsion": 18.875289916992188,
+ "cost_thickness": 3347.265625,
+ "cost_beam_compression": 1.9056826829910278,
+ "cost_non_linearity": 618.3015747070312,
+ "cost_distance_total_intern_reflection": 13019.224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 21.940460205078125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.417271226644516,
+ "cost_distorsion": 18.875289916992188,
+ "cost_thickness": 3347.265625,
+ "cost_beam_compression": 1.9056826829910278,
+ "cost_non_linearity": 618.3015747070312,
+ "cost_distance_total_intern_reflection": 13019.224609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.970230102539062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.417271226644516,
+ "cost_distorsion": 18.875289916992188,
+ "cost_thickness": 3347.265625,
+ "cost_beam_compression": 1.9056826829910278,
+ "cost_non_linearity": 618.3015747070312,
+ "cost_distance_total_intern_reflection": 13019.224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 21.940460205078125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.417271226644516,
+ "cost_distorsion": 18.875289916992188,
+ "cost_thickness": 3347.265625,
+ "cost_beam_compression": 1.9056826829910278,
+ "cost_non_linearity": 618.3015747070312,
+ "cost_distance_total_intern_reflection": 13019.224609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_510.json b/outputs/amici/optimization_results/step2/score_details_iteration_510.json
new file mode 100755
index 0000000..a4b8743
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_510.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.08775520324707,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.187115669250488,
+ "cost_distorsion": 21.241044998168945,
+ "cost_thickness": 3348.791015625,
+ "cost_beam_compression": 1.9037985801696777,
+ "cost_non_linearity": 615.7052001953125,
+ "cost_distance_total_intern_reflection": 13003.6376953125
+ },
+ "weighted components": {
+ "cost_dispersion": 54.17551040649414,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.187115669250488,
+ "cost_distorsion": 21.241044998168945,
+ "cost_thickness": 3348.791015625,
+ "cost_beam_compression": 1.9037985801696777,
+ "cost_non_linearity": 615.7052001953125,
+ "cost_distance_total_intern_reflection": 13003.6376953125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.08775520324707,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.187115669250488,
+ "cost_distorsion": 21.241044998168945,
+ "cost_thickness": 3348.791015625,
+ "cost_beam_compression": 1.9037985801696777,
+ "cost_non_linearity": 615.7052001953125,
+ "cost_distance_total_intern_reflection": 13003.6376953125
+ },
+ "weighted components": {
+ "cost_dispersion": 54.17551040649414,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 11.187115669250488,
+ "cost_distorsion": 21.241044998168945,
+ "cost_thickness": 3348.791015625,
+ "cost_beam_compression": 1.9037985801696777,
+ "cost_non_linearity": 615.7052001953125,
+ "cost_distance_total_intern_reflection": 13003.6376953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_520.json b/outputs/amici/optimization_results/step2/score_details_iteration_520.json
new file mode 100755
index 0000000..f41640f
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_520.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.731634140014648,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.435783863067627,
+ "cost_distorsion": 18.99644660949707,
+ "cost_thickness": 3349.185546875,
+ "cost_beam_compression": 1.9078487157821655,
+ "cost_non_linearity": 619.9577026367188,
+ "cost_distance_total_intern_reflection": 13010.8642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 9.463268280029297,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.435783863067627,
+ "cost_distorsion": 18.99644660949707,
+ "cost_thickness": 3349.185546875,
+ "cost_beam_compression": 1.9078487157821655,
+ "cost_non_linearity": 619.9577026367188,
+ "cost_distance_total_intern_reflection": 13010.8642578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.731634140014648,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.435783863067627,
+ "cost_distorsion": 18.99644660949707,
+ "cost_thickness": 3349.185546875,
+ "cost_beam_compression": 1.9078487157821655,
+ "cost_non_linearity": 619.9577026367188,
+ "cost_distance_total_intern_reflection": 13010.8642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 9.463268280029297,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.435783863067627,
+ "cost_distorsion": 18.99644660949707,
+ "cost_thickness": 3349.185546875,
+ "cost_beam_compression": 1.9078487157821655,
+ "cost_non_linearity": 619.9577026367188,
+ "cost_distance_total_intern_reflection": 13010.8642578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_530.json b/outputs/amici/optimization_results/step2/score_details_iteration_530.json
new file mode 100755
index 0000000..df0da76
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_530.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.54108190536499,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 10.787053108215332,
+ "cost_distorsion": 17.338829040527344,
+ "cost_thickness": 3345.69287109375,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 620.0595703125,
+ "cost_distance_total_intern_reflection": 13043.853515625
+ },
+ "weighted components": {
+ "cost_dispersion": 9.08216381072998,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 10.787053108215332,
+ "cost_distorsion": 17.338829040527344,
+ "cost_thickness": 3345.69287109375,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 620.0595703125,
+ "cost_distance_total_intern_reflection": 13043.853515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.54108190536499,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 10.787053108215332,
+ "cost_distorsion": 17.338829040527344,
+ "cost_thickness": 3345.69287109375,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 620.0595703125,
+ "cost_distance_total_intern_reflection": 13043.853515625
+ },
+ "weighted components": {
+ "cost_dispersion": 9.08216381072998,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 10.787053108215332,
+ "cost_distorsion": 17.338829040527344,
+ "cost_thickness": 3345.69287109375,
+ "cost_beam_compression": 1.9066274166107178,
+ "cost_non_linearity": 620.0595703125,
+ "cost_distance_total_intern_reflection": 13043.853515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_540.json b/outputs/amici/optimization_results/step2/score_details_iteration_540.json
new file mode 100755
index 0000000..c5865da
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_540.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 20.78745460510254,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.415579319000244,
+ "cost_distorsion": 22.187419891357422,
+ "cost_thickness": 3349.97412109375,
+ "cost_beam_compression": 1.9051295518875122,
+ "cost_non_linearity": 616.501708984375,
+ "cost_distance_total_intern_reflection": 13032.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 41.57490921020508,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.415579319000244,
+ "cost_distorsion": 22.187419891357422,
+ "cost_thickness": 3349.97412109375,
+ "cost_beam_compression": 1.9051295518875122,
+ "cost_non_linearity": 616.501708984375,
+ "cost_distance_total_intern_reflection": 13032.3828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 20.78745460510254,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.415579319000244,
+ "cost_distorsion": 22.187419891357422,
+ "cost_thickness": 3349.97412109375,
+ "cost_beam_compression": 1.9051295518875122,
+ "cost_non_linearity": 616.501708984375,
+ "cost_distance_total_intern_reflection": 13032.3828125
+ },
+ "weighted components": {
+ "cost_dispersion": 41.57490921020508,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.415579319000244,
+ "cost_distorsion": 22.187419891357422,
+ "cost_thickness": 3349.97412109375,
+ "cost_beam_compression": 1.9051295518875122,
+ "cost_non_linearity": 616.501708984375,
+ "cost_distance_total_intern_reflection": 13032.3828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_550.json b/outputs/amici/optimization_results/step2/score_details_iteration_550.json
new file mode 100755
index 0000000..1f2bb5a
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_550.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.503866195678711,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3911273181438446,
+ "cost_distorsion": 22.727895736694336,
+ "cost_thickness": 3351.447265625,
+ "cost_beam_compression": 1.9074738025665283,
+ "cost_non_linearity": 618.295166015625,
+ "cost_distance_total_intern_reflection": 13064.7607421875
+ },
+ "weighted components": {
+ "cost_dispersion": 21.007732391357422,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3911273181438446,
+ "cost_distorsion": 22.727895736694336,
+ "cost_thickness": 3351.447265625,
+ "cost_beam_compression": 1.9074738025665283,
+ "cost_non_linearity": 618.295166015625,
+ "cost_distance_total_intern_reflection": 13064.7607421875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.503866195678711,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3911273181438446,
+ "cost_distorsion": 22.727895736694336,
+ "cost_thickness": 3351.447265625,
+ "cost_beam_compression": 1.9074738025665283,
+ "cost_non_linearity": 618.295166015625,
+ "cost_distance_total_intern_reflection": 13064.7607421875
+ },
+ "weighted components": {
+ "cost_dispersion": 21.007732391357422,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.3911273181438446,
+ "cost_distorsion": 22.727895736694336,
+ "cost_thickness": 3351.447265625,
+ "cost_beam_compression": 1.9074738025665283,
+ "cost_non_linearity": 618.295166015625,
+ "cost_distance_total_intern_reflection": 13064.7607421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_560.json b/outputs/amici/optimization_results/step2/score_details_iteration_560.json
new file mode 100755
index 0000000..746883d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_560.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0434303283691406,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.464006423950195,
+ "cost_distorsion": 19.210630416870117,
+ "cost_thickness": 3349.572998046875,
+ "cost_beam_compression": 1.9094645977020264,
+ "cost_non_linearity": 621.4408569335938,
+ "cost_distance_total_intern_reflection": 13023.0166015625
+ },
+ "weighted components": {
+ "cost_dispersion": 2.0868606567382812,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.464006423950195,
+ "cost_distorsion": 19.210630416870117,
+ "cost_thickness": 3349.572998046875,
+ "cost_beam_compression": 1.9094645977020264,
+ "cost_non_linearity": 621.4408569335938,
+ "cost_distance_total_intern_reflection": 13023.0166015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0434303283691406,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.464006423950195,
+ "cost_distorsion": 19.210630416870117,
+ "cost_thickness": 3349.572998046875,
+ "cost_beam_compression": 1.9094645977020264,
+ "cost_non_linearity": 621.4408569335938,
+ "cost_distance_total_intern_reflection": 13023.0166015625
+ },
+ "weighted components": {
+ "cost_dispersion": 2.0868606567382812,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.464006423950195,
+ "cost_distorsion": 19.210630416870117,
+ "cost_thickness": 3349.572998046875,
+ "cost_beam_compression": 1.9094645977020264,
+ "cost_non_linearity": 621.4408569335938,
+ "cost_distance_total_intern_reflection": 13023.0166015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_570.json b/outputs/amici/optimization_results/step2/score_details_iteration_570.json
new file mode 100755
index 0000000..2a2afa0
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_570.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.133575439453125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 42.792659759521484,
+ "cost_distorsion": 23.1646728515625,
+ "cost_thickness": 3350.69873046875,
+ "cost_beam_compression": 1.90274178981781,
+ "cost_non_linearity": 613.6544189453125,
+ "cost_distance_total_intern_reflection": 13019.4404296875
+ },
+ "weighted components": {
+ "cost_dispersion": 88.26715087890625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 42.792659759521484,
+ "cost_distorsion": 23.1646728515625,
+ "cost_thickness": 3350.69873046875,
+ "cost_beam_compression": 1.90274178981781,
+ "cost_non_linearity": 613.6544189453125,
+ "cost_distance_total_intern_reflection": 13019.4404296875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 44.133575439453125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 42.792659759521484,
+ "cost_distorsion": 23.1646728515625,
+ "cost_thickness": 3350.69873046875,
+ "cost_beam_compression": 1.90274178981781,
+ "cost_non_linearity": 613.6544189453125,
+ "cost_distance_total_intern_reflection": 13019.4404296875
+ },
+ "weighted components": {
+ "cost_dispersion": 88.26715087890625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 42.792659759521484,
+ "cost_distorsion": 23.1646728515625,
+ "cost_thickness": 3350.69873046875,
+ "cost_beam_compression": 1.90274178981781,
+ "cost_non_linearity": 613.6544189453125,
+ "cost_distance_total_intern_reflection": 13019.4404296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_580.json b/outputs/amici/optimization_results/step2/score_details_iteration_580.json
new file mode 100755
index 0000000..9e5664d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_580.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.105409622192383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.300649404525757,
+ "cost_distorsion": 18.684490203857422,
+ "cost_thickness": 3346.071533203125,
+ "cost_beam_compression": 1.9055646657943726,
+ "cost_non_linearity": 618.7908325195312,
+ "cost_distance_total_intern_reflection": 13016.0849609375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.210819244384766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.300649404525757,
+ "cost_distorsion": 18.684490203857422,
+ "cost_thickness": 3346.071533203125,
+ "cost_beam_compression": 1.9055646657943726,
+ "cost_non_linearity": 618.7908325195312,
+ "cost_distance_total_intern_reflection": 13016.0849609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.105409622192383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.300649404525757,
+ "cost_distorsion": 18.684490203857422,
+ "cost_thickness": 3346.071533203125,
+ "cost_beam_compression": 1.9055646657943726,
+ "cost_non_linearity": 618.7908325195312,
+ "cost_distance_total_intern_reflection": 13016.0849609375
+ },
+ "weighted components": {
+ "cost_dispersion": 18.210819244384766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.300649404525757,
+ "cost_distorsion": 18.684490203857422,
+ "cost_thickness": 3346.071533203125,
+ "cost_beam_compression": 1.9055646657943726,
+ "cost_non_linearity": 618.7908325195312,
+ "cost_distance_total_intern_reflection": 13016.0849609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_590.json b/outputs/amici/optimization_results/step2/score_details_iteration_590.json
new file mode 100755
index 0000000..32d8778
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_590.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6902461647987366,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 25.454397201538086,
+ "cost_distorsion": 16.66861343383789,
+ "cost_thickness": 3347.770263671875,
+ "cost_beam_compression": 1.9091320037841797,
+ "cost_non_linearity": 621.7507934570312,
+ "cost_distance_total_intern_reflection": 13056.37890625
+ },
+ "weighted components": {
+ "cost_dispersion": 1.3804923295974731,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 25.454397201538086,
+ "cost_distorsion": 16.66861343383789,
+ "cost_thickness": 3347.770263671875,
+ "cost_beam_compression": 1.9091320037841797,
+ "cost_non_linearity": 621.7507934570312,
+ "cost_distance_total_intern_reflection": 13056.37890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6902461647987366,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 25.454397201538086,
+ "cost_distorsion": 16.66861343383789,
+ "cost_thickness": 3347.770263671875,
+ "cost_beam_compression": 1.9091320037841797,
+ "cost_non_linearity": 621.7507934570312,
+ "cost_distance_total_intern_reflection": 13056.37890625
+ },
+ "weighted components": {
+ "cost_dispersion": 1.3804923295974731,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 25.454397201538086,
+ "cost_distorsion": 16.66861343383789,
+ "cost_thickness": 3347.770263671875,
+ "cost_beam_compression": 1.9091320037841797,
+ "cost_non_linearity": 621.7507934570312,
+ "cost_distance_total_intern_reflection": 13056.37890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_60.json b/outputs/amici/optimization_results/step2/score_details_iteration_60.json
new file mode 100755
index 0000000..e6840b6
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_60.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.636567115783691,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.0587780699133873,
+ "cost_distorsion": 20.475608825683594,
+ "cost_thickness": 3355.9560546875,
+ "cost_beam_compression": 1.910298466682434,
+ "cost_non_linearity": 619.4326782226562,
+ "cost_distance_total_intern_reflection": 13020.64453125
+ },
+ "weighted components": {
+ "cost_dispersion": 11.273134231567383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.0587780699133873,
+ "cost_distorsion": 20.475608825683594,
+ "cost_thickness": 3355.9560546875,
+ "cost_beam_compression": 1.910298466682434,
+ "cost_non_linearity": 619.4326782226562,
+ "cost_distance_total_intern_reflection": 13020.64453125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.636567115783691,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.0587780699133873,
+ "cost_distorsion": 20.475608825683594,
+ "cost_thickness": 3355.9560546875,
+ "cost_beam_compression": 1.910298466682434,
+ "cost_non_linearity": 619.4326782226562,
+ "cost_distance_total_intern_reflection": 13020.64453125
+ },
+ "weighted components": {
+ "cost_dispersion": 11.273134231567383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.0587780699133873,
+ "cost_distorsion": 20.475608825683594,
+ "cost_thickness": 3355.9560546875,
+ "cost_beam_compression": 1.910298466682434,
+ "cost_non_linearity": 619.4326782226562,
+ "cost_distance_total_intern_reflection": 13020.64453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_600.json b/outputs/amici/optimization_results/step2/score_details_iteration_600.json
new file mode 100755
index 0000000..adfb750
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_600.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.780765533447266,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08926248550415039,
+ "cost_distorsion": 18.919462203979492,
+ "cost_thickness": 3347.646484375,
+ "cost_beam_compression": 1.9056713581085205,
+ "cost_non_linearity": 618.1168823242188,
+ "cost_distance_total_intern_reflection": 13019.916015625
+ },
+ "weighted components": {
+ "cost_dispersion": 23.56153106689453,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08926248550415039,
+ "cost_distorsion": 18.919462203979492,
+ "cost_thickness": 3347.646484375,
+ "cost_beam_compression": 1.9056713581085205,
+ "cost_non_linearity": 618.1168823242188,
+ "cost_distance_total_intern_reflection": 13019.916015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.780765533447266,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08926248550415039,
+ "cost_distorsion": 18.919462203979492,
+ "cost_thickness": 3347.646484375,
+ "cost_beam_compression": 1.9056713581085205,
+ "cost_non_linearity": 618.1168823242188,
+ "cost_distance_total_intern_reflection": 13019.916015625
+ },
+ "weighted components": {
+ "cost_dispersion": 23.56153106689453,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08926248550415039,
+ "cost_distorsion": 18.919462203979492,
+ "cost_thickness": 3347.646484375,
+ "cost_beam_compression": 1.9056713581085205,
+ "cost_non_linearity": 618.1168823242188,
+ "cost_distance_total_intern_reflection": 13019.916015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_610.json b/outputs/amici/optimization_results/step2/score_details_iteration_610.json
new file mode 100755
index 0000000..bc9615b
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_610.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.831762313842773,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.213442802429199,
+ "cost_distorsion": 22.262798309326172,
+ "cost_thickness": 3349.092041015625,
+ "cost_beam_compression": 1.904495358467102,
+ "cost_non_linearity": 616.2025756835938,
+ "cost_distance_total_intern_reflection": 13032.4716796875
+ },
+ "weighted components": {
+ "cost_dispersion": 45.66352462768555,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.213442802429199,
+ "cost_distorsion": 22.262798309326172,
+ "cost_thickness": 3349.092041015625,
+ "cost_beam_compression": 1.904495358467102,
+ "cost_non_linearity": 616.2025756835938,
+ "cost_distance_total_intern_reflection": 13032.4716796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 22.831762313842773,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.213442802429199,
+ "cost_distorsion": 22.262798309326172,
+ "cost_thickness": 3349.092041015625,
+ "cost_beam_compression": 1.904495358467102,
+ "cost_non_linearity": 616.2025756835938,
+ "cost_distance_total_intern_reflection": 13032.4716796875
+ },
+ "weighted components": {
+ "cost_dispersion": 45.66352462768555,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 7.213442802429199,
+ "cost_distorsion": 22.262798309326172,
+ "cost_thickness": 3349.092041015625,
+ "cost_beam_compression": 1.904495358467102,
+ "cost_non_linearity": 616.2025756835938,
+ "cost_distance_total_intern_reflection": 13032.4716796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_620.json b/outputs/amici/optimization_results/step2/score_details_iteration_620.json
new file mode 100755
index 0000000..96643c9
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_620.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.679181098937988,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.21934562921524048,
+ "cost_distorsion": 20.212980270385742,
+ "cost_thickness": 3349.92822265625,
+ "cost_beam_compression": 1.9071555137634277,
+ "cost_non_linearity": 618.6597900390625,
+ "cost_distance_total_intern_reflection": 13013.416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 17.358362197875977,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.21934562921524048,
+ "cost_distorsion": 20.212980270385742,
+ "cost_thickness": 3349.92822265625,
+ "cost_beam_compression": 1.9071555137634277,
+ "cost_non_linearity": 618.6597900390625,
+ "cost_distance_total_intern_reflection": 13013.416015625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.679181098937988,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.21934562921524048,
+ "cost_distorsion": 20.212980270385742,
+ "cost_thickness": 3349.92822265625,
+ "cost_beam_compression": 1.9071555137634277,
+ "cost_non_linearity": 618.6597900390625,
+ "cost_distance_total_intern_reflection": 13013.416015625
+ },
+ "weighted components": {
+ "cost_dispersion": 17.358362197875977,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.21934562921524048,
+ "cost_distorsion": 20.212980270385742,
+ "cost_thickness": 3349.92822265625,
+ "cost_beam_compression": 1.9071555137634277,
+ "cost_non_linearity": 618.6597900390625,
+ "cost_distance_total_intern_reflection": 13013.416015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_630.json b/outputs/amici/optimization_results/step2/score_details_iteration_630.json
new file mode 100755
index 0000000..c4059e6
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_630.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.901719093322754,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.3649959564209,
+ "cost_distorsion": 18.33240509033203,
+ "cost_thickness": 3347.679443359375,
+ "cost_beam_compression": 1.9082999229431152,
+ "cost_non_linearity": 621.0413818359375,
+ "cost_distance_total_intern_reflection": 13017.44140625
+ },
+ "weighted components": {
+ "cost_dispersion": 3.803438186645508,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.3649959564209,
+ "cost_distorsion": 18.33240509033203,
+ "cost_thickness": 3347.679443359375,
+ "cost_beam_compression": 1.9082999229431152,
+ "cost_non_linearity": 621.0413818359375,
+ "cost_distance_total_intern_reflection": 13017.44140625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.901719093322754,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.3649959564209,
+ "cost_distorsion": 18.33240509033203,
+ "cost_thickness": 3347.679443359375,
+ "cost_beam_compression": 1.9082999229431152,
+ "cost_non_linearity": 621.0413818359375,
+ "cost_distance_total_intern_reflection": 13017.44140625
+ },
+ "weighted components": {
+ "cost_dispersion": 3.803438186645508,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 16.3649959564209,
+ "cost_distorsion": 18.33240509033203,
+ "cost_thickness": 3347.679443359375,
+ "cost_beam_compression": 1.9082999229431152,
+ "cost_non_linearity": 621.0413818359375,
+ "cost_distance_total_intern_reflection": 13017.44140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_640.json b/outputs/amici/optimization_results/step2/score_details_iteration_640.json
new file mode 100755
index 0000000..832892f
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_640.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.430942535400391,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.702032089233398,
+ "cost_distorsion": 19.767976760864258,
+ "cost_thickness": 3349.348388671875,
+ "cost_beam_compression": 1.9080030918121338,
+ "cost_non_linearity": 619.9413452148438,
+ "cost_distance_total_intern_reflection": 13018.97265625
+ },
+ "weighted components": {
+ "cost_dispersion": 8.861885070800781,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.702032089233398,
+ "cost_distorsion": 19.767976760864258,
+ "cost_thickness": 3349.348388671875,
+ "cost_beam_compression": 1.9080030918121338,
+ "cost_non_linearity": 619.9413452148438,
+ "cost_distance_total_intern_reflection": 13018.97265625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.430942535400391,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.702032089233398,
+ "cost_distorsion": 19.767976760864258,
+ "cost_thickness": 3349.348388671875,
+ "cost_beam_compression": 1.9080030918121338,
+ "cost_non_linearity": 619.9413452148438,
+ "cost_distance_total_intern_reflection": 13018.97265625
+ },
+ "weighted components": {
+ "cost_dispersion": 8.861885070800781,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 4.702032089233398,
+ "cost_distorsion": 19.767976760864258,
+ "cost_thickness": 3349.348388671875,
+ "cost_beam_compression": 1.9080030918121338,
+ "cost_non_linearity": 619.9413452148438,
+ "cost_distance_total_intern_reflection": 13018.97265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_650.json b/outputs/amici/optimization_results/step2/score_details_iteration_650.json
new file mode 100755
index 0000000..a307997
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_650.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.903904438018799,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.9038472175598145,
+ "cost_distorsion": 19.470273971557617,
+ "cost_thickness": 3349.339111328125,
+ "cost_beam_compression": 1.9081717729568481,
+ "cost_non_linearity": 620.0630493164062,
+ "cost_distance_total_intern_reflection": 13011.7109375
+ },
+ "weighted components": {
+ "cost_dispersion": 7.807808876037598,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.9038472175598145,
+ "cost_distorsion": 19.470273971557617,
+ "cost_thickness": 3349.339111328125,
+ "cost_beam_compression": 1.9081717729568481,
+ "cost_non_linearity": 620.0630493164062,
+ "cost_distance_total_intern_reflection": 13011.7109375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.903904438018799,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.9038472175598145,
+ "cost_distorsion": 19.470273971557617,
+ "cost_thickness": 3349.339111328125,
+ "cost_beam_compression": 1.9081717729568481,
+ "cost_non_linearity": 620.0630493164062,
+ "cost_distance_total_intern_reflection": 13011.7109375
+ },
+ "weighted components": {
+ "cost_dispersion": 7.807808876037598,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.9038472175598145,
+ "cost_distorsion": 19.470273971557617,
+ "cost_thickness": 3349.339111328125,
+ "cost_beam_compression": 1.9081717729568481,
+ "cost_non_linearity": 620.0630493164062,
+ "cost_distance_total_intern_reflection": 13011.7109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_660.json b/outputs/amici/optimization_results/step2/score_details_iteration_660.json
new file mode 100755
index 0000000..1f9c95c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_660.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.5128519535064697,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 64.1787109375,
+ "cost_distorsion": 18.39895248413086,
+ "cost_thickness": 3350.110107421875,
+ "cost_beam_compression": 1.9125866889953613,
+ "cost_non_linearity": 624.5628662109375,
+ "cost_distance_total_intern_reflection": 13039.013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 3.0257039070129395,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 64.1787109375,
+ "cost_distorsion": 18.39895248413086,
+ "cost_thickness": 3350.110107421875,
+ "cost_beam_compression": 1.9125866889953613,
+ "cost_non_linearity": 624.5628662109375,
+ "cost_distance_total_intern_reflection": 13039.013671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.5128519535064697,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 64.1787109375,
+ "cost_distorsion": 18.39895248413086,
+ "cost_thickness": 3350.110107421875,
+ "cost_beam_compression": 1.9125866889953613,
+ "cost_non_linearity": 624.5628662109375,
+ "cost_distance_total_intern_reflection": 13039.013671875
+ },
+ "weighted components": {
+ "cost_dispersion": 3.0257039070129395,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 64.1787109375,
+ "cost_distorsion": 18.39895248413086,
+ "cost_thickness": 3350.110107421875,
+ "cost_beam_compression": 1.9125866889953613,
+ "cost_non_linearity": 624.5628662109375,
+ "cost_distance_total_intern_reflection": 13039.013671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_670.json b/outputs/amici/optimization_results/step2/score_details_iteration_670.json
new file mode 100755
index 0000000..013e134
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_670.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.0408661365509033,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 61.25468444824219,
+ "cost_distorsion": 18.652671813964844,
+ "cost_thickness": 3351.93994140625,
+ "cost_beam_compression": 1.9135743379592896,
+ "cost_non_linearity": 624.7029418945312,
+ "cost_distance_total_intern_reflection": 13045.1767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 4.081732273101807,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 61.25468444824219,
+ "cost_distorsion": 18.652671813964844,
+ "cost_thickness": 3351.93994140625,
+ "cost_beam_compression": 1.9135743379592896,
+ "cost_non_linearity": 624.7029418945312,
+ "cost_distance_total_intern_reflection": 13045.1767578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.0408661365509033,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 61.25468444824219,
+ "cost_distorsion": 18.652671813964844,
+ "cost_thickness": 3351.93994140625,
+ "cost_beam_compression": 1.9135743379592896,
+ "cost_non_linearity": 624.7029418945312,
+ "cost_distance_total_intern_reflection": 13045.1767578125
+ },
+ "weighted components": {
+ "cost_dispersion": 4.081732273101807,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 61.25468444824219,
+ "cost_distorsion": 18.652671813964844,
+ "cost_thickness": 3351.93994140625,
+ "cost_beam_compression": 1.9135743379592896,
+ "cost_non_linearity": 624.7029418945312,
+ "cost_distance_total_intern_reflection": 13045.1767578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_680.json b/outputs/amici/optimization_results/step2/score_details_iteration_680.json
new file mode 100755
index 0000000..fb1409a
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_680.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.462971806526184,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 12.060789108276367,
+ "cost_distorsion": 20.201351165771484,
+ "cost_thickness": 3350.2666015625,
+ "cost_beam_compression": 1.909525990486145,
+ "cost_non_linearity": 621.2307739257812,
+ "cost_distance_total_intern_reflection": 13043.966796875
+ },
+ "weighted components": {
+ "cost_dispersion": 2.925943613052368,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 12.060789108276367,
+ "cost_distorsion": 20.201351165771484,
+ "cost_thickness": 3350.2666015625,
+ "cost_beam_compression": 1.909525990486145,
+ "cost_non_linearity": 621.2307739257812,
+ "cost_distance_total_intern_reflection": 13043.966796875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.462971806526184,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 12.060789108276367,
+ "cost_distorsion": 20.201351165771484,
+ "cost_thickness": 3350.2666015625,
+ "cost_beam_compression": 1.909525990486145,
+ "cost_non_linearity": 621.2307739257812,
+ "cost_distance_total_intern_reflection": 13043.966796875
+ },
+ "weighted components": {
+ "cost_dispersion": 2.925943613052368,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 12.060789108276367,
+ "cost_distorsion": 20.201351165771484,
+ "cost_thickness": 3350.2666015625,
+ "cost_beam_compression": 1.909525990486145,
+ "cost_non_linearity": 621.2307739257812,
+ "cost_distance_total_intern_reflection": 13043.966796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_690.json b/outputs/amici/optimization_results/step2/score_details_iteration_690.json
new file mode 100755
index 0000000..45e9cfa
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_690.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.7885448932647705,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 26.648406982421875,
+ "cost_distorsion": 17.137252807617188,
+ "cost_thickness": 3347.046875,
+ "cost_beam_compression": 1.9087356328964233,
+ "cost_non_linearity": 621.7481689453125,
+ "cost_distance_total_intern_reflection": 13042.38671875
+ },
+ "weighted components": {
+ "cost_dispersion": 1.577089786529541,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 26.648406982421875,
+ "cost_distorsion": 17.137252807617188,
+ "cost_thickness": 3347.046875,
+ "cost_beam_compression": 1.9087356328964233,
+ "cost_non_linearity": 621.7481689453125,
+ "cost_distance_total_intern_reflection": 13042.38671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.7885448932647705,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 26.648406982421875,
+ "cost_distorsion": 17.137252807617188,
+ "cost_thickness": 3347.046875,
+ "cost_beam_compression": 1.9087356328964233,
+ "cost_non_linearity": 621.7481689453125,
+ "cost_distance_total_intern_reflection": 13042.38671875
+ },
+ "weighted components": {
+ "cost_dispersion": 1.577089786529541,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 26.648406982421875,
+ "cost_distorsion": 17.137252807617188,
+ "cost_thickness": 3347.046875,
+ "cost_beam_compression": 1.9087356328964233,
+ "cost_non_linearity": 621.7481689453125,
+ "cost_distance_total_intern_reflection": 13042.38671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_70.json b/outputs/amici/optimization_results/step2/score_details_iteration_70.json
new file mode 100755
index 0000000..d07692b
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_70.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.70500659942627,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.479903221130371,
+ "cost_distorsion": 18.854848861694336,
+ "cost_thickness": 3340.990234375,
+ "cost_beam_compression": 1.9032073020935059,
+ "cost_non_linearity": 618.51318359375,
+ "cost_distance_total_intern_reflection": 12999.7802734375
+ },
+ "weighted components": {
+ "cost_dispersion": 21.41001319885254,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.479903221130371,
+ "cost_distorsion": 18.854848861694336,
+ "cost_thickness": 3340.990234375,
+ "cost_beam_compression": 1.9032073020935059,
+ "cost_non_linearity": 618.51318359375,
+ "cost_distance_total_intern_reflection": 12999.7802734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.70500659942627,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.479903221130371,
+ "cost_distorsion": 18.854848861694336,
+ "cost_thickness": 3340.990234375,
+ "cost_beam_compression": 1.9032073020935059,
+ "cost_non_linearity": 618.51318359375,
+ "cost_distance_total_intern_reflection": 12999.7802734375
+ },
+ "weighted components": {
+ "cost_dispersion": 21.41001319885254,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.479903221130371,
+ "cost_distorsion": 18.854848861694336,
+ "cost_thickness": 3340.990234375,
+ "cost_beam_compression": 1.9032073020935059,
+ "cost_non_linearity": 618.51318359375,
+ "cost_distance_total_intern_reflection": 12999.7802734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_700.json b/outputs/amici/optimization_results/step2/score_details_iteration_700.json
new file mode 100755
index 0000000..569bdd0
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_700.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.017913818359375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.238075256347656,
+ "cost_distorsion": 21.377151489257812,
+ "cost_thickness": 3349.91455078125,
+ "cost_beam_compression": 1.9042712450027466,
+ "cost_non_linearity": 615.6781005859375,
+ "cost_distance_total_intern_reflection": 13004.568359375
+ },
+ "weighted components": {
+ "cost_dispersion": 54.03582763671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.238075256347656,
+ "cost_distorsion": 21.377151489257812,
+ "cost_thickness": 3349.91455078125,
+ "cost_beam_compression": 1.9042712450027466,
+ "cost_non_linearity": 615.6781005859375,
+ "cost_distance_total_intern_reflection": 13004.568359375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 27.017913818359375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.238075256347656,
+ "cost_distorsion": 21.377151489257812,
+ "cost_thickness": 3349.91455078125,
+ "cost_beam_compression": 1.9042712450027466,
+ "cost_non_linearity": 615.6781005859375,
+ "cost_distance_total_intern_reflection": 13004.568359375
+ },
+ "weighted components": {
+ "cost_dispersion": 54.03582763671875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 13.238075256347656,
+ "cost_distorsion": 21.377151489257812,
+ "cost_thickness": 3349.91455078125,
+ "cost_beam_compression": 1.9042712450027466,
+ "cost_non_linearity": 615.6781005859375,
+ "cost_distance_total_intern_reflection": 13004.568359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_710.json b/outputs/amici/optimization_results/step2/score_details_iteration_710.json
new file mode 100755
index 0000000..d57b72d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_710.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.838281631469727,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.523286819458008,
+ "cost_distorsion": 23.69550323486328,
+ "cost_thickness": 3351.1376953125,
+ "cost_beam_compression": 1.9043523073196411,
+ "cost_non_linearity": 615.1063842773438,
+ "cost_distance_total_intern_reflection": 13048.8642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 61.67656326293945,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.523286819458008,
+ "cost_distorsion": 23.69550323486328,
+ "cost_thickness": 3351.1376953125,
+ "cost_beam_compression": 1.9043523073196411,
+ "cost_non_linearity": 615.1063842773438,
+ "cost_distance_total_intern_reflection": 13048.8642578125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 30.838281631469727,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.523286819458008,
+ "cost_distorsion": 23.69550323486328,
+ "cost_thickness": 3351.1376953125,
+ "cost_beam_compression": 1.9043523073196411,
+ "cost_non_linearity": 615.1063842773438,
+ "cost_distance_total_intern_reflection": 13048.8642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 61.67656326293945,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.523286819458008,
+ "cost_distorsion": 23.69550323486328,
+ "cost_thickness": 3351.1376953125,
+ "cost_beam_compression": 1.9043523073196411,
+ "cost_non_linearity": 615.1063842773438,
+ "cost_distance_total_intern_reflection": 13048.8642578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_720.json b/outputs/amici/optimization_results/step2/score_details_iteration_720.json
new file mode 100755
index 0000000..b4da158
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_720.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.593205451965332,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.064307928085327,
+ "cost_distorsion": 18.605676651000977,
+ "cost_thickness": 3345.884033203125,
+ "cost_beam_compression": 1.9053995609283447,
+ "cost_non_linearity": 618.6442260742188,
+ "cost_distance_total_intern_reflection": 13018.837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 19.186410903930664,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.064307928085327,
+ "cost_distorsion": 18.605676651000977,
+ "cost_thickness": 3345.884033203125,
+ "cost_beam_compression": 1.9053995609283447,
+ "cost_non_linearity": 618.6442260742188,
+ "cost_distance_total_intern_reflection": 13018.837890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.593205451965332,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.064307928085327,
+ "cost_distorsion": 18.605676651000977,
+ "cost_thickness": 3345.884033203125,
+ "cost_beam_compression": 1.9053995609283447,
+ "cost_non_linearity": 618.6442260742188,
+ "cost_distance_total_intern_reflection": 13018.837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 19.186410903930664,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.064307928085327,
+ "cost_distorsion": 18.605676651000977,
+ "cost_thickness": 3345.884033203125,
+ "cost_beam_compression": 1.9053995609283447,
+ "cost_non_linearity": 618.6442260742188,
+ "cost_distance_total_intern_reflection": 13018.837890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_730.json b/outputs/amici/optimization_results/step2/score_details_iteration_730.json
new file mode 100755
index 0000000..52959fc
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_730.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 14.508641242980957,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08108893781900406,
+ "cost_distorsion": 18.59021759033203,
+ "cost_thickness": 3347.396240234375,
+ "cost_beam_compression": 1.9051408767700195,
+ "cost_non_linearity": 617.6644287109375,
+ "cost_distance_total_intern_reflection": 13030.6513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 29.017282485961914,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08108893781900406,
+ "cost_distorsion": 18.59021759033203,
+ "cost_thickness": 3347.396240234375,
+ "cost_beam_compression": 1.9051408767700195,
+ "cost_non_linearity": 617.6644287109375,
+ "cost_distance_total_intern_reflection": 13030.6513671875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 14.508641242980957,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08108893781900406,
+ "cost_distorsion": 18.59021759033203,
+ "cost_thickness": 3347.396240234375,
+ "cost_beam_compression": 1.9051408767700195,
+ "cost_non_linearity": 617.6644287109375,
+ "cost_distance_total_intern_reflection": 13030.6513671875
+ },
+ "weighted components": {
+ "cost_dispersion": 29.017282485961914,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.08108893781900406,
+ "cost_distorsion": 18.59021759033203,
+ "cost_thickness": 3347.396240234375,
+ "cost_beam_compression": 1.9051408767700195,
+ "cost_non_linearity": 617.6644287109375,
+ "cost_distance_total_intern_reflection": 13030.6513671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_740.json b/outputs/amici/optimization_results/step2/score_details_iteration_740.json
new file mode 100755
index 0000000..d90c880
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_740.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.959368705749512,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.0938456058502197,
+ "cost_distorsion": 18.145355224609375,
+ "cost_thickness": 3347.641845703125,
+ "cost_beam_compression": 1.9067037105560303,
+ "cost_non_linearity": 619.2673950195312,
+ "cost_distance_total_intern_reflection": 13030.8828125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.918737411499023,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.0938456058502197,
+ "cost_distorsion": 18.145355224609375,
+ "cost_thickness": 3347.641845703125,
+ "cost_beam_compression": 1.9067037105560303,
+ "cost_non_linearity": 619.2673950195312,
+ "cost_distance_total_intern_reflection": 13030.8828125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.959368705749512,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.0938456058502197,
+ "cost_distorsion": 18.145355224609375,
+ "cost_thickness": 3347.641845703125,
+ "cost_beam_compression": 1.9067037105560303,
+ "cost_non_linearity": 619.2673950195312,
+ "cost_distance_total_intern_reflection": 13030.8828125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.918737411499023,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.0938456058502197,
+ "cost_distorsion": 18.145355224609375,
+ "cost_thickness": 3347.641845703125,
+ "cost_beam_compression": 1.9067037105560303,
+ "cost_non_linearity": 619.2673950195312,
+ "cost_distance_total_intern_reflection": 13030.8828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_750.json b/outputs/amici/optimization_results/step2/score_details_iteration_750.json
new file mode 100755
index 0000000..8b655ea
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_750.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.770082473754883,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.213385105133057,
+ "cost_distorsion": 17.767709732055664,
+ "cost_thickness": 3346.6162109375,
+ "cost_beam_compression": 1.9066095352172852,
+ "cost_non_linearity": 619.5226440429688,
+ "cost_distance_total_intern_reflection": 13035.490234375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.540164947509766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.213385105133057,
+ "cost_distorsion": 17.767709732055664,
+ "cost_thickness": 3346.6162109375,
+ "cost_beam_compression": 1.9066095352172852,
+ "cost_non_linearity": 619.5226440429688,
+ "cost_distance_total_intern_reflection": 13035.490234375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.770082473754883,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.213385105133057,
+ "cost_distorsion": 17.767709732055664,
+ "cost_thickness": 3346.6162109375,
+ "cost_beam_compression": 1.9066095352172852,
+ "cost_non_linearity": 619.5226440429688,
+ "cost_distance_total_intern_reflection": 13035.490234375
+ },
+ "weighted components": {
+ "cost_dispersion": 11.540164947509766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6.213385105133057,
+ "cost_distorsion": 17.767709732055664,
+ "cost_thickness": 3346.6162109375,
+ "cost_beam_compression": 1.9066095352172852,
+ "cost_non_linearity": 619.5226440429688,
+ "cost_distance_total_intern_reflection": 13035.490234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_760.json b/outputs/amici/optimization_results/step2/score_details_iteration_760.json
new file mode 100755
index 0000000..8961207
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_760.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.066039085388184,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.3658552169799805,
+ "cost_distorsion": 18.576473236083984,
+ "cost_thickness": 3347.317626953125,
+ "cost_beam_compression": 1.9060856103897095,
+ "cost_non_linearity": 618.7532348632812,
+ "cost_distance_total_intern_reflection": 13024.36328125
+ },
+ "weighted components": {
+ "cost_dispersion": 18.132078170776367,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.3658552169799805,
+ "cost_distorsion": 18.576473236083984,
+ "cost_thickness": 3347.317626953125,
+ "cost_beam_compression": 1.9060856103897095,
+ "cost_non_linearity": 618.7532348632812,
+ "cost_distance_total_intern_reflection": 13024.36328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.066039085388184,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.3658552169799805,
+ "cost_distorsion": 18.576473236083984,
+ "cost_thickness": 3347.317626953125,
+ "cost_beam_compression": 1.9060856103897095,
+ "cost_non_linearity": 618.7532348632812,
+ "cost_distance_total_intern_reflection": 13024.36328125
+ },
+ "weighted components": {
+ "cost_dispersion": 18.132078170776367,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.3658552169799805,
+ "cost_distorsion": 18.576473236083984,
+ "cost_thickness": 3347.317626953125,
+ "cost_beam_compression": 1.9060856103897095,
+ "cost_non_linearity": 618.7532348632812,
+ "cost_distance_total_intern_reflection": 13024.36328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_770.json b/outputs/amici/optimization_results/step2/score_details_iteration_770.json
new file mode 100755
index 0000000..cf8217c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_770.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 13.455338478088379,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.07258336246013641,
+ "cost_distorsion": 19.630918502807617,
+ "cost_thickness": 3348.081787109375,
+ "cost_beam_compression": 1.9055211544036865,
+ "cost_non_linearity": 617.7592163085938,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 26.910676956176758,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.07258336246013641,
+ "cost_distorsion": 19.630918502807617,
+ "cost_thickness": 3348.081787109375,
+ "cost_beam_compression": 1.9055211544036865,
+ "cost_non_linearity": 617.7592163085938,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 13.455338478088379,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.07258336246013641,
+ "cost_distorsion": 19.630918502807617,
+ "cost_thickness": 3348.081787109375,
+ "cost_beam_compression": 1.9055211544036865,
+ "cost_non_linearity": 617.7592163085938,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ },
+ "weighted components": {
+ "cost_dispersion": 26.910676956176758,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.07258336246013641,
+ "cost_distorsion": 19.630918502807617,
+ "cost_thickness": 3348.081787109375,
+ "cost_beam_compression": 1.9055211544036865,
+ "cost_non_linearity": 617.7592163085938,
+ "cost_distance_total_intern_reflection": 13006.8837890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_780.json b/outputs/amici/optimization_results/step2/score_details_iteration_780.json
new file mode 100755
index 0000000..e9958cb
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_780.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.915675163269043,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.38348388671875,
+ "cost_distorsion": 18.076515197753906,
+ "cost_thickness": 3347.9287109375,
+ "cost_beam_compression": 1.9089323282241821,
+ "cost_non_linearity": 621.5465087890625,
+ "cost_distance_total_intern_reflection": 13021.302734375
+ },
+ "weighted components": {
+ "cost_dispersion": 1.831350326538086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.38348388671875,
+ "cost_distorsion": 18.076515197753906,
+ "cost_thickness": 3347.9287109375,
+ "cost_beam_compression": 1.9089323282241821,
+ "cost_non_linearity": 621.5465087890625,
+ "cost_distance_total_intern_reflection": 13021.302734375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.915675163269043,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.38348388671875,
+ "cost_distorsion": 18.076515197753906,
+ "cost_thickness": 3347.9287109375,
+ "cost_beam_compression": 1.9089323282241821,
+ "cost_non_linearity": 621.5465087890625,
+ "cost_distance_total_intern_reflection": 13021.302734375
+ },
+ "weighted components": {
+ "cost_dispersion": 1.831350326538086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 22.38348388671875,
+ "cost_distorsion": 18.076515197753906,
+ "cost_thickness": 3347.9287109375,
+ "cost_beam_compression": 1.9089323282241821,
+ "cost_non_linearity": 621.5465087890625,
+ "cost_distance_total_intern_reflection": 13021.302734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_790.json b/outputs/amici/optimization_results/step2/score_details_iteration_790.json
new file mode 100755
index 0000000..b338834
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_790.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.741995334625244,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.557866096496582,
+ "cost_distorsion": 18.968753814697266,
+ "cost_thickness": 3348.332275390625,
+ "cost_beam_compression": 1.9075095653533936,
+ "cost_non_linearity": 619.8233642578125,
+ "cost_distance_total_intern_reflection": 13009.83984375
+ },
+ "weighted components": {
+ "cost_dispersion": 9.483990669250488,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.557866096496582,
+ "cost_distorsion": 18.968753814697266,
+ "cost_thickness": 3348.332275390625,
+ "cost_beam_compression": 1.9075095653533936,
+ "cost_non_linearity": 619.8233642578125,
+ "cost_distance_total_intern_reflection": 13009.83984375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.741995334625244,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.557866096496582,
+ "cost_distorsion": 18.968753814697266,
+ "cost_thickness": 3348.332275390625,
+ "cost_beam_compression": 1.9075095653533936,
+ "cost_non_linearity": 619.8233642578125,
+ "cost_distance_total_intern_reflection": 13009.83984375
+ },
+ "weighted components": {
+ "cost_dispersion": 9.483990669250488,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.557866096496582,
+ "cost_distorsion": 18.968753814697266,
+ "cost_thickness": 3348.332275390625,
+ "cost_beam_compression": 1.9075095653533936,
+ "cost_non_linearity": 619.8233642578125,
+ "cost_distance_total_intern_reflection": 13009.83984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_80.json b/outputs/amici/optimization_results/step2/score_details_iteration_80.json
new file mode 100755
index 0000000..53a92d4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_80.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 14.455682754516602,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.2817267179489136,
+ "cost_distorsion": 19.453330993652344,
+ "cost_thickness": 3344.504638671875,
+ "cost_beam_compression": 1.9039195775985718,
+ "cost_non_linearity": 617.7706909179688,
+ "cost_distance_total_intern_reflection": 13000.478515625
+ },
+ "weighted components": {
+ "cost_dispersion": 28.911365509033203,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.2817267179489136,
+ "cost_distorsion": 19.453330993652344,
+ "cost_thickness": 3344.504638671875,
+ "cost_beam_compression": 1.9039195775985718,
+ "cost_non_linearity": 617.7706909179688,
+ "cost_distance_total_intern_reflection": 13000.478515625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 14.455682754516602,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.2817267179489136,
+ "cost_distorsion": 19.453330993652344,
+ "cost_thickness": 3344.504638671875,
+ "cost_beam_compression": 1.9039195775985718,
+ "cost_non_linearity": 617.7706909179688,
+ "cost_distance_total_intern_reflection": 13000.478515625
+ },
+ "weighted components": {
+ "cost_dispersion": 28.911365509033203,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.2817267179489136,
+ "cost_distorsion": 19.453330993652344,
+ "cost_thickness": 3344.504638671875,
+ "cost_beam_compression": 1.9039195775985718,
+ "cost_non_linearity": 617.7706909179688,
+ "cost_distance_total_intern_reflection": 13000.478515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_800.json b/outputs/amici/optimization_results/step2/score_details_iteration_800.json
new file mode 100755
index 0000000..55bcdd5
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_800.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.173332214355469,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5436694622039795,
+ "cost_distorsion": 18.74213981628418,
+ "cost_thickness": 3348.08642578125,
+ "cost_beam_compression": 1.907031536102295,
+ "cost_non_linearity": 619.4795532226562,
+ "cost_distance_total_intern_reflection": 13015.3271484375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.346664428710938,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5436694622039795,
+ "cost_distorsion": 18.74213981628418,
+ "cost_thickness": 3348.08642578125,
+ "cost_beam_compression": 1.907031536102295,
+ "cost_non_linearity": 619.4795532226562,
+ "cost_distance_total_intern_reflection": 13015.3271484375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.173332214355469,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5436694622039795,
+ "cost_distorsion": 18.74213981628418,
+ "cost_thickness": 3348.08642578125,
+ "cost_beam_compression": 1.907031536102295,
+ "cost_non_linearity": 619.4795532226562,
+ "cost_distance_total_intern_reflection": 13015.3271484375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.346664428710938,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.5436694622039795,
+ "cost_distorsion": 18.74213981628418,
+ "cost_thickness": 3348.08642578125,
+ "cost_beam_compression": 1.907031536102295,
+ "cost_non_linearity": 619.4795532226562,
+ "cost_distance_total_intern_reflection": 13015.3271484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_810.json b/outputs/amici/optimization_results/step2/score_details_iteration_810.json
new file mode 100755
index 0000000..0a3213c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_810.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.561624526977539,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.6472423076629639,
+ "cost_distorsion": 19.966190338134766,
+ "cost_thickness": 3348.95947265625,
+ "cost_beam_compression": 1.9068044424057007,
+ "cost_non_linearity": 618.8082275390625,
+ "cost_distance_total_intern_reflection": 13010.046875
+ },
+ "weighted components": {
+ "cost_dispersion": 17.123249053955078,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.6472423076629639,
+ "cost_distorsion": 19.966190338134766,
+ "cost_thickness": 3348.95947265625,
+ "cost_beam_compression": 1.9068044424057007,
+ "cost_non_linearity": 618.8082275390625,
+ "cost_distance_total_intern_reflection": 13010.046875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.561624526977539,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.6472423076629639,
+ "cost_distorsion": 19.966190338134766,
+ "cost_thickness": 3348.95947265625,
+ "cost_beam_compression": 1.9068044424057007,
+ "cost_non_linearity": 618.8082275390625,
+ "cost_distance_total_intern_reflection": 13010.046875
+ },
+ "weighted components": {
+ "cost_dispersion": 17.123249053955078,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 0.6472423076629639,
+ "cost_distorsion": 19.966190338134766,
+ "cost_thickness": 3348.95947265625,
+ "cost_beam_compression": 1.9068044424057007,
+ "cost_non_linearity": 618.8082275390625,
+ "cost_distance_total_intern_reflection": 13010.046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_820.json b/outputs/amici/optimization_results/step2/score_details_iteration_820.json
new file mode 100755
index 0000000..0474cfb
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_820.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.414644241333008,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.1634271144866943,
+ "cost_distorsion": 19.10839080810547,
+ "cost_thickness": 3348.18115234375,
+ "cost_beam_compression": 1.9070130586624146,
+ "cost_non_linearity": 619.3751831054688,
+ "cost_distance_total_intern_reflection": 13008.31640625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.829288482666016,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.1634271144866943,
+ "cost_distorsion": 19.10839080810547,
+ "cost_thickness": 3348.18115234375,
+ "cost_beam_compression": 1.9070130586624146,
+ "cost_non_linearity": 619.3751831054688,
+ "cost_distance_total_intern_reflection": 13008.31640625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.414644241333008,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.1634271144866943,
+ "cost_distorsion": 19.10839080810547,
+ "cost_thickness": 3348.18115234375,
+ "cost_beam_compression": 1.9070130586624146,
+ "cost_non_linearity": 619.3751831054688,
+ "cost_distance_total_intern_reflection": 13008.31640625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.829288482666016,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.1634271144866943,
+ "cost_distorsion": 19.10839080810547,
+ "cost_thickness": 3348.18115234375,
+ "cost_beam_compression": 1.9070130586624146,
+ "cost_non_linearity": 619.3751831054688,
+ "cost_distance_total_intern_reflection": 13008.31640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_830.json b/outputs/amici/optimization_results/step2/score_details_iteration_830.json
new file mode 100755
index 0000000..2724c6c
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_830.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.797946929931641,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.2500003576278687,
+ "cost_distorsion": 19.666391372680664,
+ "cost_thickness": 3348.681884765625,
+ "cost_beam_compression": 1.9068539142608643,
+ "cost_non_linearity": 618.9802856445312,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ },
+ "weighted components": {
+ "cost_dispersion": 15.595893859863281,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.2500003576278687,
+ "cost_distorsion": 19.666391372680664,
+ "cost_thickness": 3348.681884765625,
+ "cost_beam_compression": 1.9068539142608643,
+ "cost_non_linearity": 618.9802856445312,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.797946929931641,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.2500003576278687,
+ "cost_distorsion": 19.666391372680664,
+ "cost_thickness": 3348.681884765625,
+ "cost_beam_compression": 1.9068539142608643,
+ "cost_non_linearity": 618.9802856445312,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ },
+ "weighted components": {
+ "cost_dispersion": 15.595893859863281,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.2500003576278687,
+ "cost_distorsion": 19.666391372680664,
+ "cost_thickness": 3348.681884765625,
+ "cost_beam_compression": 1.9068539142608643,
+ "cost_non_linearity": 618.9802856445312,
+ "cost_distance_total_intern_reflection": 13007.435546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_840.json b/outputs/amici/optimization_results/step2/score_details_iteration_840.json
new file mode 100755
index 0000000..b9b9930
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_840.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.655543327331543,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4266393184661865,
+ "cost_distorsion": 19.439533233642578,
+ "cost_thickness": 3348.543701171875,
+ "cost_beam_compression": 1.9070768356323242,
+ "cost_non_linearity": 619.3624267578125,
+ "cost_distance_total_intern_reflection": 13004.0419921875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.311086654663086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4266393184661865,
+ "cost_distorsion": 19.439533233642578,
+ "cost_thickness": 3348.543701171875,
+ "cost_beam_compression": 1.9070768356323242,
+ "cost_non_linearity": 619.3624267578125,
+ "cost_distance_total_intern_reflection": 13004.0419921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.655543327331543,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4266393184661865,
+ "cost_distorsion": 19.439533233642578,
+ "cost_thickness": 3348.543701171875,
+ "cost_beam_compression": 1.9070768356323242,
+ "cost_non_linearity": 619.3624267578125,
+ "cost_distance_total_intern_reflection": 13004.0419921875
+ },
+ "weighted components": {
+ "cost_dispersion": 13.311086654663086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.4266393184661865,
+ "cost_distorsion": 19.439533233642578,
+ "cost_thickness": 3348.543701171875,
+ "cost_beam_compression": 1.9070768356323242,
+ "cost_non_linearity": 619.3624267578125,
+ "cost_distance_total_intern_reflection": 13004.0419921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_850.json b/outputs/amici/optimization_results/step2/score_details_iteration_850.json
new file mode 100755
index 0000000..ae65ba2
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_850.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.879611968994141,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.476664066314697,
+ "cost_distorsion": 18.84042739868164,
+ "cost_thickness": 3348.22119140625,
+ "cost_beam_compression": 1.90743088722229,
+ "cost_non_linearity": 619.7835083007812,
+ "cost_distance_total_intern_reflection": 13010.74609375
+ },
+ "weighted components": {
+ "cost_dispersion": 9.759223937988281,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.476664066314697,
+ "cost_distorsion": 18.84042739868164,
+ "cost_thickness": 3348.22119140625,
+ "cost_beam_compression": 1.90743088722229,
+ "cost_non_linearity": 619.7835083007812,
+ "cost_distance_total_intern_reflection": 13010.74609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.879611968994141,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.476664066314697,
+ "cost_distorsion": 18.84042739868164,
+ "cost_thickness": 3348.22119140625,
+ "cost_beam_compression": 1.90743088722229,
+ "cost_non_linearity": 619.7835083007812,
+ "cost_distance_total_intern_reflection": 13010.74609375
+ },
+ "weighted components": {
+ "cost_dispersion": 9.759223937988281,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 5.476664066314697,
+ "cost_distorsion": 18.84042739868164,
+ "cost_thickness": 3348.22119140625,
+ "cost_beam_compression": 1.90743088722229,
+ "cost_non_linearity": 619.7835083007812,
+ "cost_distance_total_intern_reflection": 13010.74609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_860.json b/outputs/amici/optimization_results/step2/score_details_iteration_860.json
new file mode 100755
index 0000000..9496504
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_860.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.219376087188721,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.9183993339538574,
+ "cost_distorsion": 19.37372398376465,
+ "cost_thickness": 3348.40380859375,
+ "cost_beam_compression": 1.9068700075149536,
+ "cost_non_linearity": 619.09423828125,
+ "cost_distance_total_intern_reflection": 13004.11328125
+ },
+ "weighted components": {
+ "cost_dispersion": 14.438752174377441,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.9183993339538574,
+ "cost_distorsion": 19.37372398376465,
+ "cost_thickness": 3348.40380859375,
+ "cost_beam_compression": 1.9068700075149536,
+ "cost_non_linearity": 619.09423828125,
+ "cost_distance_total_intern_reflection": 13004.11328125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.219376087188721,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.9183993339538574,
+ "cost_distorsion": 19.37372398376465,
+ "cost_thickness": 3348.40380859375,
+ "cost_beam_compression": 1.9068700075149536,
+ "cost_non_linearity": 619.09423828125,
+ "cost_distance_total_intern_reflection": 13004.11328125
+ },
+ "weighted components": {
+ "cost_dispersion": 14.438752174377441,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 1.9183993339538574,
+ "cost_distorsion": 19.37372398376465,
+ "cost_thickness": 3348.40380859375,
+ "cost_beam_compression": 1.9068700075149536,
+ "cost_non_linearity": 619.09423828125,
+ "cost_distance_total_intern_reflection": 13004.11328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_870.json b/outputs/amici/optimization_results/step2/score_details_iteration_870.json
new file mode 100755
index 0000000..5435934
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_870.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.698441505432129,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.292971134185791,
+ "cost_distorsion": 19.46329689025879,
+ "cost_thickness": 3348.56787109375,
+ "cost_beam_compression": 1.9070613384246826,
+ "cost_non_linearity": 619.247802734375,
+ "cost_distance_total_intern_reflection": 13004.0859375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.396883010864258,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.292971134185791,
+ "cost_distorsion": 19.46329689025879,
+ "cost_thickness": 3348.56787109375,
+ "cost_beam_compression": 1.9070613384246826,
+ "cost_non_linearity": 619.247802734375,
+ "cost_distance_total_intern_reflection": 13004.0859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.698441505432129,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.292971134185791,
+ "cost_distorsion": 19.46329689025879,
+ "cost_thickness": 3348.56787109375,
+ "cost_beam_compression": 1.9070613384246826,
+ "cost_non_linearity": 619.247802734375,
+ "cost_distance_total_intern_reflection": 13004.0859375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.396883010864258,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.292971134185791,
+ "cost_distorsion": 19.46329689025879,
+ "cost_thickness": 3348.56787109375,
+ "cost_beam_compression": 1.9070613384246826,
+ "cost_non_linearity": 619.247802734375,
+ "cost_distance_total_intern_reflection": 13004.0859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_880.json b/outputs/amici/optimization_results/step2/score_details_iteration_880.json
new file mode 100755
index 0000000..525eba9
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_880.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.393946647644043,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.76497220993042,
+ "cost_distorsion": 19.409669876098633,
+ "cost_thickness": 3348.527587890625,
+ "cost_beam_compression": 1.9071400165557861,
+ "cost_non_linearity": 619.4314575195312,
+ "cost_distance_total_intern_reflection": 13003.3525390625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.787893295288086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.76497220993042,
+ "cost_distorsion": 19.409669876098633,
+ "cost_thickness": 3348.527587890625,
+ "cost_beam_compression": 1.9071400165557861,
+ "cost_non_linearity": 619.4314575195312,
+ "cost_distance_total_intern_reflection": 13003.3525390625
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.393946647644043,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.76497220993042,
+ "cost_distorsion": 19.409669876098633,
+ "cost_thickness": 3348.527587890625,
+ "cost_beam_compression": 1.9071400165557861,
+ "cost_non_linearity": 619.4314575195312,
+ "cost_distance_total_intern_reflection": 13003.3525390625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.787893295288086,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.76497220993042,
+ "cost_distorsion": 19.409669876098633,
+ "cost_thickness": 3348.527587890625,
+ "cost_beam_compression": 1.9071400165557861,
+ "cost_non_linearity": 619.4314575195312,
+ "cost_distance_total_intern_reflection": 13003.3525390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_890.json b/outputs/amici/optimization_results/step2/score_details_iteration_890.json
new file mode 100755
index 0000000..a069cd4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_890.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.408153533935547,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.7156383991241455,
+ "cost_distorsion": 19.42673110961914,
+ "cost_thickness": 3348.51171875,
+ "cost_beam_compression": 1.907120943069458,
+ "cost_non_linearity": 619.3615112304688,
+ "cost_distance_total_intern_reflection": 13003.4169921875
+ },
+ "weighted components": {
+ "cost_dispersion": 12.816307067871094,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.7156383991241455,
+ "cost_distorsion": 19.42673110961914,
+ "cost_thickness": 3348.51171875,
+ "cost_beam_compression": 1.907120943069458,
+ "cost_non_linearity": 619.3615112304688,
+ "cost_distance_total_intern_reflection": 13003.4169921875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.408153533935547,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.7156383991241455,
+ "cost_distorsion": 19.42673110961914,
+ "cost_thickness": 3348.51171875,
+ "cost_beam_compression": 1.907120943069458,
+ "cost_non_linearity": 619.3615112304688,
+ "cost_distance_total_intern_reflection": 13003.4169921875
+ },
+ "weighted components": {
+ "cost_dispersion": 12.816307067871094,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.7156383991241455,
+ "cost_distorsion": 19.42673110961914,
+ "cost_thickness": 3348.51171875,
+ "cost_beam_compression": 1.907120943069458,
+ "cost_non_linearity": 619.3615112304688,
+ "cost_distance_total_intern_reflection": 13003.4169921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_90.json b/outputs/amici/optimization_results/step2/score_details_iteration_90.json
new file mode 100755
index 0000000..3db7332
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_90.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.541290283203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.6773064136505127,
+ "cost_distorsion": 20.110807418823242,
+ "cost_thickness": 3350.4384765625,
+ "cost_beam_compression": 1.9057893753051758,
+ "cost_non_linearity": 616.96923828125,
+ "cost_distance_total_intern_reflection": 13005.0576171875
+ },
+ "weighted components": {
+ "cost_dispersion": 35.08258056640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.6773064136505127,
+ "cost_distorsion": 20.110807418823242,
+ "cost_thickness": 3350.4384765625,
+ "cost_beam_compression": 1.9057893753051758,
+ "cost_non_linearity": 616.96923828125,
+ "cost_distance_total_intern_reflection": 13005.0576171875
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.541290283203125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.6773064136505127,
+ "cost_distorsion": 20.110807418823242,
+ "cost_thickness": 3350.4384765625,
+ "cost_beam_compression": 1.9057893753051758,
+ "cost_non_linearity": 616.96923828125,
+ "cost_distance_total_intern_reflection": 13005.0576171875
+ },
+ "weighted components": {
+ "cost_dispersion": 35.08258056640625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 3.6773064136505127,
+ "cost_distorsion": 20.110807418823242,
+ "cost_thickness": 3350.4384765625,
+ "cost_beam_compression": 1.9057893753051758,
+ "cost_non_linearity": 616.96923828125,
+ "cost_distance_total_intern_reflection": 13005.0576171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_900.json b/outputs/amici/optimization_results/step2/score_details_iteration_900.json
new file mode 100755
index 0000000..837329f
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_900.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.492791652679443,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6279566287994385,
+ "cost_distorsion": 19.358247756958008,
+ "cost_thickness": 3348.519287109375,
+ "cost_beam_compression": 1.907106637954712,
+ "cost_non_linearity": 619.3396606445312,
+ "cost_distance_total_intern_reflection": 13003.224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.985583305358887,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6279566287994385,
+ "cost_distorsion": 19.358247756958008,
+ "cost_thickness": 3348.519287109375,
+ "cost_beam_compression": 1.907106637954712,
+ "cost_non_linearity": 619.3396606445312,
+ "cost_distance_total_intern_reflection": 13003.224609375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.492791652679443,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6279566287994385,
+ "cost_distorsion": 19.358247756958008,
+ "cost_thickness": 3348.519287109375,
+ "cost_beam_compression": 1.907106637954712,
+ "cost_non_linearity": 619.3396606445312,
+ "cost_distance_total_intern_reflection": 13003.224609375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.985583305358887,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.6279566287994385,
+ "cost_distorsion": 19.358247756958008,
+ "cost_thickness": 3348.519287109375,
+ "cost_beam_compression": 1.907106637954712,
+ "cost_non_linearity": 619.3396606445312,
+ "cost_distance_total_intern_reflection": 13003.224609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_910.json b/outputs/amici/optimization_results/step2/score_details_iteration_910.json
new file mode 100755
index 0000000..a5f14a4
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_910.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.575793743133545,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.5813024044036865,
+ "cost_distorsion": 19.41421890258789,
+ "cost_thickness": 3348.5234375,
+ "cost_beam_compression": 1.9070994853973389,
+ "cost_non_linearity": 619.312255859375,
+ "cost_distance_total_intern_reflection": 13003.2939453125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.15158748626709,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.5813024044036865,
+ "cost_distorsion": 19.41421890258789,
+ "cost_thickness": 3348.5234375,
+ "cost_beam_compression": 1.9070994853973389,
+ "cost_non_linearity": 619.312255859375,
+ "cost_distance_total_intern_reflection": 13003.2939453125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.575793743133545,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.5813024044036865,
+ "cost_distorsion": 19.41421890258789,
+ "cost_thickness": 3348.5234375,
+ "cost_beam_compression": 1.9070994853973389,
+ "cost_non_linearity": 619.312255859375,
+ "cost_distance_total_intern_reflection": 13003.2939453125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.15158748626709,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.5813024044036865,
+ "cost_distorsion": 19.41421890258789,
+ "cost_thickness": 3348.5234375,
+ "cost_beam_compression": 1.9070994853973389,
+ "cost_non_linearity": 619.312255859375,
+ "cost_distance_total_intern_reflection": 13003.2939453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_920.json b/outputs/amici/optimization_results/step2/score_details_iteration_920.json
new file mode 100755
index 0000000..5232474
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_920.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.632888317108154,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3836560249328613,
+ "cost_distorsion": 19.301084518432617,
+ "cost_thickness": 3348.532958984375,
+ "cost_beam_compression": 1.907060146331787,
+ "cost_non_linearity": 619.3494262695312,
+ "cost_distance_total_intern_reflection": 13003.5
+ },
+ "weighted components": {
+ "cost_dispersion": 13.265776634216309,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3836560249328613,
+ "cost_distorsion": 19.301084518432617,
+ "cost_thickness": 3348.532958984375,
+ "cost_beam_compression": 1.907060146331787,
+ "cost_non_linearity": 619.3494262695312,
+ "cost_distance_total_intern_reflection": 13003.5
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.632888317108154,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3836560249328613,
+ "cost_distorsion": 19.301084518432617,
+ "cost_thickness": 3348.532958984375,
+ "cost_beam_compression": 1.907060146331787,
+ "cost_non_linearity": 619.3494262695312,
+ "cost_distance_total_intern_reflection": 13003.5
+ },
+ "weighted components": {
+ "cost_dispersion": 13.265776634216309,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3836560249328613,
+ "cost_distorsion": 19.301084518432617,
+ "cost_thickness": 3348.532958984375,
+ "cost_beam_compression": 1.907060146331787,
+ "cost_non_linearity": 619.3494262695312,
+ "cost_distance_total_intern_reflection": 13003.5
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_930.json b/outputs/amici/optimization_results/step2/score_details_iteration_930.json
new file mode 100755
index 0000000..966acaa
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_930.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.7957844734191895,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3001973628997803,
+ "cost_distorsion": 19.445650100708008,
+ "cost_thickness": 3348.5205078125,
+ "cost_beam_compression": 1.9070351123809814,
+ "cost_non_linearity": 619.2365112304688,
+ "cost_distance_total_intern_reflection": 13003.3203125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.591568946838379,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3001973628997803,
+ "cost_distorsion": 19.445650100708008,
+ "cost_thickness": 3348.5205078125,
+ "cost_beam_compression": 1.9070351123809814,
+ "cost_non_linearity": 619.2365112304688,
+ "cost_distance_total_intern_reflection": 13003.3203125
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.7957844734191895,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3001973628997803,
+ "cost_distorsion": 19.445650100708008,
+ "cost_thickness": 3348.5205078125,
+ "cost_beam_compression": 1.9070351123809814,
+ "cost_non_linearity": 619.2365112304688,
+ "cost_distance_total_intern_reflection": 13003.3203125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.591568946838379,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.3001973628997803,
+ "cost_distorsion": 19.445650100708008,
+ "cost_thickness": 3348.5205078125,
+ "cost_beam_compression": 1.9070351123809814,
+ "cost_non_linearity": 619.2365112304688,
+ "cost_distance_total_intern_reflection": 13003.3203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_940.json b/outputs/amici/optimization_results/step2/score_details_iteration_940.json
new file mode 100755
index 0000000..2815d6d
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_940.json
@@ -0,0 +1,63 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.391786575317383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.8654768466949463,
+ "cost_distorsion": 19.275577545166016,
+ "cost_thickness": 3348.45361328125,
+ "cost_beam_compression": 1.9071173667907715,
+ "cost_non_linearity": 619.4014282226562,
+ "cost_distance_total_intern_reflection": 13004.380859375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.783573150634766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.8654768466949463,
+ "cost_distorsion": 19.275577545166016,
+ "cost_thickness": 3348.45361328125,
+ "cost_beam_compression": 1.9071173667907715,
+ "cost_non_linearity": 619.4014282226562,
+ "cost_distance_total_intern_reflection": 13004.380859375
+ }
+}{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.391786575317383,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.8654768466949463,
+ "cost_distorsion": 19.275577545166016,
+ "cost_thickness": 3348.45361328125,
+ "cost_beam_compression": 1.9071173667907715,
+ "cost_non_linearity": 619.4014282226562,
+ "cost_distance_total_intern_reflection": 13004.380859375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.783573150634766,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 2.8654768466949463,
+ "cost_distorsion": 19.275577545166016,
+ "cost_thickness": 3348.45361328125,
+ "cost_beam_compression": 1.9071173667907715,
+ "cost_non_linearity": 619.4014282226562,
+ "cost_distance_total_intern_reflection": 13004.380859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/optimization_results/step2/score_details_iteration_950.json b/outputs/amici/optimization_results/step2/score_details_iteration_950.json
new file mode 100755
index 0000000..7125624
--- /dev/null
+++ b/outputs/amici/optimization_results/step2/score_details_iteration_950.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 2.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": NaN,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": NaN,
+ "cost_distorsion": NaN,
+ "cost_thickness": NaN,
+ "cost_beam_compression": NaN,
+ "cost_non_linearity": NaN,
+ "cost_distance_total_intern_reflection": NaN
+ },
+ "weighted components": {
+ "cost_dispersion": NaN,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": NaN,
+ "cost_distorsion": NaN,
+ "cost_thickness": NaN,
+ "cost_beam_compression": NaN,
+ "cost_non_linearity": NaN,
+ "cost_distance_total_intern_reflection": NaN
+ }
+}
\ No newline at end of file
diff --git a/outputs/amici/temp.yml b/outputs/amici/temp.yml
new file mode 100755
index 0000000..04088d7
--- /dev/null
+++ b/outputs/amici/temp.yml
@@ -0,0 +1,33 @@
+coded aperture:
+ number of pixels along X: 25
+ number of pixels along Y: 25
+ pixel size along X: 210
+ pixel size along Y: 210
+detector:
+ number of pixels along X: 112
+ number of pixels along Y: 112
+ pixel size along X: 71
+ pixel size along Y: 71
+infos:
+ system name: HYACAMEO
+spectral range:
+ number of spectral samples: 10
+ wavelength max: 650
+ wavelength min: 450
+system architecture:
+ dispersive element:
+ A1: 24.33140144638986
+ A2: 35.55279436588468
+ A3: 24.33140144638986
+ alpha_c: 6.308127075897412
+ catalog: Schott
+ delta alpha c: 0
+ delta beta c: 0
+ glass1: N-BAK4
+ glass2: N-SF14
+ glass3: N-BAK4
+ index evaluation method: cauchy
+ type: amici
+ wavelength center: 520.0
+ focal lens: 75000
+ system type: DD-CASSI
diff --git a/outputs/single_prism/config_system.yml b/outputs/single_prism/config_system.yml
new file mode 100755
index 0000000..42f9f4f
--- /dev/null
+++ b/outputs/single_prism/config_system.yml
@@ -0,0 +1,28 @@
+coded aperture:
+ number of pixels along X: 25
+ number of pixels along Y: 25
+ pixel size along X: 210
+ pixel size along Y: 210
+detector:
+ number of pixels along X: 112
+ number of pixels along Y: 112
+ pixel size along X: 71
+ pixel size along Y: 71
+infos:
+ system name: HYACAMEO
+spectral range:
+ number of spectral samples: 10
+ wavelength max: 650
+ wavelength min: 450
+system architecture:
+ dispersive element:
+ A1: 52.32137323112955
+ alpha_c: 43.552100185939345
+ catalog: Schott
+ delta alpha c: 0
+ delta beta c: 0
+ glass1: N-PSK3
+ type: prism
+ wavelength center: 520.0
+ focal lens: 75000
+ system type: DD-CASSI
diff --git a/outputs/single_prism/optimization_plot_individual_step1.png b/outputs/single_prism/optimization_plot_individual_step1.png
new file mode 100755
index 0000000..4d35117
Binary files /dev/null and b/outputs/single_prism/optimization_plot_individual_step1.png differ
diff --git a/outputs/single_prism/optimization_plot_individual_step2.png b/outputs/single_prism/optimization_plot_individual_step2.png
new file mode 100755
index 0000000..c21be83
Binary files /dev/null and b/outputs/single_prism/optimization_plot_individual_step2.png differ
diff --git a/outputs/single_prism/optimization_plot_total_step1.png b/outputs/single_prism/optimization_plot_total_step1.png
new file mode 100755
index 0000000..f7f5564
Binary files /dev/null and b/outputs/single_prism/optimization_plot_total_step1.png differ
diff --git a/outputs/single_prism/optimization_plot_total_step2.png b/outputs/single_prism/optimization_plot_total_step2.png
new file mode 100755
index 0000000..1dac3c2
Binary files /dev/null and b/outputs/single_prism/optimization_plot_total_step2.png differ
diff --git a/outputs/single_prism/optimization_results/step1/optimization_details.json b/outputs/single_prism/optimization_results/step1/optimization_details.json
new file mode 100755
index 0000000..03f738a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/optimization_details.json
@@ -0,0 +1,2810 @@
+[
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 0,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.0000002530119,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.516800045967102,
+ "vd1": 64.11911010742188,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 40.899999202925926,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 889.3646240234375,
+ "deviation [deg]": 1716.7866259972475,
+ "max distortion [um]": 138.92218017578125,
+ "mean distortion [um]": 34.07305145263672,
+ "beam_compression [no units]": 0.8375058174133301
+ },
+ "current_loss": 284250.90625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 10,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.11021901564839,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5507619380950928,
+ "vd1": 64.09110260009766,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 42.11072536539155,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 966.396484375,
+ "deviation [deg]": 1847.1425894768815,
+ "max distortion [um]": 151.13096618652344,
+ "mean distortion [um]": 36.928829193115234,
+ "beam_compression [no units]": 0.8222978115081787
+ },
+ "current_loss": 66856.3359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 20,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.50171521358977,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5533912181854248,
+ "vd1": 64.04188537597656,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 42.024781095065286,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 991.0957641601562,
+ "deviation [deg]": 1876.2319826613725,
+ "max distortion [um]": 126.17764282226562,
+ "mean distortion [um]": 35.2078857421875,
+ "beam_compression [no units]": 0.8227810859680176
+ },
+ "current_loss": 39638.89453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 30,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.72424960693795,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5515049695968628,
+ "vd1": 63.9898796081543,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.86234553622404,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.2086181640625,
+ "deviation [deg]": 1880.2815744995162,
+ "max distortion [um]": 110.32144165039062,
+ "mean distortion [um]": 35.45071792602539,
+ "beam_compression [no units]": 0.8245185017585754
+ },
+ "current_loss": 34577.44140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 40,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.47857794777635,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548723936080933,
+ "vd1": 63.94462585449219,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.75185698111533,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.5013427734375,
+ "deviation [deg]": 1880.5713930863783,
+ "max distortion [um]": 110.6009750366211,
+ "mean distortion [um]": 35.347129821777344,
+ "beam_compression [no units]": 0.8251384496688843
+ },
+ "current_loss": 35265.7109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 50,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.33884593773623,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5578190088272095,
+ "vd1": 63.8923225402832,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.67428310761691,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1001.9638671875,
+ "deviation [deg]": 1884.5610978258794,
+ "max distortion [um]": 110.20083618164062,
+ "mean distortion [um]": 35.413482666015625,
+ "beam_compression [no units]": 0.825506329536438
+ },
+ "current_loss": 41813.671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 60,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.39375382847396,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5561200380325317,
+ "vd1": 63.83152389526367,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.63282727444952,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1001.2174072265625,
+ "deviation [deg]": 1880.9779259457775,
+ "max distortion [um]": 112.32579803466797,
+ "mean distortion [um]": 35.40770721435547,
+ "beam_compression [no units]": 0.8260890245437622
+ },
+ "current_loss": 36938.703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 70,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.34942931585517,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5550318956375122,
+ "vd1": 63.77676773071289,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.679696032534146,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.7578125,
+ "deviation [deg]": 1874.661585567403,
+ "max distortion [um]": 112.41710662841797,
+ "mean distortion [um]": 35.1622200012207,
+ "beam_compression [no units]": 0.8257851600646973
+ },
+ "current_loss": 35277.6171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 80,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.36442158108334,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5561679601669312,
+ "vd1": 63.728729248046875,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.57943227061294,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.283447265625,
+ "deviation [deg]": 1879.6890419286394,
+ "max distortion [um]": 113.8338394165039,
+ "mean distortion [um]": 35.37784957885742,
+ "beam_compression [no units]": 0.8265746235847473
+ },
+ "current_loss": 37169.85546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 90,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.285881235817364,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5557645559310913,
+ "vd1": 63.68658447265625,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.652184030557336,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.6586303710938,
+ "deviation [deg]": 1874.2111209312625,
+ "max distortion [um]": 112.76451873779297,
+ "mean distortion [um]": 35.12367248535156,
+ "beam_compression [no units]": 0.8259515166282654
+ },
+ "current_loss": 35940.78125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 100,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.300569557627476,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5560404062271118,
+ "vd1": 63.65048599243164,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55455672165576,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.6762084960938,
+ "deviation [deg]": 1875.9847844549313,
+ "max distortion [um]": 111.17615509033203,
+ "mean distortion [um]": 35.26061248779297,
+ "beam_compression [no units]": 0.8268181085586548
+ },
+ "current_loss": 36080.8515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 110,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.273392234919996,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5552012920379639,
+ "vd1": 63.619911193847656,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55188611769028,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.792724609375,
+ "deviation [deg]": 1871.4711768853335,
+ "max distortion [um]": 108.85271453857422,
+ "mean distortion [um]": 35.11482620239258,
+ "beam_compression [no units]": 0.8269413709640503
+ },
+ "current_loss": 34192.2578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 120,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.28876357564711,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5554325580596924,
+ "vd1": 63.594520568847656,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.49624398161677,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.0682373046875,
+ "deviation [deg]": 1873.1174163998467,
+ "max distortion [um]": 112.57505798339844,
+ "mean distortion [um]": 35.21598815917969,
+ "beam_compression [no units]": 0.8274248838424683
+ },
+ "current_loss": 35281.875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 130,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.25285385608577,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5556244850158691,
+ "vd1": 63.573822021484375,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53821207897192,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8858642578125,
+ "deviation [deg]": 1872.0252418308048,
+ "max distortion [um]": 108.45843505859375,
+ "mean distortion [um]": 35.14189529418945,
+ "beam_compression [no units]": 0.8270167708396912
+ },
+ "current_loss": 34724.859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 140,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.235559817107294,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5556429624557495,
+ "vd1": 63.55671691894531,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.56409849592627,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.150390625,
+ "deviation [deg]": 1871.2283499999612,
+ "max distortion [um]": 110.5599594116211,
+ "mean distortion [um]": 35.073204040527344,
+ "beam_compression [no units]": 0.8267764449119568
+ },
+ "current_loss": 35312.02734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 150,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.2648271777008,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5552972555160522,
+ "vd1": 63.54240417480469,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53961568284635,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9954223632812,
+ "deviation [deg]": 1871.4132568811717,
+ "max distortion [um]": 108.45159912109375,
+ "mean distortion [um]": 35.12771987915039,
+ "beam_compression [no units]": 0.827042281627655
+ },
+ "current_loss": 34269.33984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 160,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.23563836428275,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5549739599227905,
+ "vd1": 63.53156661987305,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.57050179827315,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.735595703125,
+ "deviation [deg]": 1868.738882651275,
+ "max distortion [um]": 111.8961181640625,
+ "mean distortion [um]": 35.0089111328125,
+ "beam_compression [no units]": 0.826796293258667
+ },
+ "current_loss": 34770.60546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 170,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.26382997008198,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5551033020019531,
+ "vd1": 63.52256774902344,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53360853147133,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8455810546875,
+ "deviation [deg]": 1870.6410630143669,
+ "max distortion [um]": 108.48162841796875,
+ "mean distortion [um]": 35.098724365234375,
+ "beam_compression [no units]": 0.8271202445030212
+ },
+ "current_loss": 34091.5078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 180,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.25188396922363,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5552507638931274,
+ "vd1": 63.5158805847168,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53181219171962,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8320922851562,
+ "deviation [deg]": 1870.591011388129,
+ "max distortion [um]": 108.69231414794922,
+ "mean distortion [um]": 35.09042739868164,
+ "beam_compression [no units]": 0.8271193504333496
+ },
+ "current_loss": 34426.70703125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 190,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.2448078932435,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5549640655517578,
+ "vd1": 63.51049041748047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.533772456011405,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.8284912109375,
+ "deviation [deg]": 1869.1631193610028,
+ "max distortion [um]": 109.55314636230469,
+ "mean distortion [um]": 35.049407958984375,
+ "beam_compression [no units]": 0.8271350264549255
+ },
+ "current_loss": 34268.46484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 200,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27217646124774,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5553150177001953,
+ "vd1": 63.506038665771484,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.49837158554323,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.414794921875,
+ "deviation [deg]": 1871.856508837549,
+ "max distortion [um]": 111.23401641845703,
+ "mean distortion [um]": 35.17414855957031,
+ "beam_compression [no units]": 0.8274186849594116
+ },
+ "current_loss": 35263.16796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 210,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.259728441485386,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5552161931991577,
+ "vd1": 63.502506256103516,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53693141850254,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.2410888671875,
+ "deviation [deg]": 1870.8611590301812,
+ "max distortion [um]": 108.65643310546875,
+ "mean distortion [um]": 35.09828567504883,
+ "beam_compression [no units]": 0.8270761966705322
+ },
+ "current_loss": 34541.765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 220,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.265076479605504,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554958701133728,
+ "vd1": 63.499935150146484,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.529308927388804,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.908203125,
+ "deviation [deg]": 1870.1674303765615,
+ "max distortion [um]": 108.40716552734375,
+ "mean distortion [um]": 35.09387969970703,
+ "beam_compression [no units]": 0.8271766304969788
+ },
+ "current_loss": 34097.5078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 230,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.257266158289596,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554884910583496,
+ "vd1": 63.498111724853516,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53704070152926,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.3267822265625,
+ "deviation [deg]": 1869.4988368190873,
+ "max distortion [um]": 109.28044128417969,
+ "mean distortion [um]": 35.060035705566406,
+ "beam_compression [no units]": 0.827114462852478
+ },
+ "current_loss": 34236.421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 240,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.25921617729764,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554903268814087,
+ "vd1": 63.49674606323242,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53153898415281,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.5303955078125,
+ "deviation [deg]": 1869.6640727554882,
+ "max distortion [um]": 108.89812469482422,
+ "mean distortion [um]": 35.09008026123047,
+ "beam_compression [no units]": 0.8271625638008118
+ },
+ "current_loss": 34215.8984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 250,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.26444810220187,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5549243688583374,
+ "vd1": 63.495723724365234,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52522447426514,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8992919921875,
+ "deviation [deg]": 1870.0070028933362,
+ "max distortion [um]": 108.30606842041016,
+ "mean distortion [um]": 35.10075759887695,
+ "beam_compression [no units]": 0.8272181749343872
+ },
+ "current_loss": 34155.6015625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 260,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.268098838313236,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548813343048096,
+ "vd1": 63.495033264160156,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52129370039779,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.006591796875,
+ "deviation [deg]": 1870.0301708950008,
+ "max distortion [um]": 108.68692779541016,
+ "mean distortion [um]": 35.11396026611328,
+ "beam_compression [no units]": 0.8272592425346375
+ },
+ "current_loss": 34207.23828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 270,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.267951989246086,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548731088638306,
+ "vd1": 63.494598388671875,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52381062510695,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9371337890625,
+ "deviation [deg]": 1869.9932332319695,
+ "max distortion [um]": 108.49600219726562,
+ "mean distortion [um]": 35.09390640258789,
+ "beam_compression [no units]": 0.8272371888160706
+ },
+ "current_loss": 34194.4375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 280,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.2666952344388,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548286437988281,
+ "vd1": 63.49436950683594,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.5269183611793,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7426147460938,
+ "deviation [deg]": 1869.7630831776967,
+ "max distortion [um]": 108.41107177734375,
+ "mean distortion [um]": 35.08759307861328,
+ "beam_compression [no units]": 0.8272138833999634
+ },
+ "current_loss": 34143.671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 290,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.267511442044615,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548148155212402,
+ "vd1": 63.49428176879883,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.525992870546766,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7606811523438,
+ "deviation [deg]": 1869.752810573185,
+ "max distortion [um]": 108.31195831298828,
+ "mean distortion [um]": 35.08049011230469,
+ "beam_compression [no units]": 0.8272240161895752
+ },
+ "current_loss": 34136.2109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 300,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.26802712132695,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548145771026611,
+ "vd1": 63.494266510009766,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52523813464347,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7941284179688,
+ "deviation [deg]": 1869.7783828014374,
+ "max distortion [um]": 108.27433013916016,
+ "mean distortion [um]": 35.090614318847656,
+ "beam_compression [no units]": 0.8272309899330139
+ },
+ "current_loss": 34164.8125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 310,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.268040781705295,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5548079013824463,
+ "vd1": 63.49425506591797,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52529277615684,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7628173828125,
+ "deviation [deg]": 1869.7532477052919,
+ "max distortion [um]": 108.28876495361328,
+ "mean distortion [um]": 35.09393310546875,
+ "beam_compression [no units]": 0.8272312879562378
+ },
+ "current_loss": 34194.51953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 320,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.269481951620165,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5547618865966797,
+ "vd1": 63.494171142578125,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.523523757161804,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.72265625,
+ "deviation [deg]": 1869.6540187170299,
+ "max distortion [um]": 108.35929107666016,
+ "mean distortion [um]": 35.086692810058594,
+ "beam_compression [no units]": 0.827252984046936
+ },
+ "current_loss": 34163.8125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 330,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27014447996966,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5546473264694214,
+ "vd1": 63.49392318725586,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52458926667232,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.4476318359375,
+ "deviation [deg]": 1869.2586327263562,
+ "max distortion [um]": 108.40594482421875,
+ "mean distortion [um]": 35.0775032043457,
+ "beam_compression [no units]": 0.8272566795349121
+ },
+ "current_loss": 34020.68359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 340,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27073187623828,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5546224117279053,
+ "vd1": 63.49341583251953,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52970166326608,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.3492431640625,
+ "deviation [deg]": 1869.1956857029654,
+ "max distortion [um]": 108.68524169921875,
+ "mean distortion [um]": 35.074073791503906,
+ "beam_compression [no units]": 0.8272127509117126
+ },
+ "current_loss": 34072.79296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 350,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27692685781548,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554641604423523,
+ "vd1": 63.49258041381836,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52950700287474,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.68017578125,
+ "deviation [deg]": 1869.5797062588601,
+ "max distortion [um]": 108.34930419921875,
+ "mean distortion [um]": 35.09000015258789,
+ "beam_compression [no units]": 0.8272121548652649
+ },
+ "current_loss": 34046.296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 360,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.281544065694405,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554612398147583,
+ "vd1": 63.491390228271484,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53329092767492,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7897338867188,
+ "deviation [deg]": 1869.7040703432679,
+ "max distortion [um]": 108.38397216796875,
+ "mean distortion [um]": 35.10212707519531,
+ "beam_compression [no units]": 0.827180802822113
+ },
+ "current_loss": 34028.0078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 370,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.29103461354614,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5546945333480835,
+ "vd1": 63.48984909057617,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.529438700983036,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.487060546875,
+ "deviation [deg]": 1870.4904710035464,
+ "max distortion [um]": 109.19692993164062,
+ "mean distortion [um]": 35.13956069946289,
+ "beam_compression [no units]": 0.8272064328193665
+ },
+ "current_loss": 34371.4296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 380,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.28726776421888,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5545017719268799,
+ "vd1": 63.48801040649414,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54219749435262,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6934814453125,
+ "deviation [deg]": 1869.5812362212343,
+ "max distortion [um]": 108.75750732421875,
+ "mean distortion [um]": 35.08559799194336,
+ "beam_compression [no units]": 0.8271121382713318
+ },
+ "current_loss": 33982.140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 390,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.28922461341609,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5544726848602295,
+ "vd1": 63.48597717285156,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53833843747156,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7830200195312,
+ "deviation [deg]": 1869.5700893525088,
+ "max distortion [um]": 108.51727294921875,
+ "mean distortion [um]": 35.09111785888672,
+ "beam_compression [no units]": 0.8271509408950806
+ },
+ "current_loss": 33904.8515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 400,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27903738626901,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554409384727478,
+ "vd1": 63.483863830566406,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.542426305689816,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.1728515625,
+ "deviation [deg]": 1868.8195335249943,
+ "max distortion [um]": 109.27653503417969,
+ "mean distortion [um]": 35.07038497924805,
+ "beam_compression [no units]": 0.8271207809448242
+ },
+ "current_loss": 34020.48828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 410,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.287182386854255,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5545293092727661,
+ "vd1": 63.48138427734375,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.533810022051846,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.972900390625,
+ "deviation [deg]": 1869.6802466434428,
+ "max distortion [um]": 108.30802154541016,
+ "mean distortion [um]": 35.094505310058594,
+ "beam_compression [no units]": 0.8271859288215637
+ },
+ "current_loss": 33988.828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 420,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.279242291944115,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5545835494995117,
+ "vd1": 63.47893142700195,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.549679966588364,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6153564453125,
+ "deviation [deg]": 1869.48441145956,
+ "max distortion [um]": 109.42350769042969,
+ "mean distortion [um]": 35.082008361816406,
+ "beam_compression [no units]": 0.8270334601402283
+ },
+ "current_loss": 34359.8203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 430,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.28057417883227,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5544347763061523,
+ "vd1": 63.476646423339844,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55275355171487,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.2979125976562,
+ "deviation [deg]": 1868.9963534622277,
+ "max distortion [um]": 109.73307800292969,
+ "mean distortion [um]": 35.06202697753906,
+ "beam_compression [no units]": 0.8270230293273926
+ },
+ "current_loss": 34206.96875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 440,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.28812153786513,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5545787811279297,
+ "vd1": 63.47473907470703,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.542276041528076,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.1541748046875,
+ "deviation [deg]": 1869.9145494527309,
+ "max distortion [um]": 108.62347412109375,
+ "mean distortion [um]": 35.10640335083008,
+ "beam_compression [no units]": 0.82710200548172
+ },
+ "current_loss": 34216.421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 450,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.29232893439386,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5532464981079102,
+ "vd1": 63.47318649291992,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53782275818922,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 995.8703002929688,
+ "deviation [deg]": 1865.1401925813786,
+ "max distortion [um]": 110.1671371459961,
+ "mean distortion [um]": 34.9798583984375,
+ "beam_compression [no units]": 0.8273007869720459
+ },
+ "current_loss": 33759.9609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 460,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.33378818265584,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5532923936843872,
+ "vd1": 63.47123718261719,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52369451189105,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.9491577148438,
+ "deviation [deg]": 1867.3973242152576,
+ "max distortion [um]": 109.0221176147461,
+ "mean distortion [um]": 35.07514953613281,
+ "beam_compression [no units]": 0.827424943447113
+ },
+ "current_loss": 33307.625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 470,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.328672370967496,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5537484884262085,
+ "vd1": 63.469825744628906,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.56890011891279,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.4856567382812,
+ "deviation [deg]": 1868.853629829331,
+ "max distortion [um]": 109.42814636230469,
+ "mean distortion [um]": 35.07555389404297,
+ "beam_compression [no units]": 0.8269557952880859
+ },
+ "current_loss": 33500.94921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 480,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.279576971213444,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5542030334472656,
+ "vd1": 63.471580505371094,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.51366437909489,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.1436767578125,
+ "deviation [deg]": 1868.0755346790834,
+ "max distortion [um]": 108.33145141601562,
+ "mean distortion [um]": 35.06700897216797,
+ "beam_compression [no units]": 0.8274093270301819
+ },
+ "current_loss": 33672.96875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 490,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.27996629199613,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5533592700958252,
+ "vd1": 63.47105407714844,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53795594687804,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 995.6580810546875,
+ "deviation [deg]": 1864.9402046424807,
+ "max distortion [um]": 110.5728988647461,
+ "mean distortion [um]": 34.98295974731445,
+ "beam_compression [no units]": 0.8272861242294312
+ },
+ "current_loss": 33901.02734375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 500,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.36231788281898,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5547192096710205,
+ "vd1": 63.46903991699219,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.530442738791024,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.967529296875,
+ "deviation [deg]": 1874.1938542130406,
+ "max distortion [um]": 113.50718688964844,
+ "mean distortion [um]": 35.27724075317383,
+ "beam_compression [no units]": 0.8271941542625427
+ },
+ "current_loss": 36049.3828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 510,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.298383897093075,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554137110710144,
+ "vd1": 63.47090530395508,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.525624040331586,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6599731445312,
+ "deviation [deg]": 1868.7777874087874,
+ "max distortion [um]": 108.63296508789062,
+ "mean distortion [um]": 35.08797073364258,
+ "beam_compression [no units]": 0.8273073434829712
+ },
+ "current_loss": 33670.4609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 520,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.328180597347256,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539791584014893,
+ "vd1": 63.47043228149414,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.531743889827915,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.4603881835938,
+ "deviation [deg]": 1869.689207851634,
+ "max distortion [um]": 109.7064437866211,
+ "mean distortion [um]": 35.14009475708008,
+ "beam_compression [no units]": 0.8272696137428284
+ },
+ "current_loss": 33738.24609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 530,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.33349448452152,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5545003414154053,
+ "vd1": 63.47140121459961,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.48154199942832,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1001.637451171875,
+ "deviation [deg]": 1871.912243181176,
+ "max distortion [um]": 114.17343139648438,
+ "mean distortion [um]": 35.22282791137695,
+ "beam_compression [no units]": 0.8276689052581787
+ },
+ "current_loss": 35613.5
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 540,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.34891022147824,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.552722454071045,
+ "vd1": 63.46967315673828,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.56441951481725,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.6839599609375,
+ "deviation [deg]": 1866.0269150601864,
+ "max distortion [um]": 109.78018951416016,
+ "mean distortion [um]": 35.013153076171875,
+ "beam_compression [no units]": 0.8271186947822571
+ },
+ "current_loss": 33549.9765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 550,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.30193559546148,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5533658266067505,
+ "vd1": 63.470279693603516,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.61026374452638,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 995.8546142578125,
+ "deviation [deg]": 1866.0839608001343,
+ "max distortion [um]": 113.36801147460938,
+ "mean distortion [um]": 34.962310791015625,
+ "beam_compression [no units]": 0.8266207575798035
+ },
+ "current_loss": 34494.0234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 560,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.25007738418816,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541249513626099,
+ "vd1": 63.47425079345703,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.43065367501714,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.5244140625,
+ "deviation [deg]": 1866.2907242866888,
+ "max distortion [um]": 111.27965545654297,
+ "mean distortion [um]": 35.052772521972656,
+ "beam_compression [no units]": 0.8281792402267456
+ },
+ "current_loss": 34367.359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 570,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.236956590792566,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5549650192260742,
+ "vd1": 63.46989059448242,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.63679219926271,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.0104370117188,
+ "deviation [deg]": 1868.7996440141314,
+ "max distortion [um]": 115.34308624267578,
+ "mean distortion [um]": 34.970279693603516,
+ "beam_compression [no units]": 0.8261867165565491
+ },
+ "current_loss": 37419.890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 580,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.32230663466105,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5533959865570068,
+ "vd1": 63.47039794921875,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.48989532078325,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.12353515625,
+ "deviation [deg]": 1867.2052046542835,
+ "max distortion [um]": 110.5538330078125,
+ "mean distortion [um]": 35.093162536621094,
+ "beam_compression [no units]": 0.8277226686477661
+ },
+ "current_loss": 33673.0546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 590,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.2999719160751,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5529226064682007,
+ "vd1": 63.46998977661133,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.56019162772102,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 995.1483154296875,
+ "deviation [deg]": 1864.3172913901753,
+ "max distortion [um]": 111.4906005859375,
+ "mean distortion [um]": 34.95056915283203,
+ "beam_compression [no units]": 0.8271337747573853
+ },
+ "current_loss": 34146.5859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 600,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.53342778190614,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5516808032989502,
+ "vd1": 63.46770095825195,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.36596495338795,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1004.1634521484375,
+ "deviation [deg]": 1871.4418890341724,
+ "max distortion [um]": 127.06806945800781,
+ "mean distortion [um]": 35.476558685302734,
+ "beam_compression [no units]": 0.8290587067604065
+ },
+ "current_loss": 38011.2421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 610,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.58547040828705,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5517011880874634,
+ "vd1": 63.47026443481445,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.394682483753265,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1006.1304931640625,
+ "deviation [deg]": 1874.1534194931542,
+ "max distortion [um]": 128.6430206298828,
+ "mean distortion [um]": 35.57640075683594,
+ "beam_compression [no units]": 0.8287942409515381
+ },
+ "current_loss": 38857.50390625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 620,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.768420440300424,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.55443274974823,
+ "vd1": 63.48112106323242,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.49022658495799,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1020.5572509765625,
+ "deviation [deg]": 1893.8827214390594,
+ "max distortion [um]": 140.80897521972656,
+ "mean distortion [um]": 36.26345443725586,
+ "beam_compression [no units]": 0.8275972008705139
+ },
+ "current_loss": 51259.078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 630,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.21567713643339,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5419081449508667,
+ "vd1": 63.47776794433594,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.621762367994094,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 962.228759765625,
+ "deviation [deg]": 1819.278040455871,
+ "max distortion [um]": 133.80274963378906,
+ "mean distortion [um]": 34.41701126098633,
+ "beam_compression [no units]": 0.8278955817222595
+ },
+ "current_loss": 788496.25
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 640,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 49.773251632945815,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5446110963821411,
+ "vd1": 63.500003814697266,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 42.25112673397034,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 945.426025390625,
+ "deviation [deg]": 1808.9019449178677,
+ "max distortion [um]": 179.32974243164062,
+ "mean distortion [um]": 46.96977996826172,
+ "beam_compression [no units]": 0.8217372298240662
+ },
+ "current_loss": 332234.3125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 650,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 49.63215016997711,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.557469367980957,
+ "vd1": 63.48357009887695,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 42.83292566256661,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 966.4669189453125,
+ "deviation [deg]": 1849.7756547226782,
+ "max distortion [um]": 198.16561889648438,
+ "mean distortion [um]": 55.12358856201172,
+ "beam_compression [no units]": 0.8146355152130127
+ },
+ "current_loss": 126522.5078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 660,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.80171419740965,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5512564182281494,
+ "vd1": 63.46428298950195,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.525156172373435,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1013.120361328125,
+ "deviation [deg]": 1883.4376683111957,
+ "max distortion [um]": 133.24822998046875,
+ "mean distortion [um]": 35.91297912597656,
+ "beam_compression [no units]": 0.8276532888412476
+ },
+ "current_loss": 42976.359375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 670,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.65029573369964,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5509439706802368,
+ "vd1": 63.46467208862305,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.38398640751303,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1007.156494140625,
+ "deviation [deg]": 1874.5818089578972,
+ "max distortion [um]": 131.5951385498047,
+ "mean distortion [um]": 35.66291809082031,
+ "beam_compression [no units]": 0.8289815783500671
+ },
+ "current_loss": 40174.34375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 680,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.56038653856018,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5531960725784302,
+ "vd1": 63.46006774902344,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.64908995486332,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1006.3651733398438,
+ "deviation [deg]": 1878.4945784465874,
+ "max distortion [um]": 115.1246109008789,
+ "mean distortion [um]": 35.440670013427734,
+ "beam_compression [no units]": 0.82628333568573
+ },
+ "current_loss": 35570.3828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 690,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.39501399837583,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5546932220458984,
+ "vd1": 63.46416473388672,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53329775786409,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1004.3668212890625,
+ "deviation [deg]": 1875.754852966712,
+ "max distortion [um]": 115.28549194335938,
+ "mean distortion [um]": 35.3285026550293,
+ "beam_compression [no units]": 0.8271711468696594
+ },
+ "current_loss": 37222.171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 700,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.158682622904216,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541002750396729,
+ "vd1": 63.47430419921875,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.49820766100315,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 992.8123168945312,
+ "deviation [deg]": 1861.6090394219952,
+ "max distortion [um]": 112.8384780883789,
+ "mean distortion [um]": 34.83161163330078,
+ "beam_compression [no units]": 0.8275632858276367
+ },
+ "current_loss": 35616.203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 710,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.38011735579603,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540492534637451,
+ "vd1": 63.47015380859375,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.50094656686033,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.2723388671875,
+ "deviation [deg]": 1872.5779953799556,
+ "max distortion [um]": 114.85628509521484,
+ "mean distortion [um]": 35.267635345458984,
+ "beam_compression [no units]": 0.827544093132019
+ },
+ "current_loss": 35294.64453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 720,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.413803848782536,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541895627975464,
+ "vd1": 63.46955871582031,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.5324986257312,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1003.772216796875,
+ "deviation [deg]": 1874.8117404461166,
+ "max distortion [um]": 115.33847045898438,
+ "mean distortion [um]": 35.32579040527344,
+ "beam_compression [no units]": 0.8272379636764526
+ },
+ "current_loss": 35851.38671875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 730,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.370493619255484,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541545152664185,
+ "vd1": 63.47209548950195,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.492842547410106,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.1917724609375,
+ "deviation [deg]": 1872.486853335671,
+ "max distortion [um]": 114.97274017333984,
+ "mean distortion [um]": 35.25553894042969,
+ "beam_compression [no units]": 0.8276060819625854
+ },
+ "current_loss": 35497.53125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 740,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.29617433089658,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541023015975952,
+ "vd1": 63.473567962646484,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55500409904639,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.1056518554688,
+ "deviation [deg]": 1868.5382390142165,
+ "max distortion [um]": 109.62541198730469,
+ "mean distortion [um]": 35.06171798706055,
+ "beam_compression [no units]": 0.8270416259765625
+ },
+ "current_loss": 34093.0078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 750,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.32788348411836,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5541216135025024,
+ "vd1": 63.47334671020508,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.523397398662155,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.87158203125,
+ "deviation [deg]": 1870.207427964341,
+ "max distortion [um]": 110.50917053222656,
+ "mean distortion [um]": 35.151214599609375,
+ "beam_compression [no units]": 0.8273295760154724
+ },
+ "current_loss": 34303.1953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 760,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.329191465344415,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554109811782837,
+ "vd1": 63.4736213684082,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.50868175609536,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.0772094726562,
+ "deviation [deg]": 1870.2284103054712,
+ "max distortion [um]": 111.4464111328125,
+ "mean distortion [um]": 35.16221618652344,
+ "beam_compression [no units]": 0.8274660706520081
+ },
+ "current_loss": 34507.8203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 770,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.3207459364357,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540986061096191,
+ "vd1": 63.47361373901367,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.52714034232733,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.4647216796875,
+ "deviation [deg]": 1869.761771781376,
+ "max distortion [um]": 109.7909164428711,
+ "mean distortion [um]": 35.12531280517578,
+ "beam_compression [no units]": 0.8272979855537415
+ },
+ "current_loss": 34122.046875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 780,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.32195487991879,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540926456451416,
+ "vd1": 63.47356033325195,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53151166339613,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.455810546875,
+ "deviation [deg]": 1869.800895104942,
+ "max distortion [um]": 109.5936508178711,
+ "mean distortion [um]": 35.125179290771484,
+ "beam_compression [no units]": 0.8272585272789001
+ },
+ "current_loss": 34077.8515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 790,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.3117710678663,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540814399719238,
+ "vd1": 63.47357177734375,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.5525657215127,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7493896484375,
+ "deviation [deg]": 1869.2468301594704,
+ "max distortion [um]": 108.82806396484375,
+ "mean distortion [um]": 35.082298278808594,
+ "beam_compression [no units]": 0.8270664811134338
+ },
+ "current_loss": 33907.328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 800,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.321992445959225,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540770292282104,
+ "vd1": 63.473602294921875,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.536484041111905,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.3731689453125,
+ "deviation [deg]": 1869.743412232887,
+ "max distortion [um]": 109.2733383178711,
+ "mean distortion [um]": 35.13005828857422,
+ "beam_compression [no units]": 0.8272145986557007
+ },
+ "current_loss": 33999.4375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 810,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.310142067749254,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554066777229309,
+ "vd1": 63.473628997802734,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.560031118275525,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.5504760742188,
+ "deviation [deg]": 1869.1106635081771,
+ "max distortion [um]": 109.32560729980469,
+ "mean distortion [um]": 35.07816696166992,
+ "beam_compression [no units]": 0.8269996643066406
+ },
+ "current_loss": 34015.5234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 820,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.3029328030803,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540560483932495,
+ "vd1": 63.47380447387695,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.564026778939976,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.179443359375,
+ "deviation [deg]": 1868.7069720074726,
+ "max distortion [um]": 109.88224029541016,
+ "mean distortion [um]": 35.05771255493164,
+ "beam_compression [no units]": 0.8269641995429993
+ },
+ "current_loss": 34143.328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 830,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.32329018190153,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.55405855178833,
+ "vd1": 63.473751068115234,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.53333190880994,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.39990234375,
+ "deviation [deg]": 1869.7396966099786,
+ "max distortion [um]": 109.5013656616211,
+ "mean distortion [um]": 35.1307373046875,
+ "beam_compression [no units]": 0.8272458910942078
+ },
+ "current_loss": 34046.49609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 840,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31346836987505,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540499687194824,
+ "vd1": 63.47383499145508,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.547036683379574,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8030395507812,
+ "deviation [deg]": 1869.2140452514543,
+ "max distortion [um]": 108.49920654296875,
+ "mean distortion [um]": 35.09189987182617,
+ "beam_compression [no units]": 0.8271209597587585
+ },
+ "current_loss": 33828.53125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 850,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.313560577428845,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540454387664795,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54598483424739,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8009033203125,
+ "deviation [deg]": 1869.200057024034,
+ "max distortion [um]": 108.45136260986328,
+ "mean distortion [um]": 35.105037689208984,
+ "beam_compression [no units]": 0.8271310925483704
+ },
+ "current_loss": 33819.2421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 860,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.317744068295475,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540434122085571,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.539711305494734,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.053466796875,
+ "deviation [deg]": 1869.4041977179475,
+ "max distortion [um]": 108.72769165039062,
+ "mean distortion [um]": 35.104740142822266,
+ "beam_compression [no units]": 0.827189028263092
+ },
+ "current_loss": 33880.4375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 870,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31808899284856,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540410280227661,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54006306023699,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.0489501953125,
+ "deviation [deg]": 1869.4127217940318,
+ "max distortion [um]": 108.74771118164062,
+ "mean distortion [um]": 35.09768295288086,
+ "beam_compression [no units]": 0.827186107635498
+ },
+ "current_loss": 33889.484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 880,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31701323805429,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540387630462646,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.542330683041435,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.98193359375,
+ "deviation [deg]": 1869.3495562045873,
+ "max distortion [um]": 108.53482818603516,
+ "mean distortion [um]": 35.102699279785156,
+ "beam_compression [no units]": 0.8271656036376953
+ },
+ "current_loss": 33848.3203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 890,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31525787943759,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540374517440796,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54548964553256,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8544921875,
+ "deviation [deg]": 1869.2571027639822,
+ "max distortion [um]": 108.35174560546875,
+ "mean distortion [um]": 35.094337463378906,
+ "beam_compression [no units]": 0.8271366953849792
+ },
+ "current_loss": 33817.640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 900,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.315934068165426,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540374517440796,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54435241903576,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8881225585938,
+ "deviation [deg]": 1869.2898876719983,
+ "max distortion [um]": 108.34195709228516,
+ "mean distortion [um]": 35.112545013427734,
+ "beam_compression [no units]": 0.8271470665931702
+ },
+ "current_loss": 33823.54296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 910,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31511444546502,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540368556976318,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.545783343666876,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.856689453125,
+ "deviation [deg]": 1869.2477044236841,
+ "max distortion [um]": 108.39642333984375,
+ "mean distortion [um]": 35.0866584777832,
+ "beam_compression [no units]": 0.8271340727806091
+ },
+ "current_loss": 33842.6328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 920,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31547986058562,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540355443954468,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54533596627624,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8746337890625,
+ "deviation [deg]": 1869.2608183868906,
+ "max distortion [um]": 108.35272979736328,
+ "mean distortion [um]": 35.09732437133789,
+ "beam_compression [no units]": 0.827138364315033
+ },
+ "current_loss": 33839.109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 930,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.316145804029695,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.554031252861023,
+ "vd1": 63.47386932373047,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.5447075888726,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8992309570312,
+ "deviation [deg]": 1869.2787408032727,
+ "max distortion [um]": 108.30631256103516,
+ "mean distortion [um]": 35.09135818481445,
+ "beam_compression [no units]": 0.8271445631980896
+ },
+ "current_loss": 33829.4296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 940,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.315312520950954,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540212392807007,
+ "vd1": 63.4738883972168,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.5472347588655,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7964477539062,
+ "deviation [deg]": 1869.1987456277136,
+ "max distortion [um]": 108.48699951171875,
+ "mean distortion [um]": 35.0936279296875,
+ "beam_compression [no units]": 0.8271225690841675
+ },
+ "current_loss": 33861.140625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 950,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31880616271141,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5540069341659546,
+ "vd1": 63.47392272949219,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54314689064725,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9639892578125,
+ "deviation [deg]": 1869.3215797497471,
+ "max distortion [um]": 108.53482818603516,
+ "mean distortion [um]": 35.10321807861328,
+ "beam_compression [no units]": 0.8271617889404297
+ },
+ "current_loss": 33851.1875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 960,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31843050230706,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.553987979888916,
+ "vd1": 63.47395706176758,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.54701960790665,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8612060546875,
+ "deviation [deg]": 1869.2315305357297,
+ "max distortion [um]": 108.38861846923828,
+ "mean distortion [um]": 35.094505310058594,
+ "beam_compression [no units]": 0.8271284699440002
+ },
+ "current_loss": 33795.546875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 970,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.31458510580435,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539683103561401,
+ "vd1": 63.4739875793457,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55841577853681,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.5013427734375,
+ "deviation [deg]": 1868.965754214746,
+ "max distortion [um]": 109.18474578857422,
+ "mean distortion [um]": 35.07314682006836,
+ "beam_compression [no units]": 0.8270260691642761
+ },
+ "current_loss": 33952.4296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 980,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.32502846504529,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539582967758179,
+ "vd1": 63.47399139404297,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.548085117417166,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.0556640625,
+ "deviation [deg]": 1869.4529379478647,
+ "max distortion [um]": 108.48575592041016,
+ "mean distortion [um]": 35.10441589355469,
+ "beam_compression [no units]": 0.827122151851654
+ },
+ "current_loss": 33777.48828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 990,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.316699049352465,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539474487304688,
+ "vd1": 63.47407150268555,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.565232307328486,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.4677734375,
+ "deviation [deg]": 1868.9946049338002,
+ "max distortion [um]": 109.47868347167969,
+ "mean distortion [um]": 35.07938766479492,
+ "beam_compression [no units]": 0.8269659876823425
+ },
+ "current_loss": 33996.1796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1000,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.30372168992944,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539371967315674,
+ "vd1": 63.47426986694336,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.58265953499578,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.687744140625,
+ "deviation [deg]": 1868.3052476012492,
+ "max distortion [um]": 110.9752426147461,
+ "mean distortion [um]": 35.02963638305664,
+ "beam_compression [no units]": 0.826806902885437
+ },
+ "current_loss": 34355.6328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1010,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.33115855982538,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.553945779800415,
+ "vd1": 63.474143981933594,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.55299943852499,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.2098388671875,
+ "deviation [deg]": 1869.7160914762069,
+ "max distortion [um]": 108.55045318603516,
+ "mean distortion [um]": 35.10744857788086,
+ "beam_compression [no units]": 0.8270785808563232
+ },
+ "current_loss": 33789.15234375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1020,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.29357544391738,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.553922176361084,
+ "vd1": 63.474456787109375,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.60599487629512,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.9365844726562,
+ "deviation [deg]": 1867.742877145747,
+ "max distortion [um]": 112.68566131591797,
+ "mean distortion [um]": 35.00086975097656,
+ "beam_compression [no units]": 0.8265939950942993
+ },
+ "current_loss": 34787.4375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 1030,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.294261877928975,
+ "A2": 0.0,
+ "A3": 0.0,
+ "nd1": 1.5539095401763916,
+ "vd1": 63.47498321533203,
+ "nd2": 1.0,
+ "vd2": 1.0,
+ "nd3": 1.0,
+ "vd3": 1.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.57785791200926,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.2249755859375,
+ "deviation [deg]": 1867.7242990312045,
+ "max distortion [um]": 111.20056915283203,
+ "mean distortion [um]": 35.016178131103516,
+ "beam_compression [no units]": 0.826854407787323
+ },
+ "current_loss": 34418.265625
+ }
+]
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_0.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_0.json
new file mode 100755
index 0000000..aab3ace
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_0.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 12240.1865234375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 6837259.5,
+ "cost_distorsion": 19299.373046875,
+ "cost_thickness": 3807.7177734375,
+ "cost_beam_compression": 1.6249418258666992,
+ "cost_non_linearity": 761.0279541015625,
+ "cost_distance_total_intern_reflection": 15509.056640625
+ },
+ "weighted components": {
+ "cost_dispersion": 244803.734375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 68.37259674072266,
+ "cost_distorsion": 19299.373046875,
+ "cost_thickness": 3807.7177734375,
+ "cost_beam_compression": 1.6249418258666992,
+ "cost_non_linearity": 761.0279541015625,
+ "cost_distance_total_intern_reflection": 15509.056640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_10.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_10.json
new file mode 100755
index 0000000..536ded7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_10.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1129.1962890625,
+ "cost_distance_glasses": 682.6902359015255,
+ "cost_deviation": 7914989.5,
+ "cost_distorsion": 22840.568359375,
+ "cost_thickness": 3824.523681640625,
+ "cost_beam_compression": 1.777021884918213,
+ "cost_non_linearity": 897.351318359375,
+ "cost_distance_total_intern_reflection": 15946.345703125
+ },
+ "weighted components": {
+ "cost_dispersion": 22583.92578125,
+ "cost_distance_glasses": 682.6902359015255,
+ "cost_deviation": 79.14989471435547,
+ "cost_distorsion": 22840.568359375,
+ "cost_thickness": 3824.523681640625,
+ "cost_beam_compression": 1.777021884918213,
+ "cost_non_linearity": 897.351318359375,
+ "cost_distance_total_intern_reflection": 15946.345703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_100.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_100.json
new file mode 100755
index 0000000..ec7bccc
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_100.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.4572579264640808,
+ "cost_distance_glasses": 2380.6675176725457,
+ "cost_deviation": 8164096.5,
+ "cost_distorsion": 12360.1376953125,
+ "cost_thickness": 3853.634521484375,
+ "cost_beam_compression": 1.7318189144134521,
+ "cost_non_linearity": 961.2293701171875,
+ "cost_distance_total_intern_reflection": 16432.666015625
+ },
+ "weighted components": {
+ "cost_dispersion": 9.145158767700195,
+ "cost_distance_glasses": 2380.6675176725457,
+ "cost_deviation": 81.64096069335938,
+ "cost_distorsion": 12360.1376953125,
+ "cost_thickness": 3853.634521484375,
+ "cost_beam_compression": 1.7318189144134521,
+ "cost_non_linearity": 961.2293701171875,
+ "cost_distance_total_intern_reflection": 16432.666015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_1000.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_1000.json
new file mode 100755
index 0000000..d2dc31e
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_1000.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.346527099609375,
+ "cost_distance_glasses": 670.1769854495903,
+ "cost_deviation": 8097392.5,
+ "cost_distorsion": 12315.5048828125,
+ "cost_thickness": 3854.11767578125,
+ "cost_beam_compression": 1.7319309711456299,
+ "cost_non_linearity": 955.6929321289062,
+ "cost_distance_total_intern_reflection": 16370.50390625
+ },
+ "weighted components": {
+ "cost_dispersion": 106.9305419921875,
+ "cost_distance_glasses": 670.1769854495903,
+ "cost_deviation": 80.97392272949219,
+ "cost_distorsion": 12315.5048828125,
+ "cost_thickness": 3854.11767578125,
+ "cost_beam_compression": 1.7319309711456299,
+ "cost_non_linearity": 955.6929321289062,
+ "cost_distance_total_intern_reflection": 16370.50390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_1010.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_1010.json
new file mode 100755
index 0000000..8b968f6
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_1010.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6243546009063721,
+ "cost_distance_glasses": 691.4143512786839,
+ "cost_deviation": 8109627.0,
+ "cost_distorsion": 11783.201171875,
+ "cost_thickness": 3858.322998046875,
+ "cost_beam_compression": 1.7292141914367676,
+ "cost_non_linearity": 958.3870239257812,
+ "cost_distance_total_intern_reflection": 16402.515625
+ },
+ "weighted components": {
+ "cost_dispersion": 12.487092018127441,
+ "cost_distance_glasses": 691.4143512786839,
+ "cost_deviation": 81.09626770019531,
+ "cost_distorsion": 11783.201171875,
+ "cost_thickness": 3858.322998046875,
+ "cost_beam_compression": 1.7292141914367676,
+ "cost_non_linearity": 958.3870239257812,
+ "cost_distance_total_intern_reflection": 16402.515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_1020.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_1020.json
new file mode 100755
index 0000000..3735e32
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_1020.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 9.384514808654785,
+ "cost_distance_glasses": 658.4741953002016,
+ "cost_deviation": 8092518.0,
+ "cost_distorsion": 12698.05859375,
+ "cost_thickness": 3852.563232421875,
+ "cost_beam_compression": 1.7340600490570068,
+ "cost_non_linearity": 954.4871826171875,
+ "cost_distance_total_intern_reflection": 16353.505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 187.69029235839844,
+ "cost_distance_glasses": 658.4741953002016,
+ "cost_deviation": 80.92517852783203,
+ "cost_distorsion": 12698.05859375,
+ "cost_thickness": 3852.563232421875,
+ "cost_beam_compression": 1.7340600490570068,
+ "cost_non_linearity": 954.4871826171875,
+ "cost_distance_total_intern_reflection": 16353.505859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_1030.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_1030.json
new file mode 100755
index 0000000..2b1ff33
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_1030.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.700760364532471,
+ "cost_distance_glasses": 643.8962832550347,
+ "cost_deviation": 8092356.5,
+ "cost_distorsion": 12365.56640625,
+ "cost_thickness": 3852.66845703125,
+ "cost_beam_compression": 1.73145592212677,
+ "cost_non_linearity": 954.709716796875,
+ "cost_distance_total_intern_reflection": 16364.755859375
+ },
+ "weighted components": {
+ "cost_dispersion": 154.0152130126953,
+ "cost_distance_glasses": 643.8962832550347,
+ "cost_deviation": 80.9235610961914,
+ "cost_distorsion": 12365.56640625,
+ "cost_thickness": 3852.66845703125,
+ "cost_beam_compression": 1.73145592212677,
+ "cost_non_linearity": 954.709716796875,
+ "cost_distance_total_intern_reflection": 16364.755859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_110.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_110.json
new file mode 100755
index 0000000..54f608a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_110.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.872064590454102,
+ "cost_distance_glasses": 965.5099963295097,
+ "cost_deviation": 8124857.5,
+ "cost_distorsion": 11848.9130859375,
+ "cost_thickness": 3849.471435546875,
+ "cost_beam_compression": 1.730586290359497,
+ "cost_non_linearity": 955.653564453125,
+ "cost_distance_total_intern_reflection": 16392.2890625
+ },
+ "weighted components": {
+ "cost_dispersion": 97.44129180908203,
+ "cost_distance_glasses": 965.5099963295097,
+ "cost_deviation": 81.24857330322266,
+ "cost_distorsion": 11848.9130859375,
+ "cost_thickness": 3849.471435546875,
+ "cost_beam_compression": 1.730586290359497,
+ "cost_non_linearity": 955.653564453125,
+ "cost_distance_total_intern_reflection": 16392.2890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_120.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_120.json
new file mode 100755
index 0000000..be91a82
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_120.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.0046563297510147095,
+ "cost_distance_glasses": 1282.0065874958123,
+ "cost_deviation": 8139157.5,
+ "cost_distorsion": 12673.1435546875,
+ "cost_thickness": 3851.825927734375,
+ "cost_beam_compression": 1.7257511615753174,
+ "cost_non_linearity": 960.03759765625,
+ "cost_distance_total_intern_reflection": 16431.65234375
+ },
+ "weighted components": {
+ "cost_dispersion": 0.09312659502029419,
+ "cost_distance_glasses": 1282.0065874958123,
+ "cost_deviation": 81.39157104492188,
+ "cost_distorsion": 12673.1435546875,
+ "cost_thickness": 3851.825927734375,
+ "cost_beam_compression": 1.7257511615753174,
+ "cost_non_linearity": 960.03759765625,
+ "cost_distance_total_intern_reflection": 16431.65234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_130.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_130.json
new file mode 100755
index 0000000..22e82bb
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_130.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2412984371185303,
+ "cost_distance_glasses": 1656.0038724987837,
+ "cost_deviation": 8129669.5,
+ "cost_distorsion": 11763.232421875,
+ "cost_thickness": 3846.3271484375,
+ "cost_beam_compression": 1.7298322916030884,
+ "cost_non_linearity": 957.783447265625,
+ "cost_distance_total_intern_reflection": 16393.658203125
+ },
+ "weighted components": {
+ "cost_dispersion": 24.825969696044922,
+ "cost_distance_glasses": 1656.0038724987837,
+ "cost_deviation": 81.29669189453125,
+ "cost_distorsion": 11763.232421875,
+ "cost_thickness": 3846.3271484375,
+ "cost_beam_compression": 1.7298322916030884,
+ "cost_non_linearity": 957.783447265625,
+ "cost_distance_total_intern_reflection": 16393.658203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_140.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_140.json
new file mode 100755
index 0000000..169cdc7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_140.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.4210548400878906,
+ "cost_distance_glasses": 1765.5957717916747,
+ "cost_deviation": 8122752.0,
+ "cost_distorsion": 12223.5048828125,
+ "cost_thickness": 3843.679931640625,
+ "cost_beam_compression": 1.7322355508804321,
+ "cost_non_linearity": 956.5672607421875,
+ "cost_distance_total_intern_reflection": 16371.298828125
+ },
+ "weighted components": {
+ "cost_dispersion": 68.42109680175781,
+ "cost_distance_glasses": 1765.5957717916747,
+ "cost_deviation": 81.2275161743164,
+ "cost_distorsion": 12223.5048828125,
+ "cost_thickness": 3843.679931640625,
+ "cost_beam_compression": 1.7322355508804321,
+ "cost_non_linearity": 956.5672607421875,
+ "cost_distance_total_intern_reflection": 16371.298828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_150.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_150.json
new file mode 100755
index 0000000..a27dd77
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_150.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.009176254272461,
+ "cost_distance_glasses": 1204.5151757311596,
+ "cost_deviation": 8124355.0,
+ "cost_distorsion": 11761.7490234375,
+ "cost_thickness": 3848.159912109375,
+ "cost_beam_compression": 1.7295771837234497,
+ "cost_non_linearity": 958.1420288085938,
+ "cost_distance_total_intern_reflection": 16393.615234375
+ },
+ "weighted components": {
+ "cost_dispersion": 20.18352508544922,
+ "cost_distance_glasses": 1204.5151757311596,
+ "cost_deviation": 81.24354553222656,
+ "cost_distorsion": 11761.7490234375,
+ "cost_thickness": 3848.159912109375,
+ "cost_beam_compression": 1.7295771837234497,
+ "cost_non_linearity": 958.1420288085938,
+ "cost_distance_total_intern_reflection": 16393.615234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_160.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_160.json
new file mode 100755
index 0000000..bb11fc4
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_160.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.656335830688477,
+ "cost_distance_glasses": 804.6353045223523,
+ "cost_deviation": 8101153.0,
+ "cost_distorsion": 12520.7412109375,
+ "cost_thickness": 3843.69189453125,
+ "cost_beam_compression": 1.73203706741333,
+ "cost_non_linearity": 953.8409423828125,
+ "cost_distance_total_intern_reflection": 16351.8251953125
+ },
+ "weighted components": {
+ "cost_dispersion": 213.126708984375,
+ "cost_distance_glasses": 804.6353045223523,
+ "cost_deviation": 81.01152801513672,
+ "cost_distorsion": 12520.7412109375,
+ "cost_thickness": 3843.69189453125,
+ "cost_beam_compression": 1.73203706741333,
+ "cost_non_linearity": 953.8409423828125,
+ "cost_distance_total_intern_reflection": 16351.8251953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_170.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_170.json
new file mode 100755
index 0000000..cf64457
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_170.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3326830863952637,
+ "cost_distance_glasses": 1017.5808728023525,
+ "cost_deviation": 8117652.5,
+ "cost_distorsion": 11768.263671875,
+ "cost_thickness": 3848.00732421875,
+ "cost_beam_compression": 1.7287975549697876,
+ "cost_non_linearity": 957.7521362304688,
+ "cost_distance_total_intern_reflection": 16390.34375
+ },
+ "weighted components": {
+ "cost_dispersion": 26.653661727905273,
+ "cost_distance_glasses": 1017.5808728023525,
+ "cost_deviation": 81.17652130126953,
+ "cost_distorsion": 11768.263671875,
+ "cost_thickness": 3848.00732421875,
+ "cost_beam_compression": 1.7287975549697876,
+ "cost_non_linearity": 957.7521362304688,
+ "cost_distance_total_intern_reflection": 16390.34375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_180.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_180.json
new file mode 100755
index 0000000..6cb5102
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_180.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3640084266662598,
+ "cost_distance_glasses": 1312.4247386952159,
+ "cost_deviation": 8117217.0,
+ "cost_distorsion": 11814.01953125,
+ "cost_thickness": 3846.1787109375,
+ "cost_beam_compression": 1.728806495666504,
+ "cost_non_linearity": 957.7875366210938,
+ "cost_distance_total_intern_reflection": 16386.1171875
+ },
+ "weighted components": {
+ "cost_dispersion": 27.280168533325195,
+ "cost_distance_glasses": 1312.4247386952159,
+ "cost_deviation": 81.17216491699219,
+ "cost_distorsion": 11814.01953125,
+ "cost_thickness": 3846.1787109375,
+ "cost_beam_compression": 1.728806495666504,
+ "cost_non_linearity": 957.7875366210938,
+ "cost_distance_total_intern_reflection": 16386.1171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_190.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_190.json
new file mode 100755
index 0000000..4500d55
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_190.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.715450286865234,
+ "cost_distance_glasses": 915.5864731538531,
+ "cost_deviation": 8104829.5,
+ "cost_distorsion": 12001.8916015625,
+ "cost_thickness": 3845.09521484375,
+ "cost_beam_compression": 1.7286497354507446,
+ "cost_non_linearity": 955.9725341796875,
+ "cost_distance_total_intern_reflection": 16372.8310546875
+ },
+ "weighted components": {
+ "cost_dispersion": 94.30900573730469,
+ "cost_distance_glasses": 915.5864731538531,
+ "cost_deviation": 81.04829406738281,
+ "cost_distorsion": 12001.8916015625,
+ "cost_thickness": 3845.09521484375,
+ "cost_beam_compression": 1.7286497354507446,
+ "cost_non_linearity": 955.9725341796875,
+ "cost_distance_total_intern_reflection": 16372.8310546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_20.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_20.json
new file mode 100755
index 0000000..57339b0
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_20.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 79.28541564941406,
+ "cost_distance_glasses": 896.0706341442659,
+ "cost_deviation": 8166248.0,
+ "cost_distorsion": 15920.7978515625,
+ "cost_thickness": 3884.5166015625,
+ "cost_beam_compression": 1.7721891403198242,
+ "cost_non_linearity": 943.0827026367188,
+ "cost_distance_total_intern_reflection": 16325.2880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 1585.708251953125,
+ "cost_distance_glasses": 896.0706341442659,
+ "cost_deviation": 81.6624755859375,
+ "cost_distorsion": 15920.7978515625,
+ "cost_thickness": 3884.5166015625,
+ "cost_beam_compression": 1.7721891403198242,
+ "cost_non_linearity": 943.0827026367188,
+ "cost_distance_total_intern_reflection": 16325.2880859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_200.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_200.json
new file mode 100755
index 0000000..c0d0443
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_200.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.17205482721328735,
+ "cost_distance_glasses": 1577.7029409232068,
+ "cost_deviation": 8128205.0,
+ "cost_distorsion": 12373.0068359375,
+ "cost_thickness": 3849.28564453125,
+ "cost_beam_compression": 1.7258131504058838,
+ "cost_non_linearity": 960.8130493164062,
+ "cost_distance_total_intern_reflection": 16415.91015625
+ },
+ "weighted components": {
+ "cost_dispersion": 3.441096544265747,
+ "cost_distance_glasses": 1577.7029409232068,
+ "cost_deviation": 81.28205108642578,
+ "cost_distorsion": 12373.0068359375,
+ "cost_thickness": 3849.28564453125,
+ "cost_beam_compression": 1.7258131504058838,
+ "cost_non_linearity": 960.8130493164062,
+ "cost_distance_total_intern_reflection": 16415.91015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_210.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_210.json
new file mode 100755
index 0000000..9614433
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_210.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.5759460926055908,
+ "cost_distance_glasses": 1446.1139087987071,
+ "cost_deviation": 8119562.5,
+ "cost_distorsion": 11806.220703125,
+ "cost_thickness": 3847.37939453125,
+ "cost_beam_compression": 1.7292380332946777,
+ "cost_non_linearity": 958.6014404296875,
+ "cost_distance_total_intern_reflection": 16389.009765625
+ },
+ "weighted components": {
+ "cost_dispersion": 11.518921852111816,
+ "cost_distance_glasses": 1446.1139087987071,
+ "cost_deviation": 81.19562530517578,
+ "cost_distorsion": 11806.220703125,
+ "cost_thickness": 3847.37939453125,
+ "cost_beam_compression": 1.7292380332946777,
+ "cost_non_linearity": 958.6014404296875,
+ "cost_distance_total_intern_reflection": 16389.009765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_220.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_220.json
new file mode 100755
index 0000000..9e63586
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_220.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1920204162597656,
+ "cost_distance_glasses": 1043.2799098458543,
+ "cost_deviation": 8113542.0,
+ "cost_distorsion": 11752.11328125,
+ "cost_thickness": 3848.1982421875,
+ "cost_beam_compression": 1.7282336950302124,
+ "cost_non_linearity": 957.8792724609375,
+ "cost_distance_total_intern_reflection": 16389.3359375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.840408325195312,
+ "cost_distance_glasses": 1043.2799098458543,
+ "cost_deviation": 81.13542175292969,
+ "cost_distorsion": 11752.11328125,
+ "cost_thickness": 3848.1982421875,
+ "cost_beam_compression": 1.7282336950302124,
+ "cost_non_linearity": 957.8792724609375,
+ "cost_distance_total_intern_reflection": 16389.3359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_230.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_230.json
new file mode 100755
index 0000000..cc4aa69
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_230.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.7996578216552734,
+ "cost_distance_glasses": 972.9712515446477,
+ "cost_deviation": 8107742.0,
+ "cost_distorsion": 11942.21484375,
+ "cost_thickness": 3847.00244140625,
+ "cost_beam_compression": 1.7288553714752197,
+ "cost_non_linearity": 956.7374267578125,
+ "cost_distance_total_intern_reflection": 16378.6962890625
+ },
+ "weighted components": {
+ "cost_dispersion": 55.99315643310547,
+ "cost_distance_glasses": 972.9712515446477,
+ "cost_deviation": 81.0774154663086,
+ "cost_distorsion": 11942.21484375,
+ "cost_thickness": 3847.00244140625,
+ "cost_beam_compression": 1.7288553714752197,
+ "cost_non_linearity": 956.7374267578125,
+ "cost_distance_total_intern_reflection": 16378.6962890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_240.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_240.json
new file mode 100755
index 0000000..417688f
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_240.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.1597373485565186,
+ "cost_distance_glasses": 1043.9136392392807,
+ "cost_deviation": 8109175.5,
+ "cost_distorsion": 11858.8017578125,
+ "cost_thickness": 3847.301025390625,
+ "cost_beam_compression": 1.7283743619918823,
+ "cost_non_linearity": 957.1097412109375,
+ "cost_distance_total_intern_reflection": 16382.7568359375
+ },
+ "weighted components": {
+ "cost_dispersion": 43.19474792480469,
+ "cost_distance_glasses": 1043.9136392392807,
+ "cost_deviation": 81.09175109863281,
+ "cost_distorsion": 11858.8017578125,
+ "cost_thickness": 3847.301025390625,
+ "cost_beam_compression": 1.7283743619918823,
+ "cost_non_linearity": 957.1097412109375,
+ "cost_distance_total_intern_reflection": 16382.7568359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_250.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_250.json
new file mode 100755
index 0000000..f5b6fa1
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_250.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2115581035614014,
+ "cost_distance_glasses": 1122.8319833895782,
+ "cost_deviation": 8112150.0,
+ "cost_distorsion": 11730.2041015625,
+ "cost_thickness": 3848.10205078125,
+ "cost_beam_compression": 1.727818250656128,
+ "cost_non_linearity": 957.748291015625,
+ "cost_distance_total_intern_reflection": 16389.63671875
+ },
+ "weighted components": {
+ "cost_dispersion": 24.231163024902344,
+ "cost_distance_glasses": 1122.8319833895782,
+ "cost_deviation": 81.12149810791016,
+ "cost_distorsion": 11730.2041015625,
+ "cost_thickness": 3848.10205078125,
+ "cost_beam_compression": 1.727818250656128,
+ "cost_non_linearity": 957.748291015625,
+ "cost_distance_total_intern_reflection": 16389.63671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_260.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_260.json
new file mode 100755
index 0000000..e154ebb
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_260.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.9868598580360413,
+ "cost_distance_glasses": 1092.2249226006572,
+ "cost_deviation": 8112351.5,
+ "cost_distorsion": 11812.8486328125,
+ "cost_thickness": 3848.660888671875,
+ "cost_beam_compression": 1.7274075746536255,
+ "cost_non_linearity": 958.1463623046875,
+ "cost_distance_total_intern_reflection": 16392.76953125
+ },
+ "weighted components": {
+ "cost_dispersion": 19.737197875976562,
+ "cost_distance_glasses": 1092.2249226006572,
+ "cost_deviation": 81.1235122680664,
+ "cost_distorsion": 11812.8486328125,
+ "cost_thickness": 3848.660888671875,
+ "cost_beam_compression": 1.7274075746536255,
+ "cost_non_linearity": 958.1463623046875,
+ "cost_distance_total_intern_reflection": 16392.76953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_270.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_270.json
new file mode 100755
index 0000000..c0ceeea
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_270.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.129684567451477,
+ "cost_distance_glasses": 1119.5573827650842,
+ "cost_deviation": 8112030.0,
+ "cost_distorsion": 11771.3828125,
+ "cost_thickness": 3848.638427734375,
+ "cost_beam_compression": 1.7276281118392944,
+ "cost_non_linearity": 957.9623413085938,
+ "cost_distance_total_intern_reflection": 16391.453125
+ },
+ "weighted components": {
+ "cost_dispersion": 22.593690872192383,
+ "cost_distance_glasses": 1119.5573827650842,
+ "cost_deviation": 81.12030029296875,
+ "cost_distorsion": 11771.3828125,
+ "cost_thickness": 3848.638427734375,
+ "cost_beam_compression": 1.7276281118392944,
+ "cost_non_linearity": 957.9623413085938,
+ "cost_distance_total_intern_reflection": 16391.453125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_280.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_280.json
new file mode 100755
index 0000000..151f2d4
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_280.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.5810177326202393,
+ "cost_distance_glasses": 1082.2029500438632,
+ "cost_deviation": 8110034.5,
+ "cost_distorsion": 11752.9609375,
+ "cost_thickness": 3848.446044921875,
+ "cost_beam_compression": 1.7278611660003662,
+ "cost_non_linearity": 957.4374389648438,
+ "cost_distance_total_intern_reflection": 16388.17578125
+ },
+ "weighted components": {
+ "cost_dispersion": 31.62035369873047,
+ "cost_distance_glasses": 1082.2029500438632,
+ "cost_deviation": 81.100341796875,
+ "cost_distorsion": 11752.9609375,
+ "cost_thickness": 3848.446044921875,
+ "cost_beam_compression": 1.7278611660003662,
+ "cost_non_linearity": 957.4374389648438,
+ "cost_distance_total_intern_reflection": 16388.17578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_290.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_290.json
new file mode 100755
index 0000000..891a2ab
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_290.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.535911202430725,
+ "cost_distance_glasses": 1096.3274406907296,
+ "cost_deviation": 8109944.5,
+ "cost_distorsion": 11731.48046875,
+ "cost_thickness": 3848.5712890625,
+ "cost_beam_compression": 1.727759838104248,
+ "cost_non_linearity": 957.5162963867188,
+ "cost_distance_total_intern_reflection": 16388.76953125
+ },
+ "weighted components": {
+ "cost_dispersion": 30.718223571777344,
+ "cost_distance_glasses": 1096.3274406907296,
+ "cost_deviation": 81.09944152832031,
+ "cost_distorsion": 11731.48046875,
+ "cost_thickness": 3848.5712890625,
+ "cost_beam_compression": 1.727759838104248,
+ "cost_non_linearity": 957.5162963867188,
+ "cost_distance_total_intern_reflection": 16388.76953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_30.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_30.json
new file mode 100755
index 0000000..fe93807
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_30.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.2090489864349365,
+ "cost_distance_glasses": 879.5296756814959,
+ "cost_deviation": 8201538.0,
+ "cost_distorsion": 12170.8203125,
+ "cost_thickness": 3918.826171875,
+ "cost_beam_compression": 1.7548149824142456,
+ "cost_non_linearity": 956.4755249023438,
+ "cost_distance_total_intern_reflection": 16503.83984375
+ },
+ "weighted components": {
+ "cost_dispersion": 64.18097686767578,
+ "cost_distance_glasses": 879.5296756814959,
+ "cost_deviation": 82.015380859375,
+ "cost_distorsion": 12170.8203125,
+ "cost_thickness": 3918.826171875,
+ "cost_beam_compression": 1.7548149824142456,
+ "cost_non_linearity": 956.4755249023438,
+ "cost_distance_total_intern_reflection": 16503.83984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_300.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_300.json
new file mode 100755
index 0000000..21e92b6
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_300.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.454126238822937,
+ "cost_distance_glasses": 1133.6920454916576,
+ "cost_deviation": 8110166.5,
+ "cost_distorsion": 11723.3310546875,
+ "cost_thickness": 3848.650146484375,
+ "cost_beam_compression": 1.7276901006698608,
+ "cost_non_linearity": 957.7788696289062,
+ "cost_distance_total_intern_reflection": 16389.447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 29.0825252532959,
+ "cost_distance_glasses": 1133.6920454916576,
+ "cost_deviation": 81.1016616821289,
+ "cost_distorsion": 11723.3310546875,
+ "cost_thickness": 3848.650146484375,
+ "cost_beam_compression": 1.7276901006698608,
+ "cost_non_linearity": 957.7788696289062,
+ "cost_distance_total_intern_reflection": 16389.447265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_310.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_310.json
new file mode 100755
index 0000000..637b1d1
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_310.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.530620813369751,
+ "cost_distance_glasses": 1158.9979949181209,
+ "cost_deviation": 8109950.0,
+ "cost_distorsion": 11726.45703125,
+ "cost_thickness": 3848.65234375,
+ "cost_beam_compression": 1.727687120437622,
+ "cost_non_linearity": 957.708740234375,
+ "cost_distance_total_intern_reflection": 16389.26171875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.612415313720703,
+ "cost_distance_glasses": 1158.9979949181209,
+ "cost_deviation": 81.09949493408203,
+ "cost_distorsion": 11726.45703125,
+ "cost_thickness": 3848.65234375,
+ "cost_beam_compression": 1.727687120437622,
+ "cost_non_linearity": 957.708740234375,
+ "cost_distance_total_intern_reflection": 16389.26171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_320.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_320.json
new file mode 100755
index 0000000..c6f234b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_320.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.6316070556640625,
+ "cost_distance_glasses": 1110.3379542361065,
+ "cost_deviation": 8109087.5,
+ "cost_distorsion": 11741.736328125,
+ "cost_thickness": 3848.872802734375,
+ "cost_beam_compression": 1.7274701595306396,
+ "cost_non_linearity": 957.5819702148438,
+ "cost_distance_total_intern_reflection": 16389.833984375
+ },
+ "weighted components": {
+ "cost_dispersion": 32.63214111328125,
+ "cost_distance_glasses": 1110.3379542361065,
+ "cost_deviation": 81.09087371826172,
+ "cost_distorsion": 11741.736328125,
+ "cost_thickness": 3848.872802734375,
+ "cost_beam_compression": 1.7274701595306396,
+ "cost_non_linearity": 957.5819702148438,
+ "cost_distance_total_intern_reflection": 16389.833984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_330.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_330.json
new file mode 100755
index 0000000..0dbf81e
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_330.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.4098470211029053,
+ "cost_distance_glasses": 944.8861507412686,
+ "cost_deviation": 8105659.0,
+ "cost_distorsion": 11751.8486328125,
+ "cost_thickness": 3848.97412109375,
+ "cost_beam_compression": 1.727433204650879,
+ "cost_non_linearity": 957.0308227539062,
+ "cost_distance_total_intern_reflection": 16386.962890625
+ },
+ "weighted components": {
+ "cost_dispersion": 48.19694137573242,
+ "cost_distance_glasses": 944.8861507412686,
+ "cost_deviation": 81.05658721923828,
+ "cost_distorsion": 11751.8486328125,
+ "cost_thickness": 3848.97412109375,
+ "cost_beam_compression": 1.727433204650879,
+ "cost_non_linearity": 957.0308227539062,
+ "cost_distance_total_intern_reflection": 16386.962890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_340.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_340.json
new file mode 100755
index 0000000..8a6374d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_340.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.7249982357025146,
+ "cost_distance_glasses": 932.3338773845411,
+ "cost_deviation": 8105113.0,
+ "cost_distorsion": 11812.4814453125,
+ "cost_thickness": 3849.064208984375,
+ "cost_beam_compression": 1.7278724908828735,
+ "cost_non_linearity": 956.9038696289062,
+ "cost_distance_total_intern_reflection": 16384.73046875
+ },
+ "weighted components": {
+ "cost_dispersion": 54.49996566772461,
+ "cost_distance_glasses": 932.3338773845411,
+ "cost_deviation": 81.0511245727539,
+ "cost_distorsion": 11812.4814453125,
+ "cost_thickness": 3849.064208984375,
+ "cost_beam_compression": 1.7278724908828735,
+ "cost_non_linearity": 956.9038696289062,
+ "cost_distance_total_intern_reflection": 16384.73046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_350.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_350.json
new file mode 100755
index 0000000..a1a858b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_350.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.7419359683990479,
+ "cost_distance_glasses": 991.8119345690915,
+ "cost_deviation": 8108442.5,
+ "cost_distorsion": 11739.5712890625,
+ "cost_thickness": 3850.012939453125,
+ "cost_beam_compression": 1.727878451347351,
+ "cost_non_linearity": 957.3937377929688,
+ "cost_distance_total_intern_reflection": 16389.85546875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.83871841430664,
+ "cost_distance_glasses": 991.8119345690915,
+ "cost_deviation": 81.08441925048828,
+ "cost_distorsion": 11739.5712890625,
+ "cost_thickness": 3850.012939453125,
+ "cost_beam_compression": 1.727878451347351,
+ "cost_non_linearity": 957.3937377929688,
+ "cost_distance_total_intern_reflection": 16389.85546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_360.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_360.json
new file mode 100755
index 0000000..593a28d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_360.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4647440910339355,
+ "cost_distance_glasses": 969.4112487813302,
+ "cost_deviation": 8109521.5,
+ "cost_distorsion": 11747.0849609375,
+ "cost_thickness": 3850.72021484375,
+ "cost_beam_compression": 1.7281919717788696,
+ "cost_non_linearity": 957.691162109375,
+ "cost_distance_total_intern_reflection": 16390.982421875
+ },
+ "weighted components": {
+ "cost_dispersion": 29.29488182067871,
+ "cost_distance_glasses": 969.4112487813302,
+ "cost_deviation": 81.09521484375,
+ "cost_distorsion": 11747.0849609375,
+ "cost_thickness": 3850.72021484375,
+ "cost_beam_compression": 1.7281919717788696,
+ "cost_non_linearity": 957.691162109375,
+ "cost_distance_total_intern_reflection": 16390.982421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_370.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_370.json
new file mode 100755
index 0000000..931485e
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_370.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.2631068825721741,
+ "cost_distance_glasses": 1146.4572072581866,
+ "cost_deviation": 8116344.5,
+ "cost_distorsion": 11923.9697265625,
+ "cost_thickness": 3852.174072265625,
+ "cost_beam_compression": 1.7279356718063354,
+ "cost_non_linearity": 959.0831909179688,
+ "cost_distance_total_intern_reflection": 16401.587890625
+ },
+ "weighted components": {
+ "cost_dispersion": 5.262137413024902,
+ "cost_distance_glasses": 1146.4572072581866,
+ "cost_deviation": 81.16344451904297,
+ "cost_distorsion": 11923.9697265625,
+ "cost_thickness": 3852.174072265625,
+ "cost_beam_compression": 1.7279356718063354,
+ "cost_non_linearity": 959.0831909179688,
+ "cost_distance_total_intern_reflection": 16401.587890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_380.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_380.json
new file mode 100755
index 0000000..8687e36
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_380.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.7069907188415527,
+ "cost_distance_glasses": 838.9511339447496,
+ "cost_deviation": 8108455.0,
+ "cost_distorsion": 11828.1953125,
+ "cost_thickness": 3851.5966796875,
+ "cost_beam_compression": 1.7288786172866821,
+ "cost_non_linearity": 957.5993041992188,
+ "cost_distance_total_intern_reflection": 16388.841796875
+ },
+ "weighted components": {
+ "cost_dispersion": 34.13981628417969,
+ "cost_distance_glasses": 838.9511339447496,
+ "cost_deviation": 81.08454895019531,
+ "cost_distorsion": 11828.1953125,
+ "cost_thickness": 3851.5966796875,
+ "cost_beam_compression": 1.7288786172866821,
+ "cost_non_linearity": 957.5993041992188,
+ "cost_distance_total_intern_reflection": 16388.841796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_390.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_390.json
new file mode 100755
index 0000000..44e1683
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_390.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4810402393341064,
+ "cost_distance_glasses": 815.846252521773,
+ "cost_deviation": 8108359.0,
+ "cost_distorsion": 11775.998046875,
+ "cost_thickness": 3851.896484375,
+ "cost_beam_compression": 1.7284905910491943,
+ "cost_non_linearity": 957.6210327148438,
+ "cost_distance_total_intern_reflection": 16391.056640625
+ },
+ "weighted components": {
+ "cost_dispersion": 29.620803833007812,
+ "cost_distance_glasses": 815.846252521773,
+ "cost_deviation": 81.08358764648438,
+ "cost_distorsion": 11775.998046875,
+ "cost_thickness": 3851.896484375,
+ "cost_beam_compression": 1.7284905910491943,
+ "cost_non_linearity": 957.6210327148438,
+ "cost_distance_total_intern_reflection": 16391.056640625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_40.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_40.json
new file mode 100755
index 0000000..427025b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_40.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.245973587036133,
+ "cost_distance_glasses": 1612.2945422077164,
+ "cost_deviation": 8204066.5,
+ "cost_distorsion": 12232.5751953125,
+ "cost_thickness": 3880.958251953125,
+ "cost_beam_compression": 1.7486155033111572,
+ "cost_non_linearity": 956.8731689453125,
+ "cost_distance_total_intern_reflection": 16454.302734375
+ },
+ "weighted components": {
+ "cost_dispersion": 44.919471740722656,
+ "cost_distance_glasses": 1612.2945422077164,
+ "cost_deviation": 82.04066467285156,
+ "cost_distorsion": 12232.5751953125,
+ "cost_thickness": 3880.958251953125,
+ "cost_beam_compression": 1.7486155033111572,
+ "cost_non_linearity": 956.8731689453125,
+ "cost_distance_total_intern_reflection": 16454.302734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_400.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_400.json
new file mode 100755
index 0000000..8feefe5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_400.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.3384714126586914,
+ "cost_distance_glasses": 742.6150120295625,
+ "cost_deviation": 8101850.5,
+ "cost_distorsion": 11941.361328125,
+ "cost_thickness": 3850.336181640625,
+ "cost_beam_compression": 1.7287921905517578,
+ "cost_non_linearity": 956.292236328125,
+ "cost_distance_total_intern_reflection": 16380.3642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 66.76942443847656,
+ "cost_distance_glasses": 742.6150120295625,
+ "cost_deviation": 81.01850128173828,
+ "cost_distorsion": 11941.361328125,
+ "cost_thickness": 3850.336181640625,
+ "cost_beam_compression": 1.7287921905517578,
+ "cost_non_linearity": 956.292236328125,
+ "cost_distance_total_intern_reflection": 16380.3642578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_410.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_410.json
new file mode 100755
index 0000000..7819186
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_410.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0549335479736328,
+ "cost_distance_glasses": 951.8721079458253,
+ "cost_deviation": 8109316.0,
+ "cost_distorsion": 11730.6279296875,
+ "cost_thickness": 3851.58349609375,
+ "cost_beam_compression": 1.7281407117843628,
+ "cost_non_linearity": 957.9884033203125,
+ "cost_distance_total_intern_reflection": 16392.833984375
+ },
+ "weighted components": {
+ "cost_dispersion": 21.098670959472656,
+ "cost_distance_glasses": 951.8721079458253,
+ "cost_deviation": 81.09315490722656,
+ "cost_distorsion": 11730.6279296875,
+ "cost_thickness": 3851.58349609375,
+ "cost_beam_compression": 1.7281407117843628,
+ "cost_non_linearity": 957.9884033203125,
+ "cost_distance_total_intern_reflection": 16392.833984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_420.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_420.json
new file mode 100755
index 0000000..3c26bd9
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_420.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.9172377586364746,
+ "cost_distance_glasses": 1075.0711098710603,
+ "cost_deviation": 8107616.5,
+ "cost_distorsion": 11973.50390625,
+ "cost_thickness": 3850.36767578125,
+ "cost_beam_compression": 1.7296653985977173,
+ "cost_non_linearity": 957.5865478515625,
+ "cost_distance_total_intern_reflection": 16382.140625
+ },
+ "weighted components": {
+ "cost_dispersion": 38.344757080078125,
+ "cost_distance_glasses": 1075.0711098710603,
+ "cost_deviation": 81.07616424560547,
+ "cost_distorsion": 11973.50390625,
+ "cost_thickness": 3850.36767578125,
+ "cost_beam_compression": 1.7296653985977173,
+ "cost_non_linearity": 957.5865478515625,
+ "cost_distance_total_intern_reflection": 16382.140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_430.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_430.json
new file mode 100755
index 0000000..adf55ea
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_430.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.897101640701294,
+ "cost_distance_glasses": 839.5310567511757,
+ "cost_deviation": 8103385.0,
+ "cost_distorsion": 12041.3486328125,
+ "cost_thickness": 3850.571533203125,
+ "cost_beam_compression": 1.7297697067260742,
+ "cost_non_linearity": 956.7159423828125,
+ "cost_distance_total_intern_reflection": 16378.091796875
+ },
+ "weighted components": {
+ "cost_dispersion": 57.94203186035156,
+ "cost_distance_glasses": 839.5310567511757,
+ "cost_deviation": 81.03385162353516,
+ "cost_distorsion": 12041.3486328125,
+ "cost_thickness": 3850.571533203125,
+ "cost_beam_compression": 1.7297697067260742,
+ "cost_non_linearity": 956.7159423828125,
+ "cost_distance_total_intern_reflection": 16378.091796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_440.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_440.json
new file mode 100755
index 0000000..a7737be
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_440.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.7154202461242676,
+ "cost_distance_glasses": 1118.784943322103,
+ "cost_deviation": 8111347.5,
+ "cost_distorsion": 11799.0595703125,
+ "cost_thickness": 3851.7275390625,
+ "cost_beam_compression": 1.7289799451828003,
+ "cost_non_linearity": 958.2339477539062,
+ "cost_distance_total_intern_reflection": 16391.466796875
+ },
+ "weighted components": {
+ "cost_dispersion": 14.308404922485352,
+ "cost_distance_glasses": 1118.784943322103,
+ "cost_deviation": 81.11347198486328,
+ "cost_distorsion": 11799.0595703125,
+ "cost_thickness": 3851.7275390625,
+ "cost_beam_compression": 1.7289799451828003,
+ "cost_non_linearity": 958.2339477539062,
+ "cost_distance_total_intern_reflection": 16391.466796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_450.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_450.json
new file mode 100755
index 0000000..aa628b2
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_450.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.054420471191406,
+ "cost_distance_glasses": 32.9979969497485,
+ "cost_deviation": 8069980.0,
+ "cost_distorsion": 12136.7978515625,
+ "cost_thickness": 3852.3720703125,
+ "cost_beam_compression": 1.726992130279541,
+ "cost_non_linearity": 952.1080932617188,
+ "cost_distance_total_intern_reflection": 16362.171875
+ },
+ "weighted components": {
+ "cost_dispersion": 341.0884094238281,
+ "cost_distance_glasses": 32.9979969497485,
+ "cost_deviation": 80.69979858398438,
+ "cost_distorsion": 12136.7978515625,
+ "cost_thickness": 3852.3720703125,
+ "cost_beam_compression": 1.726992130279541,
+ "cost_non_linearity": 952.1080932617188,
+ "cost_distance_total_intern_reflection": 16362.171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_460.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_460.json
new file mode 100755
index 0000000..947b700
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_460.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.205954074859619,
+ "cost_distance_glasses": 41.12909389287445,
+ "cost_deviation": 8089524.5,
+ "cost_distorsion": 11885.822265625,
+ "cost_thickness": 3858.726318359375,
+ "cost_beam_compression": 1.7257505655288696,
+ "cost_non_linearity": 955.9464111328125,
+ "cost_distance_total_intern_reflection": 16399.2578125
+ },
+ "weighted components": {
+ "cost_dispersion": 84.11907958984375,
+ "cost_distance_glasses": 41.12909389287445,
+ "cost_deviation": 80.8952407836914,
+ "cost_distorsion": 11885.822265625,
+ "cost_thickness": 3858.726318359375,
+ "cost_beam_compression": 1.7257505655288696,
+ "cost_non_linearity": 955.9464111328125,
+ "cost_distance_total_intern_reflection": 16399.2578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_470.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_470.json
new file mode 100755
index 0000000..c9aa504
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_470.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.2932355403900146,
+ "cost_distance_glasses": 193.48957835831754,
+ "cost_deviation": 8102146.5,
+ "cost_distorsion": 11974.51953125,
+ "cost_thickness": 3857.94189453125,
+ "cost_beam_compression": 1.7304420471191406,
+ "cost_non_linearity": 957.0263671875,
+ "cost_distance_total_intern_reflection": 16389.35546875
+ },
+ "weighted components": {
+ "cost_dispersion": 45.86471176147461,
+ "cost_distance_glasses": 193.48957835831754,
+ "cost_deviation": 81.0214614868164,
+ "cost_distorsion": 11974.51953125,
+ "cost_thickness": 3857.94189453125,
+ "cost_beam_compression": 1.7304420471191406,
+ "cost_non_linearity": 957.0263671875,
+ "cost_distance_total_intern_reflection": 16389.35546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_480.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_480.json
new file mode 100755
index 0000000..f1740d5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_480.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.4459359645843506,
+ "cost_distance_glasses": 591.8243066545452,
+ "cost_deviation": 8095401.5,
+ "cost_distorsion": 11735.703125,
+ "cost_thickness": 3850.4189453125,
+ "cost_beam_compression": 1.7259067296981812,
+ "cost_non_linearity": 956.5408325195312,
+ "cost_distance_total_intern_reflection": 16386.880859375
+ },
+ "weighted components": {
+ "cost_dispersion": 68.91871643066406,
+ "cost_distance_glasses": 591.8243066545452,
+ "cost_deviation": 80.95401000976562,
+ "cost_distorsion": 11735.703125,
+ "cost_thickness": 3850.4189453125,
+ "cost_beam_compression": 1.7259067296981812,
+ "cost_non_linearity": 956.5408325195312,
+ "cost_distance_total_intern_reflection": 16386.880859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_490.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_490.json
new file mode 100755
index 0000000..da80b96
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_490.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 18.85226058959961,
+ "cost_distance_glasses": 57.01439130009793,
+ "cost_deviation": 8068250.0,
+ "cost_distorsion": 12226.3662109375,
+ "cost_thickness": 3850.478515625,
+ "cost_beam_compression": 1.7271387577056885,
+ "cost_non_linearity": 951.7286987304688,
+ "cost_distance_total_intern_reflection": 16355.986328125
+ },
+ "weighted components": {
+ "cost_dispersion": 377.04522705078125,
+ "cost_distance_glasses": 57.01439130009793,
+ "cost_deviation": 80.6824951171875,
+ "cost_distorsion": 12226.3662109375,
+ "cost_thickness": 3850.478515625,
+ "cost_beam_compression": 1.7271387577056885,
+ "cost_non_linearity": 951.7286987304688,
+ "cost_distance_total_intern_reflection": 16355.986328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_50.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_50.json
new file mode 100755
index 0000000..3adf2d0
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_50.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.85677433013916,
+ "cost_distance_glasses": 8226.592439148197,
+ "cost_deviation": 8238914.0,
+ "cost_distorsion": 12144.224609375,
+ "cost_thickness": 3859.501708984375,
+ "cost_beam_compression": 1.7449367046356201,
+ "cost_non_linearity": 963.6943359375,
+ "cost_distance_total_intern_reflection": 16458.388671875
+ },
+ "weighted components": {
+ "cost_dispersion": 77.13548278808594,
+ "cost_distance_glasses": 8226.592439148197,
+ "cost_deviation": 82.3891372680664,
+ "cost_distorsion": 12144.224609375,
+ "cost_thickness": 3859.501708984375,
+ "cost_beam_compression": 1.7449367046356201,
+ "cost_non_linearity": 963.6943359375,
+ "cost_distance_total_intern_reflection": 16458.388671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_500.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_500.json
new file mode 100755
index 0000000..c66b3a5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_500.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.806230545043945,
+ "cost_distance_glasses": 1623.2490666701192,
+ "cost_deviation": 8148516.0,
+ "cost_distorsion": 12883.8818359375,
+ "cost_thickness": 3863.101806640625,
+ "cost_beam_compression": 1.7280584573745728,
+ "cost_non_linearity": 965.485595703125,
+ "cost_distance_total_intern_reflection": 16454.32421875
+ },
+ "weighted components": {
+ "cost_dispersion": 176.12460327148438,
+ "cost_distance_glasses": 1623.2490666701192,
+ "cost_deviation": 81.48516082763672,
+ "cost_distorsion": 12883.8818359375,
+ "cost_thickness": 3863.101806640625,
+ "cost_beam_compression": 1.7280584573745728,
+ "cost_non_linearity": 965.485595703125,
+ "cost_distance_total_intern_reflection": 16454.32421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_510.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_510.json
new file mode 100755
index 0000000..e49ab70
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_510.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.7956719398498535,
+ "cost_distance_glasses": 545.9459515174187,
+ "cost_deviation": 8101489.5,
+ "cost_distorsion": 11801.12109375,
+ "cost_thickness": 3853.2998046875,
+ "cost_beam_compression": 1.726926565170288,
+ "cost_non_linearity": 957.1881713867188,
+ "cost_distance_total_intern_reflection": 16394.25390625
+ },
+ "weighted components": {
+ "cost_dispersion": 35.91343688964844,
+ "cost_distance_glasses": 545.9459515174187,
+ "cost_deviation": 81.014892578125,
+ "cost_distorsion": 11801.12109375,
+ "cost_thickness": 3853.2998046875,
+ "cost_beam_compression": 1.726926565170288,
+ "cost_non_linearity": 957.1881713867188,
+ "cost_distance_total_intern_reflection": 16394.25390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_520.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_520.json
new file mode 100755
index 0000000..3c4a816
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_520.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.29118090867996216,
+ "cost_distance_glasses": 387.7693545064622,
+ "cost_deviation": 8109392.0,
+ "cost_distorsion": 12035.50390625,
+ "cost_thickness": 3857.866455078125,
+ "cost_beam_compression": 1.7273038625717163,
+ "cost_non_linearity": 958.8468017578125,
+ "cost_distance_total_intern_reflection": 16409.615234375
+ },
+ "weighted components": {
+ "cost_dispersion": 5.823617935180664,
+ "cost_distance_glasses": 387.7693545064622,
+ "cost_deviation": 81.09391784667969,
+ "cost_distorsion": 12035.50390625,
+ "cost_thickness": 3857.866455078125,
+ "cost_beam_compression": 1.7273038625717163,
+ "cost_non_linearity": 958.8468017578125,
+ "cost_distance_total_intern_reflection": 16409.615234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_530.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_530.json
new file mode 100755
index 0000000..9c4d444
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_530.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.681246280670166,
+ "cost_distance_glasses": 1172.771240474778,
+ "cost_deviation": 8128689.5,
+ "cost_distorsion": 13035.572265625,
+ "cost_thickness": 3858.681396484375,
+ "cost_beam_compression": 1.723310947418213,
+ "cost_non_linearity": 962.9879150390625,
+ "cost_distance_total_intern_reflection": 16446.853515625
+ },
+ "weighted components": {
+ "cost_dispersion": 53.62492370605469,
+ "cost_distance_glasses": 1172.771240474778,
+ "cost_deviation": 81.28689575195312,
+ "cost_distorsion": 13035.572265625,
+ "cost_thickness": 3858.681396484375,
+ "cost_beam_compression": 1.723310947418213,
+ "cost_non_linearity": 962.9879150390625,
+ "cost_distance_total_intern_reflection": 16446.853515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_540.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_540.json
new file mode 100755
index 0000000..a842081
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_540.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.996121406555176,
+ "cost_distance_glasses": 1.656630160170338,
+ "cost_deviation": 8077656.5,
+ "cost_distorsion": 12051.6904296875,
+ "cost_thickness": 3861.045166015625,
+ "cost_beam_compression": 1.7288130521774292,
+ "cost_non_linearity": 953.5396728515625,
+ "cost_distance_total_intern_reflection": 16379.6162109375
+ },
+ "weighted components": {
+ "cost_dispersion": 219.92242431640625,
+ "cost_distance_glasses": 1.656630160170338,
+ "cost_deviation": 80.77656555175781,
+ "cost_distorsion": 12051.6904296875,
+ "cost_thickness": 3861.045166015625,
+ "cost_beam_compression": 1.7288130521774292,
+ "cost_non_linearity": 953.5396728515625,
+ "cost_distance_total_intern_reflection": 16379.6162109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_550.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_550.json
new file mode 100755
index 0000000..e9181bd
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_550.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.184223175048828,
+ "cost_distance_glasses": 65.77988803542509,
+ "cost_deviation": 8078149.0,
+ "cost_distorsion": 12852.3056640625,
+ "cost_thickness": 3853.843994140625,
+ "cost_beam_compression": 1.7337924242019653,
+ "cost_non_linearity": 952.173583984375,
+ "cost_distance_total_intern_reflection": 16343.71875
+ },
+ "weighted components": {
+ "cost_dispersion": 343.6844482421875,
+ "cost_distance_glasses": 65.77988803542509,
+ "cost_deviation": 80.78148651123047,
+ "cost_distorsion": 12852.3056640625,
+ "cost_thickness": 3853.843994140625,
+ "cost_beam_compression": 1.7337924242019653,
+ "cost_non_linearity": 952.173583984375,
+ "cost_distance_total_intern_reflection": 16343.71875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_560.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_560.json
new file mode 100755
index 0000000..7c4186c
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_560.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.128525733947754,
+ "cost_distance_glasses": 581.6980188616329,
+ "cost_deviation": 8079939.5,
+ "cost_distorsion": 12383.162109375,
+ "cost_thickness": 3845.902099609375,
+ "cost_beam_compression": 1.718207597732544,
+ "cost_non_linearity": 955.4259643554688,
+ "cost_distance_total_intern_reflection": 16396.080078125
+ },
+ "weighted components": {
+ "cost_dispersion": 122.57051086425781,
+ "cost_distance_glasses": 581.6980188616329,
+ "cost_deviation": 80.79939270019531,
+ "cost_distorsion": 12383.162109375,
+ "cost_thickness": 3845.902099609375,
+ "cost_beam_compression": 1.718207597732544,
+ "cost_non_linearity": 955.4259643554688,
+ "cost_distance_total_intern_reflection": 16396.080078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_570.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_570.json
new file mode 100755
index 0000000..ce945e7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_570.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.93748664855957,
+ "cost_distance_glasses": 2729.41392627115,
+ "cost_deviation": 8101678.5,
+ "cost_distorsion": 13304.02734375,
+ "cost_thickness": 3843.893798828125,
+ "cost_beam_compression": 1.7381328344345093,
+ "cost_non_linearity": 954.3167724609375,
+ "cost_distance_total_intern_reflection": 16326.7353515625
+ },
+ "weighted components": {
+ "cost_dispersion": 178.74972534179688,
+ "cost_distance_glasses": 2729.41392627115,
+ "cost_deviation": 81.01678466796875,
+ "cost_distorsion": 13304.02734375,
+ "cost_thickness": 3843.893798828125,
+ "cost_beam_compression": 1.7381328344345093,
+ "cost_non_linearity": 954.3167724609375,
+ "cost_distance_total_intern_reflection": 16326.7353515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_580.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_580.json
new file mode 100755
index 0000000..87bf7e3
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_580.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.521120309829712,
+ "cost_distance_glasses": 77.58155202829155,
+ "cost_deviation": 8087861.0,
+ "cost_distorsion": 12222.150390625,
+ "cost_thickness": 3856.96630859375,
+ "cost_beam_compression": 1.7227733135223389,
+ "cost_non_linearity": 956.4580688476562,
+ "cost_distance_total_intern_reflection": 16406.875
+ },
+ "weighted components": {
+ "cost_dispersion": 70.42240905761719,
+ "cost_distance_glasses": 77.58155202829155,
+ "cost_deviation": 80.87860870361328,
+ "cost_distorsion": 12222.150390625,
+ "cost_thickness": 3856.96630859375,
+ "cost_beam_compression": 1.7227733135223389,
+ "cost_non_linearity": 956.4580688476562,
+ "cost_distance_total_intern_reflection": 16406.875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_590.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_590.json
new file mode 100755
index 0000000..8611a87
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_590.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 23.538843154907227,
+ "cost_distance_glasses": 8.21187906727102,
+ "cost_deviation": 8062860.0,
+ "cost_distorsion": 12430.154296875,
+ "cost_thickness": 3853.543212890625,
+ "cost_beam_compression": 1.7286622524261475,
+ "cost_non_linearity": 950.8828735351562,
+ "cost_distance_total_intern_reflection": 16350.6611328125
+ },
+ "weighted components": {
+ "cost_dispersion": 470.77685546875,
+ "cost_distance_glasses": 8.21187906727102,
+ "cost_deviation": 80.62860107421875,
+ "cost_distorsion": 12430.154296875,
+ "cost_thickness": 3853.543212890625,
+ "cost_beam_compression": 1.7286622524261475,
+ "cost_non_linearity": 950.8828735351562,
+ "cost_distance_total_intern_reflection": 16350.6611328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_60.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_60.json
new file mode 100755
index 0000000..18dedbc
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_60.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.482080340385437,
+ "cost_distance_glasses": 2906.239981896632,
+ "cost_deviation": 8207613.5,
+ "cost_distorsion": 12617.0849609375,
+ "cost_thickness": 3867.926025390625,
+ "cost_beam_compression": 1.739109754562378,
+ "cost_non_linearity": 962.2950439453125,
+ "cost_distance_total_intern_reflection": 16471.703125
+ },
+ "weighted components": {
+ "cost_dispersion": 29.6416072845459,
+ "cost_distance_glasses": 2906.239981896632,
+ "cost_deviation": 82.07613372802734,
+ "cost_distorsion": 12617.0849609375,
+ "cost_thickness": 3867.926025390625,
+ "cost_beam_compression": 1.739109754562378,
+ "cost_non_linearity": 962.2950439453125,
+ "cost_distance_total_intern_reflection": 16471.703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_600.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_600.json
new file mode 100755
index 0000000..955e02f
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_600.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 17.334333419799805,
+ "cost_distance_glasses": 10.721303907269457,
+ "cost_deviation": 8124604.0,
+ "cost_distorsion": 16146.2939453125,
+ "cost_thickness": 3889.396728515625,
+ "cost_beam_compression": 1.709412932395935,
+ "cost_non_linearity": 967.5952758789062,
+ "cost_distance_total_intern_reflection": 16567.595703125
+ },
+ "weighted components": {
+ "cost_dispersion": 346.6866760253906,
+ "cost_distance_glasses": 10.721303907269457,
+ "cost_deviation": 81.24604034423828,
+ "cost_distorsion": 16146.2939453125,
+ "cost_thickness": 3889.396728515625,
+ "cost_beam_compression": 1.709412932395935,
+ "cost_non_linearity": 967.5952758789062,
+ "cost_distance_total_intern_reflection": 16567.595703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_610.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_610.json
new file mode 100755
index 0000000..22a617d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_610.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.58294677734375,
+ "cost_distance_glasses": 9.377335248635884,
+ "cost_deviation": 8148164.5,
+ "cost_distorsion": 16549.02734375,
+ "cost_thickness": 3897.412109375,
+ "cost_beam_compression": 1.7120575904846191,
+ "cost_non_linearity": 971.5792846679688,
+ "cost_distance_total_intern_reflection": 16595.25390625
+ },
+ "weighted components": {
+ "cost_dispersion": 751.658935546875,
+ "cost_distance_glasses": 9.377335248635884,
+ "cost_deviation": 81.48164367675781,
+ "cost_distorsion": 16549.02734375,
+ "cost_thickness": 3897.412109375,
+ "cost_beam_compression": 1.7120575904846191,
+ "cost_non_linearity": 971.5792846679688,
+ "cost_distance_total_intern_reflection": 16595.25390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_620.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_620.json
new file mode 100755
index 0000000..3fe4cce
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_620.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 422.6005554199219,
+ "cost_distance_glasses": 1203.9066439545386,
+ "cost_deviation": 8320619.0,
+ "cost_distorsion": 19827.16796875,
+ "cost_thickness": 3925.654296875,
+ "cost_beam_compression": 1.7240279912948608,
+ "cost_non_linearity": 999.145751953125,
+ "cost_distance_total_intern_reflection": 16766.265625
+ },
+ "weighted components": {
+ "cost_dispersion": 8452.0107421875,
+ "cost_distance_glasses": 1203.9066439545386,
+ "cost_deviation": 83.20618438720703,
+ "cost_distorsion": 19827.16796875,
+ "cost_thickness": 3925.654296875,
+ "cost_beam_compression": 1.7240279912948608,
+ "cost_non_linearity": 999.145751953125,
+ "cost_distance_total_intern_reflection": 16766.265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_630.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_630.json
new file mode 100755
index 0000000..1314872
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_630.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1426.6666259765625,
+ "cost_distance_glasses": 721260.8945947168,
+ "cost_deviation": 7677992.0,
+ "cost_distorsion": 17903.17578125,
+ "cost_thickness": 3840.63818359375,
+ "cost_beam_compression": 1.7210441827774048,
+ "cost_non_linearity": 889.61181640625,
+ "cost_distance_total_intern_reflection": 15990.0546875
+ },
+ "weighted components": {
+ "cost_dispersion": 28533.33203125,
+ "cost_distance_glasses": 721260.8945947168,
+ "cost_deviation": 76.77991485595703,
+ "cost_distorsion": 17903.17578125,
+ "cost_thickness": 3840.63818359375,
+ "cost_beam_compression": 1.7210441827774048,
+ "cost_non_linearity": 889.61181640625,
+ "cost_distance_total_intern_reflection": 15990.0546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_640.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_640.json
new file mode 100755
index 0000000..594df19
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_640.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2978.318603515625,
+ "cost_distance_glasses": 220280.31113853614,
+ "cost_deviation": 7590660.0,
+ "cost_distorsion": 32159.15625,
+ "cost_thickness": 3773.260498046875,
+ "cost_beam_compression": 1.7826277017593384,
+ "cost_non_linearity": 859.411865234375,
+ "cost_distance_total_intern_reflection": 15518.1142578125
+ },
+ "weighted components": {
+ "cost_dispersion": 59566.37109375,
+ "cost_distance_glasses": 220280.31113853614,
+ "cost_deviation": 75.90660095214844,
+ "cost_distorsion": 32159.15625,
+ "cost_thickness": 3773.260498046875,
+ "cost_beam_compression": 1.7826277017593384,
+ "cost_non_linearity": 859.411865234375,
+ "cost_distance_total_intern_reflection": 15518.1142578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_650.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_650.json
new file mode 100755
index 0000000..0d0abca
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_650.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1124.467529296875,
+ "cost_distance_glasses": 44518.99222221402,
+ "cost_deviation": 7937571.5,
+ "cost_distorsion": 39269.61328125,
+ "cost_thickness": 3751.897216796875,
+ "cost_beam_compression": 1.853644847869873,
+ "cost_non_linearity": 898.257568359375,
+ "cost_distance_total_intern_reflection": 15513.173828125
+ },
+ "weighted components": {
+ "cost_dispersion": 22489.3515625,
+ "cost_distance_glasses": 44518.99222221402,
+ "cost_deviation": 79.3757095336914,
+ "cost_distorsion": 39269.61328125,
+ "cost_thickness": 3751.897216796875,
+ "cost_beam_compression": 1.853644847869873,
+ "cost_non_linearity": 898.257568359375,
+ "cost_distance_total_intern_reflection": 15513.173828125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_660.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_660.json
new file mode 100755
index 0000000..f3e58c7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_660.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 172.1438751220703,
+ "cost_distance_glasses": 86.4305835218302,
+ "cost_deviation": 8229093.5,
+ "cost_distorsion": 17755.08984375,
+ "cost_thickness": 3930.8046875,
+ "cost_beam_compression": 1.7234671115875244,
+ "cost_non_linearity": 984.7817993164062,
+ "cost_distance_total_intern_reflection": 16692.36328125
+ },
+ "weighted components": {
+ "cost_dispersion": 3442.87744140625,
+ "cost_distance_glasses": 86.4305835218302,
+ "cost_deviation": 82.29093170166016,
+ "cost_distorsion": 17755.08984375,
+ "cost_thickness": 3930.8046875,
+ "cost_beam_compression": 1.7234671115875244,
+ "cost_non_linearity": 984.7817993164062,
+ "cost_distance_total_intern_reflection": 16692.36328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_670.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_670.json
new file mode 100755
index 0000000..692ccda
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_670.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.21540832519531,
+ "cost_distance_glasses": 240.76230263116167,
+ "cost_deviation": 8151890.5,
+ "cost_distorsion": 17317.28125,
+ "cost_thickness": 3907.407470703125,
+ "cost_beam_compression": 1.7101842164993286,
+ "cost_non_linearity": 973.39990234375,
+ "cost_distance_total_intern_reflection": 16627.953125
+ },
+ "weighted components": {
+ "cost_dispersion": 1024.30810546875,
+ "cost_distance_glasses": 240.76230263116167,
+ "cost_deviation": 81.51890563964844,
+ "cost_distorsion": 17317.28125,
+ "cost_thickness": 3907.407470703125,
+ "cost_beam_compression": 1.7101842164993286,
+ "cost_non_linearity": 973.39990234375,
+ "cost_distance_total_intern_reflection": 16627.953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_680.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_680.json
new file mode 100755
index 0000000..fb156f8
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_680.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 40.51543045043945,
+ "cost_distance_glasses": 43.28712984533367,
+ "cost_deviation": 8185956.5,
+ "cost_distorsion": 13253.67578125,
+ "cost_thickness": 3893.547607421875,
+ "cost_beam_compression": 1.7371666431427002,
+ "cost_non_linearity": 972.1258544921875,
+ "cost_distance_total_intern_reflection": 16513.841796875
+ },
+ "weighted components": {
+ "cost_dispersion": 810.30859375,
+ "cost_distance_glasses": 43.28712984533367,
+ "cost_deviation": 81.85956573486328,
+ "cost_distorsion": 13253.67578125,
+ "cost_thickness": 3893.547607421875,
+ "cost_beam_compression": 1.7371666431427002,
+ "cost_non_linearity": 972.1258544921875,
+ "cost_distance_total_intern_reflection": 16513.841796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_690.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_690.json
new file mode 100755
index 0000000..3e99701
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_690.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 19.069128036499023,
+ "cost_distance_glasses": 2153.823292223198,
+ "cost_deviation": 8162096.0,
+ "cost_distorsion": 13290.7451171875,
+ "cost_thickness": 3868.119384765625,
+ "cost_beam_compression": 1.7282885313034058,
+ "cost_non_linearity": 968.0968017578125,
+ "cost_distance_total_intern_reflection": 16476.654296875
+ },
+ "weighted components": {
+ "cost_dispersion": 381.382568359375,
+ "cost_distance_glasses": 2153.823292223198,
+ "cost_deviation": 81.62095642089844,
+ "cost_distorsion": 13290.7451171875,
+ "cost_thickness": 3868.119384765625,
+ "cost_beam_compression": 1.7282885313034058,
+ "cost_non_linearity": 968.0968017578125,
+ "cost_distance_total_intern_reflection": 16476.654296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_70.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_70.json
new file mode 100755
index 0000000..df1748c
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_70.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.51177978515625,
+ "cost_distance_glasses": 1139.1814101246734,
+ "cost_deviation": 8152583.5,
+ "cost_distorsion": 12637.60546875,
+ "cost_thickness": 3861.124755859375,
+ "cost_beam_compression": 1.7421483993530273,
+ "cost_non_linearity": 953.5570678710938,
+ "cost_distance_total_intern_reflection": 16392.642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 210.235595703125,
+ "cost_distance_glasses": 1139.1814101246734,
+ "cost_deviation": 81.52583312988281,
+ "cost_distorsion": 12637.60546875,
+ "cost_thickness": 3861.124755859375,
+ "cost_beam_compression": 1.7421483993530273,
+ "cost_non_linearity": 953.5570678710938,
+ "cost_distance_total_intern_reflection": 16392.642578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_700.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_700.json
new file mode 100755
index 0000000..e1e2e23
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_700.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 51.66278839111328,
+ "cost_distance_glasses": 688.2245349171268,
+ "cost_deviation": 8039454.0,
+ "cost_distorsion": 12732.5224609375,
+ "cost_thickness": 3831.9248046875,
+ "cost_beam_compression": 1.7243671417236328,
+ "cost_non_linearity": 946.036865234375,
+ "cost_distance_total_intern_reflection": 16302.119140625
+ },
+ "weighted components": {
+ "cost_dispersion": 1033.2557373046875,
+ "cost_distance_glasses": 688.2245349171268,
+ "cost_deviation": 80.39453887939453,
+ "cost_distorsion": 12732.5224609375,
+ "cost_thickness": 3831.9248046875,
+ "cost_beam_compression": 1.7243671417236328,
+ "cost_non_linearity": 946.036865234375,
+ "cost_distance_total_intern_reflection": 16302.119140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_710.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_710.json
new file mode 100755
index 0000000..bcfbc92
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_710.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.163524150848389,
+ "cost_distance_glasses": 624.4793698015566,
+ "cost_deviation": 8134472.0,
+ "cost_distorsion": 13191.9658203125,
+ "cost_thickness": 3865.8330078125,
+ "cost_beam_compression": 1.7245590686798096,
+ "cost_non_linearity": 964.1771240234375,
+ "cost_distance_total_intern_reflection": 16461.84765625
+ },
+ "weighted components": {
+ "cost_dispersion": 103.2704849243164,
+ "cost_distance_glasses": 624.4793698015566,
+ "cost_deviation": 81.34471893310547,
+ "cost_distorsion": 13191.9658203125,
+ "cost_thickness": 3865.8330078125,
+ "cost_beam_compression": 1.7245590686798096,
+ "cost_non_linearity": 964.1771240234375,
+ "cost_distance_total_intern_reflection": 16461.84765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_720.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_720.json
new file mode 100755
index 0000000..3a4503c
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_720.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 14.229619979858398,
+ "cost_distance_glasses": 864.5765782020346,
+ "cost_deviation": 8153890.0,
+ "cost_distorsion": 13302.962890625,
+ "cost_thickness": 3871.004638671875,
+ "cost_beam_compression": 1.7276203632354736,
+ "cost_non_linearity": 967.2041015625,
+ "cost_distance_total_intern_reflection": 16477.77734375
+ },
+ "weighted components": {
+ "cost_dispersion": 284.5924072265625,
+ "cost_distance_glasses": 864.5765782020346,
+ "cost_deviation": 81.53889465332031,
+ "cost_distorsion": 13302.962890625,
+ "cost_thickness": 3871.004638671875,
+ "cost_beam_compression": 1.7276203632354736,
+ "cost_non_linearity": 967.2041015625,
+ "cost_distance_total_intern_reflection": 16477.77734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_730.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_730.json
new file mode 100755
index 0000000..35b286a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_730.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4.803866386413574,
+ "cost_distance_glasses": 810.6882907076052,
+ "cost_deviation": 8133680.0,
+ "cost_distorsion": 13218.7314453125,
+ "cost_thickness": 3864.356201171875,
+ "cost_beam_compression": 1.7239391803741455,
+ "cost_non_linearity": 963.9356689453125,
+ "cost_distance_total_intern_reflection": 16460.68359375
+ },
+ "weighted components": {
+ "cost_dispersion": 96.07733154296875,
+ "cost_distance_glasses": 810.6882907076052,
+ "cost_deviation": 81.33679962158203,
+ "cost_distorsion": 13218.7314453125,
+ "cost_thickness": 3864.356201171875,
+ "cost_beam_compression": 1.7239391803741455,
+ "cost_non_linearity": 963.9356689453125,
+ "cost_distance_total_intern_reflection": 16460.68359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_740.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_740.json
new file mode 100755
index 0000000..1a60269
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_740.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.588554859161377,
+ "cost_distance_glasses": 731.354437600872,
+ "cost_deviation": 8099411.5,
+ "cost_distorsion": 12017.73046875,
+ "cost_thickness": 3852.96142578125,
+ "cost_beam_compression": 1.729583740234375,
+ "cost_non_linearity": 956.3616943359375,
+ "cost_distance_total_intern_reflection": 16380.10546875
+ },
+ "weighted components": {
+ "cost_dispersion": 71.7710952758789,
+ "cost_distance_glasses": 731.354437600872,
+ "cost_deviation": 80.99411010742188,
+ "cost_distorsion": 12017.73046875,
+ "cost_thickness": 3852.96142578125,
+ "cost_beam_compression": 1.729583740234375,
+ "cost_non_linearity": 956.3616943359375,
+ "cost_distance_total_intern_reflection": 16380.10546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_750.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_750.json
new file mode 100755
index 0000000..d60e62d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_750.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.016491174697875977,
+ "cost_distance_glasses": 773.960153863679,
+ "cost_deviation": 8113889.5,
+ "cost_distorsion": 12212.2763671875,
+ "cost_thickness": 3857.821044921875,
+ "cost_beam_compression": 1.7267042398452759,
+ "cost_non_linearity": 959.5864868164062,
+ "cost_distance_total_intern_reflection": 16416.357421875
+ },
+ "weighted components": {
+ "cost_dispersion": 0.32982349395751953,
+ "cost_distance_glasses": 773.960153863679,
+ "cost_deviation": 81.1388931274414,
+ "cost_distorsion": 12212.2763671875,
+ "cost_thickness": 3857.821044921875,
+ "cost_beam_compression": 1.7267042398452759,
+ "cost_non_linearity": 959.5864868164062,
+ "cost_distance_total_intern_reflection": 16416.357421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_760.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_760.json
new file mode 100755
index 0000000..3debeea
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_760.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.005961302667856216,
+ "cost_distance_glasses": 763.7883456299969,
+ "cost_deviation": 8114072.0,
+ "cost_distorsion": 12420.302734375,
+ "cost_thickness": 3858.021484375,
+ "cost_beam_compression": 1.7253392934799194,
+ "cost_non_linearity": 959.8797607421875,
+ "cost_distance_total_intern_reflection": 16422.84375
+ },
+ "weighted components": {
+ "cost_dispersion": 0.11922605335712433,
+ "cost_distance_glasses": 763.7883456299969,
+ "cost_deviation": 81.14071655273438,
+ "cost_distorsion": 12420.302734375,
+ "cost_thickness": 3858.021484375,
+ "cost_beam_compression": 1.7253392934799194,
+ "cost_non_linearity": 959.8797607421875,
+ "cost_distance_total_intern_reflection": 16422.84375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_770.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_770.json
new file mode 100755
index 0000000..9c5b070
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_770.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.28652286529541016,
+ "cost_distance_glasses": 754.6963052624429,
+ "cost_deviation": 8110022.0,
+ "cost_distorsion": 12054.044921875,
+ "cost_thickness": 3856.726806640625,
+ "cost_beam_compression": 1.7270201444625854,
+ "cost_non_linearity": 958.9821166992188,
+ "cost_distance_total_intern_reflection": 16409.0390625
+ },
+ "weighted components": {
+ "cost_dispersion": 5.730457305908203,
+ "cost_distance_glasses": 754.6963052624429,
+ "cost_deviation": 81.1002197265625,
+ "cost_distorsion": 12054.044921875,
+ "cost_thickness": 3856.726806640625,
+ "cost_beam_compression": 1.7270201444625854,
+ "cost_non_linearity": 958.9821166992188,
+ "cost_distance_total_intern_reflection": 16409.0390625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_780.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_780.json
new file mode 100755
index 0000000..326ca33
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_780.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.2961421608924866,
+ "cost_distance_glasses": 754.3668922050591,
+ "cost_deviation": 8110361.5,
+ "cost_distorsion": 12010.7685546875,
+ "cost_thickness": 3856.912353515625,
+ "cost_beam_compression": 1.7274147272109985,
+ "cost_non_linearity": 959.0042114257812,
+ "cost_distance_total_intern_reflection": 16408.046875
+ },
+ "weighted components": {
+ "cost_dispersion": 5.922842979431152,
+ "cost_distance_glasses": 754.3668922050591,
+ "cost_deviation": 81.1036148071289,
+ "cost_distorsion": 12010.7685546875,
+ "cost_thickness": 3856.912353515625,
+ "cost_beam_compression": 1.7274147272109985,
+ "cost_non_linearity": 959.0042114257812,
+ "cost_distance_total_intern_reflection": 16408.046875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_790.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_790.json
new file mode 100755
index 0000000..e8b3158
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_790.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.5640262365341187,
+ "cost_distance_glasses": 744.9453719732544,
+ "cost_deviation": 8105555.0,
+ "cost_distorsion": 11843.5478515625,
+ "cost_thickness": 3855.351318359375,
+ "cost_beam_compression": 1.7293351888656616,
+ "cost_non_linearity": 957.4591674804688,
+ "cost_distance_total_intern_reflection": 16391.962890625
+ },
+ "weighted components": {
+ "cost_dispersion": 31.28052520751953,
+ "cost_distance_glasses": 744.9453719732544,
+ "cost_deviation": 81.05554962158203,
+ "cost_distorsion": 11843.5478515625,
+ "cost_thickness": 3855.351318359375,
+ "cost_beam_compression": 1.7293351888656616,
+ "cost_non_linearity": 957.4591674804688,
+ "cost_distance_total_intern_reflection": 16391.962890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_80.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_80.json
new file mode 100755
index 0000000..9d743bf
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_80.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.2141313552856445,
+ "cost_distance_glasses": 2723.3641271821098,
+ "cost_deviation": 8196369.0,
+ "cost_distorsion": 12958.142578125,
+ "cost_thickness": 3863.424560546875,
+ "cost_beam_compression": 1.7342537641525269,
+ "cost_non_linearity": 964.0545043945312,
+ "cost_distance_total_intern_reflection": 16472.888671875
+ },
+ "weighted components": {
+ "cost_dispersion": 104.28262329101562,
+ "cost_distance_glasses": 2723.3641271821098,
+ "cost_deviation": 81.96369171142578,
+ "cost_distorsion": 12958.142578125,
+ "cost_thickness": 3863.424560546875,
+ "cost_beam_compression": 1.7342537641525269,
+ "cost_non_linearity": 964.0545043945312,
+ "cost_distance_total_intern_reflection": 16472.888671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_800.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_800.json
new file mode 100755
index 0000000..d75d200
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_800.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.3929171562194824,
+ "cost_distance_glasses": 746.8461338214244,
+ "cost_deviation": 8109865.0,
+ "cost_distorsion": 11940.662109375,
+ "cost_thickness": 3856.91796875,
+ "cost_beam_compression": 1.7278540134429932,
+ "cost_non_linearity": 958.6236572265625,
+ "cost_distance_total_intern_reflection": 16405.705078125
+ },
+ "weighted components": {
+ "cost_dispersion": 7.858343124389648,
+ "cost_distance_glasses": 746.8461338214244,
+ "cost_deviation": 81.09864807128906,
+ "cost_distorsion": 11940.662109375,
+ "cost_thickness": 3856.91796875,
+ "cost_beam_compression": 1.7278540134429932,
+ "cost_non_linearity": 958.6236572265625,
+ "cost_distance_total_intern_reflection": 16405.705078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_810.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_810.json
new file mode 100755
index 0000000..25dad46
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_810.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.1011195182800293,
+ "cost_distance_glasses": 738.7157045688999,
+ "cost_deviation": 8104376.0,
+ "cost_distorsion": 11952.0888671875,
+ "cost_thickness": 3855.1015625,
+ "cost_beam_compression": 1.7300033569335938,
+ "cost_non_linearity": 957.3762817382812,
+ "cost_distance_total_intern_reflection": 16387.443359375
+ },
+ "weighted components": {
+ "cost_dispersion": 42.02239227294922,
+ "cost_distance_glasses": 738.7157045688999,
+ "cost_deviation": 81.04375457763672,
+ "cost_distorsion": 11952.0888671875,
+ "cost_thickness": 3855.1015625,
+ "cost_beam_compression": 1.7300033569335938,
+ "cost_non_linearity": 957.3762817382812,
+ "cost_distance_total_intern_reflection": 16387.443359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_820.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_820.json
new file mode 100755
index 0000000..264f9f5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_820.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 3.3144264221191406,
+ "cost_distance_glasses": 729.5559364422808,
+ "cost_deviation": 8100876.5,
+ "cost_distorsion": 12074.1064453125,
+ "cost_thickness": 3853.99658203125,
+ "cost_beam_compression": 1.7303580045700073,
+ "cost_non_linearity": 956.3265991210938,
+ "cost_distance_total_intern_reflection": 16380.3125
+ },
+ "weighted components": {
+ "cost_dispersion": 66.28852844238281,
+ "cost_distance_glasses": 729.5559364422808,
+ "cost_deviation": 81.0087661743164,
+ "cost_distorsion": 12074.1064453125,
+ "cost_thickness": 3853.99658203125,
+ "cost_beam_compression": 1.7303580045700073,
+ "cost_non_linearity": 956.3265991210938,
+ "cost_distance_total_intern_reflection": 16380.3125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_830.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_830.json
new file mode 100755
index 0000000..51f811f
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_830.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.36011719703674316,
+ "cost_distance_glasses": 742.7485324625949,
+ "cost_deviation": 8109830.0,
+ "cost_distorsion": 11990.548828125,
+ "cost_thickness": 3857.11669921875,
+ "cost_beam_compression": 1.7275410890579224,
+ "cost_non_linearity": 958.6320190429688,
+ "cost_distance_total_intern_reflection": 16407.419921875
+ },
+ "weighted components": {
+ "cost_dispersion": 7.202343940734863,
+ "cost_distance_glasses": 742.7485324625949,
+ "cost_deviation": 81.09829711914062,
+ "cost_distorsion": 11990.548828125,
+ "cost_thickness": 3857.11669921875,
+ "cost_beam_compression": 1.7275410890579224,
+ "cost_non_linearity": 958.6320190429688,
+ "cost_distance_total_intern_reflection": 16407.419921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_840.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_840.json
new file mode 100755
index 0000000..c80b332
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_840.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4327143430709839,
+ "cost_distance_glasses": 736.9423283364467,
+ "cost_deviation": 8105271.5,
+ "cost_distorsion": 11772.078125,
+ "cost_thickness": 3855.611328125,
+ "cost_beam_compression": 1.7287904024124146,
+ "cost_non_linearity": 957.8661499023438,
+ "cost_distance_total_intern_reflection": 16394.59765625
+ },
+ "weighted components": {
+ "cost_dispersion": 28.654287338256836,
+ "cost_distance_glasses": 736.9423283364467,
+ "cost_deviation": 81.0527114868164,
+ "cost_distorsion": 11772.078125,
+ "cost_thickness": 3855.611328125,
+ "cost_beam_compression": 1.7287904024124146,
+ "cost_non_linearity": 957.8661499023438,
+ "cost_distance_total_intern_reflection": 16394.59765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_850.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_850.json
new file mode 100755
index 0000000..0f7830f
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_850.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4378328323364258,
+ "cost_distance_glasses": 737.9318183677437,
+ "cost_deviation": 8105152.0,
+ "cost_distorsion": 11761.6982421875,
+ "cost_thickness": 3855.62548828125,
+ "cost_beam_compression": 1.7286890745162964,
+ "cost_non_linearity": 957.4945678710938,
+ "cost_distance_total_intern_reflection": 16394.955078125
+ },
+ "weighted components": {
+ "cost_dispersion": 28.756656646728516,
+ "cost_distance_glasses": 737.9318183677437,
+ "cost_deviation": 81.05152130126953,
+ "cost_distorsion": 11761.6982421875,
+ "cost_thickness": 3855.62548828125,
+ "cost_beam_compression": 1.7286890745162964,
+ "cost_non_linearity": 957.4945678710938,
+ "cost_distance_total_intern_reflection": 16394.955078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_860.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_860.json
new file mode 100755
index 0000000..978554b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_860.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.8959251046180725,
+ "cost_distance_glasses": 743.1215027441862,
+ "cost_deviation": 8106921.5,
+ "cost_distorsion": 11821.7109375,
+ "cost_thickness": 3856.266845703125,
+ "cost_beam_compression": 1.7281097173690796,
+ "cost_non_linearity": 958.1856689453125,
+ "cost_distance_total_intern_reflection": 16400.4375
+ },
+ "weighted components": {
+ "cost_dispersion": 17.918502807617188,
+ "cost_distance_glasses": 743.1215027441862,
+ "cost_deviation": 81.0692138671875,
+ "cost_distorsion": 11821.7109375,
+ "cost_thickness": 3856.266845703125,
+ "cost_beam_compression": 1.7281097173690796,
+ "cost_non_linearity": 958.1856689453125,
+ "cost_distance_total_intern_reflection": 16400.4375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_870.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_870.json
new file mode 100755
index 0000000..787016d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_870.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.9044957160949707,
+ "cost_distance_glasses": 747.6224986221376,
+ "cost_deviation": 8106994.0,
+ "cost_distorsion": 11826.064453125,
+ "cost_thickness": 3856.319580078125,
+ "cost_beam_compression": 1.7281389236450195,
+ "cost_non_linearity": 958.0894775390625,
+ "cost_distance_total_intern_reflection": 16400.501953125
+ },
+ "weighted components": {
+ "cost_dispersion": 18.089914321899414,
+ "cost_distance_glasses": 747.6224986221376,
+ "cost_deviation": 81.06993865966797,
+ "cost_distorsion": 11826.064453125,
+ "cost_thickness": 3856.319580078125,
+ "cost_beam_compression": 1.7281389236450195,
+ "cost_non_linearity": 958.0894775390625,
+ "cost_distance_total_intern_reflection": 16400.501953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_880.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_880.json
new file mode 100755
index 0000000..676e3ba
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_880.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.03645920753479,
+ "cost_distance_glasses": 752.2537576528852,
+ "cost_deviation": 8106446.0,
+ "cost_distorsion": 11779.80859375,
+ "cost_thickness": 3856.15478515625,
+ "cost_beam_compression": 1.7283439636230469,
+ "cost_non_linearity": 957.8226318359375,
+ "cost_distance_total_intern_reflection": 16398.7578125
+ },
+ "weighted components": {
+ "cost_dispersion": 20.729183197021484,
+ "cost_distance_glasses": 752.2537576528852,
+ "cost_deviation": 81.06446075439453,
+ "cost_distorsion": 11779.80859375,
+ "cost_thickness": 3856.15478515625,
+ "cost_beam_compression": 1.7283439636230469,
+ "cost_non_linearity": 957.8226318359375,
+ "cost_distance_total_intern_reflection": 16398.7578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_890.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_890.json
new file mode 100755
index 0000000..a21c709
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_890.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3121881484985352,
+ "cost_distance_glasses": 758.4893959626863,
+ "cost_deviation": 8105645.5,
+ "cost_distorsion": 11740.1005859375,
+ "cost_thickness": 3855.885498046875,
+ "cost_beam_compression": 1.7286330461502075,
+ "cost_non_linearity": 957.9493408203125,
+ "cost_distance_total_intern_reflection": 16396.1875
+ },
+ "weighted components": {
+ "cost_dispersion": 26.243762969970703,
+ "cost_distance_glasses": 758.4893959626863,
+ "cost_deviation": 81.05644989013672,
+ "cost_distorsion": 11740.1005859375,
+ "cost_thickness": 3855.885498046875,
+ "cost_beam_compression": 1.7286330461502075,
+ "cost_non_linearity": 957.9493408203125,
+ "cost_distance_total_intern_reflection": 16396.1875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_90.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_90.json
new file mode 100755
index 0000000..eb581e7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_90.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.482011795043945,
+ "cost_distance_glasses": 1849.3325153892522,
+ "cost_deviation": 8148666.5,
+ "cost_distorsion": 12715.8369140625,
+ "cost_thickness": 3851.384521484375,
+ "cost_beam_compression": 1.7404848337173462,
+ "cost_non_linearity": 955.3040161132812,
+ "cost_distance_total_intern_reflection": 16376.0537109375
+ },
+ "weighted components": {
+ "cost_dispersion": 109.6402359008789,
+ "cost_distance_glasses": 1849.3325153892522,
+ "cost_deviation": 81.48666381835938,
+ "cost_distorsion": 12715.8369140625,
+ "cost_thickness": 3851.384521484375,
+ "cost_beam_compression": 1.7404848337173462,
+ "cost_non_linearity": 955.3040161132812,
+ "cost_distance_total_intern_reflection": 16376.0537109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_900.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_900.json
new file mode 100755
index 0000000..ac08250
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_900.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2362715005874634,
+ "cost_distance_glasses": 767.011748726312,
+ "cost_deviation": 8105930.5,
+ "cost_distorsion": 11737.9794921875,
+ "cost_thickness": 3855.9892578125,
+ "cost_beam_compression": 1.7285293340682983,
+ "cost_non_linearity": 957.9102783203125,
+ "cost_distance_total_intern_reflection": 16397.138671875
+ },
+ "weighted components": {
+ "cost_dispersion": 24.72542953491211,
+ "cost_distance_glasses": 767.011748726312,
+ "cost_deviation": 81.0593032836914,
+ "cost_distorsion": 11737.9794921875,
+ "cost_thickness": 3855.9892578125,
+ "cost_beam_compression": 1.7285293340682983,
+ "cost_non_linearity": 957.9102783203125,
+ "cost_distance_total_intern_reflection": 16397.138671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_910.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_910.json
new file mode 100755
index 0000000..15540fd
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_910.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3071589469909668,
+ "cost_distance_glasses": 774.4610368936941,
+ "cost_deviation": 8105563.5,
+ "cost_distorsion": 11749.7841796875,
+ "cost_thickness": 3855.863525390625,
+ "cost_beam_compression": 1.7286592721939087,
+ "cost_non_linearity": 957.6388549804688,
+ "cost_distance_total_intern_reflection": 16395.95703125
+ },
+ "weighted components": {
+ "cost_dispersion": 26.143178939819336,
+ "cost_distance_glasses": 774.4610368936941,
+ "cost_deviation": 81.05563354492188,
+ "cost_distorsion": 11749.7841796875,
+ "cost_thickness": 3855.863525390625,
+ "cost_beam_compression": 1.7286592721939087,
+ "cost_non_linearity": 957.6388549804688,
+ "cost_distance_total_intern_reflection": 16395.95703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_920.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_920.json
new file mode 100755
index 0000000..8db4eaf
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_920.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2664490938186646,
+ "cost_distance_glasses": 780.5888801377372,
+ "cost_deviation": 8105677.5,
+ "cost_distorsion": 11740.314453125,
+ "cost_thickness": 3855.91943359375,
+ "cost_beam_compression": 1.7286163568496704,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 16396.365234375
+ },
+ "weighted components": {
+ "cost_dispersion": 25.328981399536133,
+ "cost_distance_glasses": 780.5888801377372,
+ "cost_deviation": 81.05677032470703,
+ "cost_distorsion": 11740.314453125,
+ "cost_thickness": 3855.91943359375,
+ "cost_beam_compression": 1.7286163568496704,
+ "cost_non_linearity": 957.8050537109375,
+ "cost_distance_total_intern_reflection": 16396.365234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_930.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_930.json
new file mode 100755
index 0000000..8b9ba04
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_930.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.211692452430725,
+ "cost_distance_glasses": 781.2292528771608,
+ "cost_deviation": 8105831.5,
+ "cost_distorsion": 11730.2578125,
+ "cost_thickness": 3856.021728515625,
+ "cost_beam_compression": 1.728554368019104,
+ "cost_non_linearity": 957.9100341796875,
+ "cost_distance_total_intern_reflection": 16396.990234375
+ },
+ "weighted components": {
+ "cost_dispersion": 24.233848571777344,
+ "cost_distance_glasses": 781.2292528771608,
+ "cost_deviation": 81.05831146240234,
+ "cost_distorsion": 11730.2578125,
+ "cost_thickness": 3856.021728515625,
+ "cost_beam_compression": 1.728554368019104,
+ "cost_non_linearity": 957.9100341796875,
+ "cost_distance_total_intern_reflection": 16396.990234375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_940.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_940.json
new file mode 100755
index 0000000..8f2d69b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_940.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.448538064956665,
+ "cost_distance_glasses": 771.3447418977202,
+ "cost_deviation": 8105139.5,
+ "cost_distorsion": 11769.4287109375,
+ "cost_thickness": 3855.893798828125,
+ "cost_beam_compression": 1.7287743091583252,
+ "cost_non_linearity": 957.5993041992188,
+ "cost_distance_total_intern_reflection": 16395.12109375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.970760345458984,
+ "cost_distance_glasses": 771.3447418977202,
+ "cost_deviation": 81.0513916015625,
+ "cost_distorsion": 11769.4287109375,
+ "cost_thickness": 3855.893798828125,
+ "cost_beam_compression": 1.7287743091583252,
+ "cost_non_linearity": 957.5993041992188,
+ "cost_distance_total_intern_reflection": 16395.12109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_950.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_950.json
new file mode 100755
index 0000000..042143f
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_950.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0733182430267334,
+ "cost_distance_glasses": 753.705307871734,
+ "cost_deviation": 8106204.0,
+ "cost_distorsion": 11779.80859375,
+ "cost_thickness": 3856.429443359375,
+ "cost_beam_compression": 1.7283821105957031,
+ "cost_non_linearity": 958.050048828125,
+ "cost_distance_total_intern_reflection": 16398.935546875
+ },
+ "weighted components": {
+ "cost_dispersion": 21.466365814208984,
+ "cost_distance_glasses": 753.705307871734,
+ "cost_deviation": 81.0620346069336,
+ "cost_distorsion": 11779.80859375,
+ "cost_thickness": 3856.429443359375,
+ "cost_beam_compression": 1.7283821105957031,
+ "cost_non_linearity": 958.050048828125,
+ "cost_distance_total_intern_reflection": 16398.935546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_960.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_960.json
new file mode 100755
index 0000000..0f19be8
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_960.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.296851634979248,
+ "cost_distance_glasses": 728.0493351390229,
+ "cost_deviation": 8105423.0,
+ "cost_distorsion": 11748.0927734375,
+ "cost_thickness": 3856.371826171875,
+ "cost_beam_compression": 1.7287153005599976,
+ "cost_non_linearity": 957.673583984375,
+ "cost_distance_total_intern_reflection": 16396.63671875
+ },
+ "weighted components": {
+ "cost_dispersion": 25.93703269958496,
+ "cost_distance_glasses": 728.0493351390229,
+ "cost_deviation": 81.05422973632812,
+ "cost_distorsion": 11748.0927734375,
+ "cost_thickness": 3856.371826171875,
+ "cost_beam_compression": 1.7287153005599976,
+ "cost_non_linearity": 957.673583984375,
+ "cost_distance_total_intern_reflection": 16396.63671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_970.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_970.json
new file mode 100755
index 0000000..9f0e1da
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_970.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.245973587036133,
+ "cost_distance_glasses": 701.6171389670434,
+ "cost_deviation": 8103118.0,
+ "cost_distorsion": 11921.30859375,
+ "cost_thickness": 3855.782470703125,
+ "cost_beam_compression": 1.7297393083572388,
+ "cost_non_linearity": 957.2318115234375,
+ "cost_distance_total_intern_reflection": 16388.810546875
+ },
+ "weighted components": {
+ "cost_dispersion": 44.919471740722656,
+ "cost_distance_glasses": 701.6171389670434,
+ "cost_deviation": 81.03118133544922,
+ "cost_distorsion": 11921.30859375,
+ "cost_thickness": 3855.782470703125,
+ "cost_beam_compression": 1.7297393083572388,
+ "cost_non_linearity": 957.2318115234375,
+ "cost_distance_total_intern_reflection": 16388.810546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_980.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_980.json
new file mode 100755
index 0000000..329d79c
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_980.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.8917703628540039,
+ "cost_distance_glasses": 691.8285172916178,
+ "cost_deviation": 8107344.0,
+ "cost_distorsion": 11769.1591796875,
+ "cost_thickness": 3857.383544921875,
+ "cost_beam_compression": 1.7287784814834595,
+ "cost_non_linearity": 958.1900024414062,
+ "cost_distance_total_intern_reflection": 16400.291015625
+ },
+ "weighted components": {
+ "cost_dispersion": 17.835407257080078,
+ "cost_distance_glasses": 691.8285172916178,
+ "cost_deviation": 81.07344055175781,
+ "cost_distorsion": 11769.1591796875,
+ "cost_thickness": 3857.383544921875,
+ "cost_beam_compression": 1.7287784814834595,
+ "cost_non_linearity": 958.1900024414062,
+ "cost_distance_total_intern_reflection": 16400.291015625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step1/score_details_iteration_990.json b/outputs/single_prism/optimization_results/step1/score_details_iteration_990.json
new file mode 100755
index 0000000..86a2df2
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step1/score_details_iteration_990.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.3477182388305664,
+ "cost_distance_glasses": 680.5551434224252,
+ "cost_deviation": 8103368.5,
+ "cost_distorsion": 11985.58203125,
+ "cost_thickness": 3856.1064453125,
+ "cost_beam_compression": 1.7303401231765747,
+ "cost_non_linearity": 957.0877075195312,
+ "cost_distance_total_intern_reflection": 16387.1328125
+ },
+ "weighted components": {
+ "cost_dispersion": 46.95436477661133,
+ "cost_distance_glasses": 680.5551434224252,
+ "cost_deviation": 81.03368377685547,
+ "cost_distorsion": 11985.58203125,
+ "cost_thickness": 3856.1064453125,
+ "cost_beam_compression": 1.7303401231765747,
+ "cost_non_linearity": 957.0877075195312,
+ "cost_distance_total_intern_reflection": 16387.1328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/optimization_details.json b/outputs/single_prism/optimization_results/step2/optimization_details.json
new file mode 100755
index 0000000..3ecf114
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/optimization_details.json
@@ -0,0 +1,1241 @@
+[
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 0,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 50.294261877928975,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 41.57785791200926,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 929.8660278320312,
+ "deviation [deg]": 1864.678799642566,
+ "max distortion [um]": 111.7420883178711,
+ "mean distortion [um]": 34.951416015625,
+ "beam_compression [no units]": 0.8269510269165039
+ },
+ "current_loss": 131909.921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 10,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 51.58731572555535,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 42.909092517096006,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 969.3773193359375,
+ "deviation [deg]": 1930.8144831870454,
+ "max distortion [um]": 123.65194702148438,
+ "mean distortion [um]": 36.638763427734375,
+ "beam_compression [no units]": 0.8144458532333374
+ },
+ "current_loss": 55796.171875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 20,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.485027978737634,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 44.0926755078,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 995.0812377929688,
+ "deviation [deg]": 1978.0817964701216,
+ "max distortion [um]": 146.6739959716797,
+ "mean distortion [um]": 38.201934814453125,
+ "beam_compression [no units]": 0.8028695583343506
+ },
+ "current_loss": 44147.2421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 30,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.678817520963825,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.95657374330374,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1005.3524780273438,
+ "deviation [deg]": 1988.1885093472595,
+ "max distortion [um]": 129.30308532714844,
+ "mean distortion [um]": 38.18719482421875,
+ "beam_compression [no units]": 0.8042231202125549
+ },
+ "current_loss": 39698.125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 40,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41700270969889,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.33666577423339,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.9556884765625,
+ "deviation [deg]": 1974.2466179304029,
+ "max distortion [um]": 128.89720153808594,
+ "mean distortion [um]": 38.11039733886719,
+ "beam_compression [no units]": 0.8103141188621521
+ },
+ "current_loss": 39038.65625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 50,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.382356575134004,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.39284066506216,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.6956787109375,
+ "deviation [deg]": 1972.4073845907017,
+ "max distortion [um]": 122.86625671386719,
+ "mean distortion [um]": 37.97129821777344,
+ "beam_compression [no units]": 0.8097671866416931
+ },
+ "current_loss": 37475.9765625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 60,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.43908812638013,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.599255811969115,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.809814453125,
+ "deviation [deg]": 1975.4222847318588,
+ "max distortion [um]": 120.84224700927734,
+ "mean distortion [um]": 37.919918060302734,
+ "beam_compression [no units]": 0.807748556137085
+ },
+ "current_loss": 36945.6328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 70,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.4313973333747,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.53729916600793,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.1898193359375,
+ "deviation [deg]": 1975.006572098215,
+ "max distortion [um]": 117.68212890625,
+ "mean distortion [um]": 37.951168060302734,
+ "beam_compression [no units]": 0.8083558082580566
+ },
+ "current_loss": 36195.6875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 80,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.3923559720789,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.553978487961096,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.2427978515625,
+ "deviation [deg]": 1972.9496469692874,
+ "max distortion [um]": 120.58956146240234,
+ "mean distortion [um]": 37.852294921875,
+ "beam_compression [no units]": 0.8081924915313721
+ },
+ "current_loss": 36980.09375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 90,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41735446444115,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.495167144112706,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.069091796875,
+ "deviation [deg]": 1974.2599504596626,
+ "max distortion [um]": 118.6260757446289,
+ "mean distortion [um]": 37.973594665527344,
+ "beam_compression [no units]": 0.8087679743766785
+ },
+ "current_loss": 36426.7578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 100,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.38515353759912,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.56181954512827,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.8135986328125,
+ "deviation [deg]": 1972.5719648289423,
+ "max distortion [um]": 121.38715362548828,
+ "mean distortion [um]": 37.82756805419922,
+ "beam_compression [no units]": 0.8081157803535461
+ },
+ "current_loss": 37213.4296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 110,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41346125661424,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.534095807287194,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.4163818359375,
+ "deviation [deg]": 1974.0593068226044,
+ "max distortion [um]": 118.40038299560547,
+ "mean distortion [um]": 37.92345428466797,
+ "beam_compression [no units]": 0.808387279510498
+ },
+ "current_loss": 36385.22265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 120,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.426749389644506,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50303552203656,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.402099609375,
+ "deviation [deg]": 1974.7576253633465,
+ "max distortion [um]": 118.7144546508789,
+ "mean distortion [um]": 37.98773956298828,
+ "beam_compression [no units]": 0.8086910247802734
+ },
+ "current_loss": 36443.8515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 130,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.414151105720414,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.493746464765344,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.94384765625,
+ "deviation [deg]": 1974.0916545985135,
+ "max distortion [um]": 118.4554214477539,
+ "mean distortion [um]": 37.95039367675781,
+ "beam_compression [no units]": 0.8087820410728455
+ },
+ "current_loss": 36388.6796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 140,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41288752072396,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.49096657777314,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9127197265625,
+ "deviation [deg]": 1974.0243362540539,
+ "max distortion [um]": 118.5611343383789,
+ "mean distortion [um]": 37.95884704589844,
+ "beam_compression [no units]": 0.8088091015815735
+ },
+ "current_loss": 36415.06640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 150,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.42851840863953,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50755369217252,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.413330078125,
+ "deviation [deg]": 1974.852264464486,
+ "max distortion [um]": 118.53746032714844,
+ "mean distortion [um]": 37.971920013427734,
+ "beam_compression [no units]": 0.8086469769477844
+ },
+ "current_loss": 36401.3203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 160,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.3976186328344,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.54904026119118,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.5289306640625,
+ "deviation [deg]": 1973.2261330268896,
+ "max distortion [um]": 120.05269622802734,
+ "mean distortion [um]": 37.878684997558594,
+ "beam_compression [no units]": 0.8082408308982849
+ },
+ "current_loss": 36828.76953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 170,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.411166313053116,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.514981522894914,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.552734375,
+ "deviation [deg]": 1973.936035568464,
+ "max distortion [um]": 117.42407989501953,
+ "mean distortion [um]": 37.93611526489258,
+ "beam_compression [no units]": 0.808574378490448
+ },
+ "current_loss": 36152.7421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 180,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.383685046927575,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.558834752460974,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.7889404296875,
+ "deviation [deg]": 1972.4939367478642,
+ "max distortion [um]": 121.29877471923828,
+ "mean distortion [um]": 37.83027267456055,
+ "beam_compression [no units]": 0.8081449866294861
+ },
+ "current_loss": 37194.984375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 190,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.45899129762155,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50648135247283,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.8058471679688,
+ "deviation [deg]": 1976.4633148443954,
+ "max distortion [um]": 120.69002532958984,
+ "mean distortion [um]": 38.04509353637695,
+ "beam_compression [no units]": 0.8086574673652649
+ },
+ "current_loss": 36954.125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 200,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.42127840811932,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.520339806298786,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.939453125,
+ "deviation [deg]": 1974.4702110030723,
+ "max distortion [um]": 117.23375701904297,
+ "mean distortion [um]": 37.955509185791016,
+ "beam_compression [no units]": 0.8085218071937561
+ },
+ "current_loss": 36096.6328125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 210,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41934887967879,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.508885579060674,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9796752929688,
+ "deviation [deg]": 1974.367266391902,
+ "max distortion [um]": 117.83897399902344,
+ "mean distortion [um]": 37.95143508911133,
+ "beam_compression [no units]": 0.8086339831352234
+ },
+ "current_loss": 36240.1484375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 220,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.40675059575471,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.52097842898618,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.2755126953125,
+ "deviation [deg]": 1973.7036998536569,
+ "max distortion [um]": 117.97924041748047,
+ "mean distortion [um]": 37.91944122314453,
+ "beam_compression [no units]": 0.8085156083106995
+ },
+ "current_loss": 36293.9609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 230,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41860097396468,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50772786199636,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.9617919921875,
+ "deviation [deg]": 1974.328143068336,
+ "max distortion [um]": 117.87730407714844,
+ "mean distortion [um]": 37.95195388793945,
+ "beam_compression [no units]": 0.8086453080177307
+ },
+ "current_loss": 36249.9296875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 240,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41109801116142,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.52356365558703,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.427490234375,
+ "deviation [deg]": 1973.933631341876,
+ "max distortion [um]": 117.93212890625,
+ "mean distortion [um]": 37.9285774230957,
+ "beam_compression [no units]": 0.8084903359413147
+ },
+ "current_loss": 36276.109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 250,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41975527593441,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51674029660619,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.91259765625,
+ "deviation [deg]": 1974.3897786954062,
+ "max distortion [um]": 117.36388397216797,
+ "mean distortion [um]": 37.94822692871094,
+ "beam_compression [no units]": 0.8085570335388184
+ },
+ "current_loss": 36128.47265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 260,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41972795517773,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.518000466508056,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8946533203125,
+ "deviation [deg]": 1974.3884672990855,
+ "max distortion [um]": 117.26061248779297,
+ "mean distortion [um]": 37.945159912109375,
+ "beam_compression [no units]": 0.8085448741912842
+ },
+ "current_loss": 36104.40625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 270,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.417508143697475,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.52053446669013,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.767333984375,
+ "deviation [deg]": 1974.2717530265484,
+ "max distortion [um]": 117.406005859375,
+ "mean distortion [um]": 37.93433380126953,
+ "beam_compression [no units]": 0.8085199594497681
+ },
+ "current_loss": 36141.2109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 280,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.417538879548744,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.520213447799144,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.76513671875,
+ "deviation [deg]": 1974.272627290762,
+ "max distortion [um]": 117.41845703125,
+ "mean distortion [um]": 37.95334243774414,
+ "beam_compression [no units]": 0.8085231184959412
+ },
+ "current_loss": 36144.31640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 290,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41832776639788,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.519048900545656,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8074951171875,
+ "deviation [deg]": 1974.3145919730227,
+ "max distortion [um]": 117.28272247314453,
+ "mean distortion [um]": 37.93670654296875,
+ "beam_compression [no units]": 0.808534562587738
+ },
+ "current_loss": 36111.421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 300,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.419048351355315,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51810291934561,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.856689453125,
+ "deviation [deg]": 1974.3521853342145,
+ "max distortion [um]": 117.24010467529297,
+ "mean distortion [um]": 37.94358825683594,
+ "beam_compression [no units]": 0.8085438013076782
+ },
+ "current_loss": 36100.48828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 310,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.419167879665785,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51792533442719,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.879150390625,
+ "deviation [deg]": 1974.3578680516039,
+ "max distortion [um]": 117.25377655029297,
+ "mean distortion [um]": 37.957218170166016,
+ "beam_compression [no units]": 0.8085454106330872
+ },
+ "current_loss": 36102.8828125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 320,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41884003058563,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51817122123731,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8499755859375,
+ "deviation [deg]": 1974.341038465489,
+ "max distortion [um]": 117.2266845703125,
+ "mean distortion [um]": 37.942787170410156,
+ "beam_compression [no units]": 0.8085431456565857
+ },
+ "current_loss": 36097.2578125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 330,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41768231352131,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51919233451822,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.782958984375,
+ "deviation [deg]": 1974.2802771026327,
+ "max distortion [um]": 117.31519317626953,
+ "mean distortion [um]": 37.94107437133789,
+ "beam_compression [no units]": 0.8085330724716187
+ },
+ "current_loss": 36119.6796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 340,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.417976011655625,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.5179458249947,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.82763671875,
+ "deviation [deg]": 1974.2951395942666,
+ "max distortion [um]": 117.26123809814453,
+ "mean distortion [um]": 37.946929931640625,
+ "beam_compression [no units]": 0.8085451722145081
+ },
+ "current_loss": 36105.640625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 350,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.416162596430986,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.519014749599805,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7225341796875,
+ "deviation [deg]": 1974.2002819270733,
+ "max distortion [um]": 117.39600372314453,
+ "mean distortion [um]": 37.94301223754883,
+ "beam_compression [no units]": 0.8085348010063171
+ },
+ "current_loss": 36140.2890625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 360,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.4165689926866,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51817122123731,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.7562255859375,
+ "deviation [deg]": 1974.2212642682036,
+ "max distortion [um]": 117.33081817626953,
+ "mean distortion [um]": 37.943119049072266,
+ "beam_compression [no units]": 0.8085430264472961
+ },
+ "current_loss": 36124.09375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 370,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.424007068692745,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.509565182883094,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.1920166015625,
+ "deviation [deg]": 1974.6138089001827,
+ "max distortion [um]": 118.12632751464844,
+ "mean distortion [um]": 37.96122741699219,
+ "beam_compression [no units]": 0.8086273074150085
+ },
+ "current_loss": 36304.7421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 380,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.42445103098879,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50953786212641,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.21875,
+ "deviation [deg]": 1974.636758335794,
+ "max distortion [um]": 118.12852478027344,
+ "mean distortion [um]": 37.96429443359375,
+ "beam_compression [no units]": 0.8086276054382324
+ },
+ "current_loss": 36304.859375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 390,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.432339899480155,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50098988038014,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.672607421875,
+ "deviation [deg]": 1975.0535637997048,
+ "max distortion [um]": 119.2212905883789,
+ "mean distortion [um]": 37.992645263671875,
+ "beam_compression [no units]": 0.8087112307548523
+ },
+ "current_loss": 36566.0078125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 400,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.42684842738747,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50797716390106,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.34619140625,
+ "deviation [deg]": 1974.7635266467894,
+ "max distortion [um]": 118.40245056152344,
+ "mean distortion [um]": 37.97025680541992,
+ "beam_compression [no units]": 0.8086428046226501
+ },
+ "current_loss": 36369.203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 410,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.42983322005476,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50483527688286,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.5115356445312,
+ "deviation [deg]": 1974.9215499034267,
+ "max distortion [um]": 118.7776870727539,
+ "mean distortion [um]": 37.9660758972168,
+ "beam_compression [no units]": 0.8086739182472229
+ },
+ "current_loss": 36458.6875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 420,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.44056686233544,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50847576771047,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 999.9564819335938,
+ "deviation [deg]": 1975.488947378158,
+ "max distortion [um]": 119.29110717773438,
+ "mean distortion [um]": 37.993255615234375,
+ "beam_compression [no units]": 0.8086379766464233
+ },
+ "current_loss": 36585.72265625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 430,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41876489850476,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.516183636188835,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.8656616210938,
+ "deviation [deg]": 1974.3368857104736,
+ "max distortion [um]": 117.31896209716797,
+ "mean distortion [um]": 37.95510482788086,
+ "beam_compression [no units]": 0.8085624575614929
+ },
+ "current_loss": 36119.125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 440,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.388018801955944,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.533419618559364,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.2963256835938,
+ "deviation [deg]": 1972.7168741223734,
+ "max distortion [um]": 119.64938354492188,
+ "mean distortion [um]": 37.861572265625,
+ "beam_compression [no units]": 0.8083938360214233
+ },
+ "current_loss": 36752.8203125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 450,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.407508746752576,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.51132737168896,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 998.4319458007812,
+ "deviation [deg]": 1973.7423860451158,
+ "max distortion [um]": 117.38623809814453,
+ "mean distortion [um]": 37.9217643737793,
+ "beam_compression [no units]": 0.8086100816726685
+ },
+ "current_loss": 36148.9609375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 460,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.39228425509262,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.556994016479656,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.1959228515625,
+ "deviation [deg]": 1972.9457127803255,
+ "max distortion [um]": 120.78486633300781,
+ "mean distortion [um]": 37.863502502441406,
+ "beam_compression [no units]": 0.8081629276275635
+ },
+ "current_loss": 37031.1796875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 470,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.489160243185495,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.44826423508223,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.882568359375,
+ "deviation [deg]": 1978.0649668840067,
+ "max distortion [um]": 126.5205307006836,
+ "mean distortion [um]": 38.171024322509766,
+ "beam_compression [no units]": 0.809226393699646
+ },
+ "current_loss": 38605.3515625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 480,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.36569091355918,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50250959747047,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 996.6414184570312,
+ "deviation [deg]": 1971.5359617356348,
+ "max distortion [um]": 118.99485778808594,
+ "mean distortion [um]": 37.83464431762695,
+ "beam_compression [no units]": 0.8086963891983032
+ },
+ "current_loss": 36666.7421875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 490,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.460258297712585,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.55335011055746,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.291748046875,
+ "deviation [deg]": 1976.5339116796565,
+ "max distortion [um]": 117.71373748779297,
+ "mean distortion [um]": 38.00569152832031,
+ "beam_compression [no units]": 0.8081987500190735
+ },
+ "current_loss": 36214.28125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 500,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.50606837647586,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.50854406960217,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1002.9137573242188,
+ "deviation [deg]": 1978.9582463444176,
+ "max distortion [um]": 123.75543212890625,
+ "mean distortion [um]": 38.15047073364258,
+ "beam_compression [no units]": 0.8086373805999756
+ },
+ "current_loss": 37907.62109375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 510,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.41669876628083,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.40552432635087,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.1085205078125,
+ "deviation [deg]": 1974.2238870608448,
+ "max distortion [um]": 124.41068267822266,
+ "mean distortion [um]": 38.057430267333984,
+ "beam_compression [no units]": 0.8096433877944946
+ },
+ "current_loss": 37853.90625
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 520,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.32027357067317,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.61970539834413,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 993.2504272460938,
+ "deviation [deg]": 1969.1793825474404,
+ "max distortion [um]": 127.90830993652344,
+ "mean distortion [um]": 37.66267395019531,
+ "beam_compression [no units]": 0.807547926902771
+ },
+ "current_loss": 39456.1953125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 530,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.477036657408725,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.635472890043104,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.068115234375,
+ "deviation [deg]": 1977.432873857457,
+ "max distortion [um]": 121.02535247802734,
+ "mean distortion [um]": 37.980342864990234,
+ "beam_compression [no units]": 0.8073931336402893
+ },
+ "current_loss": 36984.921875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 540,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.364570762535294,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.4149021760813,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 997.6473999023438,
+ "deviation [deg]": 1971.4677691269615,
+ "max distortion [um]": 120.23616027832031,
+ "mean distortion [um]": 37.9113883972168,
+ "beam_compression [no units]": 0.8095520734786987
+ },
+ "current_loss": 36885.4453125
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 550,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.4400750887152,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.44326112151519,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1000.7076416015625,
+ "deviation [deg]": 1975.4607523572643,
+ "max distortion [um]": 123.54374694824219,
+ "mean distortion [um]": 38.0726318359375,
+ "beam_compression [no units]": 0.8092751502990723
+ },
+ "current_loss": 37656.1875
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 560,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.36153132835464,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.72333985862073,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 993.8787231445312,
+ "deviation [deg]": 1971.3860254229746,
+ "max distortion [um]": 131.76007080078125,
+ "mean distortion [um]": 37.71396255493164,
+ "beam_compression [no units]": 0.8065288662910461
+ },
+ "current_loss": 40292.34375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 570,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.526152547730284,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.42302668609903,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 1004.880859375,
+ "deviation [deg]": 1980.033372761291,
+ "max distortion [um]": 130.737060546875,
+ "mean distortion [um]": 38.29106521606445,
+ "beam_compression [no units]": 0.8094727396965027
+ },
+ "current_loss": 40049.4375
+ },
+ {
+ "reason_for_stopping": "completed",
+ "iterations": 580,
+ "end_parameters": {
+ "lba_c": 520.0,
+ "A1": 52.32137323112955,
+ "A2": 0.0,
+ "A3": 0.0,
+ "delta_beta_c": 0.0,
+ "alpha_c": 43.552100185939345,
+ "delta_alpha_c": 0.0
+ },
+ "optical system values": {
+ "dispersion [um]": 994.0932006835938,
+ "deviation [deg]": 1969.2150088141511,
+ "max distortion [um]": 124.03726196289062,
+ "mean distortion [um]": 37.704830169677734,
+ "beam_compression [no units]": 0.8082109093666077
+ },
+ "current_loss": 38297.875
+ }
+]
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_0.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_0.json
new file mode 100755
index 0000000..3ebaa2a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_0.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 4918.77392578125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8065988.5,
+ "cost_distorsion": 12486.2939453125,
+ "cost_thickness": 3852.66845703125,
+ "cost_beam_compression": 1.730489730834961,
+ "cost_non_linearity": 776.3705444335938,
+ "cost_distance_total_intern_reflection": 16336.7177734375
+ },
+ "weighted components": {
+ "cost_dispersion": 98375.4765625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 80.65988159179688,
+ "cost_distorsion": 12486.2939453125,
+ "cost_thickness": 3852.66845703125,
+ "cost_beam_compression": 1.730489730834961,
+ "cost_non_linearity": 776.3705444335938,
+ "cost_distance_total_intern_reflection": 16336.7177734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_10.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_10.json
new file mode 100755
index 0000000..b0ad5c7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_10.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 937.7485961914062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8648296.0,
+ "cost_distorsion": 15289.8037109375,
+ "cost_thickness": 4053.3173828125,
+ "cost_beam_compression": 1.855541467666626,
+ "cost_non_linearity": 842.9962158203125,
+ "cost_distance_total_intern_reflection": 16766.74609375
+ },
+ "weighted components": {
+ "cost_dispersion": 18754.97265625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 86.48295593261719,
+ "cost_distorsion": 15289.8037109375,
+ "cost_thickness": 4053.3173828125,
+ "cost_beam_compression": 1.855541467666626,
+ "cost_non_linearity": 842.9962158203125,
+ "cost_distance_total_intern_reflection": 16766.74609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_100.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_100.json
new file mode 100755
index 0000000..c3537b9
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_100.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.153153419494629,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9026413.0,
+ "cost_distorsion": 14734.8408203125,
+ "cost_thickness": 4179.662109375,
+ "cost_beam_compression": 1.9188421964645386,
+ "cost_non_linearity": 890.5478515625,
+ "cost_distance_total_intern_reflection": 17113.1328125
+ },
+ "weighted components": {
+ "cost_dispersion": 203.0630645751953,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.26412963867188,
+ "cost_distorsion": 14734.8408203125,
+ "cost_thickness": 4179.662109375,
+ "cost_beam_compression": 1.9188421964645386,
+ "cost_non_linearity": 890.5478515625,
+ "cost_distance_total_intern_reflection": 17113.1328125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_110.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_110.json
new file mode 100755
index 0000000..94e7f2d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_110.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.5078465938568115,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9040030.0,
+ "cost_distorsion": 14018.650390625,
+ "cost_thickness": 4184.1806640625,
+ "cost_beam_compression": 1.9161272048950195,
+ "cost_non_linearity": 893.31787109375,
+ "cost_distance_total_intern_reflection": 17146.599609375
+ },
+ "weighted components": {
+ "cost_dispersion": 50.15693283081055,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.40029907226562,
+ "cost_distorsion": 14018.650390625,
+ "cost_thickness": 4184.1806640625,
+ "cost_beam_compression": 1.9161272048950195,
+ "cost_non_linearity": 893.31787109375,
+ "cost_distance_total_intern_reflection": 17146.599609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_120.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_120.json
new file mode 100755
index 0000000..057a790
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_120.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.3574848771095276,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9046426.0,
+ "cost_distorsion": 14093.1220703125,
+ "cost_thickness": 4186.30224609375,
+ "cost_beam_compression": 1.9130897521972656,
+ "cost_non_linearity": 895.1143798828125,
+ "cost_distance_total_intern_reflection": 17169.78515625
+ },
+ "weighted components": {
+ "cost_dispersion": 7.149697303771973,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.4642562866211,
+ "cost_distorsion": 14093.1220703125,
+ "cost_thickness": 4186.30224609375,
+ "cost_beam_compression": 1.9130897521972656,
+ "cost_non_linearity": 895.1143798828125,
+ "cost_distance_total_intern_reflection": 17169.78515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_130.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_130.json
new file mode 100755
index 0000000..b9278b6
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_130.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1154577732086182,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9040327.0,
+ "cost_distorsion": 14031.6865234375,
+ "cost_thickness": 4184.29052734375,
+ "cost_beam_compression": 1.9121795892715454,
+ "cost_non_linearity": 894.3023071289062,
+ "cost_distance_total_intern_reflection": 17163.7734375
+ },
+ "weighted components": {
+ "cost_dispersion": 22.309154510498047,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.40326690673828,
+ "cost_distorsion": 14031.6865234375,
+ "cost_thickness": 4184.29052734375,
+ "cost_beam_compression": 1.9121795892715454,
+ "cost_non_linearity": 894.3023071289062,
+ "cost_distance_total_intern_reflection": 17163.7734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_140.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_140.json
new file mode 100755
index 0000000..bd0582e
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_140.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1821783781051636,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9039710.0,
+ "cost_distorsion": 14056.7421875,
+ "cost_thickness": 4184.0888671875,
+ "cost_beam_compression": 1.9119089841842651,
+ "cost_non_linearity": 894.34521484375,
+ "cost_distance_total_intern_reflection": 17163.9375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.64356803894043,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.3970947265625,
+ "cost_distorsion": 14056.7421875,
+ "cost_thickness": 4184.0888671875,
+ "cost_beam_compression": 1.9119089841842651,
+ "cost_non_linearity": 894.34521484375,
+ "cost_distance_total_intern_reflection": 17163.9375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_150.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_150.json
new file mode 100755
index 0000000..60916fe
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_150.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.3441815972328186,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9047294.0,
+ "cost_distorsion": 14051.1298828125,
+ "cost_thickness": 4186.5849609375,
+ "cost_beam_compression": 1.9135302305221558,
+ "cost_non_linearity": 895.0423583984375,
+ "cost_distance_total_intern_reflection": 17169.294921875
+ },
+ "weighted components": {
+ "cost_dispersion": 6.883631706237793,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.47293853759766,
+ "cost_distorsion": 14051.1298828125,
+ "cost_thickness": 4186.5849609375,
+ "cost_beam_compression": 1.9135302305221558,
+ "cost_non_linearity": 895.0423583984375,
+ "cost_distance_total_intern_reflection": 17169.294921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_160.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_160.json
new file mode 100755
index 0000000..492a138
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_160.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 6.1061835289001465,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9032402.0,
+ "cost_distorsion": 14412.6494140625,
+ "cost_thickness": 4181.6513671875,
+ "cost_beam_compression": 1.9175916910171509,
+ "cost_non_linearity": 892.0293579101562,
+ "cost_distance_total_intern_reflection": 17128.07421875
+ },
+ "weighted components": {
+ "cost_dispersion": 122.12367248535156,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.32402038574219,
+ "cost_distorsion": 14412.6494140625,
+ "cost_thickness": 4181.6513671875,
+ "cost_beam_compression": 1.9175916910171509,
+ "cost_non_linearity": 892.0293579101562,
+ "cost_distance_total_intern_reflection": 17128.07421875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_170.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_170.json
new file mode 100755
index 0000000..28796ea
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_170.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.0945777893066406,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9038901.0,
+ "cost_distorsion": 13788.4140625,
+ "cost_thickness": 4183.814453125,
+ "cost_beam_compression": 1.91425621509552,
+ "cost_non_linearity": 893.6471557617188,
+ "cost_distance_total_intern_reflection": 17152.67578125
+ },
+ "weighted components": {
+ "cost_dispersion": 41.89155578613281,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.38900756835938,
+ "cost_distorsion": 13788.4140625,
+ "cost_thickness": 4183.814453125,
+ "cost_beam_compression": 1.91425621509552,
+ "cost_non_linearity": 893.6471557617188,
+ "cost_distance_total_intern_reflection": 17152.67578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_180.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_180.json
new file mode 100755
index 0000000..3532086
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_180.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 10.310903549194336,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9025700.0,
+ "cost_distorsion": 14713.392578125,
+ "cost_thickness": 4179.427734375,
+ "cost_beam_compression": 1.9185501337051392,
+ "cost_non_linearity": 890.5648193359375,
+ "cost_distance_total_intern_reflection": 17113.205078125
+ },
+ "weighted components": {
+ "cost_dispersion": 206.21807861328125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.25699615478516,
+ "cost_distorsion": 14713.392578125,
+ "cost_thickness": 4179.427734375,
+ "cost_beam_compression": 1.9185501337051392,
+ "cost_non_linearity": 890.5648193359375,
+ "cost_distance_total_intern_reflection": 17113.205078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_190.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_190.json
new file mode 100755
index 0000000..6ae36b1
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_190.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6493896842002869,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9062061.0,
+ "cost_distorsion": 14566.08203125,
+ "cost_thickness": 4191.453125,
+ "cost_beam_compression": 1.913425326347351,
+ "cost_non_linearity": 897.48876953125,
+ "cost_distance_total_intern_reflection": 17193.576171875
+ },
+ "weighted components": {
+ "cost_dispersion": 12.987793922424316,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.62060546875,
+ "cost_distorsion": 14566.08203125,
+ "cost_thickness": 4191.453125,
+ "cost_beam_compression": 1.913425326347351,
+ "cost_non_linearity": 897.48876953125,
+ "cost_distance_total_intern_reflection": 17193.576171875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_20.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_20.json
new file mode 100755
index 0000000..3cf0a5c
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_20.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 24.19422149658203,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9076910.0,
+ "cost_distorsion": 21513.26171875,
+ "cost_thickness": 4195.61474609375,
+ "cost_beam_compression": 1.9713044166564941,
+ "cost_non_linearity": 887.6690673828125,
+ "cost_distance_total_intern_reflection": 16974.0703125
+ },
+ "weighted components": {
+ "cost_dispersion": 483.8844299316406,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.76909637451172,
+ "cost_distorsion": 21513.26171875,
+ "cost_thickness": 4195.61474609375,
+ "cost_beam_compression": 1.9713044166564941,
+ "cost_non_linearity": 887.6690673828125,
+ "cost_distance_total_intern_reflection": 16974.0703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_200.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_200.json
new file mode 100755
index 0000000..e88a7ab
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_200.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1247596740722656,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9043795.0,
+ "cost_distorsion": 13743.75390625,
+ "cost_thickness": 4185.4287109375,
+ "cost_beam_compression": 1.914781928062439,
+ "cost_non_linearity": 894.2306518554688,
+ "cost_distance_total_intern_reflection": 17158.369140625
+ },
+ "weighted components": {
+ "cost_dispersion": 22.495193481445312,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.43795013427734,
+ "cost_distorsion": 13743.75390625,
+ "cost_thickness": 4185.4287109375,
+ "cost_beam_compression": 1.914781928062439,
+ "cost_non_linearity": 894.2306518554688,
+ "cost_distance_total_intern_reflection": 17158.369140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_210.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_210.json
new file mode 100755
index 0000000..2089199
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_210.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0410624742507935,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042851.0,
+ "cost_distorsion": 13886.0234375,
+ "cost_thickness": 4185.12060546875,
+ "cost_beam_compression": 1.9136601686477661,
+ "cost_non_linearity": 894.2600708007812,
+ "cost_distance_total_intern_reflection": 17161.58203125
+ },
+ "weighted components": {
+ "cost_dispersion": 20.82124900817871,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42850494384766,
+ "cost_distorsion": 13886.0234375,
+ "cost_thickness": 4185.12060546875,
+ "cost_beam_compression": 1.9136601686477661,
+ "cost_non_linearity": 894.2600708007812,
+ "cost_distance_total_intern_reflection": 17161.58203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_220.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_220.json
new file mode 100755
index 0000000..3fada40
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_220.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.9738564491271973,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9036774.0,
+ "cost_distorsion": 13919.1015625,
+ "cost_thickness": 4183.10888671875,
+ "cost_beam_compression": 1.9148439168930054,
+ "cost_non_linearity": 893.2288208007812,
+ "cost_distance_total_intern_reflection": 17146.763671875
+ },
+ "weighted components": {
+ "cost_dispersion": 59.47712707519531,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.36773681640625,
+ "cost_distorsion": 13919.1015625,
+ "cost_thickness": 4183.10888671875,
+ "cost_beam_compression": 1.9148439168930054,
+ "cost_non_linearity": 893.2288208007812,
+ "cost_distance_total_intern_reflection": 17146.763671875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_230.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_230.json
new file mode 100755
index 0000000..b0aea34
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_230.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.0778758525848389,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042494.0,
+ "cost_distorsion": 13895.05859375,
+ "cost_thickness": 4185.00146484375,
+ "cost_beam_compression": 1.9135469198226929,
+ "cost_non_linearity": 894.4801635742188,
+ "cost_distance_total_intern_reflection": 17161.494140625
+ },
+ "weighted components": {
+ "cost_dispersion": 21.557518005371094,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42493438720703,
+ "cost_distorsion": 13895.05859375,
+ "cost_thickness": 4185.00146484375,
+ "cost_beam_compression": 1.9135469198226929,
+ "cost_non_linearity": 894.4801635742188,
+ "cost_distance_total_intern_reflection": 17161.494140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_240.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_240.json
new file mode 100755
index 0000000..945b99d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_240.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.4727869033813477,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9038879.0,
+ "cost_distorsion": 13907.9873046875,
+ "cost_thickness": 4183.80322265625,
+ "cost_beam_compression": 1.915096640586853,
+ "cost_non_linearity": 893.473876953125,
+ "cost_distance_total_intern_reflection": 17149.083984375
+ },
+ "weighted components": {
+ "cost_dispersion": 49.45573806762695,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.38878631591797,
+ "cost_distorsion": 13907.9873046875,
+ "cost_thickness": 4183.80322265625,
+ "cost_beam_compression": 1.915096640586853,
+ "cost_non_linearity": 893.473876953125,
+ "cost_distance_total_intern_reflection": 17149.083984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_250.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_250.json
new file mode 100755
index 0000000..523659b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_250.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.1824438571929932,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9043056.0,
+ "cost_distorsion": 13774.28125,
+ "cost_thickness": 4185.185546875,
+ "cost_beam_compression": 1.9144296646118164,
+ "cost_non_linearity": 894.3490600585938,
+ "cost_distance_total_intern_reflection": 17158.662109375
+ },
+ "weighted components": {
+ "cost_dispersion": 23.648876190185547,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.43055725097656,
+ "cost_distorsion": 13774.28125,
+ "cost_thickness": 4185.185546875,
+ "cost_beam_compression": 1.9144296646118164,
+ "cost_non_linearity": 894.3490600585938,
+ "cost_distance_total_intern_reflection": 17158.662109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_260.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_260.json
new file mode 100755
index 0000000..651af3a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_260.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2217912673950195,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9043046.0,
+ "cost_distorsion": 13750.05078125,
+ "cost_thickness": 4185.18115234375,
+ "cost_beam_compression": 1.9145512580871582,
+ "cost_non_linearity": 894.27685546875,
+ "cost_distance_total_intern_reflection": 17158.119140625
+ },
+ "weighted components": {
+ "cost_dispersion": 24.43582534790039,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.43045806884766,
+ "cost_distorsion": 13750.05078125,
+ "cost_thickness": 4185.18115234375,
+ "cost_beam_compression": 1.9145512580871582,
+ "cost_non_linearity": 894.27685546875,
+ "cost_distance_total_intern_reflection": 17158.119140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_270.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_270.json
new file mode 100755
index 0000000..633c536
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_270.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.519465446472168,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041979.0,
+ "cost_distorsion": 13784.169921875,
+ "cost_thickness": 4184.82666015625,
+ "cost_beam_compression": 1.9148004055023193,
+ "cost_non_linearity": 894.1500854492188,
+ "cost_distance_total_intern_reflection": 17155.341796875
+ },
+ "weighted components": {
+ "cost_dispersion": 30.38930892944336,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41978454589844,
+ "cost_distorsion": 13784.169921875,
+ "cost_thickness": 4184.82666015625,
+ "cost_beam_compression": 1.9148004055023193,
+ "cost_non_linearity": 894.1500854492188,
+ "cost_distance_total_intern_reflection": 17155.341796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_280.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_280.json
new file mode 100755
index 0000000..08da8dc
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_280.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.5248873233795166,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041983.0,
+ "cost_distorsion": 13787.09375,
+ "cost_thickness": 4184.83154296875,
+ "cost_beam_compression": 1.9147688150405884,
+ "cost_non_linearity": 894.0531616210938,
+ "cost_distance_total_intern_reflection": 17155.505859375
+ },
+ "weighted components": {
+ "cost_dispersion": 30.497745513916016,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41983032226562,
+ "cost_distorsion": 13787.09375,
+ "cost_thickness": 4184.83154296875,
+ "cost_beam_compression": 1.9147688150405884,
+ "cost_non_linearity": 894.0531616210938,
+ "cost_distance_total_intern_reflection": 17155.505859375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_290.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_290.json
new file mode 100755
index 0000000..a28e418
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_290.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4220678806304932,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042369.0,
+ "cost_distorsion": 13755.2373046875,
+ "cost_thickness": 4184.95751953125,
+ "cost_beam_compression": 1.9146543741226196,
+ "cost_non_linearity": 893.8585205078125,
+ "cost_distance_total_intern_reflection": 17156.58984375
+ },
+ "weighted components": {
+ "cost_dispersion": 28.441356658935547,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42369079589844,
+ "cost_distorsion": 13755.2373046875,
+ "cost_thickness": 4184.95751953125,
+ "cost_beam_compression": 1.9146543741226196,
+ "cost_non_linearity": 893.8585205078125,
+ "cost_distance_total_intern_reflection": 17156.58984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_30.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_30.json
new file mode 100755
index 0000000..19359b0
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_30.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 28.64902114868164,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9169899.0,
+ "cost_distorsion": 16719.287109375,
+ "cost_thickness": 4226.65478515625,
+ "cost_beam_compression": 1.9577687978744507,
+ "cost_non_linearity": 905.6940307617188,
+ "cost_distance_total_intern_reflection": 17179.8515625
+ },
+ "weighted components": {
+ "cost_dispersion": 572.9804077148438,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 91.69898986816406,
+ "cost_distorsion": 16719.287109375,
+ "cost_thickness": 4226.65478515625,
+ "cost_beam_compression": 1.9577687978744507,
+ "cost_non_linearity": 905.6940307617188,
+ "cost_distance_total_intern_reflection": 17179.8515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_300.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_300.json
new file mode 100755
index 0000000..daa5aec
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_300.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3071589469909668,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042714.0,
+ "cost_distorsion": 13745.2421875,
+ "cost_thickness": 4185.07275390625,
+ "cost_beam_compression": 1.9145619869232178,
+ "cost_non_linearity": 894.1458740234375,
+ "cost_distance_total_intern_reflection": 17157.54296875
+ },
+ "weighted components": {
+ "cost_dispersion": 26.143178939819336,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42713928222656,
+ "cost_distorsion": 13745.2421875,
+ "cost_thickness": 4185.07275390625,
+ "cost_beam_compression": 1.9145619869232178,
+ "cost_non_linearity": 894.1458740234375,
+ "cost_distance_total_intern_reflection": 17157.54296875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_310.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_310.json
new file mode 100755
index 0000000..1d57dc9
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_310.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2563037872314453,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042767.0,
+ "cost_distorsion": 13748.4482421875,
+ "cost_thickness": 4185.091796875,
+ "cost_beam_compression": 1.9145458936691284,
+ "cost_non_linearity": 894.1672973632812,
+ "cost_distance_total_intern_reflection": 17157.70703125
+ },
+ "weighted components": {
+ "cost_dispersion": 25.126075744628906,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42766571044922,
+ "cost_distorsion": 13748.4482421875,
+ "cost_thickness": 4185.091796875,
+ "cost_beam_compression": 1.9145458936691284,
+ "cost_non_linearity": 894.1672973632812,
+ "cost_distance_total_intern_reflection": 17157.70703125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_320.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_320.json
new file mode 100755
index 0000000..38d7774
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_320.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3225561380386353,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042613.0,
+ "cost_distorsion": 13742.095703125,
+ "cost_thickness": 4185.03955078125,
+ "cost_beam_compression": 1.914568543434143,
+ "cost_non_linearity": 893.9725952148438,
+ "cost_distance_total_intern_reflection": 17157.359375
+ },
+ "weighted components": {
+ "cost_dispersion": 26.451122283935547,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.4261245727539,
+ "cost_distorsion": 13742.095703125,
+ "cost_thickness": 4185.03955078125,
+ "cost_beam_compression": 1.914568543434143,
+ "cost_non_linearity": 893.9725952148438,
+ "cost_distance_total_intern_reflection": 17157.359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_330.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_330.json
new file mode 100755
index 0000000..d19d5a0
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_330.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.4811887741088867,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042055.0,
+ "cost_distorsion": 13762.8544921875,
+ "cost_thickness": 4184.8544921875,
+ "cost_beam_compression": 1.9146692752838135,
+ "cost_non_linearity": 893.9769897460938,
+ "cost_distance_total_intern_reflection": 17156.037109375
+ },
+ "weighted components": {
+ "cost_dispersion": 29.623775482177734,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42054748535156,
+ "cost_distorsion": 13762.8544921875,
+ "cost_thickness": 4184.8544921875,
+ "cost_beam_compression": 1.9146692752838135,
+ "cost_non_linearity": 893.9769897460938,
+ "cost_distance_total_intern_reflection": 17156.037109375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_340.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_340.json
new file mode 100755
index 0000000..34f7850
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_340.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.3744356632232666,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042191.0,
+ "cost_distorsion": 13750.1982421875,
+ "cost_thickness": 4184.9013671875,
+ "cost_beam_compression": 1.9145482778549194,
+ "cost_non_linearity": 893.9435424804688,
+ "cost_distance_total_intern_reflection": 17156.7734375
+ },
+ "weighted components": {
+ "cost_dispersion": 27.488712310791016,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42190551757812,
+ "cost_distorsion": 13750.1982421875,
+ "cost_thickness": 4184.9013671875,
+ "cost_beam_compression": 1.9145482778549194,
+ "cost_non_linearity": 893.9435424804688,
+ "cost_distance_total_intern_reflection": 17156.7734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_350.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_350.json
new file mode 100755
index 0000000..60370e0
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_350.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.6319189071655273,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041322.0,
+ "cost_distorsion": 13781.8212890625,
+ "cost_thickness": 4184.61181640625,
+ "cost_beam_compression": 1.9146519899368286,
+ "cost_non_linearity": 893.9727172851562,
+ "cost_distance_total_intern_reflection": 17154.919921875
+ },
+ "weighted components": {
+ "cost_dispersion": 32.63837814331055,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41321563720703,
+ "cost_distorsion": 13781.8212890625,
+ "cost_thickness": 4184.61181640625,
+ "cost_beam_compression": 1.9146519899368286,
+ "cost_non_linearity": 893.9727172851562,
+ "cost_distance_total_intern_reflection": 17154.919921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_360.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_360.json
new file mode 100755
index 0000000..a761aa6
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_360.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.546974778175354,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041513.0,
+ "cost_distorsion": 13766.5205078125,
+ "cost_thickness": 4184.6767578125,
+ "cost_beam_compression": 1.9145697355270386,
+ "cost_non_linearity": 894.0361328125,
+ "cost_distance_total_intern_reflection": 17155.59375
+ },
+ "weighted components": {
+ "cost_dispersion": 30.939495086669922,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41513061523438,
+ "cost_distorsion": 13766.5205078125,
+ "cost_thickness": 4184.6767578125,
+ "cost_beam_compression": 1.9145697355270386,
+ "cost_non_linearity": 894.0361328125,
+ "cost_distance_total_intern_reflection": 17155.59375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_370.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_370.json
new file mode 100755
index 0000000..45f23aa
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_370.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6528371572494507,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9045109.0,
+ "cost_distorsion": 13953.8291015625,
+ "cost_thickness": 4185.86474609375,
+ "cost_beam_compression": 1.9137269258499146,
+ "cost_non_linearity": 894.6830444335938,
+ "cost_distance_total_intern_reflection": 17164.943359375
+ },
+ "weighted components": {
+ "cost_dispersion": 13.056743621826172,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.45108795166016,
+ "cost_distorsion": 13953.8291015625,
+ "cost_thickness": 4185.86474609375,
+ "cost_beam_compression": 1.9137269258499146,
+ "cost_non_linearity": 894.6830444335938,
+ "cost_distance_total_intern_reflection": 17164.943359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_380.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_380.json
new file mode 100755
index 0000000..9ca1acf
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_380.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6103515625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9045321.0,
+ "cost_distorsion": 13954.3486328125,
+ "cost_thickness": 4185.93505859375,
+ "cost_beam_compression": 1.9137239456176758,
+ "cost_non_linearity": 894.6998291015625,
+ "cost_distance_total_intern_reflection": 17165.302734375
+ },
+ "weighted components": {
+ "cost_dispersion": 12.20703125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.45320892333984,
+ "cost_distorsion": 13954.3486328125,
+ "cost_thickness": 4185.93505859375,
+ "cost_beam_compression": 1.9137239456176758,
+ "cost_non_linearity": 894.6998291015625,
+ "cost_distance_total_intern_reflection": 17165.302734375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_390.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_390.json
new file mode 100755
index 0000000..bf55315
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_390.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.10718590021133423,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9049139.0,
+ "cost_distorsion": 14213.7158203125,
+ "cost_thickness": 4187.1953125,
+ "cost_beam_compression": 1.912887692451477,
+ "cost_non_linearity": 895.5543212890625,
+ "cost_distance_total_intern_reflection": 17174.99609375
+ },
+ "weighted components": {
+ "cost_dispersion": 2.1437180042266846,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.49138641357422,
+ "cost_distorsion": 14213.7158203125,
+ "cost_thickness": 4187.1953125,
+ "cost_beam_compression": 1.912887692451477,
+ "cost_non_linearity": 895.5543212890625,
+ "cost_distance_total_intern_reflection": 17174.99609375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_40.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_40.json
new file mode 100755
index 0000000..992b20a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_40.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.9133404493331909,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041745.0,
+ "cost_distorsion": 16614.48828125,
+ "cost_thickness": 4184.74609375,
+ "cost_beam_compression": 1.896858811378479,
+ "cost_non_linearity": 897.71728515625,
+ "cost_distance_total_intern_reflection": 17231.125
+ },
+ "weighted components": {
+ "cost_dispersion": 18.266809463500977,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41744995117188,
+ "cost_distorsion": 16614.48828125,
+ "cost_thickness": 4184.74609375,
+ "cost_beam_compression": 1.896858811378479,
+ "cost_non_linearity": 897.71728515625,
+ "cost_distance_total_intern_reflection": 17231.125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_400.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_400.json
new file mode 100755
index 0000000..3e22842
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_400.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.42746567726135254,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9046482.0,
+ "cost_distorsion": 14019.140625,
+ "cost_thickness": 4186.318359375,
+ "cost_beam_compression": 1.9135719537734985,
+ "cost_non_linearity": 894.9915161132812,
+ "cost_distance_total_intern_reflection": 17167.822265625
+ },
+ "weighted components": {
+ "cost_dispersion": 8.54931354522705,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.4648208618164,
+ "cost_distorsion": 14019.140625,
+ "cost_thickness": 4186.318359375,
+ "cost_beam_compression": 1.9135719537734985,
+ "cost_non_linearity": 894.9915161132812,
+ "cost_distance_total_intern_reflection": 17167.822265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_410.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_410.json
new file mode 100755
index 0000000..e148158
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_410.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.23859742283821106,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9047930.0,
+ "cost_distorsion": 14108.138671875,
+ "cost_thickness": 4186.794921875,
+ "cost_beam_compression": 1.913260817527771,
+ "cost_non_linearity": 895.1436767578125,
+ "cost_distance_total_intern_reflection": 17171.447265625
+ },
+ "weighted components": {
+ "cost_dispersion": 4.771948337554932,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.47930145263672,
+ "cost_distorsion": 14108.138671875,
+ "cost_thickness": 4186.794921875,
+ "cost_beam_compression": 1.913260817527771,
+ "cost_non_linearity": 895.1436767578125,
+ "cost_distance_total_intern_reflection": 17171.447265625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_420.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_420.json
new file mode 100755
index 0000000..51c99c8
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_420.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.0018938221037387848,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9053129.0,
+ "cost_distorsion": 14230.3681640625,
+ "cost_thickness": 4188.50927734375,
+ "cost_beam_compression": 1.9136202335357666,
+ "cost_non_linearity": 896.0192260742188,
+ "cost_distance_total_intern_reflection": 17178.341796875
+ },
+ "weighted components": {
+ "cost_dispersion": 0.037876442074775696,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.53128814697266,
+ "cost_distorsion": 14230.3681640625,
+ "cost_thickness": 4188.50927734375,
+ "cost_beam_compression": 1.9136202335357666,
+ "cost_non_linearity": 896.0192260742188,
+ "cost_distance_total_intern_reflection": 17178.341796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_430.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_430.json
new file mode 100755
index 0000000..525484a
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_430.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.2867236137390137,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9042573.0,
+ "cost_distorsion": 13763.7392578125,
+ "cost_thickness": 4185.02734375,
+ "cost_beam_compression": 1.9143754243850708,
+ "cost_non_linearity": 894.1672973632812,
+ "cost_distance_total_intern_reflection": 17158.119140625
+ },
+ "weighted components": {
+ "cost_dispersion": 25.734472274780273,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.42572784423828,
+ "cost_distorsion": 13763.7392578125,
+ "cost_thickness": 4185.02734375,
+ "cost_beam_compression": 1.9143754243850708,
+ "cost_non_linearity": 894.1672973632812,
+ "cost_distance_total_intern_reflection": 17158.119140625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_440.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_440.json
new file mode 100755
index 0000000..5240fa9
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_440.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.309854984283447,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9027741.0,
+ "cost_distorsion": 14315.974609375,
+ "cost_thickness": 4180.119140625,
+ "cost_beam_compression": 1.9160616397857666,
+ "cost_non_linearity": 891.3031616210938,
+ "cost_distance_total_intern_reflection": 17127.03515625
+ },
+ "weighted components": {
+ "cost_dispersion": 146.1970977783203,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.27740478515625,
+ "cost_distorsion": 14315.974609375,
+ "cost_thickness": 4180.119140625,
+ "cost_beam_compression": 1.9160616397857666,
+ "cost_non_linearity": 891.3031616210938,
+ "cost_distance_total_intern_reflection": 17127.03515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_450.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_450.json
new file mode 100755
index 0000000..89a4d82
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_450.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 2.458793878555298,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9037128.0,
+ "cost_distorsion": 13779.529296875,
+ "cost_thickness": 4183.23046875,
+ "cost_beam_compression": 1.9138991832733154,
+ "cost_non_linearity": 893.3978881835938,
+ "cost_distance_total_intern_reflection": 17151.33984375
+ },
+ "weighted components": {
+ "cost_dispersion": 49.17587661743164,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.37127685546875,
+ "cost_distorsion": 13779.529296875,
+ "cost_thickness": 4183.23046875,
+ "cost_beam_compression": 1.9138991832733154,
+ "cost_non_linearity": 893.3978881835938,
+ "cost_distance_total_intern_reflection": 17151.33984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_460.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_460.json
new file mode 100755
index 0000000..6b52fa7
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_460.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.86284875869751,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9029834.0,
+ "cost_distorsion": 14588.984375,
+ "cost_thickness": 4180.7998046875,
+ "cost_beam_compression": 1.9183707237243652,
+ "cost_non_linearity": 891.2567749023438,
+ "cost_distance_total_intern_reflection": 17120.66796875
+ },
+ "weighted components": {
+ "cost_dispersion": 157.25697326660156,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.29833984375,
+ "cost_distorsion": 14588.984375,
+ "cost_thickness": 4180.7998046875,
+ "cost_beam_compression": 1.9183707237243652,
+ "cost_non_linearity": 891.2567749023438,
+ "cost_distance_total_intern_reflection": 17120.66796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_470.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_470.json
new file mode 100755
index 0000000..369d7b5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_470.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.309200286865234,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9076755.0,
+ "cost_distorsion": 16007.4443359375,
+ "cost_thickness": 4196.275390625,
+ "cost_beam_compression": 1.90773606300354,
+ "cost_non_linearity": 901.3726196289062,
+ "cost_distance_total_intern_reflection": 17241.396484375
+ },
+ "weighted components": {
+ "cost_dispersion": 166.1840057373047,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.76754760742188,
+ "cost_distorsion": 16007.4443359375,
+ "cost_thickness": 4196.275390625,
+ "cost_beam_compression": 1.90773606300354,
+ "cost_non_linearity": 901.3726196289062,
+ "cost_distance_total_intern_reflection": 17241.396484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_480.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_480.json
new file mode 100755
index 0000000..7989390
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_480.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 11.280070304870605,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9016933.0,
+ "cost_distorsion": 14159.7763671875,
+ "cost_thickness": 4176.55712890625,
+ "cost_beam_compression": 1.9130361080169678,
+ "cost_non_linearity": 890.345458984375,
+ "cost_distance_total_intern_reflection": 17122.37890625
+ },
+ "weighted components": {
+ "cost_dispersion": 225.60140991210938,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.16932678222656,
+ "cost_distorsion": 14159.7763671875,
+ "cost_thickness": 4176.55712890625,
+ "cost_beam_compression": 1.9130361080169678,
+ "cost_non_linearity": 890.345458984375,
+ "cost_distance_total_intern_reflection": 17122.37890625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_490.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_490.json
new file mode 100755
index 0000000..2b97e2d
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_490.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.0851169228553772,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9062709.0,
+ "cost_distorsion": 13856.5244140625,
+ "cost_thickness": 4191.6552734375,
+ "cost_beam_compression": 1.9180124998092651,
+ "cost_non_linearity": 896.6631469726562,
+ "cost_distance_total_intern_reflection": 17175.193359375
+ },
+ "weighted components": {
+ "cost_dispersion": 1.702338457107544,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.62709045410156,
+ "cost_distorsion": 13856.5244140625,
+ "cost_thickness": 4191.6552734375,
+ "cost_beam_compression": 1.9180124998092651,
+ "cost_non_linearity": 896.6631469726562,
+ "cost_distance_total_intern_reflection": 17175.193359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_50.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_50.json
new file mode 100755
index 0000000..c806551
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_50.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.7012540102005005,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9024906.0,
+ "cost_distorsion": 15096.1171875,
+ "cost_thickness": 4179.2158203125,
+ "cost_beam_compression": 1.9023281335830688,
+ "cost_non_linearity": 893.8118896484375,
+ "cost_distance_total_intern_reflection": 17180.65625
+ },
+ "weighted components": {
+ "cost_dispersion": 34.025081634521484,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.24905395507812,
+ "cost_distorsion": 15096.1171875,
+ "cost_thickness": 4179.2158203125,
+ "cost_beam_compression": 1.9023281335830688,
+ "cost_non_linearity": 893.8118896484375,
+ "cost_distance_total_intern_reflection": 17180.65625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_500.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_500.json
new file mode 100755
index 0000000..92b4024
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_500.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 8.489981651306152,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9084954.0,
+ "cost_distorsion": 15315.4072265625,
+ "cost_thickness": 4198.9794921875,
+ "cost_beam_compression": 1.9136261940002441,
+ "cost_non_linearity": 901.037109375,
+ "cost_distance_total_intern_reflection": 17229.634765625
+ },
+ "weighted components": {
+ "cost_dispersion": 169.7996368408203,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.84954071044922,
+ "cost_distorsion": 15315.4072265625,
+ "cost_thickness": 4198.9794921875,
+ "cost_beam_compression": 1.9136261940002441,
+ "cost_non_linearity": 901.037109375,
+ "cost_distance_total_intern_reflection": 17229.634765625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_510.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_510.json
new file mode 100755
index 0000000..773ef3b
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_510.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.011776700615882874,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041538.0,
+ "cost_distorsion": 15478.017578125,
+ "cost_thickness": 4184.69775390625,
+ "cost_beam_compression": 1.9035661220550537,
+ "cost_non_linearity": 896.3541259765625,
+ "cost_distance_total_intern_reflection": 17202.283203125
+ },
+ "weighted components": {
+ "cost_dispersion": 0.23553401231765747,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.41537475585938,
+ "cost_distorsion": 15478.017578125,
+ "cost_thickness": 4184.69775390625,
+ "cost_beam_compression": 1.9035661220550537,
+ "cost_non_linearity": 896.3541259765625,
+ "cost_distance_total_intern_reflection": 17202.283203125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_520.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_520.json
new file mode 100755
index 0000000..2f40841
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_520.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 45.556732177734375,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8995392.0,
+ "cost_distorsion": 16360.5361328125,
+ "cost_thickness": 4169.3154296875,
+ "cost_beam_compression": 1.92452073097229,
+ "cost_non_linearity": 884.2266845703125,
+ "cost_distance_total_intern_reflection": 17039.10546875
+ },
+ "weighted components": {
+ "cost_dispersion": 911.1346435546875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 89.95391845703125,
+ "cost_distorsion": 16360.5361328125,
+ "cost_thickness": 4169.3154296875,
+ "cost_beam_compression": 1.92452073097229,
+ "cost_non_linearity": 884.2266845703125,
+ "cost_distance_total_intern_reflection": 17039.10546875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_530.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_530.json
new file mode 100755
index 0000000..ac89190
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_530.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.004639685153961182,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9070956.0,
+ "cost_distorsion": 14647.1357421875,
+ "cost_thickness": 4194.3369140625,
+ "cost_beam_compression": 1.926068663597107,
+ "cost_non_linearity": 896.3033447265625,
+ "cost_distance_total_intern_reflection": 17154.419921875
+ },
+ "weighted components": {
+ "cost_dispersion": 0.09279370307922363,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.70955657958984,
+ "cost_distorsion": 14647.1357421875,
+ "cost_thickness": 4194.3369140625,
+ "cost_beam_compression": 1.926068663597107,
+ "cost_non_linearity": 896.3033447265625,
+ "cost_distance_total_intern_reflection": 17154.419921875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_540.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_540.json
new file mode 100755
index 0000000..823f78e
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_540.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 5.534727096557617,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9016311.0,
+ "cost_distorsion": 14456.734375,
+ "cost_thickness": 4176.37841796875,
+ "cost_beam_compression": 1.9044792652130127,
+ "cost_non_linearity": 891.9281005859375,
+ "cost_distance_total_intern_reflection": 17157.642578125
+ },
+ "weighted components": {
+ "cost_dispersion": 110.69454193115234,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.1631088256836,
+ "cost_distorsion": 14456.734375,
+ "cost_thickness": 4176.37841796875,
+ "cost_beam_compression": 1.9044792652130127,
+ "cost_non_linearity": 891.9281005859375,
+ "cost_distance_total_intern_reflection": 17157.642578125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_550.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_550.json
new file mode 100755
index 0000000..b8bac49
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_550.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.5007566213607788,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9052872.0,
+ "cost_distorsion": 15263.0576171875,
+ "cost_thickness": 4188.4306640625,
+ "cost_beam_compression": 1.9072484970092773,
+ "cost_non_linearity": 897.2939453125,
+ "cost_distance_total_intern_reflection": 17204.955078125
+ },
+ "weighted components": {
+ "cost_dispersion": 10.015132904052734,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.52871704101562,
+ "cost_distorsion": 15263.0576171875,
+ "cost_thickness": 4188.4306640625,
+ "cost_beam_compression": 1.9072484970092773,
+ "cost_non_linearity": 897.2939453125,
+ "cost_distance_total_intern_reflection": 17204.955078125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_560.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_560.json
new file mode 100755
index 0000000..22183e5
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_560.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 37.47003173828125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9015562.0,
+ "cost_distorsion": 17360.716796875,
+ "cost_thickness": 4175.8935546875,
+ "cost_beam_compression": 1.9347113370895386,
+ "cost_non_linearity": 885.5302734375,
+ "cost_distance_total_intern_reflection": 17028.708984375
+ },
+ "weighted components": {
+ "cost_dispersion": 749.400634765625,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.1556167602539,
+ "cost_distorsion": 17360.716796875,
+ "cost_thickness": 4175.8935546875,
+ "cost_beam_compression": 1.9347113370895386,
+ "cost_non_linearity": 885.5302734375,
+ "cost_distance_total_intern_reflection": 17028.708984375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_570.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_570.json
new file mode 100755
index 0000000..59da867
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_570.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 23.82278823852539,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9094829.0,
+ "cost_distorsion": 17092.1796875,
+ "cost_thickness": 4202.1923828125,
+ "cost_beam_compression": 1.9052726030349731,
+ "cost_non_linearity": 904.7328491210938,
+ "cost_distance_total_intern_reflection": 17281.021484375
+ },
+ "weighted components": {
+ "cost_dispersion": 476.45574951171875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.94828796386719,
+ "cost_distorsion": 17092.1796875,
+ "cost_thickness": 4202.1923828125,
+ "cost_beam_compression": 1.9052726030349731,
+ "cost_non_linearity": 904.7328491210938,
+ "cost_distance_total_intern_reflection": 17281.021484375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_580.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_580.json
new file mode 100755
index 0000000..ac233f8
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_580.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 34.89027786254883,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 8995717.0,
+ "cost_distorsion": 15385.2421875,
+ "cost_thickness": 4169.49072265625,
+ "cost_beam_compression": 1.9178909063339233,
+ "cost_non_linearity": 885.8670654296875,
+ "cost_distance_total_intern_reflection": 17067.591796875
+ },
+ "weighted components": {
+ "cost_dispersion": 697.8055419921875,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 89.95716857910156,
+ "cost_distorsion": 15385.2421875,
+ "cost_thickness": 4169.49072265625,
+ "cost_beam_compression": 1.9178909063339233,
+ "cost_non_linearity": 885.8670654296875,
+ "cost_distance_total_intern_reflection": 17067.591796875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_60.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_60.json
new file mode 100755
index 0000000..0d09527
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_60.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 1.416541576385498,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9052518.0,
+ "cost_distorsion": 14602.8486328125,
+ "cost_thickness": 4188.2734375,
+ "cost_beam_compression": 1.9225144386291504,
+ "cost_non_linearity": 894.0025024414062,
+ "cost_distance_total_intern_reflection": 17139.728515625
+ },
+ "weighted components": {
+ "cost_dispersion": 28.33083152770996,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.52517700195312,
+ "cost_distorsion": 14602.8486328125,
+ "cost_thickness": 4188.2734375,
+ "cost_beam_compression": 1.9225144386291504,
+ "cost_non_linearity": 894.0025024414062,
+ "cost_distance_total_intern_reflection": 17139.728515625
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_70.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_70.json
new file mode 100755
index 0000000..533d6c1
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_70.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.6563926935195923,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9048709.0,
+ "cost_distorsion": 13849.0830078125,
+ "cost_thickness": 4187.044921875,
+ "cost_beam_compression": 1.9164419174194336,
+ "cost_non_linearity": 894.7589721679688,
+ "cost_distance_total_intern_reflection": 17159.26953125
+ },
+ "weighted components": {
+ "cost_dispersion": 13.127853393554688,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.48709106445312,
+ "cost_distorsion": 13849.0830078125,
+ "cost_thickness": 4187.044921875,
+ "cost_beam_compression": 1.9164419174194336,
+ "cost_non_linearity": 894.7589721679688,
+ "cost_distance_total_intern_reflection": 17159.26953125
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_80.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_80.json
new file mode 100755
index 0000000..fbbf633
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_80.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 7.602163791656494,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9029871.0,
+ "cost_distorsion": 14541.8427734375,
+ "cost_thickness": 4180.8115234375,
+ "cost_beam_compression": 1.9180750846862793,
+ "cost_non_linearity": 891.2103271484375,
+ "cost_distance_total_intern_reflection": 17121.96875
+ },
+ "weighted components": {
+ "cost_dispersion": 152.04327392578125,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.2987060546875,
+ "cost_distorsion": 14541.8427734375,
+ "cost_thickness": 4180.8115234375,
+ "cost_beam_compression": 1.9180750846862793,
+ "cost_non_linearity": 891.2103271484375,
+ "cost_distance_total_intern_reflection": 17121.96875
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/optimization_results/step2/score_details_iteration_90.json b/outputs/single_prism/optimization_results/step2/score_details_iteration_90.json
new file mode 100755
index 0000000..5e3f279
--- /dev/null
+++ b/outputs/single_prism/optimization_results/step2/score_details_iteration_90.json
@@ -0,0 +1,32 @@
+{
+ "components non weights": {
+ "cost_dispersion": 20.0,
+ "cost_distance_glasses": 1.0,
+ "cost_deviation": 1e-05,
+ "cost_distorsion": 1.0,
+ "cost_thickness": 1.0,
+ "cost_beam_compression": 1.0,
+ "cost_non_linearity": 1.0,
+ "cost_distance_total_intern_reflection": 1.0
+ },
+ "components with weights": {
+ "cost_dispersion": 0.8665900826454163,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 9041868.0,
+ "cost_distorsion": 14072.1455078125,
+ "cost_thickness": 4184.80224609375,
+ "cost_beam_compression": 1.9123202562332153,
+ "cost_non_linearity": 894.4546508789062,
+ "cost_distance_total_intern_reflection": 17165.693359375
+ },
+ "weighted components": {
+ "cost_dispersion": 17.331802368164062,
+ "cost_distance_glasses": 0.0,
+ "cost_deviation": 90.4186782836914,
+ "cost_distorsion": 14072.1455078125,
+ "cost_thickness": 4184.80224609375,
+ "cost_beam_compression": 1.9123202562332153,
+ "cost_non_linearity": 894.4546508789062,
+ "cost_distance_total_intern_reflection": 17165.693359375
+ }
+}
\ No newline at end of file
diff --git a/outputs/single_prism/temp.yml b/outputs/single_prism/temp.yml
new file mode 100755
index 0000000..88e8b83
--- /dev/null
+++ b/outputs/single_prism/temp.yml
@@ -0,0 +1,28 @@
+coded aperture:
+ number of pixels along X: 25
+ number of pixels along Y: 25
+ pixel size along X: 210
+ pixel size along Y: 210
+detector:
+ number of pixels along X: 112
+ number of pixels along Y: 112
+ pixel size along X: 71
+ pixel size along Y: 71
+infos:
+ system name: HYACAMEO
+spectral range:
+ number of spectral samples: 10
+ wavelength max: 650
+ wavelength min: 450
+system architecture:
+ dispersive element:
+ A1: 50.294261877928975
+ alpha_c: 41.57785791200926
+ catalog: Schott
+ delta alpha c: 0
+ delta beta c: 0
+ glass1: N-PSK3
+ type: prism
+ wavelength center: 520.0
+ focal lens: 75000
+ system type: DD-CASSI
diff --git a/playing_with_TF.py b/playing_with_TF.py
deleted file mode 100755
index b873dd9..0000000
--- a/playing_with_TF.py
+++ /dev/null
@@ -1,34 +0,0 @@
-import matplotlib.pyplot as plt
-
-from simca.functions_general_purpose import load_yaml_config
-from simca.CassiSystemOptim import CassiSystemOptim
-import torch
-
-config = "simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml"
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-
-config_system = load_yaml_config(config)
-cassi_system = CassiSystemOptim(system_config=config_system)
-cassi_system.propagate_coded_aperture_grid()
-
-pattern = cassi_system.generate_2D_pattern(config_patterns,nb_of_patterns=1)
-
-
-# Compute the 2D FFT of the tensor
-fft_result = torch.fft.fft2(pattern)
-
-# Calculate the Power Spectrum
-power_spectrum = torch.abs(fft_result)**2
-
-# Calculate the Geometric Mean of the power spectrum
-# Use torch.log and torch.exp for differentiability, adding a small epsilon to avoid log(0)
-epsilon = 1e-10
-geometric_mean = torch.exp(torch.mean(torch.log(power_spectrum + epsilon)))
-
-# Calculate the Arithmetic Mean of the power spectrum
-arithmetic_mean = torch.mean(power_spectrum)
-
-# Compute the Spectral Flatness
-spectral_flatness = geometric_mean / arithmetic_mean
-
-print("spectral_flatness: ", spectral_flatness)
\ No newline at end of file
diff --git a/requirements.txt b/requirements.txt
index 612ed2d..fe19143 100755
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,6 +1,4 @@
h5py
-pyqt5
-pyqtgraph
pyyaml
scipy
seaborn
@@ -12,6 +10,6 @@ matplotlib
opticalglass
pyyaml
snoop
-#torch
-#torch-geometric
-#torch-cluster
\ No newline at end of file
+torch
+torch-geometric
+torch-cluster
diff --git a/simca/CassiSystem.py b/simca/CassiSystem.py
old mode 100644
new mode 100755
index f88b4ce..e0a30fe
--- a/simca/CassiSystem.py
+++ b/simca/CassiSystem.py
@@ -1,656 +1,49 @@
from simca.OpticalModel import OpticalModel
-from simca.functions_acquisition import *
-from simca.functions_patterns_generation import *
-from simca.functions_scenes import *
-from simca.functions_general_purpose import *
-from scipy.signal import convolve
+from simca.helper import *
+import pytorch_lightning as pl
-class CassiSystem():
- """Class that contains the cassi system main attributes and methods"""
-
- def __init__(self, system_config=None, system_config_path=None):
-
- """
-
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
-
- """
-
- self.set_up_system(system_config=system_config, system_config_path=system_config_path)
- def update_config(self, system_config_path=None, system_config=None):
+class CassiSystem(pl.LightningModule):
- """
- Update the system configuration file and re-initialize the grids for the coded aperture and the detector
+ """Class that contains the cassi system main attributes and methods"""
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
- Returns:
- dict: updated system configuration
+ def __init__(self, system_config=None,index_estimation_method="cauchy",device="cuda"):
- """
+ # Initialize LightningModule
+ pl.LightningModule.__init__(self)
+ self.to(device)
- self.set_up_system(system_config_path=system_config_path, system_config=system_config)
+ self.system_config = system_config
- return self.system_config
+ self.X_coded_aper_coordinates, self.Y_coded_aper_coordinates = self.generate_grid_coordinates(grid_name="coded aperture")
+ self.X_detector_coordinates_grid, self.Y_detector_coordinates_grid = self.generate_grid_coordinates(grid_name="detector")
+
+ self.wavelengths, self.nb_of_spectral_samples = self.generate_wavelengths()
- def set_up_system(self, system_config_path=None, system_config=None):
+ self.optical_model = OpticalModel(self.system_config,index_estimation_method=index_estimation_method,device=self.device)
- """
- Loading system config & initializing the grids coordinates for the coded aperture and the detector
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
- """
+ def generate_grid_coordinates(self, grid_name):
+
+ X_coordinates, Y_coordinates = self.create_coordinates_grid(
+ self.system_config[f"{grid_name}"]["number of pixels along X"],
+ self.system_config[f"{grid_name}"]["number of pixels along Y"],
+ self.system_config[f"{grid_name}"]["pixel size along X"],
+ self.system_config[f"{grid_name}"]["pixel size along Y"])
- if system_config_path is not None:
- self.system_config = load_yaml_config(system_config_path)
- elif system_config is not None:
- self.system_config = system_config
- self.optical_model = OpticalModel(self.system_config)
- self.X_coded_aper_coordinates, self.Y_coded_aper_coordinates = self.create_coordinates_grid(
- self.system_config["coded aperture"]["number of pixels along X"],
- self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["pixel size along X"],
- self.system_config["coded aperture"]["pixel size along Y"])
-
- self.X_detector_coordinates_grid, self.Y_detector_coordinates_grid = self.create_coordinates_grid(
- self.system_config["detector"]["number of pixels along X"],
- self.system_config["detector"]["number of pixels along Y"],
- self.system_config["detector"]["pixel size along X"],
- self.system_config["detector"]["pixel size along Y"])
+ return X_coordinates, Y_coordinates
+
+ def generate_wavelengths(self):
+ wavelengths = torch.linspace(self.system_config["spectral range"]["wavelength min"],
+ self.system_config["spectral range"]["wavelength max"],
+ self.system_config["spectral range"]["number of spectral samples"])
+ wavelengths = wavelengths.to(self.device)
+ nb_of_spectral_samples = wavelengths.shape[0]
- def set_wavelengths(self, wavelength_min, wavelength_max, nb_of_spectral_samples):
- """
- Set the wavelengths range of the optical system
-
- Args:
- wavelength_min (float): minimum wavelength of the system
- wavelength_max (float): maximum wavelength of the system
- nb_of_spectral_samples (int): number of spectral samples of the system
- Returns:
-
- """
- self.wavelength_min = wavelength_min
- self.wavelength_max = wavelength_max
- self.nb_of_spectral_samples = nb_of_spectral_samples
-
- self.system_wavelengths = np.linspace(self.wavelength_min,self.wavelength_max,self.nb_of_spectral_samples)
-
- return self.system_wavelengths
-
- def load_dataset(self, directory, dataset_name):
- """
- Loading the dataset and related attributes
-
- Args:
- directory (str): name of the directory containing the dataset
- dataset_name (str): dataset name
-
- Returns:
- list: a list containing the dataset (shape= R_dts x C_dts x W_dts), the corresponding wavelengths (shape= W_dts), the labeled dataset, the label names and the ignored labels
- """
-
- dataset, wavelengths_vec, dataset_labels, label_names, ignored_labels = get_dataset(directory, dataset_name)
-
- self.dataset = dataset
-
- ### MODIFICATIONS TO TEST
- #self.dataset[20:50,:] /= 10
- #self.dataset[60:120, :] *= 10
- #################################
-
- self.dataset_labels = dataset_labels
- self.dataset_wavelengths = wavelengths_vec
-
- # additional attributes
- self.dataset_label_names = label_names
- self.dataset_ignored_labels = ignored_labels
- self.dataset_palette = palette_init(label_names)
-
-
- list_dataset_data = [self.dataset, self.dataset_labels, self.dataset_wavelengths, self.dataset_label_names,
- self.dataset_ignored_labels, self.dataset_palette]
-
- return list_dataset_data
-
- def interpolate_dataset_along_wavelengths(self, new_wavelengths_sampling, chunk_size):
- """
- Interpolate the dataset cube along the wavelength axis to match the system sampling
-
- Args:
- new_wavelengths_sampling (numpy.ndarray): new wavelengths on which to interpolate the dataset (shape = W)
- chunk_size (int): chunk size for the multiprocessing
-
- Returns:
- numpy.ndarray : interpolated dataset cube along the wavelength axis (shape = R_dts x C_dts x W)
-
- """
- try:
- self.dataset
- except :
- raise ValueError("The dataset must be loaded first")
-
- if self.dataset_wavelengths[0] <= new_wavelengths_sampling[0] and self.dataset_wavelengths[-1] >= new_wavelengths_sampling[-1]:
-
- self.dataset_interpolated = interpolate_data_along_wavelength(self.dataset,self.dataset_wavelengths,new_wavelengths_sampling, chunk_size)
- return self.dataset_interpolated
- else:
- raise ValueError("The new wavelengths sampling must be inside the dataset wavelengths range")
-
- def generate_2D_pattern(self, config_pattern, nb_of_patterns=1):
- """
- Generate multiple coded aperture 2D patterns based on the "pattern" configuration file
- and stack them to match the desired number of patterns.
-
- Args:
- config_pattern (dict): coded-aperture pattern configuration.
- nb_of_patterns (int): Number of patterns to generate.
-
- Returns:
- torch.Tensor: Stacked coded-aperture 2D patterns (shape = nb_of_patterns x H x L).
- """
-
- pattern_list = [] # List to hold individual patterns
-
- for _ in range(nb_of_patterns):
- pattern_type = config_pattern['pattern']['type']
-
- if pattern_type == "random":
- pattern = generate_random_pattern((self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]),
- config_pattern['pattern']['ROM'])
- elif pattern_type == "slit":
- pattern = generate_slit_pattern((self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]),
- config_pattern['pattern']['slit position'],
- config_pattern['pattern']['slit width'])
- elif pattern_type == "blue-noise type 1":
- pattern = generate_blue_noise_type_1_pattern((self.system_config["coded aperture"][
- "number of pixels along Y"],
- self.system_config["coded aperture"][
- "number of pixels along X"]))
- elif pattern_type == "blue-noise type 2":
- pattern = generate_blue_noise_type_2_pattern((self.system_config["coded aperture"][
- "number of pixels along Y"],
- self.system_config["coded aperture"][
- "number of pixels along X"]))
- elif pattern_type == "custom h5 pattern":
- pattern = load_custom_pattern((self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]),
- config_pattern['pattern']['file path'])
- else:
- raise ValueError("Pattern type is not supported, change it in the 'pattern.yml' config file")
-
- # Assume pattern is a numpy array; convert to tensor
- pattern_tensor = torch.from_numpy(pattern)
- pattern_list.append(pattern_tensor)
-
- # Stack all generated pattern tensors along a new dimension
- stacked_patterns = torch.stack(pattern_list) # Shape: (nb_of_patterns, y, x)
-
- self.pattern = stacked_patterns
- return stacked_patterns
-
- def generate_multiple_patterns(self, config_pattern, number_of_patterns):
- """
- Generate a list of coded aperture patterns based on the "pattern" configuration file
-
- Args:
- config_pattern (dict): pattern configuration
- number_of_patterns (int): number of patterns to generate
-
- Returns:
- list: coded aperture patterns (numpy.ndarray) generated according to the configuration file
- """
- list_of_patterns = list()
- pattern_type = config_pattern['pattern']['type']
-
- if pattern_type == "random":
- for i in range(number_of_patterns):
- pattern= generate_random_pattern((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"]),config_pattern['pattern']['ROM'])
- list_of_patterns.append(pattern)
-
- elif pattern_type == "slit":
- # mmmmh you are weird, why would you want to do that ?
- for i in range(number_of_patterns):
- pattern= generate_slit_pattern((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"]),
- config_pattern['pattern']['slit position'],
- config_pattern['pattern']['slit width'])
- list_of_patterns.append(pattern)
-
- elif pattern_type == "LN-random":
- list_of_patterns = generate_ln_orthogonal_pattern(size=(self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]),
- W=self.system_config["spectral range"]["number of spectral samples"],
- N=number_of_patterns)
-
- elif pattern_type == "blue-noise type 1":
-
- for i in range(number_of_patterns):
- pattern= generate_blue_noise_type_1_pattern((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"]))
- list_of_patterns.append(pattern)
-
- elif pattern_type == "blue-noise type 2":
-
- for i in range(number_of_patterns):
- pattern= generate_blue_noise_type_2_pattern((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"]))
- list_of_patterns.append(pattern)
-
- elif pattern_type == "custom h5":
- list_of_patterns = load_custom_pattern((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"]),
- config_pattern['pattern']['file path'])
-
- else:
- print("pattern type is not supported")
- list_of_patterns = None
-
- self.list_of_patterns = list_of_patterns
-
- return self.list_of_patterns
-
-
-
- def generate_filtering_cube(self):
- """
- Generate filtering cube : each slice of the cube is a propagated pattern interpolated on the detector grid
-
- Returns:
- numpy.ndarray: filtering cube generated according to the optical system & the pattern configuration (R x C x W)
-
- """
-
- self.filtering_cube = interpolate_data_on_grid_positions(data=self.pattern,
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
+ return wavelengths, nb_of_spectral_samples
- def generate_filtering_cube_torch(self):
- """
- Generate filtering cube : each slice of the cube is a propagated pattern interpolated on the detector grid
-
- Returns:
- numpy.ndarray: filtering cube generated according to the optical system & the pattern configuration (R x C x W)
-
- """
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.pattern,
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
-
- return self.filtering_cube
-
- def generate_multiple_filtering_cubes(self, number_of_patterns):
- """
- Generate multiple filtering cubes, each cube corresponds to a pattern, and for each pattern, each slice is a propagated coded apertureinterpolated on the detector grid
-
- Args:
- number_of_patterns (int): number of patterns to generate
- Returns:
- list: filtering cubes generated according to the current optical system and the pattern configuration
-
- """
- self.list_of_filtering_cubes = []
-
- for idx in range(number_of_patterns):
-
- self.filtering_cube = interpolate_data_on_grid_positions(data=self.list_of_patterns[idx],
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
- self.list_of_filtering_cubes.append(self.filtering_cube)
-
- return self.list_of_filtering_cubes
-
- def generate_multiple_filtering_cubes_torch(self, number_of_patterns):
- """
- Generate multiple filtering cubes, each cube corresponds to a pattern, and for each pattern, each slice is a propagated coded apertureinterpolated on the detector grid
-
- Args:
- number_of_patterns (int): number of patterns to generate
- Returns:
- list: filtering cubes generated according to the current optical system and the pattern configuration
-
- """
- self.list_of_filtering_cubes = []
-
- for idx in range(number_of_patterns):
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.list_of_patterns[idx],
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
- self.list_of_filtering_cubes.append(self.filtering_cube)
-
- return self.list_of_filtering_cubes
-
- def image_acquisition(self, use_psf=False, chunck_size=50):
- """
- Run the acquisition/measurement process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the interpolation
-
- Returns:
- numpy.ndarray: compressed measurement (R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths(self.optical_model.system_wavelengths, chunck_size)
-
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
-
- try:
- self.filtering_cube
- except:
- return print("Please generate filtering cube first")
-
- scene = match_dataset_to_instrument(dataset, self.filtering_cube)
-
- measurement_in_3D = generate_dd_measurement(scene, self.filtering_cube, chunck_size)
-
- self.last_filtered_interpolated_scene = measurement_in_3D
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube)
- self.scene_labels = scene_labels
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
- scene = match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop)
-
- pattern_crop = crop_center(self.pattern, scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * np.tile(pattern_crop[..., np.newaxis], (1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop)
-
- sd_measurement = interpolate_data_on_grid_positions(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.last_filtered_interpolated_scene = sd_measurement
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = match_dataset_labels_to_instrument(dataset_labels, self.last_filtered_interpolated_scene)
- self.scene_labels = scene_labels
-
- self.panchro = np.sum(self.interpolated_scene, axis=2)
-
- if use_psf:
- self.apply_psf()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.measurement = np.sum(self.last_filtered_interpolated_scene, axis=2)
-
-
- return self.measurement
-
- def image_acquisition_torch(self, use_psf=False, chunck_size=50):
- """
- Run the acquisition/measurement process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the interpolation
-
- Returns:
- numpy.ndarray: compressed measurement (R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(self.optical_model.system_wavelengths, chunck_size)
-
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
-
- try:
- self.filtering_cube
- except:
- return print("Please generate filtering cube first")
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.filtering_cube))
-
- measurement_in_3D = generate_dd_measurement_torch(scene, self.filtering_cube, chunck_size)
-
- self.last_filtered_interpolated_scene = measurement_in_3D
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop))
-
- pattern_crop = crop_center(self.pattern, scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * pattern_crop[..., None].repeat((1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop, use_torch = True)
-
- sd_measurement = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.last_filtered_interpolated_scene = sd_measurement
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.last_filtered_interpolated_scene))
- self.scene_labels = scene_labels
-
- self.panchro = torch.sum(self.interpolated_scene, dim=2)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.measurement = torch.sum(self.last_filtered_interpolated_scene, dim=2)
-
-
- return self.measurement
-
- def multiple_image_acquisitions(self, use_psf=False, nb_of_filtering_cubes=1,chunck_size=50):
- """
- Run the acquisition process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the dataset
-
- Returns:
- list: list of compressed measurements (list of numpy.ndarray of size R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths(self.optical_model.system_wavelengths, chunck_size)
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- self.list_of_filtered_scenes = []
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
- try:
- self.list_of_filtering_cubes
- except:
- return print("Please generate list of filtering cubes first")
-
- scene = match_dataset_to_instrument(dataset, self.list_of_filtering_cubes[0])
-
- if dataset_labels is not None:
- scene_labels = match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube)
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- filtered_scene = generate_dd_measurement(scene, self.list_of_filtering_cubes[i], chunck_size)
- self.list_of_filtered_scenes.append(filtered_scene)
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
-
- scene = match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop)
-
- if dataset_labels is not None:
- scene_labels = match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube)
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- mask_crop = crop_center(self.list_of_patterns[i], scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * np.tile(mask_crop[..., np.newaxis], (1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop)
-
- sd_measurement_cube = interpolate_data_on_grid_positions(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
- self.list_of_filtered_scenes.append(sd_measurement_cube)
-
- self.panchro = np.sum(self.interpolated_scene, axis=2)
-
- if use_psf:
- self.apply_psf()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.list_of_measurements = []
- for i in range(nb_of_filtering_cubes):
- self.list_of_measurements.append(np.sum(self.list_of_filtered_scenes[i], axis=2))
-
- return self.list_of_measurements
-
- def multiple_image_acquisitions_torch(self, use_psf=False, nb_of_filtering_cubes=1,chunck_size=50):
- """
- Run the acquisition process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the dataset
-
- Returns:
- list: list of compressed measurements (list of numpy.ndarray of size R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(self.optical_model.system_wavelengths, chunck_size)
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- self.list_of_filtered_scenes = []
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
- try:
- self.list_of_filtering_cubes
- except:
- return print("Please generate list of filtering cubes first")
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.list_of_filtering_cubes[0]))
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- filtered_scene = generate_dd_measurement_torch(scene, self.list_of_filtering_cubes[i], chunck_size)
- self.list_of_filtered_scenes.append(filtered_scene)
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop))
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- mask_crop = crop_center(self.list_of_patterns[i], scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * mask_crop[..., None].repeat((1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop, use_torch = True)
-
- sd_measurement_cube = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
- self.list_of_filtered_scenes.append(sd_measurement_cube)
-
- self.panchro = torch.sum(self.interpolated_scene, dim=2)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.list_of_measurements = []
- for i in range(nb_of_filtering_cubes):
- self.list_of_measurements.append(torch.sum(self.list_of_filtered_scenes[i], dim=2))
-
- return self.list_of_measurements
-
-
def create_coordinates_grid(self, nb_of_pixels_along_x, nb_of_pixels_along_y, delta_x, delta_y):
"""
@@ -672,125 +65,94 @@ def create_coordinates_grid(self, nb_of_pixels_along_x, nb_of_pixels_along_y, de
# Create a two-dimensional grid of coordinates
X_input_grid, Y_input_grid = np.meshgrid(x, y)
- return X_input_grid, Y_input_grid
+ return torch.from_numpy(X_input_grid).float().to(self.device), torch.from_numpy(Y_input_grid).float().to(self.device)
+
- def propagate_coded_aperture_grid(self, X_input_grid=None, Y_input_grid=None,use_torch=False):
+
+ def update_optical_model(self, system_config=None):
"""
- Propagate the coded_aperture pattern through one CASSI system
+ Update the optical model of the system
Args:
- X_input_grid (numpy.ndarray): x coordinates grid
- Y_input_grid (numpy.ndarray): y coordinates grid
+ system_config (dict): configuration of the system
Returns:
- tuple: propagated coded aperture x coordinates grid in the detector plane (3D numpy.ndarray), propagated coded aperture y coordinates grid in the detector plane (3D numpy.ndarray), 1D array of propagated coded aperture x coordinates (numpy.ndarray), 1D array of system wavelengths (numpy.ndarray)
+ None
"""
+ if system_config is not None:
+ self.system_config = system_config
+ self.optical_model = OpticalModel(self.system_config)
- if X_input_grid is None:
- X_input_grid = self.X_coded_aper_coordinates
- if Y_input_grid is None:
- Y_input_grid = self.Y_coded_aper_coordinates
-
- propagation_type = self.system_config["system architecture"]["propagation type"]
+ def propagate_coded_aperture_grid(self):
+
+ # if self.device == "cuda":
+ # wavelengths = self.wavelengths.cpu()
+ # else:
+ # wavelengths = self.wavelengths
+ if self.optical_model.index_estimation_method == "cauchy":
+ n1 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd1,self.optical_model.vd1)
+ n2 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd2,self.optical_model.vd2)
+ n3 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd3,self.optical_model.vd3)
+ if self.optical_model.index_estimation_method == "sellmeier":
+ n1 = self.optical_model.sellmeier(self.wavelengths,self.optical_model.glass1).clone().detach().requires_grad_(True).to(device=self.device)
+ try:
+ n2 = self.optical_model.sellmeier(self.wavelengths,self.optical_model.glass2).clone().detach().requires_grad_(True).to(device=self.device)
+ except:
+ n2 = torch.tensor(1,device=self.device).expand_as(self.wavelengths)
+ try:
+ n3 = self.optical_model.sellmeier(self.wavelengths,self.optical_model.glass3).clone().detach().requires_grad_(True).to(device=self.device)
+ except:
+ n3 = torch.tensor(1,device=self.device).expand_as(self.wavelengths)
- if propagation_type == "simca" and use_torch == False:
- self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagation_with_distorsions(X_input_grid, Y_input_grid)
- if propagation_type == "simca" and use_torch == True:
- self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagation_with_distorsions_torch(X_input_grid, Y_input_grid)
+ n1 = n1.to(self.device)
+ n2 = n2.to(self.device)
+ n3 = n3.to(self.device)
- if propagation_type == "higher-order":
- self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagation_with_no_distorsions(X_input_grid, Y_input_grid)
- self.optical_model.check_if_sampling_is_sufficiant()
+ X_input_grid = torch.from_numpy(self.X_coded_aper_coordinates) if isinstance(self.X_coded_aper_coordinates, np.ndarray) else self.X_coded_aper_coordinates
+ Y_input_grid = torch.from_numpy(self.Y_coded_aper_coordinates) if isinstance(self.Y_coded_aper_coordinates, np.ndarray) else self.Y_coded_aper_coordinates
+ wavelength_vec = torch.from_numpy(self.wavelengths) if isinstance(self.wavelengths, np.ndarray) else self.wavelengths
+ n1_vec = torch.from_numpy(n1) if isinstance(n1, np.ndarray) else n1
+ n2_vec = torch.from_numpy(n2) if isinstance(n2, np.ndarray) else n2
+ n3_vec = torch.from_numpy(n3) if isinstance(n3, np.ndarray) else n3
- if use_torch == False:
- self.X_coordinates_propagated_coded_aperture = np.nan_to_num(self.X_coordinates_propagated_coded_aperture)
- self.Y_coordinates_propagated_coded_aperture = np.nan_to_num(self.Y_coordinates_propagated_coded_aperture)
- else:
- self.X_coordinates_propagated_coded_aperture = torch.nan_to_num(self.X_coordinates_propagated_coded_aperture)
- self.Y_coordinates_propagated_coded_aperture = torch.nan_to_num(self.Y_coordinates_propagated_coded_aperture)
+ X_input_grid_3D = X_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
+ Y_input_grid_3D = Y_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
+ lba_3D = wavelength_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1).to(self.device)
+ n1_3D = n1_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+ n2_3D = n2_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+ n3_3D = n3_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+
- return self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture, self.optical_model.system_wavelengths
+ self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagate(X_input_grid_3D, Y_input_grid_3D, lba_3D, n1_3D, n2_3D, n3_3D)
+ return self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture
- def apply_psf(self):
- """
- Apply the PSF to the last measurement
+ def retropropagate_coded_aperture_grid(self):
- Returns:
- numpy.ndarray: last measurement cube convolved with by PSF (shape= R x C x W). Each slice of the 3D filtered scene is convolved with the PSF
- """
- if (self.optical_model.psf is not None) and (self.last_filtered_interpolated_scene is not None):
- # Expand the dimensions of the 2D matrix to match the 3D matrix
- psf_3D = np.expand_dims(self.optical_model.psf, axis=-1)
+ n1 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths ,self.optical_model.nd1,self.optical_model.vd1).to(self.device)
+ n2 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths ,self.optical_model.nd2,self.optical_model.vd2).to(self.device)
+ n3 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths ,self.optical_model.nd3,self.optical_model.vd3).to(self.device)
- # Perform the convolution using convolve
- result = convolve(self.last_filtered_interpolated_scene, psf_3D, mode='same')
- result_panchro = convolve(self.panchro, self.optical_model.psf, mode='same')
+ X_input_grid = torch.from_numpy(self.X_detector_coordinates_grid) if isinstance(self.X_detector_coordinates_grid, np.ndarray) else self.X_detector_coordinates_grid
+ Y_input_grid = torch.from_numpy(self.Y_detector_coordinates_grid) if isinstance(self.Y_detector_coordinates_grid, np.ndarray) else self.Y_detector_coordinates_grid
+ wavelength_vec = torch.from_numpy(self.wavelengths) if isinstance(self.wavelengths, np.ndarray) else self.wavelengths
+ n1_vec = torch.from_numpy(n1) if isinstance(n1, np.ndarray) else n1
+ n2_vec = torch.from_numpy(n2) if isinstance(n2, np.ndarray) else n2
+ n3_vec = torch.from_numpy(n3) if isinstance(n3, np.ndarray) else n3
- else:
- print("No PSF or last measurement to apply PSF")
- result = self.last_filtered_interpolated_scene
- result_panchro = self.panchro
+ X_input_grid_3D = X_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
+ Y_input_grid_3D = Y_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
+ lba_3D = wavelength_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1).to(self.device)
+ n1_3D = n1_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+ n2_3D = n2_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+ n3_3D = n3_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
+
- self.last_filtered_interpolated_scene = result
- self.panchro = result_panchro
+ self.retro_X_detect_coords, self.retro_Y_detect_coords = self.optical_model.repropagate(X_input_grid_3D, Y_input_grid_3D, lba_3D, n1_3D, n2_3D, n3_3D)
- return self.last_filtered_interpolated_scene
+ return self.retro_X_detect_coords, self.retro_Y_detect_coords
+
+
- def apply_psf_torch(self):
- """
- Apply the PSF to the last measurement
-
- Returns:
- numpy.ndarray: last measurement cube convolved with by PSF (shape= R x C x W). Each slice of the 3D filtered scene is convolved with the PSF
- """
- if (self.optical_model.psf is not None) and (self.last_filtered_interpolated_scene is not None):
- # Expand the dimensions of the 2D matrix to match the 3D matrix
- psf_3D = self.optical_model.psf[..., None]
-
- # Perform the convolution using convolve
- result = torch.nn.functional.conv3d(self.last_filtered_interpolated_scene[None, None, ...], torch.flip(psf_3D, (0,1,2))[None, None, ...], padding = tuple((np.array(psf_3D.shape)-1)//2)).squeeze(0,1)
- result_panchro = torch.nn.functional.conv2d(self.panchro[None, None, ...], torch.flip(self.optical_model.psf, (0,1))[None, None, ...], padding = tuple((np.array(self.optical_model.psf.shape)-1)//2)).squeeze(0,1)
-
- else:
- print("No PSF or last measurement to apply PSF")
- result = self.last_filtered_interpolated_scene
- result_panchro = self.panchro
-
- self.last_filtered_interpolated_scene = result
- self.panchro = result_panchro
-
- return self.last_filtered_interpolated_scene
-
-
-
- def save_acquisition(self, config_pattern, config_acquisition):
- """
- Save the all data related to an acquisition
-
- Args:
- config_pattern (dict): configuration dictionary related to pattern generation
- config_acquisition (dict): configuration dictionary related to acquisition parameters
-
- """
-
- self.result_directory = initialize_acquisitions_directory(config_acquisition)
-
- save_config_file("config_system",self.system_config,self.result_directory)
- save_config_file("config_pattern",config_pattern,self.result_directory)
- save_config_file("config_acquisition",config_acquisition,self.result_directory)
- save_data_in_hdf5("interpolated_scene",self.interpolated_scene, self.result_directory)
- try:
- save_data_in_hdf5("scene_labels",self.scene_labels,self.result_directory)
- except :
- pass
- save_data_in_hdf5("filtered_interpolated_scene",self.last_filtered_interpolated_scene, self.result_directory)
- save_data_in_hdf5("measurement",self.measurement,self.result_directory)
- save_data_in_hdf5("panchro",self.panchro,self.result_directory)
- save_data_in_hdf5("filtering_cube",self.filtering_cube,self.result_directory)
- save_data_in_hdf5("pattern",self.pattern,self.result_directory)
- save_data_in_hdf5("wavelengths",self.optical_model.system_wavelengths,self.result_directory)
-
- print("Acquisition saved in " + self.result_directory)
diff --git a/simca/CassiSystemOptim.py b/simca/CassiSystemOptim.py
deleted file mode 100755
index 2ec8f8d..0000000
--- a/simca/CassiSystemOptim.py
+++ /dev/null
@@ -1,483 +0,0 @@
-from simca.OpticalModelTorch import OpticalModelTorch
-from simca.functions_acquisition import *
-from simca.functions_patterns_generation import *
-from simca.functions_scenes import *
-from simca.functions_scenes_torch import *
-from simca.functions_general_purpose import *
-from simca.CassiSystem import CassiSystem
-from simca.functions_acquisition_torch import *
-import time
-
-
-class CassiSystemOptim(CassiSystem):
- """Class that contains the cassi system main attributes and methods"""
-
- def __init__(self, system_config=None):
-
- super().__init__(system_config=system_config)
-
- self.system_config = system_config
-
- self.X_coded_aper_coordinates, self.Y_coded_aper_coordinates = self.create_coordinates_grid(
- self.system_config["coded aperture"]["number of pixels along X"],
- self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["pixel size along X"],
- self.system_config["coded aperture"]["pixel size along Y"])
-
- self.X_detector_coordinates_grid, self.Y_detector_coordinates_grid = self.create_coordinates_grid(
- self.system_config["detector"]["number of pixels along X"],
- self.system_config["detector"]["number of pixels along Y"],
- self.system_config["detector"]["pixel size along X"],
- self.system_config["detector"]["pixel size along Y"])
-
-
- self.wavelengths = self.set_wavelengths(self.system_config["spectral range"]["wavelength min"],
- self.system_config["spectral range"]["wavelength max"],
- self.system_config["spectral range"]["number of spectral samples"])
- self.optical_model = OpticalModelTorch(self.system_config)
-
-
- self.empty_grid = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]))
- # self.array_x_positions = torch.rand(-1,1,self.system_config["coded aperture"]["number of pixels along X"])
- self.array_x_positions = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"]))+ 0.5
-
- def create_coordinates_grid(self, nb_of_pixels_along_x, nb_of_pixels_along_y, delta_x, delta_y):
- """
- Create a coordinates grid for a given number of samples along X and Y axis and a given pixel size
-
- Args:
- nb_of_pixels_along_x (int): number of samples along X axis
- nb_of_pixels_along_y (int): number of samples along Y axis
- delta_x (float): pixel size along X axis
- delta_y (float): pixel size along Y axis
-
- Returns:
- tuple: X coordinates grid (numpy.ndarray) and Y coordinates grid (numpy.ndarray)
- """
- x = np.arange(-(nb_of_pixels_along_x-1) * delta_x / 2, (nb_of_pixels_along_x+1) * delta_x / 2,delta_x)
- y = np.arange(-(nb_of_pixels_along_y-1) * delta_y / 2, (nb_of_pixels_along_y+1) * delta_y / 2, delta_y)
-
-
- # Create a two-dimensional grid of coordinates
- X_input_grid, Y_input_grid = np.meshgrid(x, y)
-
- return torch.from_numpy(X_input_grid).float(), torch.from_numpy(Y_input_grid).float()
-
- def set_wavelengths(self, wavelength_min, wavelength_max, nb_of_spectral_samples):
- """
- Set the wavelengths range of the optical system
-
- Args:
- wavelength_min (float): minimum wavelength of the system
- wavelength_max (float): maximum wavelength of the system
- nb_of_spectral_samples (int): number of spectral samples of the system
- Returns:
-
- """
- self.wavelength_min = wavelength_min
- self.wavelength_max = wavelength_max
- self.nb_of_spectral_samples = nb_of_spectral_samples
-
- self.system_wavelengths = torch.linspace(self.wavelength_min,self.wavelength_max,self.nb_of_spectral_samples)
-
- return self.system_wavelengths
-
- def update_optical_model(self, system_config=None):
- """
- Update the optical model of the system
-
- Args:
- system_config (dict): configuration of the system
-
- Returns:
- None
- """
-
- if system_config is not None:
- self.system_config = system_config
-
- self.optical_model = OpticalModelTorch(self.system_config)
-
- def propagate_coded_aperture_grid(self):
-
- if self.optical_model.continuous_glass_materials1 == True:
- n1 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd1,self.optical_model.vd1)
- else:
- n1 = self.optical_model.glass1.calc_rindex(self.wavelengths)
- if self.optical_model.continuous_glass_materials2 == True:
- n2 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd2,self.optical_model.vd2)
- else:
- n2 = self.optical_model.glass2.calc_rindex(self.wavelengths)
- if self.optical_model.continuous_glass_materials3 == True:
- n3 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths,self.optical_model.nd3,self.optical_model.vd3)
- else:
- n3 = self.optical_model.glass3.calc_rindex(self.wavelengths)
-
- # n1 = np.repeat(1.5, self.wavelengths.shape[0])
- # n2 = np.repeat(1.8, self.wavelengths.shape[0])
- # n3 = np.repeat(1.5, self.wavelengths.shape[0])
-
-
-
- X_input_grid = torch.from_numpy(self.X_coded_aper_coordinates) if isinstance(self.X_coded_aper_coordinates, np.ndarray) else self.X_coded_aper_coordinates
- Y_input_grid = torch.from_numpy(self.Y_coded_aper_coordinates) if isinstance(self.Y_coded_aper_coordinates, np.ndarray) else self.Y_coded_aper_coordinates
- wavelength_vec = torch.from_numpy(self.wavelengths) if isinstance(self.wavelengths, np.ndarray) else self.wavelengths
- n1_vec = torch.from_numpy(n1) if isinstance(n1, np.ndarray) else n1
- n2_vec = torch.from_numpy(n2) if isinstance(n2, np.ndarray) else n2
- n3_vec = torch.from_numpy(n3) if isinstance(n3, np.ndarray) else n3
-
- X_input_grid_3D = X_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples)
- Y_input_grid_3D = Y_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples)
- lba_3D = wavelength_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n1_3D = n1_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n2_3D = n2_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n3_3D = n3_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
-
- starting_time = time.time()
-
- self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagate(X_input_grid_3D, Y_input_grid_3D, lba_3D, n1_3D, n2_3D, n3_3D)
-
- return self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture
-
- def generate_filtering_cube(self):
- """
- Generate filtering cube : each slice of the cube is a propagated pattern interpolated on the detector grid
-
- Returns:
- numpy.ndarray: filtering cube generated according to the optical system & the pattern configuration (R x C x W)
-
- """
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.pattern,
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
- return self.filtering_cube
-
-
- def image_acquisition(self, hyperspectral_cube, wavelengths,use_psf=False, chunck_size=50):
- """
- Run the acquisition/measurement process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the interpolation
-
- Returns:
- numpy.ndarray: compressed measurement (R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(hyperspectral_cube, wavelengths,self.wavelengths, chunck_size)
-
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
-
- try:
- self.filtering_cube
- except:
- return print("Please generate filtering cube first")
-
- scene = match_dataset_to_instrument(dataset, self.filtering_cube)
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.filtering_cube)).to(self.device) if isinstance(scene, np.ndarray) else scene.to(self.device)
-
- measurement_in_3D = generate_dd_measurement_torch(scene, self.filtering_cube, chunck_size)
-
- self.last_filtered_interpolated_scene = measurement_in_3D
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop))
-
- pattern_crop = crop_center(self.pattern, scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * pattern_crop[..., None].repeat((1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop, use_torch = True)
-
- sd_measurement = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.last_filtered_interpolated_scene = sd_measurement
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.last_filtered_interpolated_scene))
- self.scene_labels = scene_labels
-
- self.panchro = torch.sum(self.interpolated_scene, dim=2)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.measurement = torch.sum(self.last_filtered_interpolated_scene, dim=2)
-
- return self.measurement
-
- def generate_custom_pattern_parameters_slit(self, position=0.5):
- # Position is a float: 0 means slit is on the left edge, 1 means the slit is on the right edge
- self.array_x_positions = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"]))+ position
- self.array_x_positions = self.array_x_positions.to(self.device)
- return self.array_x_positions
-
- def generate_custom_pattern_parameters_slit_width(self, nb_slits=1, nb_rows=1, start_width=1):
- # Situation where we have nb_slits per row, and nb_rows rows of slits
- # Values in self.array_x_positions correspond to the width of the slit
- # self.array_x_positions is of shape (self.system_config["coded aperture"]["number of pixels along Y"], nb_rows)
-
- self.array_x_positions = torch.zeros((nb_slits, nb_rows))+start_width # Every slit starts with the same width
- self.array_x_positions = self.array_x_positions.to(self.device)
- self.array_x_positions_normalized = torch.zeros((nb_slits, nb_rows))+start_width
- return self.array_x_positions
-
- def generate_custom_slit_pattern_width(self, start_pattern = "line", start_position = 0):
- nb_slits, nb_rows = self.array_x_positions.shape
- pos_slits = self.system_config["coded aperture"]["number of pixels along X"]//(nb_slits+1) # Equally spaced slits
- height_slits = self.system_config["coded aperture"]["number of pixels along Y"]//nb_rows # Same length slits
-
- self.pattern = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"])).to(self.device) # Pattern of correct size
- if start_pattern == "line":
- if start_position != 0:
- start_position = start_position - pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- for j in range(nb_slits):
- for i in range(nb_rows):
- top_pad = i*height_slits # Padding necessary above slit (j,i)
- if i == nb_rows-1:
- bottom_pad = 0 # Padding necessary below slit (j,i)
- # In that case, the last slit might be longer than the other ones in case size_X isn't divisible by nb_rows
- array_x_pos = torch.zeros((height_slits+self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows)) + start_position + (j+1)*pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- else:
- # Set the position of the slit (j,i)
- array_x_pos = torch.zeros((height_slits)) + start_position + (j+1)*pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- bottom_pad = (nb_rows - i-1)*height_slits + self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows # Padding necessary below slit (j,i)
- top_pad = i*height_slits
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32)
- # Expand dimensions for broadcasting
- expanded_x_positions = (array_x_pos.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)
- expanded_grid_positions = grid_positions.unsqueeze(0)
-
- # Apply Gaussian-like function
- sigma = (self.array_x_positions[j,i]+1)/2
- gaussian = torch.exp(-(((expanded_grid_positions - expanded_x_positions)) ** 2) / (2 * sigma ** 2))
-
- padded = torch.nn.functional.pad(gaussian, (0,0,top_pad,bottom_pad)) # padding: left - right - top - bottom
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern + padded/padded.max()
- elif start_pattern == "corrected":
- for j in range(nb_slits):
- for i in range(nb_rows):
- top_pad = i*height_slits # Padding necessary above slit (j,i)
- if i == nb_rows-1:
- bottom_pad = 0 # Padding necessary below slit (j,i)
- # In that case, the last slit might be longer than the other ones in case size_X isn't divisible by nb_rows
- else:
- # Set the position of the slit (j,i)
- bottom_pad = (nb_rows - i-1)*height_slits + self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows # Padding necessary below slit (j,i)
- top_pad = i*height_slits
- """ array_x_pos = torch.tensor(start_position[i])
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32)
- # Expand dimensions for broadcasting
- expanded_x_positions = (array_x_pos.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)
- expanded_grid_positions = grid_positions.unsqueeze(0)
-
- # Apply Gaussian-like function
- sigma = (self.array_x_positions[j,i]+1)/2
- gaussian = torch.exp(-(((expanded_grid_positions - expanded_x_positions)) ** 2) / (2 * sigma ** 2))
-
- padded = torch.nn.functional.pad(gaussian, (0,0,top_pad,bottom_pad)) # padding: left - right - top - bottom
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern + padded/padded.max() """
-
- c = start_position[i].clone().detach() # center of the slit
- #d = ((torch.tanh(1.1*self.array_x_positions[j,i])+1)/2)/2 # width of the slit at pos
- d = self.array_x_positions[j,i]/2 # width of the slit at pos
- m = (c-d)*(self.system_config["coded aperture"]["number of pixels along X"]-1) # left bound
- M = (c+d)*(self.system_config["coded aperture"]["number of pixels along X"]-1) # right bound
- rect = torch.arange(self.system_config["coded aperture"]["number of pixels along X"]).to(self.device)
- clamp_M = torch.clamp(M-rect, 0, 1)
-
- clamp_m = torch.clamp(rect-m, 0, 1)
- diff = 1-clamp_m
- reg = torch.where(diff < 1, diff, -1)
- clamp_m = torch.where(reg!=0, reg, 1)
- clamp_m = torch.where(clamp_m!=-1, clamp_m, 0)
- clamp_m = torch.roll(clamp_m, -1)
- clamp_m[-1]=1
-
- rect = clamp_M - clamp_m +1
- rect = torch.where(rect!=2, rect, 0)
- rect = torch.where(rect <= 1, rect, rect-1)
- #rect = torch.clamp(-(rect-m)*(rect-M)+1,0,1).to(self.device)
-
- gaussian_range = torch.arange(self.system_config["coded aperture"]["number of pixels along X"], dtype=torch.float32)
- center_pos = 0.5*(len(gaussian_range)-1)
- sigma = 1.5
- gaussian_peaks = torch.exp(-((center_pos - gaussian_range) ** 2) / (2 * sigma ** 2)).to(self.device)
- gaussian = gaussian_peaks /gaussian_peaks.max()
- res = torch.nn.functional.conv1d(rect.unsqueeze(0), gaussian.unsqueeze(0).unsqueeze(0), padding = (len(gaussian_range)-1)//2).squeeze().to(self.device)
-
- res = res/res.max()
- self.pattern[i, :] = self.pattern[i, :] + res
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern / self.pattern.max(dim=1).values.unsqueeze(-1)
-
- return self.pattern
-
- def generate_custom_slit_pattern(self):
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32).to(self.device)
- # Expand dimensions for broadcasting
- expanded_x_positions = ((self.array_x_positions.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)).to(self.device)
- expanded_grid_positions = grid_positions.unsqueeze(0).to(self.device)
-
- # Apply Gaussian-like function
- # Adjust 'sigma' to control the sharpness
- sigma = 1.5
- gaussian_peaks = torch.exp(-((expanded_grid_positions - expanded_x_positions) ** 2) / (2 * sigma ** 2)).to(self.device)
-
- # Normalize to make sure the maximum value is 1
- self.pattern = gaussian_peaks / gaussian_peaks.max()
- return self.pattern
-
-
-
- # def generate_custom_slit_pattern(self):
- # """
- # Generate a custom slit pattern
-
- # Args:
- # array_x_positions (numpy.ndarray): array of the x positions of the slits between -1 and 1
-
- # Returns:
- # numpy.ndarray: generated slit pattern
- # """
- # pattern = torch.clone(self.empty_grid)
- # self.array_x_positions += 1
- # self.array_x_positions *= self.empty_grid.shape[1] // 2
- # self.array_x_positions = self.array_x_positions.type(torch.int32)
- # for i in range(self.array_x_positions.shape[0]):
- # pattern[0, self.array_x_positions[i]] = 1
-
- # return self.pattern
-
- def interpolate_dataset_along_wavelengths_torch(self, hyperspectral_cube, wavelengths,new_wavelengths_sampling, chunk_size):
- """
- Interpolate the dataset cube along the wavelength axis to match the system sampling
-
- Args:
- new_wavelengths_sampling (numpy.ndarray): new wavelengths on which to interpolate the dataset (shape = W)
- chunk_size (int): chunk size for the multiprocessing
-
- Returns:
- numpy.ndarray : interpolated dataset cube along the wavelength axis (shape = R_dts x C_dts x W)
-
- """
- try:
- self.dataset
- except :
- self.dataset = hyperspectral_cube
- self.dataset_wavelengths = wavelengths
-
- #print(self.dataset.shape)
- #print(self.dataset_wavelengths.shape)
-
- self.dataset_wavelengths = torch.from_numpy(self.dataset_wavelengths) if isinstance(self.dataset_wavelengths, np.ndarray) else self.dataset_wavelengths
- new_wavelengths_sampling = torch.from_numpy(new_wavelengths_sampling).float() if isinstance(new_wavelengths_sampling, np.ndarray) else new_wavelengths_sampling
- self.dataset = torch.from_numpy(self.dataset).float() if isinstance(self.dataset, np.ndarray) else self.dataset
-
- self.dataset_interpolated = self.interpolate_data_along_wavelength_torch(self.dataset,self.dataset_wavelengths,new_wavelengths_sampling,chunk_size)
- return self.dataset_interpolated
-
- def interpolate_data_along_wavelength_torch(self,data, current_sampling, new_sampling, chunk_size=50):
- """Interpolate the input 3D data along a new sampling in the third axis.
-
- Args:
- data (numpy.ndarray): 3D data to interpolate
- current_sampling (numpy.ndarray): current sampling for the 3rd axis
- new_sampling (numpy.ndarray): new sampling for the 3rd axis
- chunk_size (int): size of the chunks to use for the interpolation
- """
-
- # Generate the coordinates for the original grid
- x = torch.arange(data.shape[0]).float()
- y = torch.arange(data.shape[1]).float()
- z = current_sampling
-
- # Initialize an empty array for the result
- interpolated_data = torch.empty((data.shape[0], data.shape[1], len(new_sampling)))
-
- # Perform the interpolation in chunks
- for i in range(0, data.shape[0], chunk_size):
- for j in range(0, data.shape[1], chunk_size):
- new_coordinates = torch.meshgrid(x[i:i + chunk_size], y[j:j + chunk_size], new_sampling, indexing='ij')
- new_grid = torch.stack(new_coordinates, axis=-1)
-
- min_bound = torch.tensor([torch.min(x[i:i + chunk_size]), torch.min(y[j:j + chunk_size]), torch.min(z)])
- max_bound = torch.tensor([torch.max(x[i:i + chunk_size]), torch.max(y[j:j + chunk_size]), torch.max(z)])
-
- new_grid = (2 * ((new_grid - min_bound) / (max_bound - min_bound)) - 1).unsqueeze(0).flip(
- -1).float() # Normalize between -1 and 1
-
- """new_coordinates = np.meshgrid(x[i:i+chunk_size], y[j:j+chunk_size], new_sampling, indexing='ij')
- new_grid = np.stack(new_coordinates, axis=-1)
-
- new_grid = torch.from_numpy(2*((new_grid-min_bound)/(max_bound - min_bound))-1).unsqueeze(0).flip(-1).double()"""
- interpolated_data[i:i + chunk_size, j:j + chunk_size, :] = torch.nn.functional.grid_sample(
- input=data[i:i + chunk_size, j:j + chunk_size, :][None, None, ...],
- grid=new_grid,
- padding_mode="zeros",
- mode="bilinear",
- align_corners=True).squeeze(0, 1)
-
- return interpolated_data
- def apply_psf(self):
- """
- Apply the PSF to the last measurement
-
- Returns:
- numpy.ndarray: last measurement cube convolved with by PSF (shape= R x C x W). Each slice of the 3D filtered scene is convolved with the PSF
- """
- if (self.optical_model.psf is not None) and (self.last_filtered_interpolated_scene is not None):
- # Expand the dimensions of the 2D matrix to match the 3D matrix
- psf_3D = self.optical_model.psf[..., None]
-
- # Perform the convolution using convolve
- result = torch.nn.functional.conv3d(self.last_filtered_interpolated_scene[None, None, ...], torch.flip(psf_3D, (0,1,2))[None, None, ...], padding = tuple((np.array(psf_3D.shape)-1)//2)).squeeze(0,1)
- result_panchro = torch.nn.functional.conv2d(self.panchro[None, None, ...], torch.flip(self.optical_model.psf, (0,1))[None, None, ...], padding = tuple((np.array(self.optical_model.psf.shape)-1)//2)).squeeze(0,1)
-
- else:
- print("No PSF or last measurement to apply PSF")
- result = self.last_filtered_interpolated_scene
- result_panchro = self.panchro
-
- self.last_filtered_interpolated_scene = result
- self.panchro = result_panchro
-
- return self.last_filtered_interpolated_scene
\ No newline at end of file
diff --git a/simca/CassiSystemTorch.py b/simca/CassiSystemTorch.py
deleted file mode 100644
index b85330e..0000000
--- a/simca/CassiSystemTorch.py
+++ /dev/null
@@ -1,288 +0,0 @@
-from simca.OpticalModel import OpticalModelTorch
-from simca.functions_acquisition import *
-from simca.functions_patterns_generation import *
-from simca.functions_scenes import *
-from simca.functions_general_purpose import *
-from CassiSystem import CassiSystem
-from functions_acquisition_torch import *
-
-class CassiSystemTorch(CassiSystem):
- """Class that contains the cassi system main attributes and methods"""
-
- def __init__(self, system_config=None, system_config_path=None):
-
- """
-
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
-
- """
- super().__init__(system_config=system_config, system_config_path=system_config_path)
- self.set_up_system(system_config_path=system_config_path, system_config=system_config)
-
- def set_up_system(self, system_config_path=None, system_config=None):
- """
- Loading system config & initializing the grids coordinates for the coded aperture and the detector
-
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
-
- """
-
- if system_config_path is not None:
- self.system_config = load_yaml_config(system_config_path)
- elif system_config is not None:
- self.system_config = system_config
-
- self.optical_model = OpticalModelTorch(self.system_config)
-
- self.X_coded_aper_coordinates, self.Y_coded_aper_coordinates = self.create_coordinates_grid(
- self.system_config["coded aperture"]["number of pixels along X"],
- self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["pixel size along X"],
- self.system_config["coded aperture"]["pixel size along Y"])
-
- self.X_detector_coordinates_grid, self.Y_detector_coordinates_grid = self.create_coordinates_grid(
- self.system_config["detector"]["number of pixels along X"],
- self.system_config["detector"]["number of pixels along Y"],
- self.system_config["detector"]["pixel size along X"],
- self.system_config["detector"]["pixel size along Y"])
-
- def update_config(self, system_config_path=None, system_config=None):
-
- """
- Update the system configuration file and re-initialize the grids for the coded aperture and the detector
-
- Args:
- system_config_path (str): path to the configs file
- system_config (dict): system configuration
- Returns:
- dict: updated system configuration
-
- """
-
- self.set_up_system(system_config_path=system_config_path, system_config=system_config)
-
- return self.system_config
-
- def generate_filtering_cube(self):
- """
- Generate filtering cube : each slice of the cube is a propagated pattern interpolated on the detector grid
-
- Returns:
- numpy.ndarray: filtering cube generated according to the optical system & the pattern configuration (R x C x W)
-
- """
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.pattern,
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
-
- return self.filtering_cube
-
- def generate_multiple_filtering_cubes(self, number_of_patterns):
- """
- Generate multiple filtering cubes, each cube corresponds to a pattern, and for each pattern, each slice is a propagated coded apertureinterpolated on the detector grid
-
- Args:
- number_of_patterns (int): number of patterns to generate
- Returns:
- list: filtering cubes generated according to the current optical system and the pattern configuration
-
- """
- self.list_of_filtering_cubes = []
-
- for idx in range(number_of_patterns):
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.list_of_patterns[idx],
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid)
-
- self.list_of_filtering_cubes.append(self.filtering_cube)
-
- return self.list_of_filtering_cubes
-
- def image_acquisition(self, use_psf=False, chunck_size=50):
- """
- Run the acquisition/measurement process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the interpolation
-
- Returns:
- numpy.ndarray: compressed measurement (R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(self.optical_model.system_wavelengths, chunck_size)
-
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
-
- try:
- self.filtering_cube
- except:
- return print("Please generate filtering cube first")
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.filtering_cube))
-
- measurement_in_3D = generate_dd_measurement_torch(scene, self.filtering_cube, chunck_size)
-
- self.last_filtered_interpolated_scene = measurement_in_3D
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop))
-
- pattern_crop = crop_center(self.pattern, scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * pattern_crop[..., None].repeat((1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop, use_torch = True)
-
- sd_measurement = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.last_filtered_interpolated_scene = sd_measurement
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.last_filtered_interpolated_scene))
- self.scene_labels = scene_labels
-
- self.panchro = torch.sum(self.interpolated_scene, dim=2)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.measurement = torch.sum(self.last_filtered_interpolated_scene, dim=2)
-
- return self.measurement
-
- def multiple_image_acquisitions(self, use_psf=False, nb_of_filtering_cubes=1,chunck_size=50):
- """
- Run the acquisition process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the dataset
-
- Returns:
- list: list of compressed measurements (list of numpy.ndarray of size R x C)
- """
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(self.optical_model.system_wavelengths, chunck_size)
- if dataset is None:
- return None
- dataset_labels = self.dataset_labels
-
- self.list_of_filtered_scenes = []
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
- try:
- self.list_of_filtering_cubes
- except:
- return print("Please generate list of filtering cubes first")
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.list_of_filtering_cubes[0]))
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- filtered_scene = generate_dd_measurement_torch(scene, self.list_of_filtering_cubes[i], chunck_size)
- self.list_of_filtered_scenes.append(filtered_scene)
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[0])
-
- scene = torch.from_numpy(match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop))
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
- self.interpolated_scene = scene
-
- for i in range(nb_of_filtering_cubes):
-
- mask_crop = crop_center(self.list_of_patterns[i], scene.shape[1], scene.shape[0])
-
- filtered_scene = scene * mask_crop[..., None].repeat((1, 1, scene.shape[2]))
-
- self.propagate_coded_aperture_grid(X_input_grid=X_coded_aper_coordinates_crop, Y_input_grid=Y_coded_aper_coordinates_crop, use_torch = True)
-
- sd_measurement_cube = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
- self.list_of_filtered_scenes.append(sd_measurement_cube)
-
- self.panchro = torch.sum(self.interpolated_scene, dim=2)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("No PSF was applied")
-
- # Calculate the other two arrays
- self.list_of_measurements = []
- for i in range(nb_of_filtering_cubes):
- self.list_of_measurements.append(torch.sum(self.list_of_filtered_scenes[i], dim=2))
-
- return self.list_of_measurements
-
- def apply_psf(self):
- """
- Apply the PSF to the last measurement
-
- Returns:
- numpy.ndarray: last measurement cube convolved with by PSF (shape= R x C x W). Each slice of the 3D filtered scene is convolved with the PSF
- """
- if (self.optical_model.psf is not None) and (self.last_filtered_interpolated_scene is not None):
- # Expand the dimensions of the 2D matrix to match the 3D matrix
- psf_3D = self.optical_model.psf[..., None]
-
- # Perform the convolution using convolve
- result = torch.nn.functional.conv3d(self.last_filtered_interpolated_scene[None, None, ...], torch.flip(psf_3D, (0,1,2))[None, None, ...], padding = tuple((np.array(psf_3D.shape)-1)//2)).squeeze(0,1)
- result_panchro = torch.nn.functional.conv2d(self.panchro[None, None, ...], torch.flip(self.optical_model.psf, (0,1))[None, None, ...], padding = tuple((np.array(self.optical_model.psf.shape)-1)//2)).squeeze(0,1)
-
- else:
- print("No PSF or last measurement to apply PSF")
- result = self.last_filtered_interpolated_scene
- result_panchro = self.panchro
-
- self.last_filtered_interpolated_scene = result
- self.panchro = result_panchro
-
- return self.last_filtered_interpolated_scene
\ No newline at end of file
diff --git a/simca/CassiSystem_lightning.py b/simca/CassiSystem_lightning.py
deleted file mode 100755
index ff1e1ce..0000000
--- a/simca/CassiSystem_lightning.py
+++ /dev/null
@@ -1,598 +0,0 @@
-from simca.OpticalModelTorch import OpticalModelTorch
-from simca.functions_acquisition import *
-from simca.functions_patterns_generation import *
-from simca.functions_scenes import *
-from simca.functions_scenes_torch import *
-from simca.functions_general_purpose import *
-from simca.CassiSystem import CassiSystem
-from simca.functions_acquisition_torch import *
-import pytorch_lightning as pl
-import time
-import torch.nn.functional as F
-import matplotlib.pyplot as plt
-
-
-class CassiSystemOptim(pl.LightningModule, CassiSystem):
- """Class that contains the cassi system main attributes and methods"""
-
- def __init__(self, system_config=None):
-
- # Initialize LightningModule
- pl.LightningModule.__init__(self)
- # Initialize CassiSystem with system_config
- CassiSystem.__init__(self, system_config=system_config)
-
- self.system_config = system_config
- self.X_coded_aper_coordinates, self.Y_coded_aper_coordinates = self.create_coordinates_grid(
- self.system_config["coded aperture"]["number of pixels along X"],
- self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["pixel size along X"],
- self.system_config["coded aperture"]["pixel size along Y"])
-
- self.X_detector_coordinates_grid, self.Y_detector_coordinates_grid = self.create_coordinates_grid(
- self.system_config["detector"]["number of pixels along X"],
- self.system_config["detector"]["number of pixels along Y"],
- self.system_config["detector"]["pixel size along X"],
- self.system_config["detector"]["pixel size along Y"])
-
-
- self.wavelengths = self.set_wavelengths(self.system_config["spectral range"]["wavelength min"],
- self.system_config["spectral range"]["wavelength max"],
- self.system_config["spectral range"]["number of spectral samples"])
- self.optical_model = OpticalModelTorch(self.system_config)
-
-
- self.empty_grid = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"],
- self.system_config["coded aperture"]["number of pixels along X"]))
- # self.array_x_positions = torch.rand(-1,1,self.system_config["coded aperture"]["number of pixels along X"])
- self.array_x_positions = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"]))+ 0.5
-
- def create_coordinates_grid(self, nb_of_pixels_along_x, nb_of_pixels_along_y, delta_x, delta_y):
- """
- Create a coordinates grid for a given number of samples along X and Y axis and a given pixel size
-
- Args:
- nb_of_pixels_along_x (int): number of samples along X axis
- nb_of_pixels_along_y (int): number of samples along Y axis
- delta_x (float): pixel size along X axis
- delta_y (float): pixel size along Y axis
-
- Returns:
- tuple: X coordinates grid (numpy.ndarray) and Y coordinates grid (numpy.ndarray)
- """
- x = np.arange(-(nb_of_pixels_along_x-1) * delta_x / 2, (nb_of_pixels_along_x+1) * delta_x / 2,delta_x)
- y = np.arange(-(nb_of_pixels_along_y-1) * delta_y / 2, (nb_of_pixels_along_y+1) * delta_y / 2, delta_y)
-
-
- # Create a two-dimensional grid of coordinates
- X_input_grid, Y_input_grid = np.meshgrid(x, y)
-
- print( "My DEVICE IS: ", self.device)
- return torch.from_numpy(X_input_grid).float().to(self.device), torch.from_numpy(Y_input_grid).float().to(self.device)
-
- def set_wavelengths(self, wavelength_min, wavelength_max, nb_of_spectral_samples):
- """
- Set the wavelengths range of the optical system
-
- Args:
- wavelength_min (float): minimum wavelength of the system
- wavelength_max (float): maximum wavelength of the system
- nb_of_spectral_samples (int): number of spectral samples of the system
- Returns:
-
- """
- self.wavelength_min = wavelength_min
- self.wavelength_max = wavelength_max
- self.nb_of_spectral_samples = nb_of_spectral_samples
-
- self.system_wavelengths = torch.linspace(self.wavelength_min,self.wavelength_max,self.nb_of_spectral_samples)
-
- return self.system_wavelengths
-
- def update_optical_model(self, system_config=None):
- """
- Update the optical model of the system
-
- Args:
- system_config (dict): configuration of the system
-
- Returns:
- None
- """
-
- if system_config is not None:
- self.system_config = system_config
-
- self.optical_model = OpticalModelTorch(self.system_config)
-
- def propagate_coded_aperture_grid(self):
-
- if self.optical_model.continuous_glass_materials1 == True:
- n1 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths.cpu() ,self.optical_model.nd1,self.optical_model.vd1)
- else:
- n1 = self.optical_model.glass1.calc_rindex(self.wavelengths.cpu() )
- if self.optical_model.continuous_glass_materials2 == True:
- n2 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths.cpu() ,self.optical_model.nd2,self.optical_model.vd2)
- else:
- n2 = self.optical_model.glass2.calc_rindex(self.wavelengths.cpu() )
- if self.optical_model.continuous_glass_materials3 == True:
- n3 = self.optical_model.calculate_dispersion_with_cauchy(self.wavelengths.cpu() ,self.optical_model.nd3,self.optical_model.vd3)
- else:
- n3 = self.optical_model.glass3.calc_rindex(self.wavelengths.cpu() )
-
- n1 = n1.to(self.device)
- n2 = n2.to(self.device)
- n3 = n3.to(self.device)
-
- #print("New X coded aperture_coordinates: ", self.X_coded_aper_coordinates.shape)
- #print("New Y coded aperture_coordinates: ", self.Y_coded_aper_coordinates.shape)
-
- X_input_grid = torch.from_numpy(self.X_coded_aper_coordinates) if isinstance(self.X_coded_aper_coordinates, np.ndarray) else self.X_coded_aper_coordinates
- Y_input_grid = torch.from_numpy(self.Y_coded_aper_coordinates) if isinstance(self.Y_coded_aper_coordinates, np.ndarray) else self.Y_coded_aper_coordinates
- wavelength_vec = torch.from_numpy(self.wavelengths) if isinstance(self.wavelengths, np.ndarray) else self.wavelengths
- n1_vec = torch.from_numpy(n1) if isinstance(n1, np.ndarray) else n1
- n2_vec = torch.from_numpy(n2) if isinstance(n2, np.ndarray) else n2
- n3_vec = torch.from_numpy(n3) if isinstance(n3, np.ndarray) else n3
-
- X_input_grid_3D = X_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
- Y_input_grid_3D = Y_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples).to(self.device)
- lba_3D = wavelength_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n1_3D = n1_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n2_3D = n2_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n3_3D = n3_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
-
- starting_time = time.time()
- #print('Propagating the coded aperture grid...')
- #print(X_input_grid_3D.get_device())
- #print(Y_input_grid_3D.get_device())
- #print(lba_3D.get_device())
- #print(n1_3D.get_device())
- #print(n2_3D.get_device())
-
- self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture = self.optical_model.propagate(X_input_grid_3D, Y_input_grid_3D, lba_3D, n1_3D, n2_3D, n3_3D)
-
- return self.X_coordinates_propagated_coded_aperture, self.Y_coordinates_propagated_coded_aperture
-
- def generate_filtering_cube(self):
- """
- Generate filtering cube : each slice of the cube is a propagated pattern interpolated on the detector grid
-
- Returns:
- numpy.ndarray: filtering cube generated according to the optical system & the pattern configuration (R x C x W)
-
- """
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(data=self.pattern.unsqueeze(-1).repeat(1, 1, 1, self.wavelengths.shape[0]).to(self.device),
- X_init=self.X_coordinates_propagated_coded_aperture,
- Y_init=self.Y_coordinates_propagated_coded_aperture,
- X_target=self.X_detector_coordinates_grid,
- Y_target=self.Y_detector_coordinates_grid).to(self.device)
-
- return self.filtering_cube
-
- def get_displacement_in_pixels(self,dataset_wavelengths):
-
- central_coordinates_X = self.X_coordinates_propagated_coded_aperture[0,self.X_coordinates_propagated_coded_aperture.shape[1] // 2, self.X_coordinates_propagated_coded_aperture.shape[2] // 2, :]
- displacement_in_pix = [float(coord/self.system_config["detector"]["pixel size along X"]) for coord in list(central_coordinates_X)]
-
- current_wavelengths = self.wavelengths.cpu().numpy()
- # Interpolate displacement values onto dataset_wavelengths
- interpolated_displacement_in_pix = np.interp(dataset_wavelengths.cpu().numpy(), current_wavelengths, displacement_in_pix)
-
- return interpolated_displacement_in_pix
-
-
- def image_acquisition(self, hyperspectral_cube, pattern,wavelengths,use_psf=False, chunck_size=50):
- """
- Run the acquisition/measurement process depending on the cassi system type
-
- Args:
- chunck_size (int): default block size for the interpolation
-
- Returns:
- numpy.ndarray: compressed measurement (R x C)
- """
- self.wavelengths= self.wavelengths.to(self.device)
-
- dataset = self.interpolate_dataset_along_wavelengths_torch(hyperspectral_cube, wavelengths,self.wavelengths, chunck_size)
-
- if dataset is None:
- return None
-
- try:
- dataset_labels = self.dataset_labels
- except:
- dataset_labels = None
-
- if self.system_config["system architecture"]["system type"] == "DD-CASSI":
-
- try:
- self.filtering_cube
- except:
- return print("Please generate filtering cube first")
-
-
- scene = match_dataset_to_instrument(dataset, self.filtering_cube[0,:,:,0])
-
- # scene = torch.from_numpy(match_dataset_to_instrument(dataset, self.filtering_cube)).to(self.device) if isinstance(scene, np.ndarray) else scene.to(self.device)
-
- measurement_in_3D = generate_dd_measurement_torch(scene, self.filtering_cube, chunck_size)
-
- self.last_filtered_interpolated_scene = measurement_in_3D
- self.interpolated_scene = scene
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.filtering_cube))
- self.scene_labels = scene_labels
-
-
- elif self.system_config["system architecture"]["system type"] == "SD-CASSI":
-
- X_coded_aper_coordinates_crop = crop_center(self.X_coded_aper_coordinates,dataset.shape[1], dataset.shape[2])
- Y_coded_aper_coordinates_crop = crop_center(self.Y_coded_aper_coordinates,dataset.shape[1], dataset.shape[2])
-
- self.X_coded_aper_coordinates = X_coded_aper_coordinates_crop
- self.Y_coded_aper_coordinates = Y_coded_aper_coordinates_crop
-
- # print("dataset shape: ", dataset.shape)
- # print("X coded shape: ", X_coded_aper_coordinates_crop.shape)
-
-
- scene = match_dataset_to_instrument(dataset, X_coded_aper_coordinates_crop)
-
- pattern_crop = crop_center_3D(pattern, scene.shape[2], scene.shape[1]).to(self.device)
-
- self.pattern_crop = pattern_crop
-
- pattern_crop = pattern_crop.unsqueeze(-1).repeat(1, 1, 1, scene.size(-1))
-
- #print(scene.get_device())
- #print(pattern_crop.get_device())
-
- plt.imshow(scene[0,:,:,0].cpu().numpy())
- plt.title("scene")
- plt.show()
-
- # filtered_scene = scene * pattern_crop[..., None].repeat((1, 1, scene.shape[2]))
- # print(f"scene: {scene.shape}")
- # print(f"pattern_crop: {pattern_crop.shape}")
- filtered_scene = scene * pattern_crop
-
- # print(f"filtered_scene: {filtered_scene.shape}")
-
-
- plt.imshow(pattern_crop[0,:,:,0].cpu().numpy())
- plt.title("Pattern crop1")
- plt.show()
-
-
-
- plt.imshow(filtered_scene[0,:,:,0].cpu().numpy())
- plt.title("Filtered scene")
- plt.show()
-
- #print("filtered_scene",filtered_scene.shape)
-
- self.propagate_coded_aperture_grid()
-
-
- sd_measurement = interpolate_data_on_grid_positions_torch(filtered_scene,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.filtering_cube = interpolate_data_on_grid_positions_torch(pattern_crop,
- self.X_coordinates_propagated_coded_aperture,
- self.Y_coordinates_propagated_coded_aperture,
- self.X_detector_coordinates_grid,
- self.Y_detector_coordinates_grid)
-
- self.last_filtered_interpolated_scene = sd_measurement
- self.interpolated_scene = scene
-
-
- if dataset_labels is not None:
- scene_labels = torch.from_numpy(match_dataset_labels_to_instrument(dataset_labels, self.last_filtered_interpolated_scene))
- self.scene_labels = scene_labels
-
- self.panchro = torch.sum(self.interpolated_scene, dim=3)
-
- if use_psf:
- self.apply_psf_torch()
- else:
- print("")
- #print("No PSF was applied")
-
- # Calculate the other two arrays
- self.measurement = torch.sum(self.last_filtered_interpolated_scene, dim=3)
-
- return self.measurement
-
- def generate_custom_pattern_parameters_slit(self, position=0.5):
- # Position is a float: 0 means slit is on the left edge, 1 means the slit is on the right edge
- self.array_x_positions = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"]))+ position
- self.array_x_positions = self.array_x_positions.to(self.device)
- return self.array_x_positions
-
- def generate_custom_pattern_parameters_slit_width(self, nb_slits=1, nb_rows=1, start_width=1):
- # Situation where we have nb_slits per row, and nb_rows rows of slits
- # Values in self.array_x_positions correspond to the width of the slit
- # self.array_x_positions is of shape (self.system_config["coded aperture"]["number of pixels along Y"], nb_rows)
-
- self.array_x_positions = torch.zeros((nb_slits, nb_rows))+start_width # Every slit starts with the same width
- self.array_x_positions = self.array_x_positions.to(self.device)
- self.array_x_positions_normalized = torch.zeros((nb_slits, nb_rows))+start_width
- return self.array_x_positions
-
- def generate_custom_slit_pattern_width(self, start_pattern = "line", start_position = 0):
- nb_slits, nb_rows = self.array_x_positions.shape
- pos_slits = self.system_config["coded aperture"]["number of pixels along X"]//(nb_slits+1) # Equally spaced slits
- height_slits = self.system_config["coded aperture"]["number of pixels along Y"]//nb_rows # Same length slits
-
- self.pattern = torch.zeros((self.system_config["coded aperture"]["number of pixels along Y"], self.system_config["coded aperture"]["number of pixels along X"])).to(self.device) # Pattern of correct size
- if start_pattern == "line":
- if start_position != 0:
- start_position = start_position - pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- for j in range(nb_slits):
- for i in range(nb_rows):
- top_pad = i*height_slits # Padding necessary above slit (j,i)
- if i == nb_rows-1:
- bottom_pad = 0 # Padding necessary below slit (j,i)
- # In that case, the last slit might be longer than the other ones in case size_X isn't divisible by nb_rows
- array_x_pos = torch.zeros((height_slits+self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows)) + start_position + (j+1)*pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- else:
- # Set the position of the slit (j,i)
- array_x_pos = torch.zeros((height_slits)) + start_position + (j+1)*pos_slits/self.system_config["coded aperture"]["number of pixels along X"]
- bottom_pad = (nb_rows - i-1)*height_slits + self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows # Padding necessary below slit (j,i)
- top_pad = i*height_slits
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32)
- # Expand dimensions for broadcasting
- expanded_x_positions = (array_x_pos.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)
- expanded_grid_positions = grid_positions.unsqueeze(0)
-
- # Apply Gaussian-like function
- sigma = (self.array_x_positions[j,i]+1)/2
- gaussian = torch.exp(-(((expanded_grid_positions - expanded_x_positions)) ** 2) / (2 * sigma ** 2))
-
- padded = torch.nn.functional.pad(gaussian, (0,0,top_pad,bottom_pad)) # padding: left - right - top - bottom
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern + padded/padded.max()
- elif start_pattern == "corrected":
- for j in range(nb_slits):
- for i in range(nb_rows):
- top_pad = i*height_slits # Padding necessary above slit (j,i)
- if i == nb_rows-1:
- bottom_pad = 0 # Padding necessary below slit (j,i)
- # In that case, the last slit might be longer than the other ones in case size_X isn't divisible by nb_rows
- else:
- # Set the position of the slit (j,i)
- bottom_pad = (nb_rows - i-1)*height_slits + self.system_config["coded aperture"]["number of pixels along Y"] % nb_rows # Padding necessary below slit (j,i)
- top_pad = i*height_slits
- """ array_x_pos = torch.tensor(start_position[i])
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32)
- # Expand dimensions for broadcasting
- expanded_x_positions = (array_x_pos.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)
- expanded_grid_positions = grid_positions.unsqueeze(0)
-
- # Apply Gaussian-like function
- sigma = (self.array_x_positions[j,i]+1)/2
- gaussian = torch.exp(-(((expanded_grid_positions - expanded_x_positions)) ** 2) / (2 * sigma ** 2))
-
- padded = torch.nn.functional.pad(gaussian, (0,0,top_pad,bottom_pad)) # padding: left - right - top - bottom
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern + padded/padded.max() """
-
- c = start_position[i].clone().detach() # center of the slit
- #d = ((torch.tanh(1.1*self.array_x_positions[j,i])+1)/2)/2 # width of the slit at pos
- d = self.array_x_positions[j,i]/2 # width of the slit at pos
- m = (c-d)*(self.system_config["coded aperture"]["number of pixels along X"]-1) # left bound
- M = (c+d)*(self.system_config["coded aperture"]["number of pixels along X"]-1) # right bound
- rect = torch.arange(self.system_config["coded aperture"]["number of pixels along X"]).to(self.device)
- clamp_M = torch.clamp(M-rect, 0, 1)
-
- clamp_m = torch.clamp(rect-m, 0, 1)
- diff = 1-clamp_m
- reg = torch.where(diff < 1, diff, -1)
- clamp_m = torch.where(reg!=0, reg, 1)
- clamp_m = torch.where(clamp_m!=-1, clamp_m, 0)
- clamp_m = torch.roll(clamp_m, -1)
- clamp_m[-1]=1
-
- rect = clamp_M - clamp_m +1
- rect = torch.where(rect!=2, rect, 0)
- rect = torch.where(rect <= 1, rect, rect-1)
- #rect = torch.clamp(-(rect-m)*(rect-M)+1,0,1).to(self.device)
-
- gaussian_range = torch.arange(self.system_config["coded aperture"]["number of pixels along X"], dtype=torch.float32)
- center_pos = 0.5*(len(gaussian_range)-1)
- sigma = 1.5
- gaussian_peaks = torch.exp(-((center_pos - gaussian_range) ** 2) / (2 * sigma ** 2)).to(self.device)
- gaussian = gaussian_peaks /gaussian_peaks.max()
- res = torch.nn.functional.conv1d(rect.unsqueeze(0), gaussian.unsqueeze(0).unsqueeze(0), padding = (len(gaussian_range)-1)//2).squeeze().to(self.device)
-
- res = res/res.max()
- self.pattern[i, :] = self.pattern[i, :] + res
-
- # Normalize to make sure the maximum value is 1
- self.pattern = self.pattern / self.pattern.max(dim=1).values.unsqueeze(-1)
-
- return self.pattern
-
- def generate_custom_slit_pattern(self):
-
- # Create a grid to represent positions
- grid_positions = torch.arange(self.empty_grid.shape[1], dtype=torch.float32).to(self.device)
- # Expand dimensions for broadcasting
- expanded_x_positions = ((self.array_x_positions.unsqueeze(-1)) * (self.empty_grid.shape[1]-1)).to(self.device)
- expanded_grid_positions = grid_positions.unsqueeze(0).to(self.device)
-
- # Apply Gaussian-like function
- # Adjust 'sigma' to control the sharpness
- sigma = 1.5
- gaussian_peaks = torch.exp(-((expanded_grid_positions - expanded_x_positions) ** 2) / (2 * sigma ** 2)).to(self.device)
-
- # Normalize to make sure the maximum value is 1
- self.pattern = gaussian_peaks / gaussian_peaks.max()
- return self.pattern
-
-
-
- # def generate_custom_slit_pattern(self):
- # """
- # Generate a custom slit pattern
-
- # Args:
- # array_x_positions (numpy.ndarray): array of the x positions of the slits between -1 and 1
-
- # Returns:
- # numpy.ndarray: generated slit pattern
- # """
- # pattern = torch.clone(self.empty_grid)
- # self.array_x_positions += 1
- # self.array_x_positions *= self.empty_grid.shape[1] // 2
- # self.array_x_positions = self.array_x_positions.type(torch.int32)
- # for i in range(self.array_x_positions.shape[0]):
- # pattern[0, self.array_x_positions[i]] = 1
-
- # return self.pattern
-
- def interpolate_dataset_along_wavelengths_torch(self, hyperspectral_cube, wavelengths, new_wavelengths_sampling,
- chunk_size):
- """
- Interpolate the dataset cube along the wavelength axis to match the system sampling
-
- Args:
- new_wavelengths_sampling (numpy.ndarray): new wavelengths on which to interpolate the dataset (shape = W)
- chunk_size (int): chunk size for the multiprocessing
-
- Returns:
- numpy.ndarray : interpolated dataset cube along the wavelength axis (shape = R_dts x C_dts x W)
-
- """
- try:
- self.dataset
- except:
- self.dataset = hyperspectral_cube
- self.dataset_wavelengths = wavelengths
- #print(self.dataset.shape)
- #print(self.dataset_wavelengths.shape)
-
- self.dataset = hyperspectral_cube
- self.dataset_wavelengths = wavelengths
-
-
-
- self.dataset_wavelengths = torch.from_numpy(self.dataset_wavelengths) if isinstance(self.dataset_wavelengths,
- np.ndarray) else self.dataset_wavelengths
- new_wavelengths_sampling = torch.from_numpy(new_wavelengths_sampling).float() if isinstance(
- new_wavelengths_sampling, np.ndarray) else new_wavelengths_sampling
- self.dataset = torch.from_numpy(self.dataset).float() if isinstance(self.dataset, np.ndarray) else self.dataset
-
- self.dataset_interpolated = self.interpolate_data_along_wavelength_torch(self.dataset, self.dataset_wavelengths[0],
- new_wavelengths_sampling)
- return self.dataset_interpolated
-
- def interpolate_data_along_wavelength_torch(self, data, current_sampling, new_sampling):
- """Interpolate the input 3D data along a new sampling in the third axis (lambda).
-
- Args:
- data (torch.Tensor): 4D data to interpolate with shape (batch_size, lambda, x, y).
- current_sampling (torch.Tensor): 1D tensor of current sampling for the lambda axis.
- new_sampling (torch.Tensor): 1D tensor of new sampling for the lambda axis.
- """
- # Assuming data is (batch, y, x, lambda)
- data = data.to(self.device)
-
- # Reshape data to treat lambda as a separate dimension, e.g., combining batch, y, x into one dimension
- original_shape = data.shape
- data_reshaped = data.reshape(-1, original_shape[-1]) # Shape: (batch*y*x, lambda)
-
- # Calculate the scale factor or directly use the new size
- scale_factor = len(new_sampling) / original_shape[-1]
-
- # Interpolate using 1D interpolation along the last dimension
- interpolated_data_reshaped = F.interpolate(data_reshaped.unsqueeze(1), # Add a fake channel dimension
- size=len(new_sampling),
- mode='linear',
- align_corners=True).squeeze(1) # Remove the fake channel dimension
-
- # Reshape back to the original batch, y, x format but with new lambda size
- interpolated_data = interpolated_data_reshaped.reshape(original_shape[0], original_shape[1], original_shape[2],
- -1)
-
- return interpolated_data
-
- def interpolate_data_along_wavelength_torch_old(self, data, current_sampling, new_sampling, chunk_size=50):
- """Interpolate the input 3D data along a new sampling in the third axis.
-
- Args:
- data (numpy.ndarray): 3D data to interpolate
- current_sampling (numpy.ndarray): current sampling for the 3rd axis
- new_sampling (numpy.ndarray): new sampling for the 3rd axis
- chunk_size (int): size of the chunks to use for the interpolation
- """
- # print(self.device)
- # Generate the coordinates for the original grid
- x = torch.arange(data.shape[0]).float()
- y = torch.arange(data.shape[1]).float()
- z = current_sampling
-
- # Initialize an empty array for the result
- interpolated_data = torch.empty((data.shape[0], data.shape[1], len(new_sampling)))
-
- # Perform the interpolation in chunks
- for i in range(0, data.shape[0], chunk_size):
- for j in range(0, data.shape[1], chunk_size):
- new_coordinates = torch.meshgrid(x[i:i + chunk_size], y[j:j + chunk_size], new_sampling, indexing='ij')
- new_grid = torch.stack(new_coordinates, axis=-1).to(self.device)
-
- min_bound = torch.tensor([torch.min(x[i:i + chunk_size]), torch.min(y[j:j + chunk_size]), torch.min(z)]).to(self.device)
- max_bound = torch.tensor([torch.max(x[i:i + chunk_size]), torch.max(y[j:j + chunk_size]), torch.max(z)]).to(self.device)
-
- new_grid = (2 * ((new_grid - min_bound) / (max_bound - min_bound)) - 1).unsqueeze(0).flip(
- -1).float() # Normalize between -1 and 1
-
- """new_coordinates = np.meshgrid(x[i:i+chunk_size], y[j:j+chunk_size], new_sampling, indexing='ij')
- new_grid = np.stack(new_coordinates, axis=-1)
-
- new_grid = torch.from_numpy(2*((new_grid-min_bound)/(max_bound - min_bound))-1).unsqueeze(0).flip(-1).double()"""
- interpolated_data[i:i + chunk_size, j:j + chunk_size, :] = torch.nn.functional.grid_sample(
- input=data[i:i + chunk_size, j:j + chunk_size, :][None, None, ...],
- grid=new_grid,
- padding_mode="zeros",
- mode="bilinear",
- align_corners=True).squeeze(0, 1)
-
- return interpolated_data
-
- def apply_psf(self):
- """
- Apply the PSF to the last measurement
-
- Returns:
- numpy.ndarray: last measurement cube convolved with by PSF (shape= R x C x W). Each slice of the 3D filtered scene is convolved with the PSF
- """
- if (self.optical_model.psf is not None) and (self.last_filtered_interpolated_scene is not None):
- # Expand the dimensions of the 2D matrix to match the 3D matrix
- psf_3D = self.optical_model.psf[..., None]
-
- # Perform the convolution using convolve
- result = torch.nn.functional.conv3d(self.last_filtered_interpolated_scene[None, None, ...], torch.flip(psf_3D, (0,1,2))[None, None, ...], padding = tuple((np.array(psf_3D.shape)-1)//2)).squeeze(0,1)
- result_panchro = torch.nn.functional.conv2d(self.panchro[None, None, ...], torch.flip(self.optical_model.psf, (0,1))[None, None, ...], padding = tuple((np.array(self.optical_model.psf.shape)-1)//2)).squeeze(0,1)
-
- else:
- print("No PSF or last measurement to apply PSF")
- result = self.last_filtered_interpolated_scene
- result_panchro = self.panchro
-
- self.last_filtered_interpolated_scene = result
- self.panchro = result_panchro
-
- return self.last_filtered_interpolated_scene
\ No newline at end of file
diff --git a/simca/OpticalModel.py b/simca/OpticalModel.py
index 7efc452..b638d3f 100644
--- a/simca/OpticalModel.py
+++ b/simca/OpticalModel.py
@@ -1,380 +1,316 @@
-from simca.functions_general_purpose import *
-from opticalglass.glassfactory import create_glass
+import torch
import snoop
+import opticalglass as og
+from simca.helper import *
+# import snoop
+import torch
+from opticalglass.glassfactory import create_glass
+import pytorch_lightning as pl
+from torch import nn
+from opticalglass.glassfactory import get_glass_catalog
-class OpticalModel:
+class OpticalModel(pl.LightningModule):
"""
Class that contains the optical model caracteristics and propagation models
"""
- def __init__(self, system_config):
- self.set_optical_config(system_config)
+ def __init__(self, config,index_estimation_method="cauchy",device="cpu"):
+ super().__init__()
- def update_config(self, new_config):
- """
- Update the optical model configuration
+ self.to(device)
+ self.system_config = config
+ self.index_estimation_method = index_estimation_method
- Args:
- new_config (dict): new configuration
+ self.lba_c = nn.Parameter(torch.tensor(config["system architecture"]["dispersive element"]["wavelength center"], dtype=torch.float,device=self.device,requires_grad=True))
- """
- self.set_optical_config(new_config)
+ self.define_lenses_carac()
+ self.define_dispersive_element_carac()
- def set_optical_config(self, config):
- """
- Set the optical model configuration
- Args:
- config (dict): configuration file
+ def define_lenses_carac(self):
- """
+ config = self.system_config
+ self.F = torch.tensor(config["system architecture"]["focal lens"],
+ dtype=torch.float,device=self.device) # If F needs to be optimized, wrap with nn.Parameter as well
+
+ return self.F
- self.system_config = config
+ def define_dispersive_element_carac(self):
+
+ config = self.system_config
self.dispersive_element_type = config["system architecture"]["dispersive element"]["type"]
- self.glass1 = config["system architecture"]["dispersive element"]["glass1"]
- self.A1 = math.radians(config["system architecture"]["dispersive element"]["A1"])
- self.glass2 = config["system architecture"]["dispersive element"]["glass2"]
- self.A2 = math.radians(config["system architecture"]["dispersive element"]["A2"])
- self.glass3 = config["system architecture"]["dispersive element"]["glass3"]
- self.A3 = math.radians(config["system architecture"]["dispersive element"]["A3"])
- self.G = config["system architecture"]["dispersive element"]["G"]
- self.lba_c = config["system architecture"]["dispersive element"]["wavelength center"]
- self.m = config["system architecture"]["dispersive element"]["m"]
- self.F = config["system architecture"]["focal lens"]
- self.delta_alpha_c = math.radians(config["system architecture"]["dispersive element"]["delta alpha c"])
- self.delta_beta_c = math.radians(config["system architecture"]["dispersive element"]["delta beta c"])
-
- self.nb_of_det_pixels_X = config["detector"]["number of pixels along X"]
- self.nb_of_det_pixels_Y = config["detector"]["number of pixels along Y"]
- self.nb_of_coded_apert_pixels_X = config["coded aperture"]["number of pixels along X"]
- self.nb_of_coded_apert_pixels_Y = config["coded aperture"]["number of pixels along Y"]
-
- self.set_wavelengths(config["spectral range"]["wavelength min"],
- config["spectral range"]["wavelength max"],
- config["spectral range"]["number of spectral samples"])
-
-
- def propagation_with_distorsions(self, X_input_grid, Y_input_grid):
- """
- Propagate the coded aperture coded_aperture through one CASSI system
- Args:
- X_input_grid (numpy.ndarray): x coordinates grid
- Y_input_grid (numpy.ndarray): y coordinates grid
+ if self.dispersive_element_type == "grating":
+ self.G = torch.tensor(config["system architecture"]["dispersive element"]["G"], dtype=torch.float,device=self.device)
+ self.m = torch.tensor(config["system architecture"]["dispersive element"]["m"], dtype=torch.float,device=self.device)
+ if self.index_estimation_method == "cauchy":
+ self.nd1, self.vd1 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
+ self.nd2, self.vd2 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
+ self.nd3, self.vd3 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
+ self.delta_beta_c = nn.Parameter(torch.tensor(math.radians(config["system architecture"]["dispersive element"]["delta beta c"]), dtype=torch.float,device=self.device))
+
+
+ elif self.dispersive_element_type in ["prism", "doubleprism", "amici", "tripleprism"]:
+ self.catalog = config["system architecture"]["dispersive element"]["catalog"]
+ self.glass1 = config["system architecture"]["dispersive element"]["glass1"]
+ self.A1 = nn.Parameter(torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A1"]), dtype=torch.float,device=self.device))
+ self.A2 = nn.Parameter(torch.tensor(0, dtype=torch.float,device=self.device))
+ self.A3 = nn.Parameter(torch.tensor(0, dtype=torch.float,device=self.device))
+ if self.index_estimation_method == "cauchy":
+ self.nd1, self.vd1 = self.get_corresponding_nd_vd(self.glass1,self.catalog)
+ self.nd2, self.vd2 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
+ self.nd3, self.vd3 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
+ # only used for prisms
+ self.delta_beta_c = nn.Parameter(torch.tensor(math.radians(config["system architecture"]["dispersive element"]["delta beta c"]), dtype=torch.float,device=self.device))
+
+ if self.dispersive_element_type in ["doubleprism", "amici", "tripleprism"]:
+
+ self.glass2 = config["system architecture"]["dispersive element"]["glass2"]
+ self.A2 = nn.Parameter(torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A2"]), dtype=torch.float,device=self.device))
+ if self.index_estimation_method == "cauchy":
+ self.nd2, self.vd2 = self.get_corresponding_nd_vd(self.glass2,self.catalog)
+ self.nd3, self.vd3 = (nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)),nn.Parameter(torch.tensor(1, dtype=torch.float,device=self.device)))
- Returns:
- tuple: X coordinates of the propagated coded aperture grids, Y coordinates of the propagated coded aperture grids
- """
+
+ if self.dispersive_element_type in ["amici", "tripleprism"]:
+
+ self.glass3 = config["system architecture"]["dispersive element"]["glass3"]
+ self.A3 = nn.Parameter(torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A3"]), dtype=torch.float,device=self.device))
+ if self.index_estimation_method == "cauchy":
+ self.nd3, self.vd3 = self.get_corresponding_nd_vd(self.glass3,self.catalog)
+
+ if self.dispersive_element_type =="amici":
+ self.A3 = self.A1
+ self.glass3 = self.glass1
+ if self.index_estimation_method == "cauchy":
+ self.nd3 = self.nd1
+ self.vd3 = self.vd1
+
+ self.alpha_c = nn.Parameter(
+ torch.tensor(math.radians(config["system architecture"]["dispersive element"]["alpha_c"]),
+ dtype=torch.float,device=self.device))
+ self.delta_alpha_c = nn.Parameter(torch.tensor(
+ math.radians(config["system architecture"]["dispersive element"]["delta alpha c"]), dtype=torch.float,device=self.device))
+
+ # Calculation based on the above parameters
+ alpha_c_transmis = -1 * self.propagate_central_microm_through_disperser(self.lba_c)
+ self.alpha_c_transmis = alpha_c_transmis[0,0,0]
+ # print(self.alpha_c_transmis.detach().cpu().numpy()*180/np.pi)
- self.calculate_central_dispersion()
-
- # X_coordinates_propagated_coded_aperture = np.zeros((X_input_grid.shape[0],X_input_grid.shape[1],
- # self.nb_of_spectral_samples))
- # Y_coordinates_propagated_coded_aperture = np.zeros((X_input_grid.shape[0],X_input_grid.shape[1],
- # self.nb_of_spectral_samples))
- #
- # X_input_grid_flatten = X_input_grid.flatten()
- # Y_input_grid_flatten = Y_input_grid.flatten()
- #
- # glass = create_glass(self.glass1, 'Schott')
- # print(glass)
- #
- #
- # n1 = 1.5
- # n2 = 1.8
- # n3 = 1.5
- #
- # for idx,lba in enumerate(np.linspace(self.system_wavelengths[0], self.system_wavelengths[-1],self.nb_of_spectral_samples)):
- #
- # prism_index = glass.calc_rindex(lba)
- # # n_array_flatten = np.full(X_input_grid_flatten.shape, prism_index)
- # # n_array_flatten = np.full(X_input_grid_flatten.shape, self.sellmeier(lba))
- # n1_flatten = np.full(X_input_grid_flatten.shape, n1)
- # n2_flatten = np.full(X_input_grid_flatten.shape, n2)
- # n3_flatten = np.full(X_input_grid_flatten.shape, n3)
- #
- # lba_array_flatten = np.full(X_input_grid_flatten.shape, lba)
- #
- # X_propagated_coded_aperture, Y_propagated_coded_aperture = self.propagate_through_arm(X_input_grid_flatten,Y_input_grid_flatten,
- # n1=n1_flatten,
- # n2=n2_flatten,
- # n3=n3_flatten,
- # lba=lba_array_flatten)
- #
- # X_coordinates_propagated_coded_aperture[:,:,idx] = X_propagated_coded_aperture.reshape(X_input_grid.shape)
- # Y_coordinates_propagated_coded_aperture[:,:,idx] = Y_propagated_coded_aperture.reshape(Y_input_grid.shape)
- #
- # return X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture
-
- def propagation_with_no_distorsions(self, X_input_grid, Y_input_grid):
- """
- Vanilla Propagation model used in most cassi acquisitions simulation.
+
+ def get_corresponding_nd_vd(self,glass_name,catalog):
+ glass_pd = get_glass_catalog(catalog)
+ list_of_glasses = glass_pd.df.iloc[:, 0].index.tolist()
- Args:
- X_input_grid (numpy.ndarray): X coordinates of the grid to be propagated (2D)
- Y_input_grid (numpy.ndarray): Y coordinates of the grid to be propagated (2D)
+ idx_glass = list_of_glasses.index(glass_name)
+ tuple_glass_data = glass_pd.glass_map_data("d")
- Returns:
- tuple: X coordinates grids of the propagated coded apertures, Y coordinates grids of the propagated coded apertures
- """
+ nd = tuple_glass_data[0][idx_glass]
+ vd = tuple_glass_data[1][idx_glass]
- self.calculate_central_dispersion()
+ nd = nn.Parameter(torch.tensor(nd, dtype=torch.float,device=self.device))
+ vd = nn.Parameter(torch.tensor(vd, dtype=torch.float,device=self.device))
- X_coordinates_propagated_coded_aperture = np.zeros((X_input_grid.shape[0],X_input_grid.shape[1],
- self.nb_of_spectral_samples))
- Y_coordinates_propagated_coded_aperture = np.zeros((X_input_grid.shape[0],X_input_grid.shape[1],
- self.nb_of_spectral_samples))
+ # print(f"nd = {nd}, vd = {vd}")
- for idx, wav in enumerate(self.system_wavelengths):
+ return nd, vd
- X_ref = -1 * X_input_grid + self.X0_propagated[idx]
- Y_ref = -1 * Y_input_grid + self.Y0_propagated[idx]
+ def rerun_central_dispersion(self):
+ alpha_c_transmis = -1 * self.propagate_central_microm_through_disperser(self.lba_c.detach().cpu().numpy())
+ self.alpha_c_transmis = alpha_c_transmis
- X_coordinates_propagated_coded_aperture[:,:,idx] = X_ref
- Y_coordinates_propagated_coded_aperture[:,:,idx] = Y_ref
+ return alpha_c_transmis
+
- return X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture
+ def propagate(self,X,Y,lba,n1,n2,n3):
- def set_wavelengths(self, wavelength_min, wavelength_max, nb_of_spectral_samples):
- """
- Set the wavelengths range of the optical system
+ k = self.model_Lens_pos_to_angle(X, Y, self.F)
- Args:
- wavelength_min (float): minimum wavelength of the system
- wavelength_max (float): maximum wavelength of the system
- nb_of_spectral_samples (int): number of spectral samples of the system
- Returns:
+ alpha_1 = self.define_alpha_1()
- """
- self.wavelength_min = wavelength_min
- self.wavelength_max = wavelength_max
- self.nb_of_spectral_samples = nb_of_spectral_samples
+ k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- self.system_wavelengths = np.linspace(self.wavelength_min,self.wavelength_max,self.nb_of_spectral_samples)
+ if self.dispersive_element_type in ["prism", "doubleprism", "amici", "tripleprism"]:
+ k, list_theta_in, list_theta_out = self.propagate_through_triple_prism(k,n1,n2,n3,self.A1,self.A2,self.A3)
+ elif self.dispersive_element_type == "grating":
+ k = self.model_Grating_angle_to_angle(k, lba, self.m, self.G)
- @snoop
- def calculate_central_dispersion(self):
- """
- Calculate the dispersion related to the central pixel of the coded aperture
+ k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c_transmis,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- Returns:
- numpy.float: spectral dispersion of the central pixel of the coded aperture
- """
+ X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k, self.F)
- # self.alpha_c = self.calculate_alpha_c()
- self.alpha_c = 55*np.pi/180
- X0_coordinates_array_flatten = np.zeros(self.system_wavelengths.shape[0])
- Y0_coordinates_array_flatten = np.zeros(self.system_wavelengths.shape[0])
- lba_array_flatten = self.system_wavelengths
+ return X_vec_out, Y_vec_out
+
+
+ def repropagate(self,X,Y,lba,n1,n2,n3):
- n1_array_flatten = np.full(lba_array_flatten.shape, 1.5)
- n2_array_flatten = np.full(lba_array_flatten.shape, 1.8)
- n3_array_flatten = np.full(lba_array_flatten.shape, 1.5)
+ k = self.model_Lens_pos_to_angle(X, Y, self.F)
- # n_array_flatten = np.full(lba_array_flatten.shape, self.sellmeier(lba_array_flatten))
+ alpha_1 = self.define_alpha_1()
- X0_propagated, Y0_propagated = self.propagate_through_arm(X_vec_in=X0_coordinates_array_flatten,Y_vec_in=Y0_coordinates_array_flatten,
- n1=n1_array_flatten,
- n2=n2_array_flatten,
- n3=n3_array_flatten,
- lba=lba_array_flatten)
+ k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c_transmis,-1*self.delta_alpha_c,-1*self.delta_beta_c,alpha_1)
- self.X0_propagated, self.Y0_propagated = X0_propagated, Y0_propagated
+ if self.dispersive_element_type in ["prism", "doubleprism", "amici", "tripleprism"]:
+ k, list_theta_in, list_theta_out = self.propagate_through_triple_prism(k,n1,n2,n3,self.A1,self.A2,self.A3)
+ elif self.dispersive_element_type == "grating":
+ k = self.model_Grating_angle_to_angle(k, lba, self.m, self.G)
- self.central_distorsion_in_X = np.abs(self.X0_propagated[-1] - self.X0_propagated[0])
+
+ k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c,-1*self.delta_alpha_c,-1*self.delta_beta_c,alpha_1)
- return self.central_distorsion_in_X
-
- @snoop
- def propagate_through_simple_prism(self,k,n,A):
+ # print(k)
+ X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k, self.F)
- norm_k = np.sqrt(k[0] ** 2 + k[1] ** 2 + k[2] ** 2)
- k /= norm_k
+ return X_vec_out, Y_vec_out
- k_out = self.model_Prism_angle_to_angle(k, n, A)
- k_out = k_out * norm_k
+ def calculate_dispersion_with_cauchy(self,lambda_vec, nD, V):
- return k_out
+ lambda_vec = lambda_vec * 1e-9 # Convert nm to meters for calculation
+ lambda_D = 589.3e-9 # D line wavelength in meters
+ lambda_F = 486.1e-9 # F line wavelength in meters
+ lambda_C = 656.3e-9 # C line wavelength in meters
+
+ # Calculate B using the given formula
+ B = (nD - 1) / (V * (1 / lambda_F ** 2 - 1 / lambda_C ** 2))
+
+ # Calculate A using the given formula
+ A = nD - B / lambda_D ** 2
+
+ # Calculate n for each wavelength in lambda_vec
+ n = A + B / lambda_vec ** 2 # Note: lambda_vec is already in meters
+
+ # print("lambda_vec = ",lambda_vec)
+ # print("n_cauchy = ",n)
+ # print("n sellemeir = ",self.sellmeir_NSF4(lambda_vec))
+
+
+ # return self.sellmeir_NSF4(lambda_vec)
+ return n
- def propagate_through_double_prism(self,k,n1,n2,A1,A2):
+ def sellmeier(self,lambda_vec,glass_name):
- norm_k = np.sqrt(k[0] ** 2 + k[1] ** 2 + k[2] ** 2)
- k /= norm_k
+ glass_pd = get_glass_catalog(self.catalog)
+ df = glass_pd.df["dispersion coefficients"]
- k = self.model_Prism_angle_to_angle(k, n1, A1)
- k = k * norm_k
+ B1 = df.loc[glass_name]["B1"]
+ B2 = df.loc[glass_name]["B2"]
+ B3 = df.loc[glass_name]["B3"]
+ C1 = df.loc[glass_name]["C1"]
+ C2 = df.loc[glass_name]["C2"]
+ C3 = df.loc[glass_name]["C3"]
- k = rotation_z(np.pi) @ k
+ # print(glass_name)
+ # print("B1,B2,B3,C1,C2,C3 = ",B1,B2,B3,C1,C2,C3)
- k_out = self.model_Prism_angle_to_angle(k, n2, A2)
- k_out = k_out * norm_k
+ lambda_vec = lambda_vec * 1e-3
- return k_out
+ index_square = 1 + B1*lambda_vec**2/(lambda_vec**2-C1) + B2*lambda_vec**2/(lambda_vec**2-C2)
- @snoop
- def propagate_through_triple_prism(self,k,n1,n2,n3,A1,A2,A3):
+ index_square = torch.tensor(index_square,dtype=torch.float32)
- norm_k = np.sqrt(k[0] ** 2 + k[1] ** 2 + k[2] ** 2)
+ index = torch.sqrt(index_square)
- k /= norm_k
- k = self.model_Prism_angle_to_angle(k, n1, A1)
- k *= norm_k
- k = rotation_z(np.pi) @ k
- k = self.model_Prism_angle_to_angle(k, n2, A2)
- k *= norm_k
- k = rotation_z(np.pi) @ k
- k_out = self.model_Prism_angle_to_angle(k, n3, A3)
- k_out *= norm_k
+ # print(lambda_vec)
+ # print("index = ",index)
- print('alpha', np.arctan(k_out[0, 0] / k_out[2, 0]) * 180 / np.pi)
- print('beta', np.arctan(k_out[1, 0] / k_out[2, 0]) * 180 / np.pi)
+ return index
- return k_out
- @snoop
def rotate_from_lens_to_dispersive_element(self,k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1):
-
angle_with_P1 = alpha_c - alpha_1 + delta_alpha_c
-
- print('angle_with_P1',angle_with_P1*180/np.pi)
-
- k = rotation_y(angle_with_P1) @ k[:, 0, :]
+ #TODO : check the type of k
+ k = k.to(dtype=torch.float32)
+ # k_1 = rotation_y(angle_with_P1) @ k
+ k = torch.matmul(k,rotation_y(angle_with_P1).T)
# Rotation in relation to P1 around the X axis
- k = rotation_x(delta_beta_c) @ k
+ k = k.to(dtype=torch.float32)
+
+ k = torch.matmul(k,rotation_x(delta_beta_c).T)
# Rotation of P1 in relation to frame_in along the new Y axis
- k = rotation_y(alpha_1) @ k
+ k = k.to(dtype=torch.float32)
- print('alpha', np.arctan(k[0, 0] / k[2, 0]) * 180 / np.pi)
- # print('beta', np.arctan(k[0, 0] / k[2, 0]) * 180 / np.pi)
+ k = torch.matmul(k,rotation_y(alpha_1).T)
return k
def rotate_from_dispersive_element_to_lens(self,k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1):
angle_with_P2 = alpha_c_transmis - alpha_1 - delta_alpha_c
-
- k = np.dot(rotation_y(alpha_1), k)
+ k = torch.matmul(k,rotation_y(alpha_1).T)
# Rotation in relation to P2 around the X axis
- k = np.dot(rotation_x(-delta_beta_c), k)
+ k = torch.matmul(k,rotation_x(-delta_beta_c).T)
# Rotation in relation to P2 around the Y axis
- k = np.dot(rotation_y(angle_with_P2), k)
-
+ k = torch.matmul(k,rotation_y(angle_with_P2).T)
+ #print(k.shape)
return k
- def propagate_through_arm(self, X_vec_in, Y_vec_in, n1, n2,n3,lba):
- """
- Propagate the light through one system arm : (lens + dispersive element + lens)
- Args:
- X_vec_in (numpy.ndarray) : X coordinates of the coded aperture pixels (1D array)
- Y_vec_in (numpy.ndarray) : Y coordinates of the coded aperture pixels (1D array)
- n (numpy.ndarray) : refractive indexes of the system (at the corresponding wavelength)
- lba (numpy.ndarray) : wavelengths
+ def propagate_through_triple_prism(self,k,n1,n2,n3,A1,A2,A3):
- Returns:
- tuple: flatten arrays corresponding to the propagated X and Y coordinates
- """
+ norm_k = torch.sqrt(k[...,0] ** 2 + k[...,1] ** 2 + k[...,2] ** 2)
+ norm_k = norm_k.unsqueeze(-1)
+ norm_k = norm_k.repeat(1, 1, 1,3)
+ k_normalized = k / norm_k
- dispersive_element_type = self.dispersive_element_type
- A1 = self.A1
- A2 = self.A2
- A3 = self.A3
- G = self.G
- m = self.m
- F = self.F
- delta_alpha_c = self.delta_alpha_c
- delta_beta_c = self.delta_beta_c
- alpha_c = self.alpha_c
- # alpha_c_transmis = self.alpha_c_transmis
-
- # alpha_c = 50*np.pi/180
-
-
- k = self.model_Lens_pos_to_angle(X_vec_in, Y_vec_in, F)
-
- if dispersive_element_type == "prism":
- alpha_1 = A1 - A1/2
- k = self.rotate_from_lens_to_dispersive_element(k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1)
- k = self.propagate_through_simple_prism(k,n1,A1)
- k = self.rotate_from_dispersive_element_to_lens(k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1)
-
- elif dispersive_element_type == "doubleprism":
- alpha_1 = A1 - A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1)
- k = self.propagate_through_double_prism(k,n1,n2,A1,A2)
- k = self.rotate_from_dispersive_element_to_lens(k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1)
-
- elif dispersive_element_type == "tripleprism":
- alpha_1 = A1 - A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1)
- k = self.propagate_through_triple_prism(k,n1,n2,n3,A1,A2,A3)
- k = self.rotate_from_dispersive_element_to_lens(k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1)
-
- elif dispersive_element_type == "grating":
- alpha_1 = 0
- k = self.rotate_from_lens_to_dispersive_element(k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1)
- k = self.model_Grating_angle_to_angle(k, lba, m, G)
- k = self.rotate_from_dispersive_element_to_lens(k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1)
+ k,theta_in_1, theta_out_1,distance_from_total_intern_reflection1 = self.model_Prism_angle_to_angle_torch(k_normalized, n1, A1)
+ k = k * norm_k
+ k = torch.matmul(k,rotation_z(torch.tensor(np.pi,device=self.device)).T)
+ k,theta_in_2, theta_out_2,distance_from_total_intern_reflection2 = self.model_Prism_angle_to_angle_torch(k, n2, A2)
+ k = k * norm_k
+ k = torch.matmul(k,rotation_z(torch.tensor(np.pi,device=self.device)).T)
+ k,theta_in_3, theta_out_3,distance_from_total_intern_reflection3 = self.model_Prism_angle_to_angle_torch(k, n3, A3)
+ k = k * norm_k
- X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k, F)
+ list_theta_in = [theta_in_1,theta_in_2,theta_in_3]
+ list_theta_out = [theta_out_1,theta_out_2,theta_out_3]
+
+ self.min_distance_from_total_intern_reflection = min(torch.min(distance_from_total_intern_reflection1),
+ torch.min(distance_from_total_intern_reflection2),
+ torch.min(distance_from_total_intern_reflection3))
+
+ return k, list_theta_in, list_theta_out
- return X_vec_out, Y_vec_out
- def model_Grating_angle_to_angle(self,k_in, lba, m, G):
+
+
+ def model_Grating_angle_to_angle(self, k_in, lba, m, G):
"""
Model of the grating
Args:
- k_in (numpy.ndarray) : wave vector of the incident ray (shape = 3 x N)
- lba (numpy.ndarray) : wavelengths (shape = N) -- in nm
+ k_in (torch.Tensor) : wave vector of the incident ray (shape = 3 x N)
+ lba (torch.Tensor) : wavelengths (shape = N) -- in nm
m (float) : diffraction order of the grating -- no units
G (float) : lines density of the grating -- in lines/mm
Returns:
- numpy.ndarray: wave vector of the outgoing ray (shape = 3 x N)
-
+ torch.Tensor: wave vector of the outgoing ray (shape = 3 x N)
"""
- alpha_in = np.arctan(k_in[0]) * np.sqrt(1 + np.tan(k_in[0])**2 + np.tan(k_in[1])**2)
- beta_in = np.arctan(k_in[1]) * np.sqrt(1 + np.tan(k_in[0])**2 + np.tan(k_in[1])**2)
- alpha_out = -1*np.arcsin(m * lba*10**-9 * G * 10**3 - np.sin(alpha_in))
- beta_out = beta_in
+ alpha_in = torch.atan(k_in[...,0]) * torch.sqrt(1 + torch.tan(k_in[...,0])**2 + torch.tan(k_in[...,1])**2)
+ beta_in = torch.atan(k_in[...,1]) * torch.sqrt(1 + torch.tan(k_in[...,0])**2 + torch.tan(k_in[...,1])**2)
+ alpha_out = -1 * torch.asin(m * lba * 10**-9 * G * 10**3 - torch.sin(alpha_in))
+ beta_out = beta_in
- k_out = [np.sin(alpha_out) * np.cos(beta_out),
- np.sin(beta_out)*np.cos(alpha_out),
- np.cos(alpha_out) * np.cos(beta_out)]
+ k_out = torch.stack([
+ torch.sin(alpha_out) * torch.cos(beta_out),
+ torch.sin(beta_out) * torch.cos(alpha_out),
+ torch.cos(alpha_out) * torch.cos(beta_out)
+ ], dim=-1)
return k_out
- def simplified_grating_in_out(self, alpha,lba,m,G):
- """
- Model 1D of the grating in the dispersion direction
-
- Args:
- alpha (numpy.ndarray or float) : angle of the incident ray (shape = N) -- in radians
- lba (numpy.ndarray or float) : wavelengths (shape = N) -- in nm
- m (float) : diffraction order of the grating -- no units
- G (float) : lines density of the grating -- in lines/mm
-
- Returns:
- numpy.ndarray: angle of the outgoing ray (shape = N) -- in radians
-
- """
-
- alpha_out = np.arcsin(m * lba * 10 ** -9 * G * 10 ** 3 - np.sin(alpha))
-
- return alpha_out
def model_Lens_angle_to_position(self,k_in,F):
"""
Model of the lens : angle to position
Args:
- k_in (numpy.ndarray) : wave vector of the incident ray (shape = 3 x N)
+ k_in (torch.tensor) : wave vector of the incident ray (shape = 3 x N)
F (float) : focal length of the lens -- in um
Returns:
@@ -382,15 +318,14 @@ def model_Lens_angle_to_position(self,k_in,F):
"""
- alpha = np.arctan(k_in[0] / k_in[2])
- beta = np.arctan(k_in[1] / k_in[2])
+ alpha = torch.arctan(k_in[...,0] / k_in[...,2])
+ beta = torch.arctan(k_in[...,1] / k_in[...,2])
- x = F * np.tan(alpha)
- y = F * np.tan(beta)
+ x = F * torch.tan(alpha)
+ y = F * torch.tan(beta)
return x, y
- @snoop
def model_Prism_angle_to_angle(self,k0, n,A):
"""
Ray tracing through the prism
@@ -413,109 +348,74 @@ def model_Prism_angle_to_angle(self,k0, n,A):
return kout
- def model_Lens_pos_to_angle(self,x_obj, y_obj, F):
+
+ def model_Prism_angle_to_angle_torch(self,k0, n,A):
"""
- Model of the lens : position to angle
+ Ray tracing through the prism
Args:
- x_obj (numpy.ndarray) : position X in the image plane (shape = N) -- in um
- y_obj (numpy.ndarray) : position Y in the image plane (shape = N) -- in um
- F (float) : focal length of the lens -- in um
+ k0 (torch.tensor) : wave vector of the incident ray
+ n (torch.tensor) : refractive index of the prism
+ A (float) : angle of the prism -- in radians
Returns:
- numpy.ndarray: wave vector of the outgoing ray (shape = 3 x N)
+ torch.tensor: wave vector of the outgoing ray
"""
+ kp = torch.zeros_like(k0,device=k0.device)
+ kout = torch.zeros_like(k0,device=k0.device)
- alpha = -1*np.arctan(x_obj / F)
- beta = -1*np.arctan(y_obj / F)
+ theta_in = torch.atan2(k0[...,0], k0[...,2])
- k_out = np.array([[np.sin(alpha) * np.cos(beta)],
- [np.sin(beta)*np.cos(alpha)],
- [np.cos(alpha) * np.cos(beta)]])
+ kp[...,0] = k0[...,0]
+ kp[...,1] = k0[...,1]
- return k_out
+ # compare = n ** 2 - k0[...,0] ** 2 - k0[...,1] ** 2
- def calculate_alpha_c(self):
- """
- Calculate the relative angle of incidence between the lenses and the dispersive element
- Returns:
- float: angle of incidence
- """
- if self.dispersive_element_type == "prism":
- self.Dm = self.calculate_minimum_deviation(self.sellmeier(self.lba_c), self.A1)
- self.alpha_c = self.get_incident_angle_min_dev(self.A1,self.Dm)
- self.alpha_c_transmis = self.alpha_c
-
- if self.dispersive_element_type == "doubletprism":
- self.Dm = self.calculate_minimum_deviation(self.sellmeier(self.lba_c), self.A1)
- self.alpha_c = self.get_incident_angle_min_dev(self.A1,self.Dm)
- self.alpha_c_transmis = self.alpha_c
+ kp[...,2] = torch.sqrt(n ** 2 - k0[...,0] ** 2 - k0[...,1] ** 2)
- if self.dispersive_element_type == "grating":
- self.alpha_c = 0
- self.alpha_c_transmis = self.simplified_grating_in_out(self.alpha_c,self.lba_c,self.m,self.G)
+ theta_out = torch.atan2(kp[...,0], kp[...,2])
- return self.alpha_c
+ kp_r = torch.matmul(kp, rotation_y(-A).T)
+ kout[...,0] = kp_r[...,0]
+ kout[...,1] = kp_r[...,1]
+ kout[...,2] = torch.sqrt(1 - kp_r[...,0] ** 2 - kp_r[...,1] ** 2)
- def calculate_minimum_deviation(self,n, A):
- """
- minimum deviation angle of a prism of index n and apex angle A
-
- Args:
- n (float or numpy.ndarray): index of the prism -- no units
- A (float): apex angle of the prism -- in radians
-
- Returns:
- float or numpy.ndarray: minimum deviation angle -- in radians
- """
- return 2 * np.arcsin(n * np.sin(A / 2)) - A
-
- def get_incident_angle_min_dev(self,A, D_m):
- """
- Calculate the angle of incidence corresponding to the minimum deviation angle
-
- Args:
- A (float): apex angle of the prism -- in radians
- D_m (float): minimum deviation angle -- in radians
-
- Returns:
- float: angle of incidence corresponding to minimum of deviation -- in radians
- """
- return (A + D_m) / 2
+ distance_from_total_intern_reflection = 1 - kp_r[...,0] ** 2 - kp_r[...,1] ** 2
+ return kout, theta_in, theta_out,distance_from_total_intern_reflection
+
- def sellmeier(self,lambda_, glass_type="BK7"):
+ def model_Lens_pos_to_angle(self,x_obj, y_obj, F):
"""
- Evaluating the refractive index value of a prism for a given lambda based on Sellmeier equation
+ Model of the lens : position to angle
Args:
- lambda_ (numpy.ndarray of float) : wavelength in nm
+ x_obj (torch.tensor) : position X in the image plane -- in um
+ y_obj (torch.tensor) : position Y in the image plane -- in um
+ F (torch.tensor) : focal length of the lens -- in um
Returns:
- numpy.ndarray of float: index value corresponding to the input wavelength
+ torch.tensor: wave vector of the outgoing ray
"""
+ alpha = -1 * torch.atan(x_obj / F)
+ beta = -1 * torch.atan(y_obj / F)
- if glass_type == "BK7":
- B1 = 1.03961212
- B2 = 0.231792344
- B3 = 1.01046945
- C1 = 6.00069867 * (10 ** -3)
- C2 = 2.00179144 * (10 ** -2)
- C3 = 1.03560653 * (10 ** 2)
+ # Adjusting the dimension for k_out to make it a 4D tensor
+ #TODO : verify that float64 is the right type
+ k_out = torch.zeros(size=(x_obj.shape[0], x_obj.shape[1], x_obj.shape[2], 3),dtype=torch.float64,device=x_obj.device)
- else :
- raise Exception("glass_type is Unknown")
+ # the fourth dimension should have 3 components
+ k_out[...,0] = torch.sin(alpha) * torch.cos(beta)
+ k_out[...,1] = torch.sin(beta) * torch.cos(alpha)
+ k_out[...,2] = torch.cos(alpha) * torch.cos(beta)
- lambda_in_mm = lambda_ / 1000
+ return k_out
- n = np.sqrt(1 + B1 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C1) + B2 * lambda_in_mm ** 2 / (
- lambda_in_mm ** 2 - C2) + B3 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C3))
- return n
def generate_2D_gaussian(self,radius, sample_size_x, sample_size_y, nb_of_samples):
"""
@@ -582,3 +482,165 @@ def check_if_sampling_is_sufficiant(self):
print("The 'number of spectral samples' (cf. system config) is not sufficiant to avoid weird sampling effect( aliasing ?). RAISE IT !")
return nb_of_sample_points_per_pix
+
+
+
+ def propagate_central_microm_through_disperser(self,lambda_):
+
+ if self.index_estimation_method == "cauchy":
+ n1 = self.calculate_dispersion_with_cauchy(lambda_,self.nd1,self.vd1).clone().detach().requires_grad_(True).to(device=self.device)
+ n2 = self.calculate_dispersion_with_cauchy(lambda_,self.nd2,self.vd2).clone().detach().requires_grad_(True).to(device=self.device)
+ n3 = self.calculate_dispersion_with_cauchy(lambda_,self.nd3,self.vd3).clone().detach().requires_grad_(True).to(device=self.device)
+ if self.index_estimation_method == "sellmeier":
+ n1 = self.sellmeier(lambda_,self.glass1).clone().detach().requires_grad_(True).to(device=self.device)
+ try:
+ n2 = self.sellmeier(lambda_,self.glass2).clone().detach().requires_grad_(True).to(device=self.device)
+ except:
+ n2 = torch.tensor(1,device=self.device)
+ try:
+ n3 = self.sellmeier(lambda_,self.glass3).clone().detach().requires_grad_(True).to(device=self.device)
+ except:
+ n3 = torch.tensor(1,device=self.device)
+
+ x0 = torch.zeros((1,1,1,1)).to(device=self.device)
+ y0 = torch.zeros((1,1,1,1)).to(device=self.device)
+
+ k = self.model_Lens_pos_to_angle(x0, y0, self.F)
+
+ alpha_1 = self.define_alpha_1()
+
+ k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
+
+ if self.dispersive_element_type in ["prism", "doubleprism", "amici", "tripleprism"]:
+ k, list_theta_in, list_theta_out = self.propagate_through_triple_prism(k,n1,n2,n3,self.A1,self.A2,self.A3)
+ self.list_theta_in = list_theta_in
+ self.list_theta_out = list_theta_out
+ elif self.dispersive_element_type == "grating":
+ k = self.model_Grating_angle_to_angle(k, lambda_, self.m, self.G)
+
+ alpha = torch.arctan(k[...,0] / k[...,2])
+ beta = torch.arctan(k[...,1] / k[...,2])
+
+
+
+ return alpha
+
+
+
+ def define_alpha_1(self):
+ """
+ Define the angle alpha_1 depending on the type of dispersive element
+
+ Returns:
+ float: angle alpha_1
+ """
+
+ if self.dispersive_element_type == "prism":
+ alpha_1 = self.A1 / 2
+ elif self.dispersive_element_type in ["doubleprism", "amici", "tripleprism"]:
+ alpha_1 = self.A1 - self.A2 / 2
+ elif self.dispersive_element_type == "grating":
+ alpha_1 = torch.tensor(0,device=self.device)
+ else:
+ raise Exception("dispersive_element_type should be prism or grating")
+
+ return alpha_1
+
+
+
+
+
+
+def rotation_z(theta):
+ """
+ Rotate 3D matrix around the Z axis using PyTorch
+
+ Args:
+ theta (torch.Tensor): Input angle (in rad)
+
+ Returns:
+ torch.Tensor: 3D rotation matrix
+ """
+ # Ensure theta is a tensor with requires_grad=True
+ if not isinstance(theta, torch.Tensor):
+ theta = torch.tensor(theta, requires_grad=True)
+
+ cos_theta = torch.cos(theta)
+ sin_theta = torch.sin(theta)
+
+ # Construct the rotation matrix using torch.stack to support gradient computation
+ # For rotation around the Z axis, the changes affect the first two rows
+ row1 = torch.stack([cos_theta, -sin_theta, torch.zeros_like(theta)])
+ row2 = torch.stack([sin_theta, cos_theta, torch.zeros_like(theta)])
+ row3 = torch.stack([torch.zeros_like(theta), torch.zeros_like(theta), torch.ones_like(theta)])
+
+ # Concatenate the rows to form the rotation matrix
+ r = torch.stack([row1, row2, row3], dim=0)
+
+ # Adjust the matrix to have the correct shape (3, 3) for each theta
+ r = r.transpose(0, 1) # This may need adjustment based on how you intend to use r
+
+ return r
+
+
+def rotation_y(theta):
+ """
+ Rotate 3D matrix around the Y axis using PyTorch
+
+ Args:
+ theta (torch.Tensor): Input angle (in rad)
+
+ Returns:
+ torch.Tensor: 3D rotation matrix
+ """
+ # Ensure theta is a tensor with requires_grad=True
+ if not isinstance(theta, torch.Tensor):
+ theta = torch.tensor(theta, requires_grad=True, dtype=torch.float32)
+
+ cos_theta = torch.cos(theta)
+ sin_theta = torch.sin(theta)
+
+ # Construct the rotation matrix using torch.stack to support gradient computation
+ # For rotation around the Y axis, the changes affect the first and third rows
+ row1 = torch.stack([cos_theta, torch.zeros_like(theta), -sin_theta]) # Note the change to -sin_theta for correct Y-axis rotation
+ row2 = torch.stack([torch.zeros_like(theta), torch.ones_like(theta), torch.zeros_like(theta)])
+ row3 = torch.stack([sin_theta, torch.zeros_like(theta), cos_theta])
+
+ # Concatenate the rows to form the rotation matrix
+ r = torch.stack([row1, row2, row3], dim=0)
+
+ # Adjust the matrix to have the correct shape (3, 3) for each theta
+ r = r.transpose(0, 1) # Adjust transpose for consistency with your requirements
+
+ return r
+
+
+def rotation_x(theta):
+ """
+ Rotate 3D matrix around the X axis using PyTorch
+
+ Args:
+ theta (tensor): Input angle (in rad)
+
+ Returns:
+ torch.Tensor: 3D rotation matrix
+ """
+ # Ensure theta is a tensor with requires_grad=True
+ if not isinstance(theta, torch.Tensor):
+ theta = torch.tensor(theta, requires_grad=True, dtype=torch.float32)
+
+ cos_theta = torch.cos(theta)
+ sin_theta = torch.sin(theta)
+
+ # Use torch.stack and torch.cat to construct the rotation matrix
+ row1 = torch.stack([torch.ones_like(theta), torch.zeros_like(theta), torch.zeros_like(theta)])
+ row2 = torch.stack([torch.zeros_like(theta), cos_theta, -sin_theta])
+ row3 = torch.stack([torch.zeros_like(theta), sin_theta, cos_theta])
+
+ # Concatenate the rows to form the rotation matrix
+ r = torch.stack([row1, row2, row3], dim=0)
+
+ # Transpose the matrix to match the expected shape
+ r = r.transpose(0, 1)
+
+ return r
diff --git a/simca/OpticalModelTorch.py b/simca/OpticalModelTorch.py
deleted file mode 100644
index 79256c1..0000000
--- a/simca/OpticalModelTorch.py
+++ /dev/null
@@ -1,944 +0,0 @@
-import torch
-import snoop
-
-
-def rotation_z_torch(theta):
- """
- Rotate 3D matrix around the Z axis using PyTorch
-
- Args:
- theta (torch.Tensor): Input angle (in rad)
-
- Returns:
- torch.Tensor: 3D rotation matrix
- """
- # Ensure theta is a tensor with requires_grad=True
- if not isinstance(theta, torch.Tensor):
- theta = torch.tensor(theta, requires_grad=True)
-
- cos_theta = torch.cos(theta)
- sin_theta = torch.sin(theta)
-
- # Construct the rotation matrix using torch.stack to support gradient computation
- # For rotation around the Z axis, the changes affect the first two rows
- row1 = torch.stack([cos_theta, -sin_theta, torch.zeros_like(theta)])
- row2 = torch.stack([sin_theta, cos_theta, torch.zeros_like(theta)])
- row3 = torch.stack([torch.zeros_like(theta), torch.zeros_like(theta), torch.ones_like(theta)])
-
- # Concatenate the rows to form the rotation matrix
- r = torch.stack([row1, row2, row3], dim=0)
-
- # Adjust the matrix to have the correct shape (3, 3) for each theta
- r = r.transpose(0, 1) # This may need adjustment based on how you intend to use r
-
- return r
-
-
-def rotation_y_torch(theta):
- """
- Rotate 3D matrix around the Y axis using PyTorch
-
- Args:
- theta (torch.Tensor): Input angle (in rad)
-
- Returns:
- torch.Tensor: 3D rotation matrix
- """
- # Ensure theta is a tensor with requires_grad=True
- if not isinstance(theta, torch.Tensor):
- theta = torch.tensor(theta, requires_grad=True, dtype=torch.float32)
-
- cos_theta = torch.cos(theta)
- sin_theta = torch.sin(theta)
-
- # Construct the rotation matrix using torch.stack to support gradient computation
- # For rotation around the Y axis, the changes affect the first and third rows
- row1 = torch.stack([cos_theta, torch.zeros_like(theta), -sin_theta]) # Note the change to -sin_theta for correct Y-axis rotation
- row2 = torch.stack([torch.zeros_like(theta), torch.ones_like(theta), torch.zeros_like(theta)])
- row3 = torch.stack([sin_theta, torch.zeros_like(theta), cos_theta])
-
- # Concatenate the rows to form the rotation matrix
- r = torch.stack([row1, row2, row3], dim=0)
-
- # Adjust the matrix to have the correct shape (3, 3) for each theta
- r = r.transpose(0, 1) # Adjust transpose for consistency with your requirements
-
- return r
-
-
-def rotation_x_torch(theta):
- """
- Rotate 3D matrix around the X axis using PyTorch
-
- Args:
- theta (tensor): Input angle (in rad)
-
- Returns:
- torch.Tensor: 3D rotation matrix
- """
- # Ensure theta is a tensor with requires_grad=True
- if not isinstance(theta, torch.Tensor):
- theta = torch.tensor(theta, requires_grad=True, dtype=torch.float32)
-
- cos_theta = torch.cos(theta)
- sin_theta = torch.sin(theta)
-
- # Use torch.stack and torch.cat to construct the rotation matrix
- row1 = torch.stack([torch.ones_like(theta), torch.zeros_like(theta), torch.zeros_like(theta)])
- row2 = torch.stack([torch.zeros_like(theta), cos_theta, -sin_theta])
- row3 = torch.stack([torch.zeros_like(theta), sin_theta, cos_theta])
-
- # Concatenate the rows to form the rotation matrix
- r = torch.stack([row1, row2, row3], dim=0)
-
- # Transpose the matrix to match the expected shape
- r = r.transpose(0, 1)
-
- return r
-
-from simca.functions_general_purpose import *
-# import snoop
-import torch
-from opticalglass.glassfactory import create_glass
-import pytorch_lightning as pl
-
-class OpticalModelTorch(pl.LightningModule):
- """
- Class that contains the optical model caracteristics and propagation models
- """
- def __init__(self, config):
- super().__init__()
- self.system_config = config
- self.dispersive_element_type = config["system architecture"]["dispersive element"]["type"]
- self.lba_c = torch.tensor(config["system architecture"]["dispersive element"]["wavelength center"])
-
- # Can be optimized
- # 1 - with DE
- self.glass1 = create_glass(config["system architecture"]["dispersive element"]["glass1"], 'Schott')
- self.glass2 = create_glass(config["system architecture"]["dispersive element"]["glass2"], 'Schott')
- self.glass3 = create_glass(config["system architecture"]["dispersive element"]["glass3"], 'Schott')
-
- # - with any optimizer
- self.A1 = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A1"]),requires_grad=True)
- self.A2 = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A2"]),requires_grad=True)
- self.A3 = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["A3"]),requires_grad=True)
- self.F = torch.tensor(config["system architecture"]["focal lens"])
-
-
- self.G = torch.tensor(config["system architecture"]["dispersive element"]["G"])
- self.m = torch.tensor(config["system architecture"]["dispersive element"]["m"])
-
- self.alpha_c = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["alpha_c"]),requires_grad=True)
- self.delta_alpha_c = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["delta alpha c"]))
- self.delta_beta_c = torch.tensor(math.radians(config["system architecture"]["dispersive element"]["delta beta c"]))
-
- self.continuous_glass_materials1 = config["system architecture"]["dispersive element"]["continuous glass materials 1"]
- self.continuous_glass_materials2 = config["system architecture"]["dispersive element"]["continuous glass materials 2"]
- self.continuous_glass_materials3 = config["system architecture"]["dispersive element"]["continuous glass materials 3"]
-
- self.nd1 = torch.tensor(config["system architecture"]["dispersive element"]["nd1"],requires_grad=True)
- self.vd1 = torch.tensor(config["system architecture"]["dispersive element"]["vd1"],requires_grad=True)
- self.nd2 = torch.tensor(config["system architecture"]["dispersive element"]["nd2"],requires_grad=True)
- self.vd2 = torch.tensor(config["system architecture"]["dispersive element"]["vd2"],requires_grad=True)
- self.nd3 = torch.tensor(config["system architecture"]["dispersive element"]["nd3"],requires_grad=True)
- self.vd3 = torch.tensor(config["system architecture"]["dispersive element"]["vd3"],requires_grad=True)
-
- alpha_c_transmis = -1*self.propagate_central_microm_through_disperser(self.lba_c)
- self.alpha_c_transmis = alpha_c_transmis
-
- print("Optica lmodel device : ",self.device)
-
-
-
- def rerun_central_dispersion(self):
- alpha_c_transmis = -1 * self.propagate_central_microm_through_disperser(self.lba_c)
- self.alpha_c_transmis = alpha_c_transmis
-
- return alpha_c_transmis
-
- def propagate(self,X,Y,lba,n1,n2,n3):
-
- k = self.model_Lens_pos_to_angle(X, Y, self.F)
-
-
- if self.dispersive_element_type == "prism":
- alpha_1 = self.A1 - self.A1/2
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k, list_theta_in, list_theta_out = self.propagate_through_simple_prism(k,n1,self.A1)
- k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c_transmis,self.delta_alpha_c,self.delta_beta_c,alpha_1)
-
- elif self.dispersive_element_type == "doubleprism":
- alpha_1 = self.A1 - self.A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k, list_theta_in, list_theta_out = self.propagate_through_double_prism(k,n1,n2,self.A1,self.A2)
- k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c_transmis,self.delta_alpha_c,self.delta_beta_c,alpha_1)
-
- elif self.dispersive_element_type == "tripleprism":
- alpha_1 = self.A1 - self.A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k, list_theta_in, list_theta_out = self.propagate_through_triple_prism(k,n1,n2,n3,self.A1,self.A2,self.A3)
- k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c_transmis,self.delta_alpha_c,self.delta_beta_c,alpha_1)
-
- elif self.dispersive_element_type == "grating":
- alpha_1 = 0
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k = self.model_Grating_angle_to_angle(k, lba, self.m, self.G)
- k = self.rotate_from_dispersive_element_to_lens(k,self.alpha_c_transmis,self.delta_alpha_c,self.delta_beta_c,alpha_1)
-
- # print(k)
- X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k, self.F)
-
- return X_vec_out, Y_vec_out
-
- def calculate_dispersion_with_cauchy(self,lambda_vec, nD, V):
- lambda_vec = lambda_vec * 1e-9 # Convert nm to meters for calculation
- lambda_D = 589.3e-9 # D line wavelength in meters
- lambda_F = 486.1e-9 # F line wavelength in meters
- lambda_C = 656.3e-9 # C line wavelength in meters
-
- # Calculate B using the given formula
- B = (nD - 1) / (V * (1 / lambda_F ** 2 - 1 / lambda_C ** 2))
-
- # Calculate A using the given formula
- A = nD - B / lambda_D ** 2
-
- # Calculate n for each wavelength in lambda_vec
- n = A + B / lambda_vec ** 2 # Note: lambda_vec is already in meters
-
- return n
-
- def rotate_from_lens_to_dispersive_element(self,k,alpha_c,delta_alpha_c,delta_beta_c,alpha_1):
-
-
- angle_with_P1 = alpha_c - alpha_1 + delta_alpha_c
- k = k.to(dtype=torch.float32)
- # k_1 = rotation_y_torch(angle_with_P1) @ k
- k = torch.matmul(k,rotation_y_torch(angle_with_P1).T)
- # Rotation in relation to P1 around the X axis
- k = k.to(dtype=torch.float32)
- k = torch.matmul(k,rotation_x_torch(delta_beta_c).T)
- # Rotation of P1 in relation to frame_in along the new Y axis
- k = k.to(dtype=torch.float32)
-
- k = torch.matmul(k,rotation_y_torch(alpha_1).T)
-
-
-
- return k
-
- def rotate_from_dispersive_element_to_lens(self,k,alpha_c_transmis,delta_alpha_c,delta_beta_c,alpha_1):
-
- angle_with_P2 = alpha_c_transmis - alpha_1 - delta_alpha_c
- k = torch.matmul(k,rotation_y_torch(alpha_1).T)
- # Rotation in relation to P2 around the X axis
- k = torch.matmul(k,rotation_x_torch(-delta_beta_c).T)
- # Rotation in relation to P2 around the Y axis
- k = torch.matmul(k,rotation_y_torch(angle_with_P2).T)
- #print(k.shape)
- return k
-
- def propagate_through_simple_prism(self, k, n, A):
- norm_k = torch.sqrt(k[..., 0] ** 2 + k[..., 1] ** 2 + k[..., 2] ** 2)
- norm_k = norm_k.unsqueeze(-1)
- norm_k = norm_k.repeat(1, 1, 1, 3)
- # Use out-of-place operation instead of in-place
- k_normalized = k / norm_k
-
- k_updated, theta_in, theta_out,distance_from_total_intern_reflection = self.model_Prism_angle_to_angle_torch(k_normalized, n, A)
- # Apply the normalization factor to k_updated if necessary
- k_updated = k_updated * norm_k
-
- list_theta_in = [theta_in]
- list_theta_out = [theta_out]
-
- return k_updated, list_theta_in, list_theta_out
-
- def propagate_through_double_prism(self,k,n1,n2,A1,A2):
-
- norm_k = torch.sqrt(k[...,0] ** 2 + k[...,1] ** 2 + k[...,2] ** 2)
- norm_k = norm_k.unsqueeze(-1)
- norm_k = norm_k.repeat(1, 1, 1,3)
- k_normalized = k / norm_k
-
- k,theta_in_1, theta_out_1,distance_from_total_intern_reflection = self.model_Prism_angle_to_angle_torch(k_normalized, n1, A1)
- k = k * norm_k
- k = torch.matmul(k,rotation_z_torch(torch.tensor(np.pi)).T)
- k,theta_in_2, theta_out_2,distance_from_total_intern_reflection = self.model_Prism_angle_to_angle_torch(k, n2, A2)
- k = k * norm_k
- k = torch.matmul(k, rotation_z_torch(torch.tensor(np.pi)).T)
-
- list_theta_in = [theta_in_1,theta_in_2]
- list_theta_out = [theta_out_1,theta_out_2]
-
- return k,list_theta_in, list_theta_out
-
-
-
- def propagate_through_triple_prism(self,k,n1,n2,n3,A1,A2,A3):
-
- norm_k = torch.sqrt(k[...,0] ** 2 + k[...,1] ** 2 + k[...,2] ** 2)
- norm_k = norm_k.unsqueeze(-1)
- norm_k = norm_k.repeat(1, 1, 1,3)
- k_normalized = k / norm_k
-
-
- k,theta_in_1, theta_out_1,distance_from_total_intern_reflection1 = self.model_Prism_angle_to_angle_torch(k_normalized, n1, A1)
- k = k * norm_k
- k = torch.matmul(k,rotation_z_torch(torch.tensor(np.pi)).T)
- k,theta_in_2, theta_out_2,distance_from_total_intern_reflection2 = self.model_Prism_angle_to_angle_torch(k, n2, A2)
- k = k * norm_k
- k = torch.matmul(k,rotation_z_torch(torch.tensor(np.pi)).T)
- k,theta_in_3, theta_out_3,distance_from_total_intern_reflection3 = self.model_Prism_angle_to_angle_torch(k, n3, A3)
- k = k * norm_k
-
- list_theta_in = [theta_in_1,theta_in_2,theta_in_3]
- list_theta_out = [theta_out_1,theta_out_2,theta_out_3]
-
- self.min_distance_from_total_intern_reflection = min(torch.min(distance_from_total_intern_reflection1),
- torch.min(distance_from_total_intern_reflection2),
- torch.min(distance_from_total_intern_reflection3))
-
- return k, list_theta_in, list_theta_out
-
-
-
- def propagation_with_distorsions_torch(self, X_input_grid, Y_input_grid):
- """
- Propagate the coded aperture coded_aperture through one CASSI system
-
- Args:
- X_input_grid (numpy.ndarray): x coordinates grid
- Y_input_grid (numpy.ndarray): y coordinates grid
-
- Returns:
- tuple: X coordinates of the propagated coded aperture grids, Y coordinates of the propagated coded aperture grids
- """
-
- self.calculate_central_dispersion()
-
- X_input_grid = torch.from_numpy(X_input_grid) if isinstance(X_input_grid, np.ndarray) else X_input_grid
- Y_input_grid = torch.from_numpy(Y_input_grid) if isinstance(Y_input_grid, np.ndarray) else Y_input_grid
- wavelength_vec = torch.from_numpy(self.system_wavelengths) if isinstance(self.system_wavelengths, np.ndarray) else self.system_wavelengths
-
- X_input_grid_3D = X_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples)
- Y_input_grid_3D = Y_input_grid[:,:,None].repeat(1, 1,self.nb_of_spectral_samples)
- lba_3D = wavelength_vec[None,None,:].repeat(X_input_grid.shape[0], X_input_grid.shape[1],1)
- n_tensor = self.sellmeier_torch(lba_3D)
-
- X, Y = self.propagate_through_arm_torch(X_input_grid_3D,Y_input_grid_3D,n=n_tensor,lba=lba_3D)
-
- return X, Y
-
- def calculate_central_dispersion(self):
- """
- Calculate the dispersion related to the central pixel of the coded aperture
-
- Returns:
- numpy.float: spectral dispersion of the central pixel of the coded aperture
- """
-
- self.alpha_c = self.calculate_alpha_c()
-
- X0_coordinates_array_flatten = np.zeros(self.system_wavelengths.shape[0])
- Y0_coordinates_array_flatten = np.zeros(self.system_wavelengths.shape[0])
- lba_array_flatten = self.system_wavelengths
-
- n_array_flatten = np.full(lba_array_flatten.shape, self.sellmeier(lba_array_flatten))
-
- X0_propagated, Y0_propagated = self.propagate_through_arm(X_vec_in=X0_coordinates_array_flatten,Y_vec_in=Y0_coordinates_array_flatten,n=n_array_flatten,lba=lba_array_flatten)
-
- self.X0_propagated, self.Y0_propagated = X0_propagated, Y0_propagated
-
- self.central_distorsion_in_X = np.abs(self.X0_propagated[-1] - self.X0_propagated[0])
-
- return self.central_distorsion_in_X
-
- def propagate_through_arm(self, X_vec_in, Y_vec_in, n, lba):
-
- """
- Propagate the light through one system arm : (lens + dispersive element + lens)
-
- Args:
- X_vec_in (numpy.ndarray) : X coordinates of the coded aperture pixels (1D array)
- Y_vec_in (numpy.ndarray) : Y coordinates of the coded aperture pixels (1D array)
- n (numpy.ndarray) : refractive indexes of the system (at the corresponding wavelength)
- lba (numpy.ndarray) : wavelengths
-
- Returns:
- tuple: flatten arrays corresponding to the propagated X and Y coordinates
- """
-
- dispersive_element_type = self.dispersive_element_type
- A = self.A
- G = self.G
- m = self.m
- F = self.F
- delta_alpha_c = self.delta_alpha_c
- delta_beta_c = self.delta_beta_c
- alpha_c = self.alpha_c
- alpha_c_transmis = self.alpha_c_transmis
-
-
- if dispersive_element_type == "prism":
-
- angle_with_P1 = alpha_c - A / 2 + delta_alpha_c
- angle_with_P2 = alpha_c_transmis - A / 2 - delta_alpha_c
-
- k = self.model_Lens_pos_to_angle(X_vec_in, Y_vec_in, F)
- # Rotation in relation to P1 around the Y axis
-
- k_1 = rotation_y(angle_with_P1) @ k[:, 0, :]
- # Rotation in relation to P1 around the X axis
- k_2 = rotation_x(delta_beta_c) @ k_1
- # Rotation of P1 in relation to frame_in along the new Y axis
- k_3 = rotation_y(A / 2) @ k_2
-
- norm_k = np.sqrt(k_3[0] ** 2 + k_3[1] ** 2 + k_3[2] ** 2)
- k_3 /= norm_k
-
- k_out_p = self.model_Prism_angle_to_angle(k_3, n, A)
- k_out_p = k_out_p * norm_k
-
- k_3_bis = np.dot(rotation_y(A / 2), k_out_p)
-
- # Rotation in relation to P2 around the X axis
- k_2_bis = np.dot(rotation_x(-delta_beta_c), k_3_bis)
- # Rotation in relation to P2 around the Y axis
- k_1_bis = np.dot(rotation_y(angle_with_P2), k_2_bis)
-
- X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k_1_bis, F)
-
-
- elif dispersive_element_type == "grating":
-
- angle_with_P1 = alpha_c - delta_alpha_c
- angle_with_P2 = alpha_c_transmis + delta_alpha_c
-
- k = self.model_Lens_pos_to_angle(X_vec_in, Y_vec_in, F)
- # Rotation in relation to P1 around the Y axis
-
- k_1 = rotation_y(angle_with_P1) @ k[:, 0, :]
- # Rotation in relation to P1 around the X axis
- k_2 = rotation_x(delta_beta_c) @ k_1
-
- k_3 = rotation_y(0) @ k_2
- norm_k = np.sqrt(k_3[0] ** 2 + k_3[1] ** 2 + k_3[2] ** 2)
- k_3 /= norm_k
-
- k_out_p = self.model_Grating_angle_to_angle(k_3, lba, m, G)
- k_out_p = k_out_p * norm_k
-
- k_3_bis = np.dot(rotation_y(0), k_out_p)
-
- # Rotation in relation to P2 around the X axis
- k_2_bis = np.dot(rotation_x(-delta_beta_c), k_3_bis)
- # Rotation in relation to P2 around the Y axis
- k_1_bis = np.dot(rotation_y(angle_with_P2), k_2_bis)
-
- X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k_1_bis, F)
-
- else:
- raise Exception("dispersive_element_type should be prism or grating")
-
- return X_vec_out, Y_vec_out
-
-
- def propagate_through_arm_torch(self, X_tensor_in, Y_tensor_in, n, lba):
-
- """
- Propagate the light through one system arm : (lens + dispersive element + lens)
-
- Args:
- X_tensor_in (torch.tensor) : X coordinates of the coded aperture pixels (3D array)
- Y_tensor_in (torch.tensor) : Y coordinates of the coded aperture pixels (3D array)
- n (torch.tensor) : refractive indexes of the system (at the corresponding wavelength)
- lba (torch.tensor) : wavelengths
-
- Returns:
- tuple: tensors corresponding to the propagated X and Y coordinates
- """
-
- dispersive_element_type = self.dispersive_element_type
- A = self.A
- G = self.G
- m = self.m
- F = self.F
- delta_alpha_c = self.delta_alpha_c
- delta_beta_c = self.delta_beta_c
- alpha_c = self.alpha_c
- alpha_c_transmis = self.alpha_c_transmis
-
- alpha_c = torch.tensor(alpha_c, dtype=torch.float64)
- A = torch.tensor(A, dtype=torch.float64)
- delta_alpha_c = torch.tensor(delta_alpha_c, dtype=torch.float64)
- alpha_c_transmis = torch.tensor(alpha_c_transmis, dtype=torch.float64)
- delta_beta_c = torch.tensor(delta_beta_c, dtype=torch.float64)
-
-
-
-
- if dispersive_element_type == "prism":
-
- angle_with_P1 = alpha_c - A / 2 + delta_alpha_c
- angle_with_P2 = alpha_c_transmis - A / 2 - delta_alpha_c
-
- # THERE IS A PROBLEM HERE ???
- k = self.model_Lens_pos_to_angle_torch(X_tensor_in, Y_tensor_in, F)
- # Rotation in relation to P1 around the Y axis
-
- # k_1 = rotation_y_torch(angle_with_P1) @ k
- k_1 = torch.matmul(k,rotation_y_torch(angle_with_P1).T)
- # Rotation in relation to P1 around the X axis
- k_2 = torch.matmul(k_1,rotation_x_torch(delta_beta_c).T)
- # Rotation of P1 in relation to frame_in along the new Y axis
- k_3 = torch.matmul(k_2,rotation_y_torch(A / 2).T)
-
- norm_k = torch.sqrt(k_3[...,0] ** 2 + k_3[...,1] ** 2 + k_3[...,2] ** 2)
- norm_k = norm_k.unsqueeze(-1)
- norm_k = norm_k.repeat(1, 1, 1,3)
- k_3 /= norm_k
-
- k_out_p = self.model_Prism_angle_to_angle_torch(k_3, n, A)
- k_out_p = k_out_p * norm_k
-
- k_3_bis = torch.matmul(k_out_p,rotation_y_torch(A / 2).T)
-
- # Rotation in relation to P2 around the X axis
- k_2_bis = torch.matmul(k_3_bis,rotation_x_torch(-delta_beta_c).T)
- # Rotation in relation to P2 around the Y axis
- k_1_bis = torch.matmul(k_2_bis,rotation_y_torch(angle_with_P2).T)
-
- X_vec_out, Y_vec_out = self.model_Lens_angle_to_position_torch(k_1_bis, F)
-
-
- # elif dispersive_element_type == "grating":
- #
- # angle_with_P1 = alpha_c - delta_alpha_c
- # angle_with_P2 = alpha_c_transmis + delta_alpha_c
- #
- # k = self.model_Lens_pos_to_angle(X_vec_in, Y_vec_in, F)
- # # Rotation in relation to P1 around the Y axis
- #
- # k_1 = rotation_y(angle_with_P1) @ k[:, 0, :]
- # # Rotation in relation to P1 around the X axis
- # k_2 = rotation_x(delta_beta_c) @ k_1
- #
- # k_3 = rotation_y(0) @ k_2
- # norm_k = np.sqrt(k_3[0] ** 2 + k_3[1] ** 2 + k_3[2] ** 2)
- # k_3 /= norm_k
- #
- # k_out_p = self.model_Grating_angle_to_angle(k_3, lba, m, G)
- # k_out_p = k_out_p * norm_k
- #
- # k_3_bis = np.dot(rotation_y(0), k_out_p)
- #
- # # Rotation in relation to P2 around the X axis
- # k_2_bis = np.dot(rotation_x(-delta_beta_c), k_3_bis)
- # # Rotation in relation to P2 around the Y axis
- # k_1_bis = np.dot(rotation_y(angle_with_P2), k_2_bis)
- #
- # X_vec_out, Y_vec_out = self.model_Lens_angle_to_position(k_1_bis, F)
- #
- # else:
- # raise Exception("dispersive_element_type should be prism or grating")
- #
- return X_vec_out, Y_vec_out
-
- def model_Grating_angle_to_angle(self,k_in, lba, m, G):
- """
- Model of the grating
-
- Args:
- k_in (numpy.ndarray) : wave vector of the incident ray (shape = 3 x N)
- lba (numpy.ndarray) : wavelengths (shape = N) -- in nm
- m (float) : diffraction order of the grating -- no units
- G (float) : lines density of the grating -- in lines/mm
-
- Returns:
- numpy.ndarray: wave vector of the outgoing ray (shape = 3 x N)
-
- """
-
- alpha_in = np.arctan(k_in[0]) * np.sqrt(1 + np.tan(k_in[0])**2 + np.tan(k_in[1])**2)
- beta_in = np.arctan(k_in[1]) * np.sqrt(1 + np.tan(k_in[0])**2 + np.tan(k_in[1])**2)
-
- alpha_out = -1*np.arcsin(m * lba*10**-9 * G * 10**3 - np.sin(alpha_in))
- beta_out = beta_in
-
-
- k_out = [np.sin(alpha_out) * np.cos(beta_out),
- np.sin(beta_out)*np.cos(alpha_out),
- np.cos(alpha_out) * np.cos(beta_out)]
-
- return k_out
-
- def simplified_grating_in_out(self, alpha,lba,m,G):
- """
- Model 1D of the grating in the dispersion direction
-
- Args:
- alpha (numpy.ndarray or float) : angle of the incident ray (shape = N) -- in radians
- lba (numpy.ndarray or float) : wavelengths (shape = N) -- in nm
- m (float) : diffraction order of the grating -- no units
- G (float) : lines density of the grating -- in lines/mm
-
- Returns:
- numpy.ndarray: angle of the outgoing ray (shape = N) -- in radians
-
- """
-
- alpha_out = np.arcsin(m * lba * 10 ** -9 * G * 10 ** 3 - np.sin(alpha))
-
- return alpha_out
-
- def model_Lens_angle_to_position(self,k_in,F):
- """
- Model of the lens : angle to position
-
- Args:
- k_in (torch.tensor) : wave vector of the incident ray (shape = 3 x N)
- F (float) : focal length of the lens -- in um
-
- Returns:
- tuple: position in the image plane (X,Y) -- in um
-
- """
-
- alpha = torch.arctan(k_in[...,0] / k_in[...,2])
- beta = torch.arctan(k_in[...,1] / k_in[...,2])
-
- x = F * torch.tan(alpha)
- y = F * torch.tan(beta)
-
- return x, y
-
- def model_Prism_angle_to_angle(self,k0, n,A):
- """
- Ray tracing through the prism
-
- Args:
- k0 (numpy.ndarray) : wave vector of the incident ray (shape = 3 x N)
- n (numpy.ndarray) : refractive index of the prism (shape = N)
- A (float) : angle of the prism -- in radians
-
- Returns:
- numpy.ndarray: wave vector of the outgoing ray (shape = 3 x N)
-
- """
-
- kp = np.array([k0[0], k0[1], np.sqrt(n ** 2 - k0[0] ** 2 - k0[1] ** 2)])
-
- kp_r = np.matmul(rotation_y(-A), kp)
-
- kout = [kp_r[0], kp_r[1], np.sqrt(1 - kp_r[0] ** 2 - kp_r[1] ** 2)]
-
- return kout
-
-
- def model_Prism_angle_to_angle_torch(self,k0, n,A):
- """
- Ray tracing through the prism
-
- Args:
- k0 (torch.tensor) : wave vector of the incident ray
- n (torch.tensor) : refractive index of the prism
- A (float) : angle of the prism -- in radians
-
- Returns:
- torch.tensor: wave vector of the outgoing ray
-
- """
- kp = torch.zeros_like(k0,device=k0.device)
- kout = torch.zeros_like(k0,device=k0.device)
-
- theta_in = torch.atan2(k0[...,0], k0[...,2])
-
- kp[...,0] = k0[...,0]
- kp[...,1] = k0[...,1]
-
- # compare = n ** 2 - k0[...,0] ** 2 - k0[...,1] ** 2
-
-
- kp[...,2] = torch.sqrt(n ** 2 - k0[...,0] ** 2 - k0[...,1] ** 2)
-
- theta_out = torch.atan2(kp[...,0], kp[...,2])
-
- kp_r = torch.matmul(kp, rotation_y_torch(-A).T)
-
- kout[...,0] = kp_r[...,0]
- kout[...,1] = kp_r[...,1]
- kout[...,2] = torch.sqrt(1 - kp_r[...,0] ** 2 - kp_r[...,1] ** 2)
-
- distance_from_total_intern_reflection = 1 - kp_r[...,0] ** 2 - kp_r[...,1] ** 2
-
- return kout, theta_in, theta_out,distance_from_total_intern_reflection
-
- def model_Lens_pos_to_angle(self,x_obj, y_obj, F):
- """
- Model of the lens : position to angle
-
- Args:
- x_obj (torch.tensor) : position X in the image plane -- in um
- y_obj (torch.tensor) : position Y in the image plane -- in um
- F (torch.tensor) : focal length of the lens -- in um
-
- Returns:
- torch.tensor: wave vector of the outgoing ray
-
- """
-
- alpha = -1 * torch.atan(x_obj / F)
- beta = -1 * torch.atan(y_obj / F)
-
- # Adjusting the dimension for k_out to make it a 4D tensor
- k_out = torch.zeros(size=(x_obj.shape[0], x_obj.shape[1], x_obj.shape[2], 3),dtype=torch.float64,device=x_obj.device)
-
- # the fourth dimension should have 3 components
- k_out[...,0] = torch.sin(alpha) * torch.cos(beta)
- k_out[...,1] = torch.sin(beta) * torch.cos(alpha)
- k_out[...,2] = torch.cos(alpha) * torch.cos(beta)
-
- # k_out = torch.cat([
- # sin_alpha * cos_beta,
- # sin_beta * cos_alpha,
- # cos_alpha * cos_beta
- # ], dim=-1)
-
- return k_out
-
- def calculate_alpha_c(self):
- """
- Calculate the relative angle of incidence between the lenses and the dispersive element
-
- Returns:
- float: angle of incidence
- """
- if self.dispersive_element_type == "prism":
- self.Dm = self.calculate_minimum_deviation(self.sellmeier(self.lba_c), self.A)
- self.alpha_c = self.get_incident_angle_min_dev(self.A,self.Dm)
- self.alpha_c_transmis = self.alpha_c
-
- if self.dispersive_element_type == "grating":
- self.alpha_c = 0
- self.alpha_c_transmis = self.simplified_grating_in_out(self.alpha_c,self.lba_c,self.m,self.G)
-
- return self.alpha_c
-
-
- def calculate_minimum_deviation(self,n, A):
- """
- minimum deviation angle of a prism of index n and apex angle A
-
- Args:
- n (float or numpy.ndarray): index of the prism -- no units
- A (float): apex angle of the prism -- in radians
-
- Returns:
- float or numpy.ndarray: minimum deviation angle -- in radians
- """
- return 2 * np.arcsin(n * np.sin(A / 2)) - A
-
- def get_incident_angle_min_dev(self,A, D_m):
- """
- Calculate the angle of incidence corresponding to the minimum deviation angle
-
- Args:
- A (float): apex angle of the prism -- in radians
- D_m (float): minimum deviation angle -- in radians
-
- Returns:
- float: angle of incidence corresponding to minimum of deviation -- in radians
- """
- return (A + D_m) / 2
-
-
- def sellmeier(self,lambda_, glass_type="BK7"):
- """
- Evaluating the refractive index value of a prism for a given lambda based on Sellmeier equation
-
- Args:
- lambda_ (numpy.ndarray of float) : wavelength in nm
-
- Returns:
- numpy.ndarray of float: index value corresponding to the input wavelength
-
- """
-
- if glass_type == "BK7":
- B1 = 1.03961212
- B2 = 0.231792344
- B3 = 1.01046945
- C1 = 6.00069867 * (10 ** -3)
- C2 = 2.00179144 * (10 ** -2)
- C3 = 1.03560653 * (10 ** 2)
-
- else :
- raise Exception("glass_type is Unknown")
-
- lambda_in_mm = lambda_ / 1000
-
- n = np.sqrt(1 + B1 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C1) + B2 * lambda_in_mm ** 2 / (
- lambda_in_mm ** 2 - C2) + B3 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C3))
-
- return n
-
- def sellmeier_torch(self,lambda_, glass_type="BK7"):
- """
- Evaluating the refractive index value of a prism for a given lambda based on Sellmeier equation
-
- Args:
- lambda_ (numpy.ndarray of float) : wavelength in nm
-
- Returns:
- numpy.ndarray of float: index value corresponding to the input wavelength
-
- """
-
- if glass_type == "BK7":
- B1 = 1.03961212
- B2 = 0.231792344
- B3 = 1.01046945
- C1 = 6.00069867 * (10 ** -3)
- C2 = 2.00179144 * (10 ** -2)
- C3 = 1.03560653 * (10 ** 2)
-
- else :
- raise Exception("glass_type is Unknown")
-
- lambda_in_mm = lambda_ / 1000
-
- n = torch.sqrt(1 + B1 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C1) + B2 * lambda_in_mm ** 2 / (
- lambda_in_mm ** 2 - C2) + B3 * lambda_in_mm ** 2 / (lambda_in_mm ** 2 - C3))
-
- return n
-
- def generate_2D_gaussian(self,radius, sample_size_x, sample_size_y, nb_of_samples):
- """
- Generate a 2D Gaussian of a given radius
-
- Args:
- radius (float): radius of the Gaussian
- sample_size_x (float): size of each sample along the X axis
- sample_size_y (float): size of each sample along the Y axis
- nb_of_samples (int): number of samples along each axis
-
- Returns:
- numpy.ndarray: 2D Gaussian shape array
- """
-
- # Define the grid
- grid_size_x = sample_size_x * (nb_of_samples - 1)
- grid_size_y = sample_size_y * (nb_of_samples - 1)
- x = np.linspace(-grid_size_x / 2, grid_size_x / 2, nb_of_samples)
- y = np.linspace(-grid_size_y / 2, grid_size_y / 2, nb_of_samples)
- X, Y = np.meshgrid(x, y)
-
- # Compute the 2D Gaussian function
- gaussian_2d = np.exp(-(X ** 2 + Y ** 2) / (2 * radius ** 2))
-
- return gaussian_2d
-
- def generate_psf(self, type, radius):
- """
- Generate a PSF
-
- Args:
- type (str): type of PSF to generate
- radius (float): radius of the PSF
-
- Returns:
- numpy.ndarray: PSF generated (shape = R x C)
- """
-
- if type == "Gaussian":
- PSF = self.generate_2D_gaussian(radius, self.system_config["detector"]["pixel size along X"],
- self.system_config["detector"]["pixel size along Y"], 10)
- self.psf = PSF
-
- return self.psf
-
- def check_if_sampling_is_sufficiant(self):
- """
- Check if the sampling is sufficiant to avoid aliasing.
-
- Returns:
- float: number of sample points per pixel
-
- """
-
- pix_size = self.system_config["detector"]["pixel size along X"]
- nb_of_system_wavelengths = self.system_wavelengths.shape[0]
-
- nb_of_sample_points_per_pix = pix_size / (self.central_distorsion_in_X / nb_of_system_wavelengths )
- print("number of spectral sample points per pixel =",nb_of_sample_points_per_pix)
-
- if nb_of_sample_points_per_pix < 2:
-
- print("The 'number of spectral samples' (cf. system config) is not sufficiant to avoid weird sampling effect( aliasing ?). RAISE IT !")
-
- return nb_of_sample_points_per_pix
-
-
- def propagate_central_microm_through_disperser(self,lambda_):
-
- if self.continuous_glass_materials1:
- n1 = self.calculate_dispersion_with_cauchy(lambda_,self.nd1,self.vd1)
- else:
- n1 = self.glass1.calc_rindex(lambda_)
- if self.continuous_glass_materials2:
- n2 = self.calculate_dispersion_with_cauchy(lambda_,self.nd2,self.vd2)
- else:
- n2 = self.glass2.calc_rindex(lambda_)
- if self.continuous_glass_materials3:
- n3 = self.calculate_dispersion_with_cauchy(lambda_,self.nd3,self.vd3)
- else:
- n3 = self.glass3.calc_rindex(lambda_)
-
- # n1 = 1.5
- # n2 = 1.8
- # n3 = 1.5
-
- x0 = torch.zeros((1,1,1,1))
- y0 = torch.zeros((1,1,1,1))
-
- k = self.model_Lens_pos_to_angle(x0, y0, self.F)
-
- # torch.autograd.set_detect_anomaly(True)
-
- if self.dispersive_element_type == "prism":
-
- alpha_1 = self.A1 - self.A1/2
- # alpha_1.backward(retain_graph=True) # This requires alpha_1 to be a scalar
- # print("A1 requires grd",self.A1.grad)
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- # k.backward(torch.ones_like(k), retain_graph=True)
- # print("A1 requires grd", self.A1.grad)
- k, list_theta_in, list_theta_out = self.propagate_through_simple_prism(k,n1,self.A1)
- # k.backward(torch.ones_like(k), retain_graph=True)
- # print("A1 requires grd", self.A1.grad)
-
- elif self.dispersive_element_type == "doubleprism":
- alpha_1 = self.A1 - self.A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k, list_theta_in, list_theta_out = self.propagate_through_double_prism(k,n1,n2,self.A1,self.A2)
-
- elif self.dispersive_element_type == "tripleprism":
- alpha_1 = self.A1 - self.A2/2
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k, list_theta_in, list_theta_out = self.propagate_through_triple_prism(k,n1,n2,n3,self.A1,self.A2,self.A3)
-
- elif self.dispersive_element_type == "grating":
- alpha_1 = 0
- k = self.rotate_from_lens_to_dispersive_element(k,self.alpha_c,self.delta_alpha_c,self.delta_beta_c,alpha_1)
- k = self.model_Grating_angle_to_angle(k, lambda_, self.m, self.G)
-
- alpha = torch.arctan(k[...,0] / k[...,2])
- beta = torch.arctan(k[...,1] / k[...,2])
- #
- # alpha.backward(retain_graph=True) # This requires alpha_1 to be a scalar
- # print("A1 requires grd", self.A1.grad)
-
- self.list_theta_in = list_theta_in
- self.list_theta_out = list_theta_out
-
- return alpha
diff --git a/simca/__init__.py b/simca/__init__.py
index 0b47a3f..d41900b 100644
--- a/simca/__init__.py
+++ b/simca/__init__.py
@@ -1 +1,3 @@
-from .CassiSystem import *
\ No newline at end of file
+from .CassiSystem import *
+from .cost_functions_optics import *
+from .helper import *
\ No newline at end of file
diff --git a/simca/configs/acquisition.yml b/simca/configs/acquisition.yml
deleted file mode 100644
index 7975f47..0000000
--- a/simca/configs/acquisition.yml
+++ /dev/null
@@ -1,8 +0,0 @@
-acquisition name : test_acquisition
-acquisition type: single acq.
-results directory: ./data/results/
-psf:
- use_psf: False
- type: Gaussian
- radius: 100
-
diff --git a/simca/configs/cassi_system.yml b/simca/configs/cassi_system.yml
deleted file mode 100644
index e7bffc2..0000000
--- a/simca/configs/cassi_system.yml
+++ /dev/null
@@ -1,34 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 201 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 253 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 55 # pixel size along X -- in um
- pixel size along Y: 55 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 400 # minimum wavelength -- in nm
- wavelength max: 600 # maximum wavelength -- in nm
- number of spectral samples: 3
diff --git a/simca/configs/cassi_system_bk7prism.yml b/simca/configs/cassi_system_bk7prism.yml
deleted file mode 100644
index f71373d..0000000
--- a/simca/configs/cassi_system_bk7prism.yml
+++ /dev/null
@@ -1,38 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 543 # central wavelength -- in nm
-detector:
- number of pixels along X: 201 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 111 # number of pixels along X axis -- no units
- number of pixels along Y: 111 # number of pixels along Y axis -- no units
- pixel size along X: 101 # pixel size along X -- in um
- pixel size along Y: 101 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 542 # minimum wavelength -- in nm
- wavelength max: 544 # maximum wavelength -- in nm
- number of spectral samples: 50
diff --git a/simca/configs/cassi_system_optim_optics.yml b/simca/configs/cassi_system_optim_optics.yml
deleted file mode 100755
index 91456d1..0000000
--- a/simca/configs/cassi_system_optim_optics.yml
+++ /dev/null
@@ -1,39 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-SF10 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 70 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 70 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 30
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 543 # central wavelength -- in nm
-detector:
- number of pixels along X: 201 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 11 # number of pixels along X axis -- no units
- number of pixels along Y: 13 # number of pixels along Y axis -- no units
- pixel size along X: 300 # pixel size along X -- in um
- pixel size along Y: 300 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 750 # maximum wavelength -- in nm
- number of spectral samples: 15
diff --git a/simca/configs/cassi_system_optim_optics_doublet.yml b/simca/configs/cassi_system_optim_optics_doublet.yml
deleted file mode 100755
index b52a749..0000000
--- a/simca/configs/cassi_system_optim_optics_doublet.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 50000
- dispersive element:
- # dispersive element caracteristics
- type: doubleprism # name of the dispersive element
- glass1: N-LAK34 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-SF66 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 40 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 20.4 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.7292
- nd2: 1.7847
- nd3: 1.55
- vd1: 54.50
- vd2: 26.09
- vd3: 54.50
- continuous glass materials 1: True
- continuous glass materials 2: True
- continuous glass materials 3: True
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 80
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 600 # central wavelength -- in nm
-detector:
- number of pixels along X: 201 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 11 # number of pixels along X axis -- no units
- number of pixels along Y: 13 # number of pixels along Y axis -- no units
- pixel size along X: 1500 # pixel size along X -- in um
- pixel size along Y: 1500 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 400 # minimum wavelength -- in nm
- wavelength max: 1100 # maximum wavelength -- in nm
- number of spectral samples: 15
diff --git a/simca/configs/cassi_system_optim_optics_full_triplet.yml b/simca/configs/cassi_system_optim_optics_full_triplet.yml
deleted file mode 100755
index c09e29a..0000000
--- a/simca/configs/cassi_system_optim_optics_full_triplet.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 50000
- dispersive element:
- # dispersive element caracteristics
- type: tripleprism # name of the dispersive element
- glass1: P-SK60 # glass type of the dispersive element (only used if type == 'prism')
- glass2: SF4 # glass type of the dispersive element (only used if type == 'prism')
- glass3: P-SK60 # glass type of the dispersive element (only used if type == 'prism')
- A1: 21.5 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 43.0 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 21.5 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.6074
- nd2: 1.7552
- nd3: 1.6074
- vd1: 56.65
- vd2: 27.58
- vd3: 56.65
- continuous glass materials 1: False
- continuous glass materials 2: False
- continuous glass materials 3: False
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 2.6
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 600 # central wavelength -- in nm
-detector:
- number of pixels along X: 145 # number of pixels along X axis -- no units
- number of pixels along Y: 901 # number of pixels along Y axis -- no units
- pixel size along X: 15 # pixel size along X -- in um
- pixel size along Y: 15 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 145 # 151 # number of pixels along X axis -- no units
- number of pixels along Y: 901 # 151 # number of pixels along Y axis -- no units
- pixel size along X: 15 # pixel size along X -- in um
- pixel size along Y: 15 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 410 # minimum wavelength -- in nm
- wavelength max: 1050 # maximum wavelength -- in nm
- number of spectral samples: 151
diff --git a/simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml b/simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml
deleted file mode 100755
index e60a715..0000000
--- a/simca/configs/cassi_system_optim_optics_full_triplet_dd_cassi.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 75000
- dispersive element:
- # dispersive element caracteristics
- type: tripleprism # name of the dispersive element
- glass1: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-SF4 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- A1: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 53.4 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.6074
- nd2: 1.7552
- nd3: 1.6074
- vd1: 56.65
- vd2: 27.58
- vd3: 56.65
- continuous glass materials 1: False
- continuous glass materials 2: False
- continuous glass materials 3: False
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 0
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 112 # number of pixels along X axis -- no units
- number of pixels along Y: 112 # number of pixels along Y axis -- no units
- pixel size along X: 70 # pixel size along X -- in um
- pixel size along Y: 70 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 131 # number of pixels along X axis -- no units
- number of pixels along Y: 131 # number of pixels along Y axis -- no units
- pixel size along X: 80 # pixel size along X -- in um
- pixel size along Y: 80 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 650 # maximum wavelength -- in nm
- number of spectral samples: 55
diff --git a/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi.yml b/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi.yml
deleted file mode 100755
index a7dedbf..0000000
--- a/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: SD-CASSI
- propagation type: simca
- focal lens: 75000
- dispersive element:
- # dispersive element caracteristics
- type: tripleprism # name of the dispersive element
- glass1: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-SF4 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- A1: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 53.4 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.6074
- nd2: 1.7552
- nd3: 1.6074
- vd1: 56.65
- vd2: 27.58
- vd3: 56.65
- continuous glass materials 1: False
- continuous glass materials 2: False
- continuous glass materials 3: False
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 0
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 112 # number of pixels along X axis -- no units
- number of pixels along Y: 112 # number of pixels along Y axis -- no units
- pixel size along X: 70 # pixel size along X -- in um
- pixel size along Y: 70 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 131 # number of pixels along X axis -- no units
- number of pixels along Y: 131 # number of pixels along Y axis -- no units
- pixel size along X: 80 # pixel size along X -- in um
- pixel size along Y: 80 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 650 # maximum wavelength -- in nm
- number of spectral samples: 55
diff --git a/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi_shifted.yml b/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi_shifted.yml
deleted file mode 100755
index 2156ab4..0000000
--- a/simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi_shifted.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: SD-CASSI
- propagation type: simca
- focal lens: 75000
- dispersive element:
- # dispersive element caracteristics
- type: tripleprism # name of the dispersive element
- glass1: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-SF4 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- A1: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 53.4 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 26.7 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.6074
- nd2: 1.7552
- nd3: 1.6074
- vd1: 56.65
- vd2: 27.58
- vd3: 56.65
- continuous glass materials 1: False
- continuous glass materials 2: False
- continuous glass materials 3: False
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 0
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 139 # number of pixels along X axis -- no units
- number of pixels along Y: 112 # number of pixels along Y axis -- no units
- pixel size along X: 70 # pixel size along X -- in um
- pixel size along Y: 70 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 112 # number of pixels along X axis -- no units
- number of pixels along Y: 112 # number of pixels along Y axis -- no units
- pixel size along X: 80 # pixel size along X -- in um
- pixel size along Y: 80 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 650 # maximum wavelength -- in nm
- number of spectral samples: 55
diff --git a/simca/configs/cassi_system_optim_optics_full_triplet_starting_point.yml b/simca/configs/cassi_system_optim_optics_full_triplet_starting_point.yml
deleted file mode 100755
index 29d9aba..0000000
--- a/simca/configs/cassi_system_optim_optics_full_triplet_starting_point.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 50000
- dispersive element:
- # dispersive element caracteristics
- type: tripleprism # name of the dispersive element
- glass1: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- glass2: SF4 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-SK2 # glass type of the dispersive element (only used if type == 'prism')
- A1: 24 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 48 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 24 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- nd1: 1.6074
- nd2: 1.7552
- nd3: 1.6074
- vd1: 56.65
- vd2: 27.58
- vd3: 56.65
- continuous glass materials 1: True
- continuous glass materials 2: True
- continuous glass materials 3: True
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 0.5
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 600 # central wavelength -- in nm
-detector:
- number of pixels along X: 201 # number of pixels along X axis -- no units
- number of pixels along Y: 201 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 11 # number of pixels along X axis -- no units
- number of pixels along Y: 13 # number of pixels along Y axis -- no units
- pixel size along X: 1000 # pixel size along X -- in um
- pixel size along Y: 1000 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 400 # minimum wavelength -- in nm
- wavelength max: 1100 # maximum wavelength -- in nm
- number of spectral samples: 15
diff --git a/simca/configs/cassi_system_simple_optim.yml b/simca/configs/cassi_system_simple_optim.yml
deleted file mode 100644
index 142a7da..0000000
--- a/simca/configs/cassi_system_simple_optim.yml
+++ /dev/null
@@ -1,39 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 100000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- alpha_c: 50
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 620 # central wavelength -- in nm
-detector:
- number of pixels along X: 145
- number of pixels along Y: 145
- pixel size along X: 240 # pixel size along X -- in um
- pixel size along Y: 240 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 145
- number of pixels along Y: 145
- pixel size along X: 320 # pixel size along X -- in um
- pixel size along Y: 320 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 700 # maximum wavelength -- in nm
- number of spectral samples: 61 #61
diff --git a/simca/configs/cassi_system_simple_optim_max_center.yml b/simca/configs/cassi_system_simple_optim_max_center.yml
deleted file mode 100644
index 9fe740a..0000000
--- a/simca/configs/cassi_system_simple_optim_max_center.yml
+++ /dev/null
@@ -1,38 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 100000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 575 # central wavelength -- in nm
-detector:
- number of pixels along X: 145 # number of pixels along X axis -- no units
- number of pixels along Y: 145 # number of pixels along Y axis -- no units
- pixel size along X: 8 # pixel size along X -- in um
- pixel size along Y: 8 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 145 # number of pixels along X axis -- no units
- number of pixels along Y: 145 # number of pixels along Y axis -- no units
- pixel size along X: 11 # pixel size along X -- in um
- pixel size along Y: 11 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 700 # maximum wavelength -- in nm
- number of spectral samples: 3
diff --git a/simca/configs/cassi_system_simple_optim_max_lighting.yml b/simca/configs/cassi_system_simple_optim_max_lighting.yml
deleted file mode 100644
index 45791c7..0000000
--- a/simca/configs/cassi_system_simple_optim_max_lighting.yml
+++ /dev/null
@@ -1,38 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 100000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 600 # central wavelength -- in nm
-detector:
- number of pixels along X: 145 # number of pixels along X axis -- no units
- number of pixels along Y: 145 # number of pixels along Y axis -- no units
- pixel size along X: 6 # pixel size along X -- in um
- pixel size along Y: 6 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 145 # number of pixels along X axis -- no units
- number of pixels along Y: 145 # number of pixels along Y axis -- no units
- pixel size along X: 12 # pixel size along X -- in um
- pixel size along Y: 12 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 400 # minimum wavelength -- in nm
- wavelength max: 800 # maximum wavelength -- in nm
- number of spectral samples: 5
diff --git a/simca/configs/cassi_system_simple_optim_smile.yml b/simca/configs/cassi_system_simple_optim_smile.yml
deleted file mode 100644
index 52b2158..0000000
--- a/simca/configs/cassi_system_simple_optim_smile.yml
+++ /dev/null
@@ -1,38 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 100000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 620 # central wavelength -- in nm
-detector:
- number of pixels along X: 400 # number of pixels along X axis -- no units
- number of pixels along Y: 401 # number of pixels along Y axis -- no units
- pixel size along X: 30 # pixel size along X -- in um
- pixel size along Y: 30 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 100 # number of pixels along X axis -- no units
- number of pixels along Y: 401 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 700 # maximum wavelength -- in nm
- number of spectral samples: 9
diff --git a/simca/configs/cassi_system_simple_optim_smile_mono.yml b/simca/configs/cassi_system_simple_optim_smile_mono.yml
deleted file mode 100644
index c5503cc..0000000
--- a/simca/configs/cassi_system_simple_optim_smile_mono.yml
+++ /dev/null
@@ -1,38 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 4000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- glass1: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass2: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- glass3: N-BK7 # glass type of the dispersive element (only used if type == 'prism')
- A1: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A2: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- A3: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 600 # central wavelength -- in nm
-detector:
- number of pixels along X: 167 # number of pixels along X axis -- no units -> dataset size /0.6
- number of pixels along Y: 100 # number of pixels along Y axis -- no units
- pixel size along X: 8 # pixel size along X -- in um
- pixel size along Y: 8 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 167 # number of pixels along X axis -- no units -> dataset size /0.6
- number of pixels along Y: 100 # number of pixels along Y axis -- no units
- pixel size along X: 11 # pixel size along X -- in um
- pixel size along Y: 11 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 500 # minimum wavelength -- in nm
- wavelength max: 700 # maximum wavelength -- in nm
- number of spectral samples: 3
diff --git a/simca/configs/cassi_system_test.yml b/simca/configs/cassi_system_test.yml
deleted file mode 100755
index f80aec6..0000000
--- a/simca/configs/cassi_system_test.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 30 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 41 # number of pixels along X axis -- no units
- number of pixels along Y: 41 # number of pixels along Y axis -- no units
- pixel size along X: 40 # pixel size along X -- in um
- pixel size along Y: 40 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 43 # number of pixels along X axis -- no units
- number of pixels along Y: 37 # number of pixels along Y axis -- no units
- pixel size along X: 55 # pixel size along X -- in um
- pixel size along Y: 55 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 400 # minimum wavelength -- in nm
- wavelength max: 600 # maximum wavelength -- in nm
- number of spectral samples: 3
diff --git a/simca/configs/dataset.yml b/simca/configs/dataset.yml
deleted file mode 100644
index 52835c7..0000000
--- a/simca/configs/dataset.yml
+++ /dev/null
@@ -1 +0,0 @@
-datasets directory: ./datasets/
diff --git a/simca/configs/pattern.yml b/simca/configs/pattern.yml
deleted file mode 100644
index 0013ea4..0000000
--- a/simca/configs/pattern.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- results directory: ./data/patterns/
-
-pattern:
- type: random
- slit position: 0
- slit width: 1
- ROM : 0.5
-
diff --git a/simca/cost_functions.py b/simca/cost_functions.py
deleted file mode 100644
index 07ac8e6..0000000
--- a/simca/cost_functions.py
+++ /dev/null
@@ -1,191 +0,0 @@
-import torch
-from matplotlib import pyplot as plt
-import math
-
-def evaluate_slit_scanning_straightness(filtering_cube, device, sigma = 0.75, pos_slit=0.5):
- """
- Evaluate the straightness of the slit scanning.
- working cost function for up to focal >100000
- """
-
- pos_cube = round(filtering_cube.shape[1]*pos_slit)
- cost_value = torch.tensor(0.0, requires_grad=True).to(device)
-
- gaussian = (torch.arange(filtering_cube.shape[1]) - pos_cube).to(device)
- gaussian = torch.exp(-torch.square(gaussian)/(2*sigma**2)).unsqueeze(0).to(device)
- gaussian = gaussian
- w = filtering_cube.shape[2]//2
- """for i in range(filtering_cube.shape[2]):
- vertical_binning = torch.sum(filtering_cube[:, :, i], axis=0)
- #max_value = torch.max(vertical_binning)
- std_deviation_vertical = torch.std(vertical_binning)
- #std_deviation_horizontal = torch.std(torch.sum(filtering_cube[:,:,i], axis=1))
- # Reward the max value and penalize based on the standard deviation
-
- # Calculate the differences between consecutive rows (vectorized)
- row_diffs = filtering_cube[1:, :, i] - filtering_cube[:-1, :, i]
- #cost_value = cost_value + max_value / std_deviation - torch.sum(torch.sum(torch.abs(row_diffs)))
- cost_value = cost_value + std_deviation_vertical - 0.2*torch.sum(torch.sum(torch.square(row_diffs))) #- 0.2*torch.sum(torch.sum(torch.abs(row_diffs)))"""
- row_diffs = filtering_cube[1:, :, w] - filtering_cube[:-1, :, w]
- cost_value = cost_value - torch.sum((torch.abs(filtering_cube[:, :, w] - gaussian)+1e-8)**0.4) + 0.6*torch.sum(filtering_cube[:, pos_cube,w]) - 0.8*torch.sum(torch.sum(torch.abs(row_diffs))) #- 2*torch.sum(torch.var(filtering_cube[:, :, 0], dim=0))
- #delta = 2
- #cost_value = cost_value - (delta**2)*torch.sum((torch.sqrt(1+((filtering_cube[:, :, 0] - gaussian)/delta)**2)-1)) # pseudo-huber loss
- # Minimizing the negative of cost_value to maximize the original objective
- return -cost_value
-
-def evaluate_center(acquisition):
- """
- Evaluate the value of the central pixel of each line
- """
- cost_value = torch.sum(acquisition[:, acquisition.shape[1]//2], axis=0)
-
- return -cost_value
-
-def evaluate_mean_lighting(acquisition):
- """
- Evaluate the mean and std values of the acquisition, maximizing mean and minimizing std
- """
- #cost_value = torch.mean(acquisition)/(torch.std(acquisition)+1e-9)
- cost_value = 2*torch.mean(acquisition) - 8*torch.std(acquisition)
-
- return -cost_value
-
-def evaluate_max_lighting(widths, acquisition, target):
- cost_value = 0
-
- #col = acquisition[:, pos_cube]
- #col = acquisition[:, pos_cube-2:pos_cube+2]
- col = acquisition[acquisition>100].flatten()
- #col = acquisition[93:208, 30].unsqueeze(1)
- """for i in range(1, 5):
- col = torch.cat((col, acquisition[93:208, 30+i*15].unsqueeze(1)), 1) """
-
- #cost_value = 2*torch.mean(col)**2 - 25*torch.var(col)
- #cost_value = - torch.var(col)
- """ cost_value = 15*torch.mean(col)**2 - 25*torch.var(col)
- cost_value = 8000*torch.mean(col)**2 - torch.sum((col-10000)**2)
- cost_value = 0.75*torch.mean(col) - torch.mean(torch.abs(col-6000))
- cost_value = torch.mean(col) - 2*torch.std(col)
-
- lines = torch.mean(acquisition, axis=1)
-
- #cost_value = - torch.var(torch.log(col))
-
- cost_value = - torch.var((torch.log(col)- torch.log(torch.tensor([40000])))**2)
- cost_value = - torch.var(torch.log(col)) - torch.log(torch.var(col))# - torch.mean((torch.log(col)- torch.log(torch.tensor([14000])))**2)
- #cost_value = - torch.var(torch.log(col)**2) - torch.var((torch.log(col)- torch.log(torch.tensor([20000])))**2)
- cost_value = - torch.var(torch.log(col)**2) - 2*torch.var((torch.log(col)- torch.log(torch.tensor([6000])))**2)
- #cost_value = - torch.sum((2000*10000*((col-2000)+(col-10000)) - (10000-2000))/2)
- #cost_value = -torch.var(torch.log(col)) """
- #cost_value = -torch.var(torch.exp(col/11000))
- row_diffs = torch.abs(widths[0,1:] - widths[0,:-1])
- #cost_value = - torch.var(torch.exp(col/18100)) - torch.sum(-torch.log(1+row_diffs))
- #print(torch.var(torch.exp(col/20000)))
- #print(torch.mean(torch.log(col)))
- #print(torch.sum(-torch.log(1+row_diffs)))
-
-
- def saturation(scene, target_, margin=0.05):
- cost = 0
- for elem in scene:
- if elem <= target_*(1+margin):
- cost += (target_-elem)
- else:
- cost += (elem-target_)**3
- return cost
-
- def bowl(scene, target_, saturation=None):
- if saturation is None:
- saturation = target_*1.2
- s = saturation
- t = target_
- cost = 0
- for x in scene:
- if x <= t:
- cost += ((t-x)/t)**2
- elif x < s:
- A = -1/((s-t)**2) + 2/(t**2)
- B = -1/(s-t) + t/((s-t)**2) - 2/t
- C = - 1/2*A*t - B*t
- cost += - math.log((s-x)/(s-t)) + 1/2*A*x**2 + B*x + C
- #cost += - math.exp(80*(1-(saturation-elem)/(saturation-target_)))
- #cost += (elem-target_)**4
- else:
- cost += 1e18*x**2
- return cost
-
- def bowl_inverse(scene, target_, saturation=None):
- if saturation is None:
- saturation = target_*1.2
- s = saturation
- t = target_
- cost = 0
- for x in scene:
- if x <= t:
- cost += ((t-x)/t)**2
- elif x < s:
- A = -2/((s-t)**3) + 2/(t**2)
- B = -1/((s-t)**2) - A*t
- C = -1/(s-t) - 1/2*A*t - B*t
- cost += - 1/(s-x) + 1/2*A*x**2 + B*x + C
- #cost += - math.exp(80*(1-(saturation-elem)/(saturation-target_)))
- #cost += (elem-target_)**4
- else:
- cost += 1e18*x**2
- return cost
-
-
- #cost_value = - torch.var(col) - torch.sum(-torch.log(1+row_diffs))
- #cost_value = - torch.var(torch.exp(col/18000)) - 10000*torch.sum(torch.log(1/(1+row_diffs)))
- #cost_value = - torch.var(torch.exp(col/30000))# - 2*torch.count_nonzero(row_diffs)
- #cost_value = - torch.var(torch.exp(col/20000)) - 40*torch.count_nonzero(row_diffs)
- #cost_value = torch.mean(col)
- #cost_value = - 2*torch.var((torch.exp(col/20000)- torch.exp(torch.tensor([9000])/20000))**2)
- #cost_value = - saturation(col, 45000, margin=0.1)
-
- #print("Jumps: ", torch.count_nonzero(row_diffs))
- print("Var: ", torch.var(col))
- #print("Saturation: ", - saturation(col.flatten(), 120000, margin=0.1))
- print("Min: ", torch.min(col))
- print("Mean: ", torch.mean(col))
- print("Max: ", torch.max(col))
-
- #cost_value = - torch.var(torch.exp(col/100000)) #- 1e-5*saturation(col.flatten(), 200000, margin=0.1)
- #cost_value = - torch.var((torch.log(col.squeeze())- torch.log(torch.tensor([200000]).to('cuda')))**2)
- #cost_value = - torch.var(col) #- saturation(col.flatten(), 120000, margin=0.1)
- cost_value = - bowl(col, target, saturation=2.2e6)
- print("Cost: ", - cost_value)
- return - cost_value
-
-# def evalute_slit_scanning_straightness(filtering_cube,threshold):
-# """
-# Evaluate the straightness of the slit scanning.
-# working cost function for up to focal >100000
-# """
-# cost_value = torch.tensor(0.0, requires_grad=True)
-
-# for i in range(filtering_cube.shape[2]):
-# vertical_binning = torch.sum(filtering_cube[:, :, i], axis=0)
-# max_value = torch.max(vertical_binning)
-# values_above_threshold = vertical_binning > threshold
-# number_of_values_above_threshold = torch.sum(values_above_threshold)
-# cost_value = cost_value + max_value / number_of_values_above_threshold
-# return -cost_value
-
-
-# def evalute_slit_scanning_straightness(filtering_cube,threshold):
-# """
-# Evaluate the straightness of the slit scanning.
-# """
-# cost_value =0
-
-# for i in range(filtering_cube.shape[2]):
-# vertical_binning = torch.sum(filtering_cube[:,:,i],axis=0)
-# max_value = torch.max(vertical_binning)
-# # Differentiable way to count values above threshold
-# values_above_threshold = vertical_binning > threshold
-# number_of_values_above_threshold = torch.sum(values_above_threshold)
-# cost_value += 1 / (number_of_values_above_threshold ** 2)
-
-# cost_value = -1*(cost_value)
-# return cost_value
\ No newline at end of file
diff --git a/simca/cost_functions_optics.py b/simca/cost_functions_optics.py
index 89eb7e2..f0af0e0 100755
--- a/simca/cost_functions_optics.py
+++ b/simca/cost_functions_optics.py
@@ -3,14 +3,122 @@
import numpy as np
from sklearn.linear_model import LinearRegression
from sklearn.metrics import r2_score
+import os
+import math
+import json
+from torch.optim import Adam
+from opticalglass.glassfactory import get_glass_catalog
-def testing_model(cassi_system,nd_values, vd_values):
- cassi_system.optical_model.A3 = cassi_system.optical_model.A1
- cassi_system.optical_model.nd3 = cassi_system.optical_model.nd1
- cassi_system.optical_model.vd3 = cassi_system.optical_model.vd1
+import numpy as np
+import matplotlib.pyplot as plt
+from matplotlib.colors import LinearSegmentedColormap
- alpha_c_out = cassi_system.optical_model.rerun_central_dispersion()
- # Forward pass
+from simca.helper import *
+import matplotlib
+
+from simca import load_yaml_config
+from simca.CassiSystem import CassiSystem
+from opticalglass.glassfactory import get_glass_catalog
+
+
+from torch.optim import Adam
+from torch.optim.lr_scheduler import CosineAnnealingLR
+
+def get_catalog_glass_infos(catalog, device="cpu"):
+ glass_pd = get_glass_catalog(catalog)
+ list_of_glasses = glass_pd.df.iloc[:, 0].index.tolist()
+
+ tuple_glass_data = glass_pd.glass_map_data("d")
+
+ nd = tuple_glass_data[0][:]
+ vd = tuple_glass_data[1][:]
+ nd_values = torch.tensor(nd, device=device)
+ vd_values = torch.tensor(vd, device=device)
+
+ return list_of_glasses, nd_values, vd_values
+
+
+def plot_grids_coordinates(cassi_system,test_name='test',save_fig_dir=None,save_fig=False):
+
+ X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture = cassi_system.propagate_coded_aperture_grid()
+
+
+ dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(X_coordinates_propagated_coded_aperture.unsqueeze(0), Y_coordinates_propagated_coded_aperture.unsqueeze(0))
+ x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(
+ cassi_system.X_coded_aper_coordinates,
+ cassi_system.Y_coded_aper_coordinates,
+ central_coordinates_X
+ )
+ plt.figure()
+
+ # plot distorsion grids
+ plt.scatter(x_vec_no_dist.detach().cpu().numpy()[..., 0], y_vec_no_dist.detach().cpu().numpy()[..., 0], label="no dist", color='grey',s=70)
+ plt.scatter(x_vec_no_dist.detach().cpu().numpy()[..., 3], y_vec_no_dist.detach().cpu().numpy()[..., 3], label="no dist", color='grey',s=70)
+ plt.scatter(x_vec_no_dist.detach().cpu().numpy()[..., -1], y_vec_no_dist.detach().cpu().numpy()[..., -1], label="no dist", color='grey',s=70)
+ plt.scatter(X_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., 0], Y_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., 0], color='blue', label="distor")
+ plt.scatter(X_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., 3], Y_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., 3], color='green', label="distor")
+ plt.scatter(X_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., -1], Y_coordinates_propagated_coded_aperture.detach().cpu().numpy()[..., -1], color='red', label="distor")
+
+ if save_fig:
+ plt.savefig(save_fig_dir +f"grids_coordinates_{test_name}.svg")
+
+ plt.show()
+
+ if save_fig:
+ np.save(save_fig_dir + f"x_coordinates_{test_name}",x_vec_no_dist.detach().cpu().numpy())
+ np.save(save_fig_dir + f"y_coordinates_{test_name}",y_vec_no_dist.detach().cpu().numpy())
+ np.save(save_fig_dir + f"wavelengths_{test_name}",cassi_system.wavelengths.detach().cpu().numpy())
+
+
+
+def format_score_details(cost_details,weighted_cost_components,cost_weights):
+ score_details = {
+ 'components non weights': {key: value for key, value in cost_weights.items()},
+ 'components with weights': {key : float(value) for key, value in cost_details.items()},
+ 'weighted components': {key : float(value) for key, value in weighted_cost_components.items()},
+ }
+ return score_details
+
+
+
+def initialize_optimizer(cassi_system, params_to_optimize, num_iterations):
+ base_params = []
+ glass_params = []
+
+ for name, param in cassi_system.optical_model.named_parameters():
+ if name in params_to_optimize:
+ if name in ['nd1', 'vd1', 'nd2', "vd2", "nd3", "vd3"]:
+ glass_params.append(param)
+ else:
+ base_params.append(param)
+
+ # Define parameter groups with different initial learning rates
+ param_groups = [
+ {'params': base_params, 'lr': 0.01}, # Base initial learning rate
+ {'params': glass_params, 'lr': 0.01} # Higher initial learning rate for glass parameters
+ ]
+
+ optimizer = Adam(param_groups)
+
+ # Create a cosine annealing scheduler
+ scheduler = CosineAnnealingLR(optimizer, T_max=num_iterations, eta_min=1e-6)
+
+ return optimizer, scheduler
+
+
+def setup_results_directory(output_dir, step_name):
+ # Create the optimization_results directory within the output_dir
+ optimization_results_dir = os.path.join(output_dir, "optimization_results")
+ os.makedirs(optimization_results_dir, exist_ok=True)
+
+ # Create a subdirectory for the current step
+ step_dir = os.path.join(optimization_results_dir, step_name)
+ os.makedirs(step_dir, exist_ok=True)
+
+ return step_dir
+
+def evaluate_optical_performances(cassi_system,save_fig_dir=None):
+ cassi_system.optical_model.rerun_central_dispersion()
x_vec_out, y_vec_out = cassi_system.propagate_coded_aperture_grid()
alpha_c = cassi_system.optical_model.alpha_c
@@ -19,53 +127,112 @@ def testing_model(cassi_system,nd_values, vd_values):
list_theta_in = cassi_system.optical_model.list_theta_in
list_theta_out = cassi_system.optical_model.list_theta_out
- # evaluate spectral dispersion
dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
-
y_second_derivative = calculate_second_derivative(cassi_system.wavelengths, central_coordinates_X)
-
- # evaluate direct_view
deviation = evaluate_direct_view(alpha_c, alpha_c_out, list_apex_angles)
- # print("deviation in degrees", deviation * 180 / np.pi)
-
- # evaluate beam compression
beam_compression = evaluate_beam_compression(list_theta_in, list_theta_out)
- # print("beam compression", beam_compression)
-
- # evaluate thickness
thickness = evaluate_thickness(list_apex_angles)
- # print("thickness", thickness)
+ x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(
+ cassi_system.X_coded_aper_coordinates,
+ cassi_system.Y_coded_aper_coordinates,
+ central_coordinates_X
+ )
+ distortion_metric, _,mean_distortion = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist,save_fig_dir)
- # evaluate distortions
- x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system.X_coded_aper_coordinates,
- cassi_system.Y_coded_aper_coordinates,
- central_coordinates_X)
- distortion_metric = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist)
+ performances = {
+ 'dispersion [um]': int(dispersion),
+ 'deviation [deg]': float(deviation)*180/np.pi,
+ 'max distortion [um]': float(distortion_metric),
+ 'mean distortion [um]': float(mean_distortion),
+ 'beam_compression [no units]': float(beam_compression),}
- # print("distortion metric", distortion_metric)
- # distance from closest point
- current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
- current_value2 = [cassi_system.optical_model.nd2, cassi_system.optical_model.vd2]
- current_value3 = [cassi_system.optical_model.nd3, cassi_system.optical_model.vd3]
+ return performances
- distance_closest_point1, min_idx1 = evaluate_distance(current_value1, nd_values, vd_values)
- distance_closest_point2, min_idx2 = evaluate_distance(current_value2, nd_values, vd_values)
- distance_closest_point3, min_idx3 = evaluate_distance(current_value3, nd_values, vd_values)
- # # cost functions
- cost_distance_glasses = (10**4*(distance_closest_point1**2 + distance_closest_point2**2 + distance_closest_point3**2))**2
- cost_deviation = deviation*10
- cost_distorsion = distortion_metric**2
- cost_thickness = thickness*10
- cost_beam_compression = torch.abs(beam_compression - 1)*10
- cost_non_linearity = 0.001* y_second_derivative**2
- # cost_distance_total_intern_reflection = 0.1*softplus(cassi_system.optical_model.min_distance_from_total_intern_reflection)**2
+def evaluate_cost_functions(cassi_system, cost_weights, target_dispersion, nd_values, vd_values, iteration_number, list_of_glasses):
+ cassi_system.optical_model.rerun_central_dispersion()
+ x_vec_out, y_vec_out = cassi_system.propagate_coded_aperture_grid()
- score = cost_distance_glasses + cost_deviation + cost_distorsion + cost_thickness + cost_beam_compression + cost_non_linearity
+ alpha_c = cassi_system.optical_model.alpha_c
+ alpha_c_out = cassi_system.optical_model.alpha_c_transmis
+ list_apex_angles = [cassi_system.optical_model.A1, cassi_system.optical_model.A2, cassi_system.optical_model.A3]
+ list_theta_in = cassi_system.optical_model.list_theta_in
+ list_theta_out = cassi_system.optical_model.list_theta_out
+
+ dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
+ y_second_derivative = calculate_second_derivative(cassi_system.wavelengths, central_coordinates_X)
+ deviation = evaluate_direct_view(alpha_c, alpha_c_out, list_apex_angles)
+ beam_compression = evaluate_beam_compression(list_theta_in, list_theta_out)
+ thickness = evaluate_thickness(list_apex_angles)
+ x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(
+ cassi_system.X_coded_aper_coordinates,
+ cassi_system.Y_coded_aper_coordinates,
+ central_coordinates_X
+ )
+ distortion_metric, _,mean_distortion = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist)
+ if cassi_system.optical_model.index_estimation_method == "cauchy":
+ distance_glasses_metric = evaluate_distance_glasses(cassi_system, nd_values, vd_values, list_of_glasses)
+ else :
+ distance_glasses_metric = 0
+
+
+
+ cost_components = {
+ 'cost_dispersion': (target_dispersion - dispersion) ** 2,
+ 'cost_distance_glasses': (10 ** 10 * distance_glasses_metric) * iteration_number,
+ 'cost_deviation': (deviation * 5000) ** 2,
+ 'cost_distorsion': distortion_metric ** 2,
+ 'cost_thickness': thickness * 5000,
+ 'cost_beam_compression': torch.abs(beam_compression - 1) * 10,
+ 'cost_non_linearity': 0.001 * y_second_derivative ** 2,
+ 'cost_distance_total_intern_reflection': 2 * softplus(cassi_system.optical_model.min_distance_from_total_intern_reflection) ** 2
+ }
+
+ interesting_values = {
+ 'dispersion [um]': dispersion,
+ 'deviation [deg]': deviation*180/np.pi,
+ 'max distortion [um]': distortion_metric,
+ 'mean distortion [um]': mean_distortion,
+ 'beam_compression [no units]': beam_compression,}
+
+
+ weighted_cost_components = {key: cost_weights[key] * value for key, value in cost_components.items()}
+
+
+ score = sum(cost_weights.get(key, 0) * value for key, value in cost_components.items())
+
+
+ return score, cost_components,weighted_cost_components,interesting_values
+
+
+def save_optimization_details(results_dir, non_improvement_count, patience, i, latest_optical_params, current_loss,interesting_values):
+ optimization_details = {
+ 'reason_for_stopping': 'no improvement' if non_improvement_count >= patience else 'completed',
+ 'iterations': i,
+ 'end_parameters': {
+ param_name: (param.item() if 'A' not in param_name and 'alpha_c' not in param_name and 'delta' not in param_name else math.degrees(param.item()))
+ for param_name, param in latest_optical_params.items()
+ },
+ 'optical system values': {param_name: (param.item() if 'deviation' not in param_name else math.degrees(param.item())) for param_name, param in interesting_values.items()},
+ 'current_loss': current_loss,
+ }
+
+ details_path = os.path.join(results_dir, 'optimization_details.json')
+ with open(details_path, 'a') as f:
+ json.dump(optimization_details, f, indent=4)
+
+
+def plot_glass_selection(nd_values, vd_values, current_glass_values_1, current_glass_values_2, min_idx_1, min_idx_2):
+ plt.scatter(nd_values.detach().cpu().numpy(), vd_values.detach().cpu().numpy(), c='b', label='all glasses')
+ plt.scatter(current_glass_values_1[0].detach().cpu().numpy(), current_glass_values_1[1].detach().cpu().numpy(), c='r', label='current glass 1')
+ plt.scatter(current_glass_values_2[0].detach().cpu().numpy(), current_glass_values_2[1].detach().cpu().numpy(), c='g', label='current glass 2')
+ plt.scatter(nd_values[min_idx_1].detach().cpu().numpy(), vd_values[min_idx_1].detach().cpu().numpy(), c='r', label='closest glass 1', marker='x')
+ plt.scatter(nd_values[min_idx_2].detach().cpu().numpy(), vd_values[min_idx_2].detach().cpu().numpy(), c='g', label='closest glass 2', marker='x')
+ plt.show()
+
- return score
def calculate_second_derivative(x, y):
"""
Calculate the second derivative of y with respect to x using central differences.
@@ -97,8 +264,8 @@ def get_cassi_system_no_spectial_distorsions(X, Y, central_coordinates_X):
central_coordinates_X = [coord for coord in list(central_coordinates_X)]
- X_vec_out = torch.zeros((1,X.shape[0],X.shape[1],len(central_coordinates_X)))
- Y_vec_out = torch.zeros((1,X.shape[0],X.shape[1],len(central_coordinates_X)))
+ X_vec_out = torch.zeros((1,X.shape[0],X.shape[1],len(central_coordinates_X)),device=X.device)
+ Y_vec_out = torch.zeros((1,X.shape[0],X.shape[1],len(central_coordinates_X)),device=Y.device)
for i in range(X_vec_out.shape[-1]):
@@ -110,14 +277,12 @@ def get_cassi_system_no_spectial_distorsions(X, Y, central_coordinates_X):
def evaluate_spectral_dispersion_values(x_vec_out, y_vec_out):
# calculate spectral dispersion in um
-
-
+
central_coordinates_X = x_vec_out[0,x_vec_out.shape[1]//2, x_vec_out.shape[2]//2,:]
spectral_dispersion = torch.abs(central_coordinates_X[0] - central_coordinates_X[-1])
-
return spectral_dispersion, central_coordinates_X
@@ -126,7 +291,6 @@ def evaluate_direct_view(alpha_c,alpha_c_out,list_apex_angles):
total_dev = alpha_c + alpha_c_out
for idx,angle in enumerate(list_apex_angles):
total_dev += ((-1)**(idx+1))*angle
-
return total_dev
def softplus(x):
return torch.log(1 + torch.exp(-x+5))**3
@@ -146,15 +310,65 @@ def evaluate_thickness(list_angles):
return sum_angles
-def evaluate_distortions(X_vec_out_distor, Y_vec_out_distors, X_vec_out, Y_vec_out):
+def evaluate_distance_glasses(cassi_system, nd_values, vd_values, list_of_glasses):
- distance_map = torch.sqrt((X_vec_out_distor - X_vec_out)**2 + (Y_vec_out_distors - Y_vec_out)**2)
+ if cassi_system.system_config["system architecture"]["dispersive element"]["type"] == 'prism':
+ current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
+ distance_closest_point1, min_idx_1 = evaluate_distance(current_value1, nd_values, vd_values)
+ cost_distance_glass = distance_closest_point1**2
+
+ elif cassi_system.system_config["system architecture"]["dispersive element"]["type"] == 'doubleprism' or cassi_system.system_config["system architecture"]["dispersive element"]["type"] == 'amici':
+ current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
+ current_value2 = [cassi_system.optical_model.nd2, cassi_system.optical_model.vd2]
+ distance_closest_point1, min_idx_1 = evaluate_distance(current_value1, nd_values, vd_values)
+ distance_closest_point2, min_idx_2 = evaluate_distance(current_value2, nd_values, vd_values)
+ cost_distance_glass = distance_closest_point1**2 + distance_closest_point2**2
+
+ elif cassi_system.system_config["system architecture"]["dispersive element"]["type"] == 'tripleprism':
+ current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
+ current_value2 = [cassi_system.optical_model.nd2, cassi_system.optical_model.vd2]
+ current_value3 = [cassi_system.optical_model.nd3, cassi_system.optical_model.vd3]
+ distance_closest_point1, min_idx_1 = evaluate_distance(current_value1, nd_values, vd_values)
+ distance_closest_point2, min_idx_2 = evaluate_distance(current_value2, nd_values, vd_values)
+ distance_closest_point3, min_idx_3 = evaluate_distance(current_value3, nd_values, vd_values)
+ cost_distance_glass = distance_closest_point1**2 + distance_closest_point2**2 + distance_closest_point3**2
+ return cost_distance_glass
+
+def evaluate_distortions(X_vec_out_distor, Y_vec_out_distors, X_vec_out, Y_vec_out,save_fig_dir=None):
+
+ #print gradient value
+ parula_map = LinearSegmentedColormap.from_list('parula', cm_data)
+ distance_map = torch.sqrt((X_vec_out_distor - X_vec_out)**2 + (Y_vec_out_distors - Y_vec_out)**2)
+
# mean distance
distortion_metric = torch.max(torch.max(torch.max(distance_map)))
+ mean_distortion = torch.mean(torch.mean(torch.mean(distance_map)))
# distortion_metric = np.sum(np.sum(distance_map))
# distortion_metric = torch.sum(torch.sum(torch.sum(distance_map)))
- return distortion_metric
+
+ if save_fig_dir is not None:
+ print(X_vec_out[0,13,13,:])
+
+ for i in [0,5,-1]:
+
+ max_x = X_vec_out[0,0,0,i].detach().cpu().numpy()
+ min_x = X_vec_out[0,0,-1,i].detach().cpu().numpy()
+ max_y = Y_vec_out[0,0,0,i].detach().cpu().numpy()
+ min_y = Y_vec_out[0,-1,0,i].detach().cpu().numpy()
+ # print(min_x, max_x, min_y, max_y)
+
+ plt.figure()
+ norm = matplotlib.colors.LogNorm(vmin=0.1, vmax=125)
+ plt.imshow(distance_map[0,:,:,i].detach().cpu().numpy(),cmap=parula_map,extent=[min_x, max_x, min_y, max_y],norm=norm)
+ # plt.imshow(distance_map[0,:,:,0].detach().cpu().numpy(),cmap=parula_map)
+ plt.xlabel("x [$\mu$m]",fontsize=18)
+ plt.ylabel("y [$\mu$m]",fontsize=18)
+ plt.title(f"Distortion map at $\lambda$ = {i}",fontsize=14)
+ plt.colorbar()
+ plt.savefig(save_fig_dir + f"distor_map_{i}.svg")
+ # plt.show()
+ return distortion_metric, distance_map,mean_distortion
def evaluate_distance(current_value_pair,nd_values,vd_values):
@@ -198,4 +412,258 @@ def evaluate_approximation_thickness(list_angles):
sum_angles = np.sum(list_angles)
return sum_angles
+def testing_model(cassi_system,nd_values, vd_values):
+ cassi_system.optical_model.A3 = cassi_system.optical_model.A1
+ cassi_system.optical_model.nd3 = cassi_system.optical_model.nd1
+ cassi_system.optical_model.vd3 = cassi_system.optical_model.vd1
+
+ alpha_c_out = cassi_system.optical_model.rerun_central_dispersion()
+ # Forward pass
+ x_vec_out, y_vec_out = cassi_system.propagate_coded_aperture_grid()
+
+ alpha_c = cassi_system.optical_model.alpha_c
+ alpha_c_out = cassi_system.optical_model.alpha_c_transmis
+ list_apex_angles = [cassi_system.optical_model.A1, cassi_system.optical_model.A2, cassi_system.optical_model.A3]
+ list_theta_in = cassi_system.optical_model.list_theta_in
+ list_theta_out = cassi_system.optical_model.list_theta_out
+
+ # evaluate spectral dispersion
+ dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
+
+ y_second_derivative = calculate_second_derivative(cassi_system.wavelengths, central_coordinates_X)
+
+ # evaluate direct_view
+ deviation = evaluate_direct_view(alpha_c, alpha_c_out, list_apex_angles)
+ # print("deviation in degrees", deviation * 180 / np.pi)
+
+ # evaluate beam compression
+ beam_compression = evaluate_beam_compression(list_theta_in, list_theta_out)
+ # print("beam compression", beam_compression)
+
+ # evaluate thickness
+ thickness = evaluate_thickness(list_apex_angles)
+ # print("thickness", thickness)
+
+ # evaluate distortions
+ x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system.X_coded_aper_coordinates,
+ cassi_system.Y_coded_aper_coordinates,
+ central_coordinates_X)
+ distortion_metric,_ = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist)
+
+ # print("distortion metric", distortion_metric)
+
+ # distance from closest point
+ current_value1 = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
+ current_value2 = [cassi_system.optical_model.nd2, cassi_system.optical_model.vd2]
+ current_value3 = [cassi_system.optical_model.nd3, cassi_system.optical_model.vd3]
+
+ distance_closest_point1, min_idx1 = evaluate_distance(current_value1, nd_values, vd_values)
+ distance_closest_point2, min_idx2 = evaluate_distance(current_value2, nd_values, vd_values)
+ distance_closest_point3, min_idx3 = evaluate_distance(current_value3, nd_values, vd_values)
+
+ # # cost functions
+ cost_distance_glasses = (10**4*(distance_closest_point1**2 + distance_closest_point2**2 + distance_closest_point3**2))**2
+ cost_deviation = deviation*10
+ cost_distorsion = distortion_metric**2
+ cost_thickness = thickness*10
+ cost_beam_compression = torch.abs(beam_compression - 1)*10
+ cost_non_linearity = 0.001* y_second_derivative**2
+ # cost_distance_total_intern_reflection = 0.1*softplus(cassi_system.optical_model.min_distance_from_total_intern_reflection)**2
+
+
+ score = cost_distance_glasses + cost_deviation + cost_distorsion + cost_thickness + cost_beam_compression + cost_non_linearity
+
+ return score
+
+
+def optimize_cassi_system(params_to_optimize, target_dispersion, cost_weights, config_path, iterations, patience, output_dir, step_name, index_estimation_method="cauchy", device='cpu'):
+ results_dir = setup_results_directory(output_dir, step_name)
+
+ config_system = load_yaml_config(config_path)
+ cassi_system = CassiSystem(system_config=config_system, device=device, index_estimation_method=index_estimation_method)
+ device = cassi_system.device
+ catalog = config_system["system architecture"]["dispersive element"]["catalog"]
+
+ list_of_glasses, nd_values, vd_values = get_catalog_glass_infos(catalog=catalog, device=device)
+
+ optimizer, scheduler = initialize_optimizer(cassi_system, params_to_optimize, 300)
+ non_improvement_count = 0
+ best_loss = float('inf')
+
+ optimization_details = []
+
+ for i in range(iterations):
+ optimizer.zero_grad()
+
+ if cassi_system.system_config['system architecture']['dispersive element']['type'] == 'amici':
+
+ if cassi_system.optical_model.index_estimation_method == "cauchy":
+ cassi_system.optical_model.nd3 = cassi_system.optical_model.nd1
+ cassi_system.optical_model.vd3 = cassi_system.optical_model.vd1
+ if cassi_system.optical_model.index_estimation_method == "sellmeier":
+ cassi_system.optical_model.glass3 = cassi_system.optical_model.glass1
+
+ score, cost_details, weighted_cost_components, interesting_values = evaluate_cost_functions(cassi_system, cost_weights, target_dispersion, nd_values, vd_values, i, list_of_glasses)
+ current_loss = score.item()
+
+ latest_optical_params = {param_name: param.clone().detach() for param_name, param in cassi_system.optical_model.named_parameters()}
+
+ if cassi_system.system_config['system architecture']['dispersive element']['type'] == 'amici':
+ latest_optical_params['A3'] = latest_optical_params['A1']
+ if cassi_system.optical_model.index_estimation_method == "cauchy":
+ latest_optical_params['nd3'] = latest_optical_params['nd1']
+ latest_optical_params['vd3'] = latest_optical_params['vd1']
+
+
+ if i % 10 == 0:
+ print(f'Iteration {i}, Loss: {current_loss}')
+
+
+ details = {
+ 'reason_for_stopping': 'no improvement' if non_improvement_count >= patience else 'completed',
+ 'iterations': i,
+ 'end_parameters': {
+ param_name: (param.item() if 'A' not in param_name and 'alpha_c' not in param_name and 'delta' not in param_name else math.degrees(param.item()))
+ for param_name, param in latest_optical_params.items()
+ },
+ 'optical system values': {param_name: (param.item() if 'deviation' not in param_name else math.degrees(param.item())) for param_name, param in interesting_values.items()},
+ 'current_loss': current_loss,
+ }
+
+ if math.isnan(current_loss):
+ print("nan value")
+ break
+
+ optimization_details.append(details)
+
+ # Save optical characteristics corresponding to the various iterations
+ details_path = os.path.join(results_dir, 'optimization_details.json')
+ with open(details_path, 'w') as f:
+ json.dump(optimization_details, f, indent=4)
+
+ score_details = format_score_details(cost_details, weighted_cost_components, cost_weights)
+ # Save the cost functions score details
+ details_path = os.path.join(results_dir, f'score_details_iteration_{i}.json')
+ with open(details_path, 'a') as f:
+ json.dump(score_details, f, indent=4)
+
+
+
+ score.backward()
+ optimizer.step()
+ scheduler.step() # Step the scheduler
+
+ if current_loss < best_loss:
+ best_loss = current_loss
+ non_improvement_count = 0
+ else:
+ non_improvement_count += 1
+
+ if non_improvement_count >= patience:
+ print(f'Stopping early at iteration {i} due to no improvement.')
+ break
+
+ # After the optimization loop
+ final_config = cassi_system.system_config
+ return final_config, latest_optical_params
+
+def test_cassi_system(config_path, index_estimation_method="sellmeier", save_fig_dir=None, save_fig=False):
+
+ config_system = load_yaml_config(config_path)
+ cassi_system = CassiSystem(system_config=config_system, index_estimation_method=index_estimation_method, device="cpu")
+
+ plot_grids_coordinates(cassi_system, save_fig_dir=save_fig_dir, save_fig=save_fig)
+ performances = evaluate_optical_performances(cassi_system, save_fig_dir=save_fig_dir)
+
+ return cassi_system.system_config, performances
+
+import json
+import os
+import matplotlib.pyplot as plt
+def plot_optimization_process(output_dir, step_name):
+ step_dir = os.path.join(output_dir, "optimization_results", step_name)
+ iterations = []
+ weighted_costs = {}
+ total_costs = []
+
+ def parse_json_objects(content):
+ decoder = json.JSONDecoder()
+ pos = 0
+ while True:
+ try:
+ obj, pos = decoder.raw_decode(content, pos)
+ yield obj
+ except json.JSONDecodeError:
+ if pos == len(content):
+ break
+ pos += 1
+
+ # Read all score details files
+ for filename in os.listdir(step_dir):
+ if filename.startswith("score_details_iteration_") and filename.endswith(".json"):
+ file_path = os.path.join(step_dir, filename)
+ try:
+ with open(file_path, 'r') as f:
+ content = f.read()
+ # Parse multiple JSON objects in the file
+ for data in parse_json_objects(content):
+ iteration = int(filename.split('_')[-1].split('.')[0])
+ iterations.append(iteration)
+ total_cost = 0
+ for cost_name, cost_value in data['weighted components'].items():
+ if cost_name not in weighted_costs:
+ weighted_costs[cost_name] = []
+ weighted_costs[cost_name].append(cost_value)
+ total_cost += cost_value
+ total_costs.append(total_cost)
+ except Exception as e:
+ print(f"Error processing file {filename}: {str(e)}")
+ continue # Skip this file and continue with the next one
+
+ if not iterations:
+ print(f"No valid data found for step {step_name}. Skipping plot creation.")
+ return
+
+ # Sort data by iteration
+ sorted_indices = sorted(range(len(iterations)), key=lambda k: iterations[k])
+ iterations = [iterations[i] for i in sorted_indices]
+ for cost_name in weighted_costs:
+ weighted_costs[cost_name] = [weighted_costs[cost_name][i] for i in sorted_indices]
+ total_costs = [total_costs[i] for i in sorted_indices]
+
+ # Plot individual weighted costs
+ plt.figure(figsize=(12, 8))
+ for cost_name, cost_values in weighted_costs.items():
+ plt.plot(iterations, cost_values, label=cost_name)
+
+ plt.xlabel('Iteration')
+ plt.ylabel('Weighted Cost')
+ plt.title(f'Individual Weighted Costs over Iterations - {step_name}')
+ plt.legend()
+ plt.yscale('log') # Use log scale for y-axis
+ plt.grid(True)
+
+ # Save the individual weighted costs plot
+ individual_plot_path = os.path.join(output_dir, f"optimization_plot_individual_{step_name}.png")
+ plt.savefig(individual_plot_path)
+ plt.close()
+
+ # Plot total cost function
+ plt.figure(figsize=(12, 8))
+ plt.plot(iterations, total_costs, label='Total Cost')
+
+ plt.xlabel('Iteration')
+ plt.ylabel('Total Cost')
+ plt.title(f'Total Cost Function over Iterations - {step_name}')
+ plt.legend()
+ plt.yscale('log') # Use log scale for y-axis
+ plt.grid(True)
+
+ # Save the total cost plot
+ total_plot_path = os.path.join(output_dir, f"optimization_plot_total_{step_name}.png")
+ plt.savefig(total_plot_path)
+ plt.close()
+
+ print(f"Individual costs plot saved as {individual_plot_path}")
+ print(f"Total cost plot saved as {total_plot_path}")
\ No newline at end of file
diff --git a/simca/functions_acquisition.py b/simca/functions_acquisition.py
deleted file mode 100644
index d0d7e4b..0000000
--- a/simca/functions_acquisition.py
+++ /dev/null
@@ -1,318 +0,0 @@
-import numpy as np
-from scipy.interpolate import griddata
-from tqdm import tqdm
-import multiprocessing as mp
-from multiprocessing import Pool
-
-import torch
-
-def generate_sd_measurement_cube(filtered_scene,X_input, Y_input, X_target, Y_target,grid_type,interp_method):
- """
- Generate SD measurement cube from the coded aperture and the scene.
- For Single-Disperser CASSI systems, the scene is filtered then propagated in the detector plane.
-
- Args:
- filtered_scene (numpy.ndarray): filtered scene (shape = R x C x W)
-
- Returns:
- numpy.ndarray: SD measurement cube (shape = R x C x W)
- """
-
- print("--- Generating SD measurement cube ---- ")
-
- measurement_sd = interpolate_data_on_grid_positions(filtered_scene,
- X_input,
- Y_input,
- X_target,
- Y_target,
- grid_type=grid_type,
- interp_method=interp_method)
- return measurement_sd
-
-def generate_dd_measurement(scene, filtering_cube,chunk_size):
- """
- Generate DD-CASSI type system measurement from a scene and a filtering cube. ref : "Single-shot compressive spectral imaging with a dual-disperser architecture", M.Gehm et al., Optics Express, 2007
-
- Args:
- scene (numpy.ndarray): observed scene (shape = R x C x W)
- filtering_cube (numpy.ndarray): filtering cube of the instrument for a given pattern (shape = R x C x W)
- chunk_size (int) : size of the spatial chunks in which the Hadamard product is performed
-
- Returns:
- numpy.ndarray: filtered scene (shape = R x C x W)
- """
-
- # Initialize an empty array for the result
- filtered_scene = np.empty_like(filtering_cube)
-
- # Calculate total iterations for tqdm
- total_iterations = (filtering_cube.shape[0] // chunk_size + 1) * (filtering_cube.shape[1] // chunk_size + 1)
-
- with tqdm(total=total_iterations) as pbar:
- # Perform the multiplication in chunks
- for i in range(0, filtering_cube.shape[0], chunk_size):
- for j in range(0, filtering_cube.shape[1], chunk_size):
- filtered_scene[i:i + chunk_size, j:j + chunk_size, :] = filtering_cube[i:i + chunk_size,
- j:j + chunk_size, :] * scene[
- i:i + chunk_size,
- j:j + chunk_size,
- :]
- pbar.update()
-
- filtered_scene = np.nan_to_num(filtered_scene)
-
- return filtered_scene
-
-def match_dataset_to_instrument(dataset, filtering_cube):
- """
- Match the size of the dataset to the size of the filtering cube. Either by padding or by cropping
-
- Args:
- dataset (torch.Tensor): dataset
- filtering_cube (torch.Tensor): filtering cube of the instrument
-
- Returns:
- torch.Tensor: observed scene (shape = R x C x W)
- """
-
- #print("filtering_cube : ", filtering_cube.shape)
- #print("dataset : ", dataset.shape)
-
- # Initialize scene as dataset for simplicity
- scene = dataset.clone()
-
- # Match spatial dimensions (R and C)
- if filtering_cube.shape[0] != dataset.shape[1] or filtering_cube.shape[1] != dataset.shape[2]:
- # Calculate padding
- pad_height = (filtering_cube.shape[0] - dataset.shape[1]) / 2
- pad_width = (filtering_cube.shape[1] - dataset.shape[2]) / 2
-
- # Apply padding if necessary
- if pad_height > 0 or pad_width > 0:
- pad_height_low = int(torch.floor(pad_height)) if isinstance(pad_height, torch.Tensor) else int(
- pad_height // 1)
- pad_height_high = int(torch.ceil(pad_height)) if isinstance(pad_height, torch.Tensor) else int(
- -(-pad_height // 1)) # Equivalent to ceil for positive numbers
- pad_width_low = int(torch.floor(pad_width)) if isinstance(pad_width, torch.Tensor) else int(pad_width // 1)
- pad_width_high = int(torch.ceil(pad_width)) if isinstance(pad_width, torch.Tensor) else int(
- -(-pad_width // 1))
-
- padding = (
- pad_width_low, pad_width_high, pad_height_low, pad_height_high, 0, 0) # Padding for W, H, and dummy D
- scene = torch.nn.functional.pad(scene, padding, "constant", 0)
-
- # Crop if necessary (this adjusts if the padding made the scene too large)
- scene = scene[:, :filtering_cube.shape[0], :filtering_cube.shape[1], :]
-
- print("Dataset Spatial Adjustment: Filtering cube and scene must have the same number of rows and columns.")
-
- # Match spectral dimensions (W)
- if len(filtering_cube.shape) == 3 and filtering_cube.shape[2] != dataset.shape[2]:
- scene = scene[:, :, :filtering_cube.shape[2]]
- print("Dataset Spectral Cropping: Filtering cube and scene must have the same number of wavelengths")
-
- return scene
-
-def match_dataset_to_instrument_old(dataset, filtering_cube):
- """
- Match the size of the dataset to the size of the filtering cube. Either by padding or by cropping
-
- Args:
- dataset (numpy.ndarray): dataset
- filtering_cube (numpy.ndarray): filtering cube of the instrument
-
- Returns:
- numpy.ndarray: observed scene (shape = R x C x W)
- """
-
- print("filtering_cube : ", filtering_cube.shape)
- print("dataset : ", dataset.shape)
-
- if filtering_cube.shape[0] != dataset.shape[0] or filtering_cube.shape[1] != dataset.shape[1]:
- if dataset.shape[0] < filtering_cube.shape[0]:
- dataset = np.pad(dataset, ((np.floor((filtering_cube.shape[0] - dataset.shape[0])/2).astype('int'), np.ceil((filtering_cube.shape[0] - dataset.shape[0])/2).astype('int')), (0, 0), (0, 0)), mode="constant")
- if dataset.shape[1] < filtering_cube.shape[1]:
- dataset = np.pad(dataset, ((0, 0), (np.floor((filtering_cube.shape[1] - dataset.shape[1])/2).astype('int'), np.ceil((filtering_cube.shape[1] - dataset.shape[1])/2).astype('int')), (0, 0)), mode="constant")
- scene = dataset[0:filtering_cube.shape[0], 0:filtering_cube.shape[1], :]
- print("Dataset Spatial Cropping : Filtering cube and scene must have the same number of lines and columns")
-
- else:
- scene = dataset
-
- if len(filtering_cube.shape) == 3 and filtering_cube.shape[2] != dataset.shape[2]:
- scene = dataset[:, :, 0:filtering_cube.shape[2]]
- print("Dataset Spectral Cropping : Filtering cube and scene must have the same number of wavelengths")
- else:
- scene = dataset
-
- try:
- scene
- except:
- print("Please load a scene first")
-
- return scene
-
-def match_dataset_labels_to_instrument(dataset_labels, filtering_cube):
- """
- Match the size of the dataset labels to the size of the filtering cube. Either by padding or by cropping
-
- Args:
- dataset_labels (numpy.ndarray): dataset labels (shape = R_dts x C_dts)
- filtering_cube (numpy.ndarray): filtering cube of the instrument
-
- Returns:
- numpy.ndarray: scene labels (shape = R x C)
- """
-
- if filtering_cube.shape[0] != dataset_labels.shape[0] or filtering_cube.shape[1] != dataset_labels.shape[1]:
- if dataset_labels.shape[0] < filtering_cube.shape[0]:
- dataset_labels = np.pad(dataset_labels, ((0, filtering_cube.shape[0] - dataset_labels.shape[0])), mode="constant")
- if dataset_labels.shape[1] < filtering_cube.shape[1]:
- dataset_labels = np.pad(dataset_labels, ((0, 0), (0, filtering_cube.shape[1] - dataset_labels.shape[1])), mode="constant")
- dataset_labels = dataset_labels[0:filtering_cube.shape[0], 0:filtering_cube.shape[1]]
- print("Filtering cube and scene must have the same lines and columns")
-
- return dataset_labels
-
-import torch
-
-def crop_center_3D(tensor, nb_of_pixels_along_x, nb_of_pixels_along_y):
- """
- Crop the given tensor to the given size, centered on the tensor, for each item in the batch.
-
- Args:
- tensor (torch.Tensor): 3D tensor to be cropped with shape (batch, y, x).
- nb_of_pixels_along_x (int): Number of samples to keep along the X axis.
- nb_of_pixels_along_y (int): Number of samples to keep along the Y axis.
-
- Returns:
- torch.Tensor: Cropped tensor with shape (batch, nb_of_pixels_along_y, nb_of_pixels_along_x).
- """
-
- _, y_len, x_len = tensor.shape # Ignore batch dimension for the cropping calculations
-
- x_start = x_len // 2 - nb_of_pixels_along_x // 2
- x_end = x_start + nb_of_pixels_along_x
-
- y_start = y_len // 2 - nb_of_pixels_along_y // 2
- y_end = y_start + nb_of_pixels_along_y
-
- # Perform cropping for each item in the batch
- cropped_tensor = tensor[:, y_start:y_end, x_start:x_end]
-
- return cropped_tensor
-
-
-def crop_center(array, nb_of_pixels_along_x, nb_of_pixels_along_y):
- """
- Crop the given array to the given size, centered on the array
-
- Args:
- array (numpy.ndarray): 2D array to be cropped
- nb_of_pixels_along_x (int): number of samples to keep along the X axis
- nb_of_pixels_along_y (int): number of samples to keep along the Y axis
-
- Returns:
- numpy.ndarray: cropped array
- """
-
- y_len, x_len = array.shape
-
- x_start = x_len//2 - nb_of_pixels_along_x//2
- x_end = x_start + nb_of_pixels_along_x
-
- y_start = y_len//2 - nb_of_pixels_along_y//2
- y_end = y_start + nb_of_pixels_along_y
-
- if nb_of_pixels_along_x= 50) and (convergence_counter >= max_iter_cnv): # If loss didn't decrease in max_iter_cnv steps, break
- break
-
- cassi_system.array_x_positions.data = torch.relu(cassi_system.array_x_positions.data) # Prevent the parameters to be negative
+from simca import load_yaml_config
+from simca.CassiSystem import CassiSystem
+from simca.cost_functions_optics import evaluate_distance, get_catalog_glass_infos
- # Optional: Print cost_value every few iterations to monitor progress
- if iteration % 5 == 0: # Adjust printing frequency as needed
- print(f"\nIteration {iteration}, Cost: {cost_value.item()}")
- if plot_frequency is not None:
- if iteration % plot_frequency == 0:
- print(f"Exec time: {time.time() - time_start:.3f}s")
- plt.imshow(cassi_system.pattern.detach().numpy(), aspect=aspect_plot)
- plt.show()
- plt.imshow(cassi_system.filtering_cube[:, :, cassi_system.filtering_cube.shape[2]//2].detach().numpy(), aspect=aspect_plot)
- plt.show()
- plt.plot(np.sum(cassi_system.filtering_cube[:, :, cassi_system.filtering_cube.shape[2]//2].detach().numpy(),axis=0))
- plt.show()
-
- cassi_system.array_x_positions.data = torch.relu(best_x.data)
- cassi_system.generate_custom_slit_pattern()
- cassi_system.pattern = cassi_system.pattern.to(device)
- cassi_system.generate_filtering_cube()
- cassi_system.filtering_cube = cassi_system.filtering_cube.to(device)
-
- return cassi_system
-def optim_width(cassi_system, position, target, nb_rows, start_width, device,
- algo, lr, num_iterations, max_iter_cnv, threshold = 0,
- plot_frequency = None, aspect_plot = 1):
+def save_config_system(output_config_path, results_dir, config_path, index_estimation_method='cauchy', iteration_nb=None):
- #start_width = torch.rand(size=(1,nb_rows), generator=gen)*1.5-0.75
- #start_width = 0.005
- cassi_system.generate_custom_pattern_parameters_slit_width(nb_slits=1, nb_rows=nb_rows, start_width = start_width) #0.005
-
- cassi_system.array_x_positions = cassi_system.array_x_positions.to(device)
- # Ensure array_x_positions is a tensor with gradient tracking
- cassi_system.array_x_positions = cassi_system.array_x_positions.clone().detach().requires_grad_(True)
-
- best_x = cassi_system.array_x_positions.clone().detach()
-
- convergence_counter = 0 # Counter to check convergence
- min_cost_value = np.inf
-
- # Define the optimizer
- if algo == "LBFGS":
- optimizer = torch.optim.LBFGS([cassi_system.array_x_positions], lr=lr) # Adjust the learning rate as needed
- elif algo == "ADAM":
- optimizer = torch.optim.Adam([cassi_system.array_x_positions], lr=lr) # Adjust the learning rate as needed
- time_start = time.time()
- # Main optimization loop
- for iteration in range(num_iterations): # Define num_iterations as needed
-
- if algo == "LBFGS":
- def closure():
- optimizer.zero_grad()
- cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = position)
-
- cassi_system.pattern = cassi_system.pattern.to(device)
- cassi_system.generate_filtering_cube()
- cassi_system.filtering_cube = cassi_system.filtering_cube.to(device)
-
- cassi_system.image_acquisition(use_psf=False, chunck_size=cassi_system.system_config["detector"]["number of pixels along Y"])
- cost_value = evaluate_max_lighting(cassi_system.array_x_positions.detach(), cassi_system.measurement, target)
- cost_value.backward()
- return cost_value
-
- optimizer.step(closure)
-
- cost_value = evaluate_max_lighting(cassi_system.array_x_positions.detach(), cassi_system.measurement, target)
-
- elif algo == "ADAM":
- optimizer.zero_grad() # Clear previous gradients
- cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = position)
-
- cassi_system.pattern = cassi_system.pattern.to(device)
- cassi_system.generate_filtering_cube()
- cassi_system.filtering_cube = cassi_system.filtering_cube.to(device)
- cassi_system.image_acquisition(use_psf=False, chunck_size=cassi_system.system_config["detector"]["number of pixels along Y"])
- cost_value = evaluate_max_lighting(cassi_system.array_x_positions.detach(), cassi_system.measurement, target)
- cost_value.backward()
- optimizer.step()
-
- if (cost_value - min_cost_value) < threshold:
- min_cost_value = cost_value
- convergence_counter = 0
- best_x = cassi_system.array_x_positions.clone().detach()
- else:
- convergence_counter+=1
+ config_system = load_yaml_config(config_path)
+ cassi_system = CassiSystem(system_config=config_system, index_estimation_method=index_estimation_method)
+ device = cassi_system.device
+ catalog = config_system["system architecture"]["dispersive element"]["catalog"]
+
+
+ with open(os.path.join(results_dir, 'optimization_details.json'), 'r') as f:
+ optimization_details = json.load(f)
+
+ if iteration_nb is None:
+ iteration_nb = max(detail['iterations'] for detail in optimization_details)
+
+
+ iteration_details = next(detail for detail in optimization_details if detail['iterations'] == iteration_nb)
+ latest_optical_params = iteration_details['end_parameters']
+
+ # test a given configuration
+ list_of_glasses, nd_values, vd_values = get_catalog_glass_infos(catalog=catalog, device=device)
+
+ if cassi_system.optical_model.index_estimation_method == "cauchy":
+ current_glass_values_1 = [latest_optical_params["nd1"], latest_optical_params["vd1"]]
+ distance_closest_point1, min_idx_1 = evaluate_distance(current_glass_values_1, nd_values, vd_values)
+ glass_1 = list_of_glasses[min_idx_1]
+
+ try:
+ current_glass_values_2 = [latest_optical_params["nd2"], latest_optical_params["vd2"]]
+ distance_closest_point2, min_idx_2 = evaluate_distance(current_glass_values_2, nd_values, vd_values)
+ glass_2 = list_of_glasses[min_idx_2]
+ except:
+ pass
+ try:
+ current_glass_values_3 = [latest_optical_params["nd3"], latest_optical_params["vd3"]]
+ distance_closest_point3, min_idx_3 = evaluate_distance(current_glass_values_3, nd_values, vd_values)
+ glass_3 = list_of_glasses[min_idx_3]
+ except:
+ pass
- if (iteration >= 50) and (convergence_counter >= max_iter_cnv): # If loss didn't decrease in max_iter_cnv steps, break
- break
-
- cassi_system.array_x_positions.data = torch.relu(cassi_system.array_x_positions.data) # Prevent the parameters to be negative
-
- # Optional: Print cost_value every few iterations to monitor progress
- if iteration % 5 == 0: # Adjust printing frequency as needed
- print(f"\nIteration {iteration}, Cost: {cost_value.item()}")
+ else:
+ glass_1 = cassi_system.optical_model.glass1
+ try:
+ glass_2 = cassi_system.optical_model.glass2
+ except:
+ pass
+ try:
+ glass_3 = cassi_system.optical_model.glass3
+ except:
+ pass
+
+ cassi_system.system_config["system architecture"]["dispersive element"]["wavelength center"] = latest_optical_params["lba_c"]
+ cassi_system.system_config["system architecture"]["dispersive element"]["alpha_c"] = latest_optical_params["alpha_c"]
+ cassi_system.system_config["system architecture"]["dispersive element"]["A1"] = latest_optical_params["A1"]
+ cassi_system.system_config["system architecture"]["dispersive element"]['glass1'] = glass_1
+
+
+ if cassi_system.system_config['system architecture']['dispersive element']['type'] in ["doubleprism", "amici", "tripleprism"]:
+ cassi_system.system_config["system architecture"]["dispersive element"]["A2"] = latest_optical_params["A2"]
+ cassi_system.system_config["system architecture"]["dispersive element"]['glass2'] = glass_2
- if plot_frequency is not None:
- if iteration % plot_frequency == 0:
- print(f"Exec time: {time.time() - time_start:.3f}s")
- plt.figure()
- plt.imshow(cassi_system.pattern.detach().numpy(), aspect=aspect_plot)
+
+ if cassi_system.system_config['system architecture']['dispersive element']['type'] in ["amici", "tripleprism"]:
+ cassi_system.system_config["system architecture"]["dispersive element"]["A3"] = latest_optical_params["A3"]
+ cassi_system.system_config["system architecture"]["dispersive element"]['glass3'] = glass_3
- plt.figure()
- plt.imshow(cassi_system.filtering_cube[:, :, cassi_system.filtering_cube.shape[2]//2].detach().numpy(), aspect=aspect_plot)
+ if cassi_system.system_config['system architecture']['dispersive element']['type'] in ["amici"]:
+ cassi_system.system_config["system architecture"]["dispersive element"]["A3"] = latest_optical_params["A1"]
+ cassi_system.system_config["system architecture"]["dispersive element"]['glass3'] = glass_1
- #plt.figure()
- #plt.plot(np.sum(cassi_system.filtering_cube[:, :, cassi_system.filtering_cube.shape[2]//2].detach().numpy(),axis=0))
+
- plt.figure()
- plt.imshow(cassi_system.measurement.detach().numpy(), cmap="gray")
- plt.colorbar()
- plt.show()
+ cassi_system.update_optical_model(cassi_system.system_config)
- cassi_system.array_x_positions.data = torch.relu(best_x.data)
- #cassi_system.array_x_positions.data = best_x.data
- cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = position)
- cassi_system.pattern = cassi_system.pattern.to(device)
- cassi_system.generate_filtering_cube()
+ with open(output_config_path, 'w') as yaml_file:
+ yaml.dump(config_system, yaml_file, default_flow_style=False)
- return cassi_system
diff --git a/simca/functions_patterns_generation.py b/simca/functions_patterns_generation.py
deleted file mode 100644
index bfe9468..0000000
--- a/simca/functions_patterns_generation.py
+++ /dev/null
@@ -1,344 +0,0 @@
-import numpy as np
-from scipy import fftpack
-from scipy import ndimage
-import h5py
-def generate_blue_noise_type_1_pattern(shape):
- """
- Generate blue noise (high frequency pseudo-random) type pattern
-
- Args:
- shape (tuple of int): shape of the pattern
-
- Returns:
- numpy.ndarray: binary blue noise type pattern
-
- """
-
- N = shape[0] * shape[1]
- rng = np.random.default_rng()
- noise = rng.standard_normal(N)
- noise = np.reshape(noise, shape)
-
- f_x = fftpack.fftfreq(shape[1])
- f_y = fftpack.fftfreq(shape[0])
- f_x_shift = fftpack.fftshift(f_x)
- f_y_shift = fftpack.fftshift(f_y)
- f_matrix = np.sqrt(f_x_shift[None, :] ** 2 + f_y_shift[:, None] ** 2)
-
- spectrum = fftpack.fftshift(fftpack.fft2(noise))
- filtered_spectrum = spectrum * f_matrix
- filtered_noise = fftpack.ifft2(fftpack.ifftshift(filtered_spectrum)).real
-
- # Make the pattern binary
- threshold = np.median(filtered_noise)
- binary_pattern = np.where(filtered_noise > threshold, 1, 0)
-
- return binary_pattern
-
-def generate_orthogonal_pattern(size, W, N):
- """
- Generate an orthogonal pattern according to https://hal.laas.fr/hal-02993037
-
- Args:
- size (list of int): size of the pattern
- W (int): number of wavelengths in the scene
- N (int): number of acquisitions
-
- Returns:
- numpy.ndarray: orthogonal pattern : shape = size[0] x (size[1]+W-1) x N):
- """
-
- C, R = size[0], size[1] # Number of columns, number of rows
-
- K = C + W - 1 # Number of columns in H
- M = int(np.ceil(W/N)) # Number of open mirrors
- H_model = np.zeros((R, W, N)) # Periodic model
- for line in range(R):
- available_pos = list(range(W)) # Positions of possible mirrors to open
- for n in range(N):
- if available_pos:
- if (len(available_pos)>=M):
- ind = np.random.choice(len(available_pos), M, replace=False) # Indices of the N positions among the available ones
- pos = np.array(available_pos)[ind] # N mirrors to open
- else:
- ind = list(range(len(available_pos)))
- pos = np.array(available_pos)
- H_model[line, pos, n] = 1 # Open the mirrors
- for i in sorted(ind, reverse=True):
- available_pos.pop(i) # Remove the positions of already opened mirrors
-
- pattern = np.tile(H_model, [1, int(np.ceil(K/W)), 1])[:, :K, :] # Repeat the model periodically
-
- return pattern
-
-def generate_ln_orthogonal_pattern(size, W, N):
- """
- Generate a Length-N orthogonal pattern according to https://hal.laas.fr/hal-02993037
-
- Args:
- size (tuple): size of the pattern
- W (int): number of wavelengths in the scene
- N (int): number of acquisitions
-
- Returns:
- numpy.ndarray : length-N orthogonal pattern of shape = size[0] x (size[1]+W-1) x N):
- """
-
- C, R = size[1], size[0] # Number of columns, number of rows
-
- K = C + W - 1 # Number of columns in H
- M = int(np.floor(W/N)) # Number of open mirrors
- H_model = np.zeros((R, W, N)) # Periodic model
- for line in range(R):
- for m in range(M):
- available = list(range(m*N, m*N+N)) # Positions of possible mirrors to open
- for n in range(N):
- ind = np.random.randint(len(available)) # Randomly choose a mirror among the possible ones
- H_model[line, available[ind], n] = 1 # Open the mirror
- available.pop(ind) # Remove the mirror from the list of possible ones
- available = list(range(M*N, W)) # List of positions where we can't apply the Length-N method (if W%N != 0)
- for n in range(W-(M*N)):
- ind = np.random.randint(len(available)) # Randomly open those mirrors among the remaining positions
- H_model[line, available[ind], n] = 1
- available.pop(ind)
- pattern = np.tile(H_model, [1, int(np.ceil(K/W)), 1])[:, :K, :]
-
- list_of_patterns = []
- for i in range(pattern.shape[2]):
- m = pattern[:, :-(W-1), i]
- list_of_patterns.append(m)
-
- return list_of_patterns
-
-def generate_random_pattern(shape, ROM):
- """
- Generate a random pattern with a given rate of open/close mirrors
-
- Args:
- shape (tuple of int): shape of the pattern
- ROM (float): ratio of open mirrors
-
- Returns:
- numpy.ndarray: random pattern
- """
-
- pattern = np.random.choice([0, 1], size=shape, p=[1 - ROM, ROM])
-
- return pattern
-
-def generate_slit_pattern(shape, slit_position,slit_width):
- """
- Generate a slit pattern that starts at the center of the image and goes to the right as slit position increases.
-
- Args:
- shape (tuple): shape of the pattern
- slit_position (int): position of the slit in relation to the central column
- slit_width (int): width of the slit in pixels
-
- Returns:
- numpy.ndarray: slit pattern
-
- """
- size_y, size_x = shape[0], shape[1]
- slit_position = size_x // 2 + slit_position
- slit_width = slit_width
- pattern = np.zeros((size_y,size_x))
-
- pattern[:, slit_position - slit_width // 2:slit_position + slit_width] = 1
-
- return pattern
-
-# Source of blue noise codes: https://momentsingraphics.de/BlueNoise.html
-def FindLargestVoid(BinaryPattern,StandardDeviation):
- """This function returns the indices of the largest void in the given binary
- pattern as defined by Ulichney.
- \param BinaryPattern A boolean array (should be two-dimensional although the
- implementation works in arbitrary dimensions).
- \param StandardDeviation The standard deviation used for the Gaussian filter
- in pixels. This can be a single float for an isotropic Gaussian or a
- tuple with one float per dimension for an anisotropic Gaussian.
- \return A flat index i such that BinaryPattern.flat[i] corresponds to the
- largest void. By definition this is a majority pixel.
- \sa GetVoidAndClusterBlueNoise"""
- # The minority value is always True for convenience
- if(np.count_nonzero(BinaryPattern)*2>=np.size(BinaryPattern)):
- BinaryPattern=np.logical_not(BinaryPattern)
- # Apply the Gaussian. We do not want to cut off the Gaussian at all because even
- # the tiniest difference can change the ranking. Therefore we apply the Gaussian
- # through a fast Fourier transform by means of the convolution theorem.
- FilteredArray=np.fft.ifftn(ndimage.fourier_gaussian(np.fft.fftn(np.where(BinaryPattern,1.0,0.0)),StandardDeviation)).real
- # Find the largest void
- return np.argmin(np.where(BinaryPattern,2.0,FilteredArray))
-
-# Source of blue noise codes: https://momentsingraphics.de/BlueNoise.html
-def FindTightestCluster(BinaryPattern,StandardDeviation):
- """Like FindLargestVoid() but finds the tightest cluster which is a minority
- pixel by definition.
- \sa GetVoidAndClusterBlueNoise"""
- if(np.count_nonzero(BinaryPattern)*2>=np.size(BinaryPattern)):
- BinaryPattern=np.logical_not(BinaryPattern)
- FilteredArray=np.fft.ifftn(ndimage.fourier_gaussian(np.fft.fftn(np.where(BinaryPattern,1.0,0.0)),StandardDeviation)).real
- return np.argmax(np.where(BinaryPattern,FilteredArray,-1.0))
-
-# Source of blue noise codes: https://momentsingraphics.de/BlueNoise.html
-def GetVoidAndClusterBlueNoise(OutputShape,StandardDeviation=1.5,InitialSeedFraction=0.1):
- """Generates a blue noise dither array of the given shape using the method
- proposed by Ulichney [1993] in "The void-and-cluster method for dither array
- generation" published in Proc. SPIE 1913.
- \param OutputShape The shape of the output array. This function works in
- arbitrary dimension, i.e. OutputShape can have arbitrary length. Though
- it is only tested for the 2D case where you should pass a tuple
- (Height,Width).
- \param StandardDeviation The standard deviation in pixels used for the
- Gaussian filter defining largest voids and tightest clusters. Larger
- values lead to more low-frequency content but better isotropy. Small
- values lead to more ordered patterns with less low-frequency content.
- Ulichney proposes to use a value of 1.5. If you want an anisotropic
- Gaussian, you can pass a tuple of length len(OutputShape) with one
- standard deviation per dimension.
- \param InitialSeedFraction The only non-deterministic step in the algorithm
- marks a small number of pixels in the grid randomly. This parameter
- defines the fraction of such points. It has to be positive but less
- than 0.5. Very small values lead to ordered patterns, beyond that there
- is little change.
- \return An integer array of shape OutputShape containing each integer from 0
- to np.prod(OutputShape)-1 exactly once."""
- nRank=np.prod(OutputShape)
- # Generate the initial binary pattern with a prescribed number of ones
- nInitialOne=max(1,min(int((nRank-1)/2),int(nRank*InitialSeedFraction)))
- # Start from white noise (this is the only randomized step)
- InitialBinaryPattern=np.zeros(OutputShape,dtype=bool)
- InitialBinaryPattern.flat=np.random.permutation(np.arange(nRank)) 0
- pca = PCA(n_dim_pca)
- pca.fit(img[mask])
-
- for c in np.unique(complete_gt):
- if c in ignored_labels:
- continue
- mask = complete_gt == c
- class_spectrums = img[mask]
- # pca = PCA(n_dim_pca)
- class_spectrums_pca = pca.transform(class_spectrums)
-
- mean_spectrum = np.mean(class_spectrums, axis=0)
- std_spectrum = np.std(class_spectrums, axis=0)
-
- stats_per_class['mean_spectrums'][class_names[c]] = mean_spectrum
- stats_per_class['std_spectrums'][class_names[c]] = std_spectrum
- stats_per_class['non_degenerate_mean_spectrums'][class_names[c]] = np.mean(class_spectrums_pca, axis=0)
- stats_per_class['non_degenerate_covariance'][class_names[c]] = np.cov(np.transpose(class_spectrums_pca))
-
- return stats_per_class
-
-
-
-def interpolate_data_along_wavelength(data, current_sampling, new_sampling, chunk_size=50):
- """Interpolate the input 3D data along a new sampling in the third axis.
-
- Args:
- data (numpy.ndarray): 3D data to interpolate
- current_sampling (numpy.ndarray): current sampling for the 3rd axis
- new_sampling (numpy.ndarray): new sampling for the 3rd axis
- chunk_size (int): size of the chunks to use for the interpolation
- """
-
- # Generate the coordinates for the original grid
- x = np.arange(data.shape[0])
- y = np.arange(data.shape[1])
- z = current_sampling
-
- # Initialize an empty array for the result
- interpolated_data = np.empty((data.shape[0], data.shape[1], len(new_sampling)))
-
- # Perform the interpolation in chunks
- for i in range(0, data.shape[0], chunk_size):
- for j in range(0, data.shape[1], chunk_size):
- new_coordinates = np.meshgrid(x[i:i+chunk_size], y[j:j+chunk_size], new_sampling, indexing='ij')
- interpolated_data[i:i+chunk_size, j:j+chunk_size, :] = interpn((x[i:i+chunk_size], y[j:j+chunk_size], z), data[i:i+chunk_size, j:j+chunk_size, :], tuple(new_coordinates))
-
- return interpolated_data
\ No newline at end of file
diff --git a/simca/functions_scenes_torch.py b/simca/functions_scenes_torch.py
deleted file mode 100644
index 2a8bd52..0000000
--- a/simca/functions_scenes_torch.py
+++ /dev/null
@@ -1,3 +0,0 @@
-import torch
-import snoop
-
diff --git a/simca/helper.py b/simca/helper.py
new file mode 100644
index 0000000..1271e3f
--- /dev/null
+++ b/simca/helper.py
@@ -0,0 +1,71 @@
+import yaml
+import math
+import os
+import numpy as np
+from datetime import datetime
+import h5py
+import torch
+
+def load_yaml_config(file_path):
+ """
+ Load a YAML configuration file as a dictionary
+
+ Args:
+ file_path (str): path to the YAML configuration file
+
+ Returns:
+ dict: configuration dictionary
+ """
+ with open(file_path, "r") as file:
+ config = yaml.safe_load(file)
+ return config
+
+
+
+
+
+
+
+cm_data = [[0.2081, 0.1663, 0.5292], [0.2116238095, 0.1897809524, 0.5776761905],
+ [0.212252381, 0.2137714286, 0.6269714286], [0.2081, 0.2386, 0.6770857143],
+ [0.1959047619, 0.2644571429, 0.7279], [0.1707285714, 0.2919380952,
+ 0.779247619], [0.1252714286, 0.3242428571, 0.8302714286],
+ [0.0591333333, 0.3598333333, 0.8683333333], [0.0116952381, 0.3875095238,
+ 0.8819571429], [0.0059571429, 0.4086142857, 0.8828428571],
+ [0.0165142857, 0.4266, 0.8786333333], [0.032852381, 0.4430428571,
+ 0.8719571429], [0.0498142857, 0.4585714286, 0.8640571429],
+ [0.0629333333, 0.4736904762, 0.8554380952], [0.0722666667, 0.4886666667,
+ 0.8467], [0.0779428571, 0.5039857143, 0.8383714286],
+ [0.079347619, 0.5200238095, 0.8311809524], [0.0749428571, 0.5375428571,
+ 0.8262714286], [0.0640571429, 0.5569857143, 0.8239571429],
+ [0.0487714286, 0.5772238095, 0.8228285714], [0.0343428571, 0.5965809524,
+ 0.819852381], [0.0265, 0.6137, 0.8135], [0.0238904762, 0.6286619048,
+ 0.8037619048], [0.0230904762, 0.6417857143, 0.7912666667],
+ [0.0227714286, 0.6534857143, 0.7767571429], [0.0266619048, 0.6641952381,
+ 0.7607190476], [0.0383714286, 0.6742714286, 0.743552381],
+ [0.0589714286, 0.6837571429, 0.7253857143],
+ [0.0843, 0.6928333333, 0.7061666667], [0.1132952381, 0.7015, 0.6858571429],
+ [0.1452714286, 0.7097571429, 0.6646285714], [0.1801333333, 0.7176571429,
+ 0.6424333333], [0.2178285714, 0.7250428571, 0.6192619048],
+ [0.2586428571, 0.7317142857, 0.5954285714], [0.3021714286, 0.7376047619,
+ 0.5711857143], [0.3481666667, 0.7424333333, 0.5472666667],
+ [0.3952571429, 0.7459, 0.5244428571], [0.4420095238, 0.7480809524,
+ 0.5033142857], [0.4871238095, 0.7490619048, 0.4839761905],
+ [0.5300285714, 0.7491142857, 0.4661142857], [0.5708571429, 0.7485190476,
+ 0.4493904762], [0.609852381, 0.7473142857, 0.4336857143],
+ [0.6473, 0.7456, 0.4188], [0.6834190476, 0.7434761905, 0.4044333333],
+ [0.7184095238, 0.7411333333, 0.3904761905],
+ [0.7524857143, 0.7384, 0.3768142857], [0.7858428571, 0.7355666667,
+ 0.3632714286], [0.8185047619, 0.7327333333, 0.3497904762],
+ [0.8506571429, 0.7299, 0.3360285714], [0.8824333333, 0.7274333333, 0.3217],
+ [0.9139333333, 0.7257857143, 0.3062761905], [0.9449571429, 0.7261142857,
+ 0.2886428571], [0.9738952381, 0.7313952381, 0.266647619],
+ [0.9937714286, 0.7454571429, 0.240347619], [0.9990428571, 0.7653142857,
+ 0.2164142857], [0.9955333333, 0.7860571429, 0.196652381],
+ [0.988, 0.8066, 0.1793666667], [0.9788571429, 0.8271428571, 0.1633142857],
+ [0.9697, 0.8481380952, 0.147452381], [0.9625857143, 0.8705142857, 0.1309],
+ [0.9588714286, 0.8949, 0.1132428571], [0.9598238095, 0.9218333333,
+ 0.0948380952], [0.9661, 0.9514428571, 0.0755333333],
+ [0.9763, 0.9831, 0.0538]]
+
+
diff --git a/simca/tests/__init__.py b/simca/tests/__init__.py
deleted file mode 100644
index e69de29..0000000
diff --git a/simca/tests/test_cassisystem_initialization.py b/simca/tests/test_cassisystem_initialization.py
deleted file mode 100644
index 0513648..0000000
--- a/simca/tests/test_cassisystem_initialization.py
+++ /dev/null
@@ -1,315 +0,0 @@
-import unittest
-import numpy as np
-import random
-import glob
-from simca.functions_general_purpose import load_yaml_config
-from simca.CassiSystem import CassiSystem
-import h5py as h5
-import os
-
-class TestCassiSystemInitialization(unittest.TestCase):
-
- def setUp(self):
- self.config_system = load_yaml_config('./simca/tests/test_configs/cassi_system.yml')
- self.config_dataset = load_yaml_config('./simca/tests/test_configs/dataset.yml')
- def test_config_system_loading(self):
-
- config_files = glob.glob('./simca/tests/test_configs/*.yml')
-
- for config_file in config_files:
- config_system = load_yaml_config(config_file)
- self.assertIsInstance(config_system, dict)
-
- self.config_system = load_yaml_config('./simca/tests/test_configs/cassi_system.yml')
- self.config_dataset = load_yaml_config('./simca/tests/test_configs/dataset.yml')
- def test_coded_aper_grid_generation(self):
-
- config_files = glob.glob('./simca/tests/test_configs/cassi_system*.yml')
-
- for config_file in config_files:
- config_system = load_yaml_config(config_file)
-
- cassi_system = CassiSystem(system_config=config_system)
-
- self.assertEqual(cassi_system.X_coded_aper_coordinates.shape, (config_system["coded aperture"]["number of pixels along Y"], config_system["coded aperture"]["number of pixels along X"]))
- self.assertEqual(cassi_system.Y_coded_aper_coordinates.shape, (config_system["coded aperture"]["number of pixels along Y"], config_system["coded aperture"]["number of pixels along X"]))
-
- def test_loading_dataset(self):
-
- # load all datasets in the datasets directory
-
- for dataset in glob.glob('./datasets/*'):
-
- dataset_name = os.path.basename(os.path.normpath(dataset))
- # dataset_name = dataset.split('\\')[-1].split('\\')[0]
-
-
- cassi_system = CassiSystem(system_config=self.config_system)
-
- cassi_system.load_dataset(dataset_name, self.config_dataset["datasets directory"])
-
- self.assertIsInstance(cassi_system.dataset, np.ndarray)
- self.assertEqual(cassi_system.dataset.ndim, 3)
-
- self.assertIsInstance(cassi_system.dataset_wavelengths, np.ndarray)
- self.assertEqual(cassi_system.dataset_wavelengths.ndim, 1)
- self.assertIs(cassi_system.dataset_wavelengths.shape[0] > 0, True)
- self.assertEqual(cassi_system.dataset_wavelengths.shape[0], cassi_system.dataset.shape[2])
-
- if cassi_system.dataset_labels is not None :
- self.assertIsInstance(cassi_system.dataset_labels,np.ndarray)
- self.assertEqual(cassi_system.dataset_labels.ndim, 2)
- self.assertEqual(cassi_system.dataset_labels.shape[0], cassi_system.dataset.shape[0])
- self.assertEqual(cassi_system.dataset_labels.shape[1], cassi_system.dataset.shape[1])
-
- self.assertIsInstance(cassi_system.dataset_label_names, list)
- self.assertIs(len(cassi_system.dataset_label_names),len(list(np.unique(cassi_system.dataset_labels))))
-
- # ignored labels not tested
-
- self.assertIsInstance(cassi_system.dataset_palette, dict)
-
- def test_generate_pattern(self):
-
- cassi_system = CassiSystem(system_config=self.config_system)
-
- config_files = glob.glob('./simca/tests/test_configs/filtering_simple*.yml')
-
- for config_file in config_files:
-
- config_pattern = load_yaml_config(config_file)
- pattern = cassi_system.generate_2D_pattern(config_pattern)
-
- self.assertIsInstance(pattern, np.ndarray)
- self.assertEqual(pattern.shape, (self.config_system["coded aperture"]["number of pixels along Y"], self.config_system["coded aperture"]["number of pixels along X"]))
-
- def test_generate_multiple_patterns(self,num_tests=4,number_of_pattern=3):
-
- config_system_files = glob.glob('./simca/tests/test_configs/cassi_system*.yml')
- config_patterns_files = glob.glob('./simca/tests/test_configs/filtering_multiple*.yml')
-
- # Create all possible combinations of system and pattern configs
- all_combinations = [(system, coded_aperture) for system in config_system_files for coded_aperture in config_patterns_files]
-
- # Randomly choose 'num_tests' combinations to test
- selected_combinations = random.sample(all_combinations, num_tests)
-
- for config_system_file, config_patterns_file in selected_combinations:
- config_system = load_yaml_config(config_system_file)
- config_patterns = load_yaml_config(config_patterns_file)
-
- cassi_system = CassiSystem(system_config=config_system)
- cassi_system.generate_multiple_patterns(config_patterns,number_of_patterns=number_of_pattern)
- cassi_system.propagate_coded_aperture_grid()
- list_of_filtering_cubes = cassi_system.generate_multiple_filtering_cubes(number_of_patterns=number_of_pattern)
-
- self.assertIsInstance(list_of_filtering_cubes,list)
- self.assertEqual(len(list_of_filtering_cubes),number_of_pattern)
- self.assertEqual(list_of_filtering_cubes[0].ndim, 3)
- self.assertEqual(list_of_filtering_cubes[0].shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(list_of_filtering_cubes[0].shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
- self.assertEqual(list_of_filtering_cubes[0].shape[2], len(cassi_system.optical_model.system_wavelengths))
-
- self.assertEqual(list_of_filtering_cubes[-1].ndim, 3)
- self.assertEqual(list_of_filtering_cubes[-1].shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(list_of_filtering_cubes[-1].shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
- self.assertEqual(list_of_filtering_cubes[-1].shape[2], len(cassi_system.optical_model.system_wavelengths))
- def test_values_pattern_h5(self):
-
- config_folders = glob.glob('./simca/tests/test_configs/mask_*')
-
- for config_folder in config_folders:
- config_system = load_yaml_config(os.path.join(config_folder, "config_system.yml"))
- cassi_system = CassiSystem(system_config=config_system)
-
- config_file = os.path.join(config_folder, "config_pattern_gen.yml")
- config_pattern = load_yaml_config(config_file)
- pattern = cassi_system.generate_2D_pattern(config_pattern)
-
- with h5.File(os.path.join(config_folder, "pattern.h5"), 'r') as f:
- true_pattern = np.array(f['pattern'])
-
- self.assertIsNone(np.testing.assert_array_equal(pattern, true_pattern))
-
- def test_propagate_coded_aperture_grid(self):
-
- cassi_system = CassiSystem(system_config=self.config_system)
-
- config_files = glob.glob('./simca/tests/test_configs/filtering_simple*.yml')
-
- for config_file in config_files:
-
- config_pattern = load_yaml_config(config_file)
- cassi_system.generate_2D_pattern(config_pattern)
- X_grid, Y_grid, W_list = cassi_system.propagate_coded_aperture_grid()
-
- self.assertIsInstance(X_grid, np.ndarray)
- self.assertEqual(X_grid.ndim, 3)
- self.assertEqual(X_grid.shape[0], self.config_system["coded aperture"]["number of pixels along Y"])
- self.assertEqual(X_grid.shape[1], self.config_system["coded aperture"]["number of pixels along X"])
- self.assertEqual(X_grid.shape[2], W_list.shape[0])
-
- self.assertIsInstance(Y_grid, np.ndarray)
- self.assertEqual(Y_grid.ndim, 3)
- self.assertEqual(Y_grid.shape[0], self.config_system["coded aperture"]["number of pixels along Y"])
- self.assertEqual(Y_grid.shape[1], self.config_system["coded aperture"]["number of pixels along X"])
- self.assertEqual(Y_grid.shape[2], W_list.shape[0])
-
-
- def test_generate_filtering_cube(self, num_tests=5):
-
- config_system_files = glob.glob('./simca/tests/test_configs/cassi_system*.yml')
- config_patterns_files = glob.glob('./simca/tests/test_configs/filtering_simple*.yml')
-
- # Create all possible combinations of system and coded_aperture configs
- all_combinations = [(system, pattern) for system in config_system_files for pattern in config_patterns_files]
-
- # Randomly choose 'num_tests' combinations to test
- selected_combinations = random.sample(all_combinations, num_tests)
-
- for config_system_file, config_patterns_file in selected_combinations:
- config_system = load_yaml_config(config_system_file)
- config_patterns = load_yaml_config(config_patterns_file)
-
- cassi_system = CassiSystem(system_config=config_system)
- cassi_system.generate_2D_pattern(config_patterns)
- cassi_system.propagate_coded_aperture_grid()
- filtering_cube = cassi_system.generate_filtering_cube()
-
- self.assertIsInstance(filtering_cube, np.ndarray)
- self.assertEqual(filtering_cube.ndim, 3)
- self.assertEqual(filtering_cube.shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(filtering_cube.shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
- self.assertEqual(filtering_cube.shape[2], len(cassi_system.optical_model.system_wavelengths))
-
- def test_values_filtering_cube(self):
- config_folders = glob.glob('./simca/tests/test_configs/mask_*')
-
- for config_folder in config_folders:
- config_system = load_yaml_config(os.path.join(config_folder, "config_system.yml"))
- cassi_system = CassiSystem(system_config = config_system)
-
- config_file = os.path.join(config_folder, "config_pattern_gen.yml")
- config_pattern = load_yaml_config(config_file)
- cassi_system.generate_2D_pattern(config_pattern)
- cassi_system.propagate_coded_aperture_grid()
-
- filtering_cube = cassi_system.generate_filtering_cube()
-
- config_values = load_yaml_config(os.path.join(config_folder, "config_test_values.yml"))["filtering_cube"]
-
- res_values = load_yaml_config(os.path.join(config_folder, "test_values.yml"))["filtering_cube"]
-
- for i in range(1, 9):
- self.assertEqual(filtering_cube[tuple(config_values[f"pos{i}"])], res_values[i-1])
-
- self.assertEqual(np.sum(filtering_cube), res_values[8])
- self.assertEqual(np.sum(np.trace(filtering_cube, axis1=0, axis2=1)), res_values[9])
- self.assertEqual(np.sum(filtering_cube[:][1][:]), res_values[10])
-
-
-
-
- def test_acquisition(self, num_tests=5, num_acq=1):
- config_system_files = glob.glob('./simca/tests/test_configs/cassi_system*.yml')
- if num_acq > 1:
- config_patterns_files = glob.glob('./simca/tests/test_configs/filtering_multiple*.yml')
- else:
- config_patterns_files = glob.glob('./simca/tests/test_configs/filtering_simple*.yml')
-
- config_datasets = os.listdir(self.config_dataset["datasets directory"])
-
- # Create all possible combinations of system and pattern configs
- all_combinations = [(system, dataset, coded_aperture) for system in config_system_files
- for coded_aperture in config_patterns_files
- for dataset in config_datasets]
-
- # Randomly choose 'num_tests' combinations to test
- selected_combinations = random.sample(all_combinations, num_tests)
-
- for config_system_file, dataset_name, config_patterns_file in selected_combinations:
- config_system = load_yaml_config(config_system_file)
- config_patterns = load_yaml_config(config_patterns_file)
-
- cassi_system = CassiSystem(system_config=config_system)
-
- cassi_system.load_dataset(dataset_name, self.config_dataset["datasets directory"])
-
- if num_acq > 1:
- cassi_system.generate_multiple_patterns(config_patterns, number_of_patterns=num_acq)
- else:
- cassi_system.generate_2D_pattern(config_patterns)
- cassi_system.propagate_coded_aperture_grid()
-
- if num_acq > 1:
- cassi_system.generate_multiple_filtering_cubes(number_of_patterns=num_acq)
- list_of_measurements = cassi_system.multiple_image_acquisitions(nb_of_filtering_cubes=num_acq)
-
- self.assertIsInstance(list_of_measurements, list)
- self.assertEqual(len(list_of_measurements), num_acq)
- self.assertEqual(list_of_measurements[0].ndim, 2)
- self.assertEqual(list_of_measurements[0].shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(list_of_measurements[0].shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
-
- self.assertEqual(list_of_measurements[-1].ndim, 2)
- self.assertEqual(list_of_measurements[-1].shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(list_of_measurements[-1].shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
- else:
- cassi_system.generate_filtering_cube()
- measurement = cassi_system.image_acquisition()
-
- self.assertIsInstance(measurement, np.ndarray)
- self.assertEqual(measurement.ndim, 2)
- self.assertEqual(measurement.shape[0], cassi_system.Y_detector_coordinates_grid.shape[0])
- self.assertEqual(measurement.shape[1], cassi_system.X_detector_coordinates_grid.shape[1])
-
-
- def test_values_acquisition(self):
- config_folders = glob.glob('./simca/tests/test_configs/mask_*')
-
- for config_folder in config_folders:
- config_system = load_yaml_config(os.path.join(config_folder, "config_system.yml"))
-
- cassi_system = CassiSystem(system_config=config_system)
-
- cassi_system.load_dataset("lego" if config_folder[-4:] == "lego" else "paviaU",
- self.config_dataset["datasets directory"])
-
- config_file = os.path.join(config_folder, "config_pattern_gen.yml")
- config_pattern = load_yaml_config(config_file)
- cassi_system.generate_2D_pattern(config_pattern)
- cassi_system.propagate_coded_aperture_grid()
-
- cassi_system.generate_filtering_cube()
-
- measurement = cassi_system.image_acquisition()
-
- for item in ["filtered_interpolated_scene", "interpolated_scene", "measurement"]:
- config_values = load_yaml_config(os.path.join(config_folder, "config_test_values.yml"))[item]
- res_values = load_yaml_config(os.path.join(config_folder, "test_values.yml"))[item]
-
- tested_item = measurement
- if item == "filtered_interpolated_scene":
- tested_item = cassi_system.last_filtered_interpolated_scene
-
- self.assertEqual(np.sum(tested_item), res_values[8])
- self.assertEqual(np.sum(np.trace(tested_item, axis1=0, axis2=1)), res_values[9])
- self.assertEqual(np.sum(tested_item[:][2][:]), res_values[10])
- elif item == "interpolated_scene":
- tested_item = cassi_system.interpolated_scene
- self.assertEqual(np.sum(tested_item), res_values[8])
- self.assertEqual(np.sum(np.trace(tested_item, axis1=0, axis2=1)), res_values[9])
- self.assertEqual(np.sum(tested_item[:][3][:]), res_values[10])
- else:
- self.assertEqual(np.trace(tested_item), res_values[8])
- self.assertEqual(np.sum(tested_item[:][4]), res_values[9])
- self.assertEqual(np.sum(tested_item[7][:]), res_values[10])
-
- for i in range(1, 9):
- self.assertEqual(tested_item[tuple(config_values[f"pos{i}"])], res_values[i - 1])
-
-
-if __name__ == '__main__':
- unittest.main()
-
-
diff --git a/simca/tests/test_configs/cassi_system.yml b/simca/tests/test_configs/cassi_system.yml
deleted file mode 100755
index 3fe0670..0000000
--- a/simca/tests/test_configs/cassi_system.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: grating # name of the dispersive element
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 80 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 23 # number of pixels along X axis -- no units
- number of pixels along Y: 21 # number of pixels along Y axis -- no units
- pixel size along X: 400 # pixel size along X -- in um
- pixel size along Y: 400 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 31 # number of pixels along X axis -- no units
- number of pixels along Y: 22 # number of pixels along Y axis -- no units
- pixel size along X: 550 # pixel size along X -- in um
- pixel size along Y: 550 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 610 # maximum wavelength -- in nm
- number of spectral samples: 11
diff --git a/simca/tests/test_configs/cassi_system_grating.yml b/simca/tests/test_configs/cassi_system_grating.yml
deleted file mode 100755
index 3fe0670..0000000
--- a/simca/tests/test_configs/cassi_system_grating.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: grating # name of the dispersive element
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 80 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 23 # number of pixels along X axis -- no units
- number of pixels along Y: 21 # number of pixels along Y axis -- no units
- pixel size along X: 400 # pixel size along X -- in um
- pixel size along Y: 400 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 31 # number of pixels along X axis -- no units
- number of pixels along Y: 22 # number of pixels along Y axis -- no units
- pixel size along X: 550 # pixel size along X -- in um
- pixel size along Y: 550 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 610 # maximum wavelength -- in nm
- number of spectral samples: 11
diff --git a/simca/tests/test_configs/cassi_system_grating_even.yml b/simca/tests/test_configs/cassi_system_grating_even.yml
deleted file mode 100755
index c6251ff..0000000
--- a/simca/tests/test_configs/cassi_system_grating_even.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: grating # name of the dispersive element
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 80 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 22 # number of pixels along X axis -- no units
- number of pixels along Y: 10 # number of pixels along Y axis -- no units
- pixel size along X: 400 # pixel size along X -- in um
- pixel size along Y: 400 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 32 # number of pixels along X axis -- no units
- number of pixels along Y: 12 # number of pixels along Y axis -- no units
- pixel size along X: 550 # pixel size along X -- in um
- pixel size along Y: 550 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 610 # maximum wavelength -- in nm
- number of spectral samples: 11
diff --git a/simca/tests/test_configs/cassi_system_prism.yml b/simca/tests/test_configs/cassi_system_prism.yml
deleted file mode 100755
index 14c18a1..0000000
--- a/simca/tests/test_configs/cassi_system_prism.yml
+++ /dev/null
@@ -1,33 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- system name: HYACAMEO
-
-system architecture:
- system type: DD-CASSI
- propagation type: simca
- focal lens: 200000
- dispersive element:
- # dispersive element caracteristics
- type: prism # name of the dispersive element
- A: 60 # apex angle of the prism in degrees (only used if type == 'prism') -- in degrees
- m: 1 # grating order to consider (only used if type == 'grating') -- no units
- G: 150 # grating density (only used if type == 'grating') -- in lines/mm
- delta alpha c: 0
- delta beta c: 0
- wavelength center: 550 # central wavelength -- in nm
-detector:
- number of pixels along X: 23 # number of pixels along X axis -- no units
- number of pixels along Y: 21 # number of pixels along Y axis -- no units
- pixel size along X: 400 # pixel size along X -- in um
- pixel size along Y: 400 # pixel size along Y -- in um
-coded aperture:
- number of pixels along X: 31 # number of pixels along X axis -- no units
- number of pixels along Y: 22 # number of pixels along Y axis -- no units
- pixel size along X: 550 # pixel size along X -- in um
- pixel size along Y: 550 # pixel size along Y -- in um
-
-spectral range:
- wavelength min: 450 # minimum wavelength -- in nm
- wavelength max: 610 # maximum wavelength -- in nm
- number of spectral samples: 11
diff --git a/simca/tests/test_configs/dataset.yml b/simca/tests/test_configs/dataset.yml
deleted file mode 100755
index 52835c7..0000000
--- a/simca/tests/test_configs/dataset.yml
+++ /dev/null
@@ -1 +0,0 @@
-datasets directory: ./datasets/
diff --git a/simca/tests/test_configs/filtering_multiple_LN_random.yml b/simca/tests/test_configs/filtering_multiple_LN_random.yml
deleted file mode 100755
index 117e09d..0000000
--- a/simca/tests/test_configs/filtering_multiple_LN_random.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- results directory: ./data/patterns/
-
-pattern:
- type: LN-random
- slit position: -120
- slit width: 1
- ROM : 0.2
-
diff --git a/simca/tests/test_configs/filtering_multiple_blue_noise_type_1.yml b/simca/tests/test_configs/filtering_multiple_blue_noise_type_1.yml
deleted file mode 100755
index 21503d4..0000000
--- a/simca/tests/test_configs/filtering_multiple_blue_noise_type_1.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- results directory: ./data/patterns/
-
-pattern:
- type: blue-noise type 1
- slit position: -120
- slit width: 1
- ROM : 0.5
-
diff --git a/simca/tests/test_configs/filtering_simple_random.yml b/simca/tests/test_configs/filtering_simple_random.yml
deleted file mode 100755
index 827ca20..0000000
--- a/simca/tests/test_configs/filtering_simple_random.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- results directory: ./data/patterns/
-
-pattern:
- type: random
- slit position: -120
- slit width: 1
- ROM : 0.5
-
diff --git a/simca/tests/test_configs/filtering_simple_slit.yml b/simca/tests/test_configs/filtering_simple_slit.yml
deleted file mode 100755
index 362d04d..0000000
--- a/simca/tests/test_configs/filtering_simple_slit.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-##### Configuration file for the chosen optical system
-
-infos:
- results directory: ./data/patterns/
-
-pattern:
- type: slit
- slit position: -120
- slit width: 1
- ROM : 0.5
-
diff --git a/simca/tests/test_configs/mask_1_paviaU/config_acquisition.yml b/simca/tests/test_configs/mask_1_paviaU/config_acquisition.yml
deleted file mode 100755
index ebe6986..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_1
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_1_paviaU/config_pattern.yml b/simca/tests/test_configs/mask_1_paviaU/config_pattern.yml
deleted file mode 100755
index 998e352..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.2
- type: random
diff --git a/simca/tests/test_configs/mask_1_paviaU/config_pattern_gen.yml b/simca/tests/test_configs/mask_1_paviaU/config_pattern_gen.yml
deleted file mode 100755
index f4f9813..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_1_paviaU/pattern.h5"
diff --git a/simca/tests/test_configs/mask_1_paviaU/config_system.yml b/simca/tests/test_configs/mask_1_paviaU/config_system.yml
deleted file mode 100755
index 6a61b89..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 253
- number of pixels along Y: 201
- pixel size along X: 55
- pixel size along Y: 55
-detector:
- number of pixels along X: 201
- number of pixels along Y: 201
- pixel size along X: 40
- pixel size along Y: 40
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 50
- wavelength max: 640
- wavelength min: 450
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: prism
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_1_paviaU/config_test_values.yml b/simca/tests/test_configs/mask_1_paviaU/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_1_paviaU/pattern.h5 b/simca/tests/test_configs/mask_1_paviaU/pattern.h5
deleted file mode 100755
index 1ee7a71..0000000
Binary files a/simca/tests/test_configs/mask_1_paviaU/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_1_paviaU/test_values.yml b/simca/tests/test_configs/mask_1_paviaU/test_values.yml
deleted file mode 100755
index bf419da..0000000
--- a/simca/tests/test_configs/mask_1_paviaU/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.0
- - 0.4562489998260105
- - 0.0008222301214630717
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 401158.3428907903
- - 2157.330726395199
- - 2109.87383629261
-filtered_interpolated_scene:
- - 0.0
- - 0.0
- - 0.783820650342228
- - 0.0
- - 0.0
- - 221.46541402863778
- - 0.0
- - 268.0363568387399
- - 430984443.1225793
- - 2418725.3938502944
- - 1593072.6377794368
-interpolated_scene:
- - 692.0764119601328
- - 638.4608448030376
- - 726.280493592786
- - 585.3663977218795
- - 426.78785002373036
- - 606.0
- - 833.4803037494066
- - 644.7441860465118
- - 2159171766.105838
- - 10976422.60180351
- - 8674573.360227812
-measurement:
- - 6561.947214345341
- - 5360.68591810263
- - 3083.7532730829944
- - 3708.6646717614713
- - 14695.497168224794
- - 535.2547920650765
- - 5636.719297618377
- - 7334.099727680887
- - 2418725.3938502944
- - 1451464.3451155904
- - 1719785.9128740178
diff --git a/simca/tests/test_configs/mask_2_paviaU/config_acquisition.yml b/simca/tests/test_configs/mask_2_paviaU/config_acquisition.yml
deleted file mode 100755
index f127d70..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_2
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_2_paviaU/config_pattern.yml b/simca/tests/test_configs/mask_2_paviaU/config_pattern.yml
deleted file mode 100755
index 998e352..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.2
- type: random
diff --git a/simca/tests/test_configs/mask_2_paviaU/config_pattern_gen.yml b/simca/tests/test_configs/mask_2_paviaU/config_pattern_gen.yml
deleted file mode 100755
index 408a644..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_2_paviaU/pattern.h5"
diff --git a/simca/tests/test_configs/mask_2_paviaU/config_system.yml b/simca/tests/test_configs/mask_2_paviaU/config_system.yml
deleted file mode 100755
index ede830d..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 280
- number of pixels along Y: 180
- pixel size along X: 60
- pixel size along Y: 60
-detector:
- number of pixels along X: 201
- number of pixels along Y: 201
- pixel size along X: 40
- pixel size along Y: 40
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 40
- wavelength max: 640
- wavelength min: 450
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: prism
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_2_paviaU/config_test_values.yml b/simca/tests/test_configs/mask_2_paviaU/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_2_paviaU/pattern.h5 b/simca/tests/test_configs/mask_2_paviaU/pattern.h5
deleted file mode 100755
index bdfe385..0000000
Binary files a/simca/tests/test_configs/mask_2_paviaU/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_2_paviaU/test_values.yml b/simca/tests/test_configs/mask_2_paviaU/test_values.yml
deleted file mode 100755
index 5aad682..0000000
--- a/simca/tests/test_configs/mask_2_paviaU/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.0
- - 0.4781231023906518
- - 0.0
- - 0.4033565646219036
- - 0.7295859062206334
- - 0.46909178641873817
- - 0.42946621193258877
- - 0.16729098686093252
- - 322699.8704635679
- - 1598.8711749374324
- - 1642.4934344419808
-filtered_interpolated_scene:
- - 105.74936684397196
- - 11.81995585511221
- - 0.0
- - 0.0
- - 0.0
- - 255.76203997676916
- - 0.0
- - 71.90370222275355
- - 345261914.5863092
- - 1741704.4192137509
- - 1202707.0266184276
-interpolated_scene:
- - 684.83542039356
- - 654.8354203935601
- - 797.5384615384614
- - 621.8318425760287
- - 465.55098389982095
- - 581.0626118067973
- - 799.5831842576026
- - 644.7441860465118
- - 1726947650.0035784
- - 8779586.089445438
- - 6939396.205724508
-measurement:
- - 14998.176748672591
- - 3936.0774803689487
- - 9203.297838803872
- - 4703.992403739194
- - 5024.117612651319
- - 1212.6203207057674
- - 3152.069979766863
- - 4656.069488554003
- - 1741704.4192137509
- - 1257968.1722089043
- - 1148565.2032749562
diff --git a/simca/tests/test_configs/mask_3_paviaU/config_acquisition.yml b/simca/tests/test_configs/mask_3_paviaU/config_acquisition.yml
deleted file mode 100755
index e8bfcc2..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_3
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_3_paviaU/config_pattern.yml b/simca/tests/test_configs/mask_3_paviaU/config_pattern.yml
deleted file mode 100755
index 8adf7d5..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.3
- type: random
diff --git a/simca/tests/test_configs/mask_3_paviaU/config_pattern_gen.yml b/simca/tests/test_configs/mask_3_paviaU/config_pattern_gen.yml
deleted file mode 100755
index 2353dc4..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_3_paviaU/pattern.h5"
diff --git a/simca/tests/test_configs/mask_3_paviaU/config_system.yml b/simca/tests/test_configs/mask_3_paviaU/config_system.yml
deleted file mode 100755
index 61bb9ad..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 250
- number of pixels along Y: 250
- pixel size along X: 40
- pixel size along Y: 40
-detector:
- number of pixels along X: 201
- number of pixels along Y: 201
- pixel size along X: 40
- pixel size along Y: 40
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 65
- wavelength max: 750
- wavelength min: 450
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: prism
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_3_paviaU/config_test_values.yml b/simca/tests/test_configs/mask_3_paviaU/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_3_paviaU/pattern.h5 b/simca/tests/test_configs/mask_3_paviaU/pattern.h5
deleted file mode 100755
index 2c046a8..0000000
Binary files a/simca/tests/test_configs/mask_3_paviaU/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_3_paviaU/test_values.yml b/simca/tests/test_configs/mask_3_paviaU/test_values.yml
deleted file mode 100755
index 8ea7913..0000000
--- a/simca/tests/test_configs/mask_3_paviaU/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.5019137995044721
- - 0.4343108759386766
- - 0.498919083507629
- - 0.5012110821158251
- - 0.8005539787639803
- - 0.4980924263828779
- - 0.0
- - 0.0
- - 779158.1875528373
- - 3817.191559136262
- - 4353.563925028386
-filtered_interpolated_scene:
- - 127.71775505857346
- - 94.00100747835882
- - 409.86673434422755
- - 0.0
- - 222.3718821167046
- - 106.39520263725046
- - 222.4101631893931
- - 323.1086725354025
- - 912218474.764462
- - 4741071.782112292
- - 4406946.781538208
-interpolated_scene:
- - 682.6933139534884
- - 651.5566860465117
- - 782.5000000000001
- - 610.2906976744187
- - 460.2180232558141
- - 592.9534883720929
- - 808.5450581395347
- - 644.7441860465118
- - 3052977499.545059
- - 15910900.296511626
- - 12631115.042151162
-measurement:
- - 11418.438332962376
- - 13366.988450811368
- - 6609.483602812603
- - 23322.530910444148
- - 18205.08371650114
- - 2908.2515451353565
- - 28847.001182023727
- - 23297.688387114125
- - 4741071.782112291
- - 3623902.192840429
- - 3956084.724631695
diff --git a/simca/tests/test_configs/mask_4_paviaU/config_acquisition.yml b/simca/tests/test_configs/mask_4_paviaU/config_acquisition.yml
deleted file mode 100755
index 4902a52..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_4
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_4_paviaU/config_pattern.yml b/simca/tests/test_configs/mask_4_paviaU/config_pattern.yml
deleted file mode 100755
index 29964a4..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.1
- type: random
diff --git a/simca/tests/test_configs/mask_4_paviaU/config_pattern_gen.yml b/simca/tests/test_configs/mask_4_paviaU/config_pattern_gen.yml
deleted file mode 100755
index b0aaa11..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_4_paviaU/pattern.h5"
diff --git a/simca/tests/test_configs/mask_4_paviaU/config_system.yml b/simca/tests/test_configs/mask_4_paviaU/config_system.yml
deleted file mode 100755
index b76083c..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 260
- number of pixels along Y: 290
- pixel size along X: 35
- pixel size along Y: 35
-detector:
- number of pixels along X: 240
- number of pixels along Y: 230
- pixel size along X: 60
- pixel size along Y: 60
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 100
- wavelength max: 750
- wavelength min: 450
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: grating
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_4_paviaU/config_test_values.yml b/simca/tests/test_configs/mask_4_paviaU/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_4_paviaU/pattern.h5 b/simca/tests/test_configs/mask_4_paviaU/pattern.h5
deleted file mode 100755
index bb5c2e6..0000000
Binary files a/simca/tests/test_configs/mask_4_paviaU/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_4_paviaU/test_values.yml b/simca/tests/test_configs/mask_4_paviaU/test_values.yml
deleted file mode 100755
index f25083d..0000000
--- a/simca/tests/test_configs/mask_4_paviaU/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 254016.8039554461
- - 1519.539015578192
- - 0.0
-filtered_interpolated_scene:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 309387719.0194986
- - 1994322.886341379
- - 0.0
-interpolated_scene:
- - 698.2262156448204
- - 637.3086680761099
- - 654.2304439746302
- - 600.9154334038054
- - 391.81818181818164
- - 600.291754756871
- - 832.059196617336
- - 644.7441860465118
- - 6659755236.000004
- - 26383217.103594076
- - 24917267.507399578
-measurement:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 1994322.886341379
- - 0.0
- - 0.0
diff --git a/simca/tests/test_configs/mask_5_paviaU/config_acquisition.yml b/simca/tests/test_configs/mask_5_paviaU/config_acquisition.yml
deleted file mode 100755
index f450e66..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_5
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_5_paviaU/config_pattern.yml b/simca/tests/test_configs/mask_5_paviaU/config_pattern.yml
deleted file mode 100755
index 901fcb1..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.5
- type: random
diff --git a/simca/tests/test_configs/mask_5_paviaU/config_pattern_gen.yml b/simca/tests/test_configs/mask_5_paviaU/config_pattern_gen.yml
deleted file mode 100755
index 10638dc..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_5_paviaU/pattern.h5"
diff --git a/simca/tests/test_configs/mask_5_paviaU/config_system.yml b/simca/tests/test_configs/mask_5_paviaU/config_system.yml
deleted file mode 100755
index 165222f..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 120
- number of pixels along Y: 120
- pixel size along X: 30
- pixel size along Y: 30
-detector:
- number of pixels along X: 240
- number of pixels along Y: 230
- pixel size along X: 20
- pixel size along Y: 20
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 82
- wavelength max: 540
- wavelength min: 440
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: grating
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_5_paviaU/config_test_values.yml b/simca/tests/test_configs/mask_5_paviaU/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_5_paviaU/pattern.h5 b/simca/tests/test_configs/mask_5_paviaU/pattern.h5
deleted file mode 100755
index e7b80b0..0000000
Binary files a/simca/tests/test_configs/mask_5_paviaU/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_5_paviaU/test_values.yml b/simca/tests/test_configs/mask_5_paviaU/test_values.yml
deleted file mode 100755
index d6406d4..0000000
--- a/simca/tests/test_configs/mask_5_paviaU/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 1306307.6205817943
- - 6423.226064394912
- - 0.0
-filtered_interpolated_scene:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 1421620878.9982252
- - 6606316.709156611
- - 0.0
-interpolated_scene:
- - 662.2015503875969
- - 702.8716623600347
- - 510.43410852713185
- - 634.1007751937983
- - 420.8087855297156
- - 597.4780361757105
- - 706.1464254952624
- - 533.6046511627906
- - 4637010843.51163
- - 16945779.057708874
- - 16701104.793281656
-measurement:
- - 0.0
- - 0.0
- - 0.0
- - 0.0
- - 13322.931476876352
- - 0.0
- - 0.0
- - 0.0
- - 6606316.70915661
- - 0.0
- - 0.0
diff --git a/simca/tests/test_configs/mask_6_lego/config_acquisition.yml b/simca/tests/test_configs/mask_6_lego/config_acquisition.yml
deleted file mode 100755
index 5ad47d4..0000000
--- a/simca/tests/test_configs/mask_6_lego/config_acquisition.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-acquisition name: mask_6
-acquisition type: single acq.
-psf:
- radius: 100.0
- type: Gaussian
- use_psf: false
-results directory: ./data/results/
diff --git a/simca/tests/test_configs/mask_6_lego/config_pattern.yml b/simca/tests/test_configs/mask_6_lego/config_pattern.yml
deleted file mode 100755
index bd6f1b1..0000000
--- a/simca/tests/test_configs/mask_6_lego/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- ROM: 0.25
- type: random
diff --git a/simca/tests/test_configs/mask_6_lego/config_pattern_gen.yml b/simca/tests/test_configs/mask_6_lego/config_pattern_gen.yml
deleted file mode 100755
index 344e131..0000000
--- a/simca/tests/test_configs/mask_6_lego/config_pattern_gen.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/mask_6_lego/pattern.h5"
diff --git a/simca/tests/test_configs/mask_6_lego/config_system.yml b/simca/tests/test_configs/mask_6_lego/config_system.yml
deleted file mode 100755
index 9f3c33a..0000000
--- a/simca/tests/test_configs/mask_6_lego/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 140
- number of pixels along Y: 140
- pixel size along X: 40
- pixel size along Y: 40
-detector:
- number of pixels along X: 240
- number of pixels along Y: 230
- pixel size along X: 20
- pixel size along Y: 20
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 72
- wavelength max: 540
- wavelength min: 440
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: prism
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/mask_6_lego/config_test_values.yml b/simca/tests/test_configs/mask_6_lego/config_test_values.yml
deleted file mode 100755
index b88b0ac..0000000
--- a/simca/tests/test_configs/mask_6_lego/config_test_values.yml
+++ /dev/null
@@ -1,49 +0,0 @@
-filtering_cube:
- pos1: [13, 15, 5]
- pos2: [2, 17, 9]
- pos3: [23, 47, 4]
- pos4: [42, 6, 7]
- pos5: [35, 15, 2]
- pos6: [26, 26, 0]
- pos7: [10, 29, 5]
- pos8: [38, 34, 6]
-
-pattern:
- pos1: [22, 13]
- pos2: [15, 29]
- pos3: [0, 12]
- pos4: [2, 3]
- pos5: [43, 49]
- pos6: [12, 38]
- pos7: [30, 30]
- pos8: [19, 5]
-
-filtered_interpolated_scene:
- pos1: [19, 4, 4]
- pos2: [8, 3, 6]
- pos3: [23, 46, 2]
- pos4: [23, 46, 6]
- pos5: [10, 27, 0]
- pos6: [34, 26, 1]
- pos7: [12, 17, 9]
- pos8: [36, 0, 5]
-
-interpolated_scene:
- pos1: [14, 5, 7]
- pos2: [24, 41, 5]
- pos3: [15, 17, 8]
- pos4: [39, 45, 6]
- pos5: [0, 29, 2]
- pos6: [24, 5, 4]
- pos7: [45, 29, 5]
- pos8: [14, 46, 0]
-
-measurement:
- pos1: [35, 14]
- pos2: [16, 6]
- pos3: [29, 12]
- pos4: [7, 7]
- pos5: [26, 47]
- pos6: [1, 9]
- pos7: [16, 18]
- pos8: [19, 22]
diff --git a/simca/tests/test_configs/mask_6_lego/pattern.h5 b/simca/tests/test_configs/mask_6_lego/pattern.h5
deleted file mode 100755
index c78a6c1..0000000
Binary files a/simca/tests/test_configs/mask_6_lego/pattern.h5 and /dev/null differ
diff --git a/simca/tests/test_configs/mask_6_lego/test_values.yml b/simca/tests/test_configs/mask_6_lego/test_values.yml
deleted file mode 100755
index 47e1ded..0000000
--- a/simca/tests/test_configs/mask_6_lego/test_values.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-filtering_cube:
- - 0.46808728159217505
- - 0.0
- - 0.0
- - 0.1659178094341765
- - 0.2918750453341612
- - 0.0
- - 0.0
- - 0.0
- - 1000250.6255381543
- - 4115.8824488934215
- - 4361.237864248265
-filtered_interpolated_scene:
- - 0.04403969501278561
- - 0.0
- - 0.0
- - 0.0
- - 0.014889273108940868
- - 0.0018015415750151707
- - 0.15511347183704402
- - 0.02732662696651672
- - 30693163.761450082
- - 137704.80024976336
- - 13620.84074946024
-interpolated_scene:
- - 0.22214750309417203
- - 0.22328458084745623
- - 0.49245083581169663
- - 0.5573751047476557
- - 0.32735496752651816
- - 1.4244956998787288
- - 0.2796510372871011
- - 0.15856122544162124
- - 123395778.9145514
- - 633714.4340161
- - 52262.49548764464
-measurement:
- - 21.183344770933445
- - 5.092007275260731
- - 42.82782140288372
- - 52.4493175578932
- - 40.15501240589488
- - 40.30756549159434
- - 8.269692485075415
- - 42.69756368507286
- - 137704.80024976336
- - 14806.26730763114
- - 11694.401894395689
diff --git a/simca/tests/test_configs/wavelengths_spacing/config_pattern.yml b/simca/tests/test_configs/wavelengths_spacing/config_pattern.yml
deleted file mode 100755
index 643c890..0000000
--- a/simca/tests/test_configs/wavelengths_spacing/config_pattern.yml
+++ /dev/null
@@ -1,3 +0,0 @@
-pattern:
- type: custom h5 pattern
- file path: "./simca/tests/test_configs/wavelengths_spacing/pattern.h5"
diff --git a/simca/tests/test_configs/wavelengths_spacing/config_system.yml b/simca/tests/test_configs/wavelengths_spacing/config_system.yml
deleted file mode 100755
index 8c08b2b..0000000
--- a/simca/tests/test_configs/wavelengths_spacing/config_system.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-coded aperture:
- number of pixels along X: 50
- number of pixels along Y: 50
- pixel size along X: 10
- pixel size along Y: 10
-detector:
- number of pixels along X: 50
- number of pixels along Y: 50
- pixel size along X: 10
- pixel size along Y: 10
-infos:
- system name: HYACAMEO
-spectral range:
- number of spectral samples: 3
- wavelength max: 600
- wavelength min: 400
-system architecture:
- dispersive element:
- A: 15
- G: 30
- delta alpha c: 0
- delta beta c: 0
- m: 1
- type: prism
- wavelength center: 550
- focal lens: 200000
- propagation type: simca
- system type: DD-CASSI
diff --git a/simca/tests/test_configs/wavelengths_spacing/dataset.yml b/simca/tests/test_configs/wavelengths_spacing/dataset.yml
deleted file mode 100755
index c677c25..0000000
--- a/simca/tests/test_configs/wavelengths_spacing/dataset.yml
+++ /dev/null
@@ -1 +0,0 @@
-datasets directory: ./simca/tests/test_configs/wavelengths_spacing/
diff --git a/simca/tests/test_configs/wavelengths_spacing/pattern.h5 b/simca/tests/test_configs/wavelengths_spacing/pattern.h5
deleted file mode 100755
index c7f0f80..0000000
Binary files a/simca/tests/test_configs/wavelengths_spacing/pattern.h5 and /dev/null differ
diff --git a/simple_script.py b/simple_script.py
deleted file mode 100644
index 3cb59ae..0000000
--- a/simple_script.py
+++ /dev/null
@@ -1,34 +0,0 @@
-from simca import CassiSystem, load_yaml_config
-
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-dataset_name = "indian_pines"
-
-if __name__ == '__main__':
-
- # Initialize the CASSI system
- cassi_system = CassiSystem(system_config=config_system)
-
- # DATASET : Load the hyperspectral dataset
- cassi_system.load_dataset(dataset_name, config_dataset["datasets directory"])
-
- # pattern : Generate the coded aperture pattern
- cassi_system.generate_2D_pattern(config_patterns)
-
- # PROPAGATION : Propagate the pattern grid to the detector plane
- cassi_system.propagate_coded_aperture_grid()
-
- # FILTERING CUBE : Generate the filtering cube
- cassi_system.generate_filtering_cube()
-
- # PSF (optional) : Generate the psf
- cassi_system.optical_model.generate_psf(type="Gaussian",radius=100)
-
- # ACQUISITION : Simulate the acquisition with psf (use_psf is optional)
- cassi_system.image_acquisition(use_psf=True,chunck_size=50)
-
- # Save the acquisition
- cassi_system.save_acquisition(config_patterns, config_acquisition)
diff --git a/simple_script_optim_testing.py b/simple_script_optim_testing.py
deleted file mode 100644
index dbf8e1f..0000000
--- a/simple_script_optim_testing.py
+++ /dev/null
@@ -1,221 +0,0 @@
-from simca import load_yaml_config
-from simca.CassiSystemOptim import CassiSystemOptim
-from simca.CassiSystem import CassiSystem
-import numpy as np
-import snoop
-import matplotlib.pyplot as plt
-#import matplotlib
-import torch
-import time
-from pprint import pprint
-from simca.cost_functions import evaluate_slit_scanning_straightness, evaluate_center, evaluate_mean_lighting, evaluate_max_lighting
-from simca.functions_optim import optim_smile, optim_width
-
-#matplotlib.use('Agg')
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_max_center.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-dataset_name = "indian_pines"
-
-test = "SMILE"
-
-algo = "LBFGS"
-
-if test=="SMILE":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim.yml")
- aspect = 1
-elif test=="EQUAL_LIGHT" or test=="MAX_CENTER":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_max_center.yml")
- aspect = 1
-elif test == "MAX_LIGHT":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim.yml")
- aspect = 1
-elif test == "SMILE_mono":
- config_system = load_yaml_config("simca/configs/cassi_system_simple_optim_smile_mono.yml")
- aspect = 1
-
-
-if __name__ == '__main__':
- time_start = time.time()
- # Initialize the CASSI system
- cassi_system = CassiSystemOptim(system_config=config_system)
-
- # time0 = time.time()
- # DATASET : Load the hyperspectral dataset
- cassi_system.load_dataset(dataset_name, config_dataset["datasets directory"])
-
- # Loop beginning if optics optim.
- cassi_system.update_optical_model(system_config=config_system)
- X_vec_out, Y_vec_out = cassi_system.propagate_coded_aperture_grid()
- sigma = 0.75
-
- num_iterations = 3000 # Define num_iterations as needed
-
- """ convergence_counter = 0 # Counter to check convergence
- max_cnt = 100
- min_cost_value = np.inf
-
- if test == "EQUAL_LIGHT":
- cassi_system.generate_custom_pattern_parameters_slit_width(nb_slits=2, nb_rows=2, start_width = 1)
- elif test == "MAX_LIGHT":
- cassi_system.generate_custom_pattern_parameters_slit_width(nb_slits=1, nb_rows=cassi_system.system_config["detector"]["number of pixels along Y"], start_width = sigma)
- elif (test == "SMILE") or (test == "SMILE_mono"):
- cassi_system.generate_custom_pattern_parameters_slit(position=0.5)
-
- # Ensure array_x_positions is a tensor with gradient tracking
- cassi_system.array_x_positions = cassi_system.array_x_positions.clone().detach().requires_grad_(True)
-
- # Define the optimizer
- lr = 0.005 # default: 0.005
- optimizer = torch.optim.Adam([cassi_system.array_x_positions], lr=lr) # Adjust the learning rate as needed
-
- # Main optimization loop
- for iteration in range(num_iterations): # Define num_iterations as needed
- optimizer.zero_grad() # Clear previous gradients
- if test == "EQUAL_LIGHT":
- pattern = cassi_system.generate_custom_slit_pattern_width(start_pattern = "line", start_position = 0)
- elif test == "MAX_LIGHT":
- start_position = torch.tensor([0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.4923,
- 0.4859, 0.4915, 0.4934, 0.4972, 0.4996, 0.5003, 0.5009, 0.5013, 0.5033,
- 0.5041, 0.5064, 0.5068, 0.5078, 0.5070, 0.5099, 0.5103, 0.5146, 0.5145,
- 0.5146, 0.5152, 0.5173, 0.5195, 0.5215, 0.5208, 0.5208, 0.5222, 0.5247,
- 0.5272, 0.5287, 0.5285, 0.5240, 0.5283, 0.5282, 0.5288, 0.5288, 0.5291,
- 0.5289, 0.5282, 0.5334, 0.5314, 0.5324, 0.5370, 0.5323, 0.5322, 0.5341,
- 0.5329, 0.5361, 0.5364, 0.5346, 0.5333, 0.5340, 0.5333, 0.5339, 0.5345,
- 0.5359, 0.5349, 0.5364, 0.5344, 0.5341, 0.5346, 0.5353, 0.5345, 0.5347,
- 0.5346, 0.5362, 0.5363, 0.5330, 0.5321, 0.5323, 0.5299, 0.5315, 0.5318,
- 0.5298, 0.5291, 0.5291, 0.5298, 0.5292, 0.5256, 0.5270, 0.5283, 0.5268,
- 0.5255, 0.5245, 0.5200, 0.5205, 0.5207, 0.5190, 0.5188, 0.5144, 0.5122,
- 0.5138, 0.5133, 0.5131, 0.5122, 0.5111, 0.5156, 0.5118, 0.5091, 0.5077,
- 0.5068, 0.5030, 0.5003, 0.5000, 0.4992, 0.4970, 0.4968, 0.4947, 0.4949,
- 0.4935, 0.4983, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000])
- pattern = cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = start_position)
- else:
- pattern = cassi_system.generate_custom_slit_pattern()
- #print(pattern[:, pattern.shape[1]//2-4:pattern.shape[1]//2+4])
- cassi_system.generate_filtering_cube()
- pos_slit = 0.4625
- pos_slit = 0.41
- if (test == "SMILE"):
- cost_value = evaluate_slit_scanning_straightness(cassi_system.filtering_cube, sigma = sigma, pos_slit = pos_slit)
- elif (test == "SMILE_mono"):
- cost_value = evaluate_slit_scanning_straightness(cassi_system.filtering_cube, sigma = sigma, pos_slit = pos_slit)
- cassi_system.image_acquisition(use_psf = False, chunck_size = 50)
- elif test == "MAX_CENTER":
- cassi_system.image_acquisition(use_psf=False, chunck_size=50)
- cost_value = evaluate_center(cassi_system.measurement)
- elif test == "EQUAL_LIGHT":
- cassi_system.image_acquisition(use_psf=False, chunck_size=50)
- cost_value = evaluate_mean_lighting(cassi_system.measurement)
- elif test == "MAX_LIGHT":
- cassi_system.image_acquisition(use_psf=False, chunck_size=50)
- cost_value = evaluate_max_lighting(cassi_system.measurement, pos_slit)
-
- if cost_value < min_cost_value:
- min_cost_value = cost_value
- convergence_counter = 0
- best_x = cassi_system.array_x_positions.clone().detach()
- else:
- convergence_counter+=1
-
- if (iteration >= 50) and (convergence_counter >= max_cnt): # If loss didn't decrease in 25 steps, break
- break
-
- cost_value.backward() # Perform backpropagation
- # print("Gradients after backward:", cassi_system.array_x_positions.grad)
- optimizer.step() # Update x positions
- cassi_system.array_x_positions.data = torch.relu(cassi_system.array_x_positions.data) # Prevent the parameters to be negative
- # Optional: Print cost_value every few iterations to monitor progress
- if iteration % 5 == 0: # Adjust printing frequency as needed
- print(f"Iteration {iteration}, Cost: {cost_value.item()}")
-
- if iteration % 200 == 0:
- print(f"Exec time: {time.time() - time_start}s")
- plt.imshow(pattern.detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.imshow(cassi_system.filtering_cube[:, :, 0].detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.plot(np.sum(cassi_system.filtering_cube[:, :, 0].detach().numpy(),axis=0))
- plt.show()
-
- if (test=="MAX_CENTER") or (test == "EQUAL_LIGHT") or (test == "SMILE_mono") or (test == "MAX_LIGHT"):
- #plt.imshow(cassi_system.panchro.detach().numpy(), zorder=3)
- plt.imshow(cassi_system.measurement.detach().numpy(), zorder=5)
- plt.show()
- #plt.imshow(cassi_system.panchro.detach().numpy())
- #plt.show()
- cassi_system.array_x_positions.data = torch.relu(best_x.data)
-
- if test == "EQUAL_LIGHT":
- pattern = cassi_system.generate_custom_slit_pattern_width(start_pattern = "line", start_position = 0)
- elif test == "MAX_LIGHT":
- pattern = cassi_system.generate_custom_slit_pattern_width(start_pattern = "corrected", start_position = start_position)
- else:
- pattern = cassi_system.generate_custom_slit_pattern()
- cassi_system.generate_filtering_cube()
- print(cassi_system.array_x_positions)
- #print(torch.std(cassi_system.measurement.detach()))
-
- print(f"Min cost: {min_cost_value}")
- print(f"Exec time: {time.time() - time_start}s")
- plt.imshow(pattern.detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.imshow(cassi_system.filtering_cube[:, :, 0].detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.plot(np.sum(cassi_system.filtering_cube[:, :, 0].detach().numpy(),axis=0))
- plt.show()
-
- if (test=="MAX_CENTER") or (test == "EQUAL_LIGHT") or (test == "SMILE_mono") or (test == "MAX_LIGHT"):
- plt.imshow(cassi_system.measurement.detach().numpy())
- plt.show()"""
- algo = "ADAM"
- if algo == "LBFGS":
- lr = 0.002 # default: 0.05
- elif algo == "ADAM":
- lr = 0.005 # default: 0.005
-
- max_cnt = 25
-
- #cassi_system = optim_smile(cassi_system, 0.5, 0.41, sigma, 'cpu', algo, lr, num_iterations, max_cnt, plot_frequency=200)
- start_position = torch.tensor([0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.4923,
- 0.4859, 0.4915, 0.4934, 0.4972, 0.4996, 0.5003, 0.5009, 0.5013, 0.5033,
- 0.5041, 0.5064, 0.5068, 0.5078, 0.5070, 0.5099, 0.5103, 0.5146, 0.5145,
- 0.5146, 0.5152, 0.5173, 0.5195, 0.5215, 0.5208, 0.5208, 0.5222, 0.5247,
- 0.5272, 0.5287, 0.5285, 0.5240, 0.5283, 0.5282, 0.5288, 0.5288, 0.5291,
- 0.5289, 0.5282, 0.5334, 0.5314, 0.5324, 0.5370, 0.5323, 0.5322, 0.5341,
- 0.5329, 0.5361, 0.5364, 0.5346, 0.5333, 0.5340, 0.5333, 0.5339, 0.5345,
- 0.5359, 0.5349, 0.5364, 0.5344, 0.5341, 0.5346, 0.5353, 0.5345, 0.5347,
- 0.5346, 0.5362, 0.5363, 0.5330, 0.5321, 0.5323, 0.5299, 0.5315, 0.5318,
- 0.5298, 0.5291, 0.5291, 0.5298, 0.5292, 0.5256, 0.5270, 0.5283, 0.5268,
- 0.5255, 0.5245, 0.5200, 0.5205, 0.5207, 0.5190, 0.5188, 0.5144, 0.5122,
- 0.5138, 0.5133, 0.5131, 0.5122, 0.5111, 0.5156, 0.5118, 0.5091, 0.5077,
- 0.5068, 0.5030, 0.5003, 0.5000, 0.4992, 0.4970, 0.4968, 0.4947, 0.4949,
- 0.4935, 0.4983, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000,
- 0.5000])
- cassi_system = optim_width(cassi_system, start_position, 0.41, cassi_system.system_config["detector"]["number of pixels along Y"], sigma, 'cpu', algo, lr, num_iterations, max_cnt, plot_frequency = 200)
-
- print(f"Exec time: {time.time() - time_start:.3f}s")
- print(cassi_system.array_x_positions)
- plt.imshow(cassi_system.pattern.detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.imshow(cassi_system.filtering_cube[:, :, 0].detach().numpy(), aspect=aspect)
- plt.show()
-
- plt.plot(np.sum(cassi_system.filtering_cube[:, :, 0].detach().numpy(),axis=0))
- plt.show()
-
- if (test=="MAX_CENTER") or (test == "EQUAL_LIGHT") or (test == "SMILE_mono") or (test == "MAX_LIGHT"):
- plt.imshow(cassi_system.measurement.detach().numpy())
- plt.show()
diff --git a/testing_optim_proposition.py b/testing_optim_proposition.py
deleted file mode 100755
index d13a96f..0000000
--- a/testing_optim_proposition.py
+++ /dev/null
@@ -1,137 +0,0 @@
-from simca import load_yaml_config
-import matplotlib.pyplot as plt
-from simca.CassiSystemOptim import CassiSystemOptim
-from simca.cost_functions_optics import *
-from opticalglass.glassfactory import get_glass_catalog
-import pandas as pd
-
-
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system_optim_optics_full_triplet_sd_cassi.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-hoya_pd = get_glass_catalog('Schott')
-
-# Access the 'nd' values where the first level is NaN
-idx = pd.IndexSlice
-
-nd_values = hoya_pd.df.loc[:, idx[pd.NA, 'nd']]
-vd_values = hoya_pd.df.loc[:, idx["abbe number", 'vd']]
-
-if __name__ == '__main__':
-
- # Initialize the CASSI system
- cassi_system = CassiSystemOptim(system_config=config_system)
- #
- # config_system["system architecture"]["dispersive element"]["glass1"] = "N-BK7"
- # # config_system["system architecture"]["dispersive element"]["glass2"] = "N-SF11"
- # config_system["system architecture"]["dispersive element"]["glass3"] = "N-BK7"
- # config_system["system architecture"]["dispersive element"]["A1"] = 70
- # # config_system["system architecture"]["dispersive element"]["A2"] = 60
- # config_system["system architecture"]["dispersive element"]["A3"] = 70
- # config_system["system architecture"]["dispersive element"]["alpha_c"] = 55
-
-
- cassi_system.update_optical_model(system_config=config_system)
-
- x_vec_out, y_vec_out = cassi_system.propagate_coded_aperture_grid()
-
- #
- alpha_c = cassi_system.optical_model.alpha_c
- alpha_c_out = cassi_system.optical_model.alpha_c_transmis
- list_apex_angles = [cassi_system.optical_model.A1, cassi_system.optical_model.A2, cassi_system.optical_model.A3]
- list_theta_in = cassi_system.optical_model.list_theta_in
- list_theta_out = cassi_system.optical_model.list_theta_out
-
- # evaluate spectral dispersion
- dispersion, central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
- print("dispersion in microns", dispersion)
-
- # evaluate direct_view
- deviation = evaluate_direct_view(alpha_c,alpha_c_out,list_apex_angles)
- print("deviation in degrees", deviation*180/np.pi)
-
- # evaluate beam compression
- beam_compression = evaluate_beam_compression(list_theta_in, list_theta_out)
- print("beam compression", beam_compression)
-
- #evaluate thickness
- thickness = evaluate_thickness(list_apex_angles)
- print("thickness", thickness)
-
- # evaluate distortions
- x_vec_no_dist, y_vec_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system.X_coded_aper_coordinates,
- cassi_system.Y_coded_aper_coordinates,
- central_coordinates_X)
-
- # print(x_vec_no_dist)
-
- print(x_vec_no_dist.shape, y_vec_no_dist.shape)
- distortion_metric = evaluate_distortions(x_vec_out, y_vec_out, x_vec_no_dist, y_vec_no_dist)
-
- print("distortion metric", distortion_metric)
-
- displacement_in_pix = central_coordinates_X.detach().numpy()/cassi_system.system_config["detector"]["pixel size along X"]
-
- plt.plot(cassi_system.wavelengths.detach().numpy(), displacement_in_pix)
- plt.title("central coordinates in pix")
- plt.show()
- # y_second_derivative = calculate_second_derivative(cassi_system.wavelengths, central_coordinates_X)
- #
- # plt.plot(y_second_derivative.detach().numpy())
- # plt.show()
- print(x_vec_out.detach().numpy().shape)
-
- plt.scatter(x_vec_out.detach().numpy()[...,0], y_vec_out.detach().numpy()[...,0],color='blue',label="distor")
- plt.scatter(x_vec_out.detach().numpy()[...,3], y_vec_out.detach().numpy()[...,0],color='green',label="distor")
- plt.scatter(x_vec_out.detach().numpy()[...,-1], y_vec_out.detach().numpy()[...,-1],color='red',label="distor")
- plt.scatter(cassi_system.X_detector_coordinates_grid.detach().numpy(),cassi_system.Y_detector_coordinates_grid.detach().numpy(),color='black',label="distor")
- #
- # plt.scatter(x_vec_no_dist.detach().numpy()[...,0], y_vec_no_dist.detach().numpy()[...,0],label="no dist",color='green')
- # plt.scatter(x_vec_no_dist.detach().numpy()[...,-1], y_vec_no_dist.detach().numpy()[...,-1],label="no dist",color='green')
-
- plt.legend()
- plt.show()
-
-
- # distance from closest point
- current_value = [cassi_system.optical_model.nd1, cassi_system.optical_model.vd1]
- distance_closest_point = evaluate_distance(current_value,nd_values, vd_values)
-
-
-
-
-
-
-
-
-
-
- # print(cassi_system.optical_model.list_theta_in, cassi_system.optical_model.list_theta_out)
- #
- # dispersion,central_coordinates_X = evaluate_spectral_dispersion_values(x_vec_out, y_vec_out)
- # r2, y_pred = evaluate_linearity(central_coordinates_X)
- #
- # y_second_derivative = calculate_second_derivative(cassi_system.wavelengths,central_coordinates_X)
- #
- # plt.plot(y_second_derivative)
- # plt.show()
- #
- # #no distorsions X_vec_out, Y_vec_out
- # x_vec_out_no_dist, y_vec_out_no_dist = get_cassi_system_no_spectial_distorsions(cassi_system.X_coded_aper_coordinates,
- # cassi_system.Y_coded_aper_coordinates,
- # central_coordinates_X)
- #
- # print(r2)
- #
- # plt.plot(central_coordinates_X)
- # plt.plot(y_pred)
- # plt.show()
- #
- # plt.scatter(x_vec_out[...,0], y_vec_out[...,0],color='blue')
- # plt.scatter(x_vec_out[:,:,-1], y_vec_out[:,:,-1],color='red')
- # plt.scatter(x_vec_out_no_dist[...,0], y_vec_out_no_dist[...,0])
- # plt.scatter(x_vec_out_no_dist[:,:,-1], y_vec_out_no_dist[:,:,-1])
- #
- # plt.show()
\ No newline at end of file
diff --git a/testing_pytorch_propagation.py b/testing_pytorch_propagation.py
deleted file mode 100755
index 9d71f69..0000000
--- a/testing_pytorch_propagation.py
+++ /dev/null
@@ -1,32 +0,0 @@
-from simca import CassiSystem, load_yaml_config
-import matplotlib.pyplot as plt
-
-config_dataset = load_yaml_config("simca/configs/dataset.yml")
-config_system = load_yaml_config("simca/configs/cassi_system_test.yml")
-config_patterns = load_yaml_config("simca/configs/pattern.yml")
-config_acquisition = load_yaml_config("simca/configs/acquisition.yml")
-
-if __name__ == '__main__':
-
- # Initialize the CASSI system
- cassi_system = CassiSystem(system_config=config_system)
-
-
- # pattern : Generate the coded aperture pattern
- cassi_system.generate_2D_pattern(config_patterns)
-
- # PROPAGATION : Propagate the pattern grid to the detector plane
- # X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture, system_wavelengths = cassi_system.propagate_coded_aperture_grid(use_torch=False)
-
- # print(system_wavelengths)
- # plt.scatter(X_coordinates_propagated_coded_aperture[:,:,0], Y_coordinates_propagated_coded_aperture[:,:,0],color='blue')
- # plt.scatter(X_coordinates_propagated_coded_aperture[:,:,45], Y_coordinates_propagated_coded_aperture[:,:,45],color='green')
- # plt.scatter(X_coordinates_propagated_coded_aperture[:,:,90], Y_coordinates_propagated_coded_aperture[:,:,90],color='red')
- # plt.show()
-
- X_coordinates_propagated_coded_aperture, Y_coordinates_propagated_coded_aperture, system_wavelengths = cassi_system.propagate_coded_aperture_grid(use_torch=True)
-
- plt.scatter(X_coordinates_propagated_coded_aperture[...,0], Y_coordinates_propagated_coded_aperture[...,0],color='blue')
- plt.scatter(X_coordinates_propagated_coded_aperture[:,:,1], Y_coordinates_propagated_coded_aperture[:,:,1],color='green')
- plt.scatter(X_coordinates_propagated_coded_aperture[:,:,2], Y_coordinates_propagated_coded_aperture[:,:,2],color='red')
- plt.show()
diff --git a/tests.py b/tests.py
deleted file mode 100755
index 5945ad2..0000000
--- a/tests.py
+++ /dev/null
@@ -1,5 +0,0 @@
-from simca.tests import test_cassisystem_initialization
-import unittest
-
-if __name__ == '__main__':
- unittest.main(test_cassisystem_initialization, exit=False)
diff --git a/train_resnet_for_noise_generation.py b/train_resnet_for_noise_generation.py
deleted file mode 100644
index 05afcd6..0000000
--- a/train_resnet_for_noise_generation.py
+++ /dev/null
@@ -1,58 +0,0 @@
-import pytorch_lightning as pl
-from data_handler import CubesDataModule
-from Resnet_only import ResnetOnly
-from pytorch_lightning.callbacks import EarlyStopping, ModelCheckpoint
-from pytorch_lightning.loggers import TensorBoardLogger
-import torch
-import datetime
-
-
-data_dir = "/local/users/ademaio/lpaillet/mst_datasets/cave_1024_28/"
-datamodule = CubesDataModule(data_dir, batch_size=4, num_workers=11)
-
-datetime_ = datetime.datetime.now().strftime('%y-%m-%d_%Hh%M')
-
-name = "testing_resnet_only"
-model_name = "resnet_only"
-
-log_dir = 'tb_logs'
-
-train = True
-
-logger = TensorBoardLogger(log_dir, name=name)
-
-early_stop_callback = EarlyStopping(
- monitor='val_loss', # Metric to monitor
- patience=40, # Number of epochs to wait for improvement
- verbose=True,
- mode='min' # 'min' for metrics where lower is better, 'max' for vice versa
- )
-
-checkpoint_callback = ModelCheckpoint(
- monitor='val_loss', # Metric to monitor
- dirpath='checkpoints/', # Directory path for saving checkpoints
- filename=f'best-checkpoint_{model_name}_{datetime_}', # Checkpoint file name
- save_top_k=1, # Save the top k models
- mode='min', # 'min' for metrics where lower is better, 'max' for vice versa
- save_last=True # Additionally, save the last checkpoint to a file named 'last.ckpt'
-)
-
-reconstruction_module = ResnetOnly(log_dir=log_dir+'/'+ name)
-
-
-if torch.cuda.is_available():
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=1,
- callbacks=[early_stop_callback, checkpoint_callback])
-else:
- trainer = pl.Trainer( logger=logger,
- accelerator="cpu",
- max_epochs=500,
- log_every_n_steps=1,
- callbacks=[early_stop_callback, checkpoint_callback])
-
-
-trainer.fit(reconstruction_module, datamodule)
-
diff --git a/training_simca_reconstruction.py b/training_simca_reconstruction.py
deleted file mode 100755
index 500ca70..0000000
--- a/training_simca_reconstruction.py
+++ /dev/null
@@ -1,63 +0,0 @@
-import pytorch_lightning as pl
-from data_handler import CubesDataModule
-from optimization_modules import JointReconstructionModule_V1
-from pytorch_lightning.callbacks import EarlyStopping, ModelCheckpoint
-from pytorch_lightning.loggers import TensorBoardLogger
-import torch
-import datetime
-
-
-data_dir = "./datasets_reconstruction/mst_datasets/cave_1024_28"
-datamodule = CubesDataModule(data_dir, batch_size=4, num_workers=11)
-
-datetime_ = datetime.datetime.now().strftime('%y-%m-%d_%Hh%M')
-
-name = "testing_simca_reconstruction"
-model_name = "dauhst_9"
-reconstruction_checkpoint = "/home/lpaillet/Documents/simca/tb_logs/testing_simca_reconstruction/version_24/checkpoints/epoch=499-step=18000.ckpt"
-reconstruction_checkpoint = None
-
-log_dir = 'tb_logs'
-
-train = True
-
-logger = TensorBoardLogger(log_dir, name=name)
-
-early_stop_callback = EarlyStopping(
- monitor='val_loss', # Metric to monitor
- patience=40, # Number of epochs to wait for improvement
- verbose=True,
- mode='min' # 'min' for metrics where lower is better, 'max' for vice versa
- )
-
-checkpoint_callback = ModelCheckpoint(
- monitor='val_loss', # Metric to monitor
- dirpath='checkpoints/', # Directory path for saving checkpoints
- filename=f'best-checkpoint_{model_name}_{datetime_}', # Checkpoint file name
- save_top_k=1, # Save the top k models
- mode='min', # 'min' for metrics where lower is better, 'max' for vice versa
- save_last=True # Additionally, save the last checkpoint to a file named 'last.ckpt'
-)
-
-reconstruction_module = JointReconstructionModule_V1(model_name,log_dir=log_dir+'/'+ name,
- reconstruction_checkpoint=reconstruction_checkpoint)
-
-
-if torch.cuda.is_available():
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=1,
- callbacks=[early_stop_callback, checkpoint_callback])
-else:
- trainer = pl.Trainer( logger=logger,
- accelerator="cpu",
- max_epochs=500,
- log_every_n_steps=1,
- callbacks=[early_stop_callback, checkpoint_callback])
-
-if train:
- trainer.fit(reconstruction_module, datamodule)
-else:
- #trainer.predict(reconstruction_module, datamodule)
- trainer.predict(reconstruction_module, datamodule, ckpt_path=reconstruction_checkpoint)
diff --git a/training_simca_reconstruction_with_resnet.py b/training_simca_reconstruction_with_resnet.py
deleted file mode 100755
index cf1fda3..0000000
--- a/training_simca_reconstruction_with_resnet.py
+++ /dev/null
@@ -1,66 +0,0 @@
-import pytorch_lightning as pl
-from data_handler import CubesDataModule
-from optimization_modules_with_resnet import JointReconstructionModule_V2
-from pytorch_lightning.callbacks import EarlyStopping, ModelCheckpoint
-from pytorch_lightning.loggers import TensorBoardLogger
-import torch
-import datetime
-
-
-# data_dir = "./datasets_reconstruction/"
-data_dir = "/local/users/ademaio/lpaillet/mst_datasets/cave_1024_28"
-data_dir = "./datasets_reconstruction/mst_datasets/cave_1024_28"
-datamodule = CubesDataModule(data_dir, batch_size=4, num_workers=5)
-
-datetime_ = datetime.datetime.now().strftime('%y-%m-%d_%Hh%M')
-
-name = "testing_simca_reconstruction_full"
-model_name = "dauhst_9"
-reconstruction_checkpoint = "/home/lpaillet/Documents/simca/tb_logs/testing_simca_reconstruction/version_24/checkpoints/epoch=499-step=18000.ckpt"
-
-log_dir = 'tb_logs'
-
-train = True
-
-logger = TensorBoardLogger(log_dir, name=name)
-
-early_stop_callback = EarlyStopping(
- monitor='val_loss', # Metric to monitor
- patience=40, # Number of epochs to wait for improvement
- verbose=True,
- mode='min' # 'min' for metrics where lower is better, 'max' for vice versa
- )
-
-checkpoint_callback = ModelCheckpoint(
- monitor='val_loss', # Metric to monitor
- dirpath='checkpoints_with_resnet/', # Directory path for saving checkpoints
- filename=f'best-checkpoint_{model_name}_{datetime_}', # Checkpoint file name
- save_top_k=1, # Save the top k models
- mode='min', # 'min' for metrics where lower is better, 'max' for vice versa
- save_last=True # Additionally, save the last checkpoint to a file named 'last.ckpt'
-)
-
-reconstruction_module = JointReconstructionModule_V2(model_name,
- log_dir=log_dir+'/'+ name,
- reconstruction_checkpoint = reconstruction_checkpoint)
-
-
-if torch.cuda.is_available():
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=30,
- callbacks=[early_stop_callback, checkpoint_callback])
-else:
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=30,
- callbacks=[early_stop_callback, checkpoint_callback])
-
-if train:
- #reconstruction_checkpoint = None
- #trainer.fit(reconstruction_module, datamodule, ckpt_path = reconstruction_checkpoint)
- trainer.fit(reconstruction_module, datamodule)
-else:
- trainer.predict(reconstruction_module, datamodule, ckpt_path=reconstruction_checkpoint)
\ No newline at end of file
diff --git a/training_simca_reconstruction_with_resnet_v2.py b/training_simca_reconstruction_with_resnet_v2.py
deleted file mode 100755
index 22148eb..0000000
--- a/training_simca_reconstruction_with_resnet_v2.py
+++ /dev/null
@@ -1,79 +0,0 @@
-import pytorch_lightning as pl
-from data_handler import CubesDataModule
-from optimization_modules import JointReconstructionModule_V1
-from optimization_modules_with_resnet import JointReconstructionModule_V2
-from optimization_modules_with_resnet_v2 import JointReconstructionModule_V3
-from pytorch_lightning.callbacks import EarlyStopping, ModelCheckpoint
-from pytorch_lightning.loggers import TensorBoardLogger
-import torch
-import datetime
-
-
-# data_dir = "./datasets_reconstruction/"
-data_dir = "/local/users/ademaio/lpaillet/mst_datasets/cave_1024_28"
-# data_dir = "./datasets_reconstruction/mst_datasets/cave_1024_28"
-datamodule = CubesDataModule(data_dir, batch_size=4, num_workers=5)
-
-datetime_ = datetime.datetime.now().strftime('%y-%m-%d_%Hh%M')
-
-name = "testing_simca_reconstruction_full"
-model_name = "dauhst_9"
-reconstruction_checkpoint = "./checkpoints/epoch=499-step=18000.ckpt"
-resnet_checkpoint = None
-
-log_dir = 'tb_logs'
-
-train = True
-retrain_recons = True
-
-logger = TensorBoardLogger(log_dir, name=name)
-
-early_stop_callback = EarlyStopping(
- monitor='val_loss', # Metric to monitor
- patience=40, # Number of epochs to wait for improvement
- verbose=True,
- mode='min' # 'min' for metrics where lower is better, 'max' for vice versa
- )
-
-checkpoint_callback = ModelCheckpoint(
- monitor='val_loss', # Metric to monitor
- dirpath='checkpoints_with_resnet/', # Directory path for saving checkpoints
- filename=f'best-checkpoint_{model_name}_{datetime_}', # Checkpoint file name
- save_top_k=1, # Save the top k models
- mode='min', # 'min' for metrics where lower is better, 'max' for vice versa
- save_last=True # Additionally, save the last checkpoint to a file named 'last.ckpt'
-)
-
-#sub_module = JointReconstructionModule_V1.load_from_checkpoint(reconstruction_checkpoint)
-checkpoint = torch.load(reconstruction_checkpoint)
-sub_module = JointReconstructionModule_V1(model_name, log_dir)
-sub_module.load_state_dict(checkpoint["state_dict"])
-
-
-resnet_checkpoint = "./checkpoints/best-checkpoint_resnet_only_24-03-09_18h05.ckpt"
-
-if not retrain_recons or not train:
- sub_module.eval()
-
-reconstruction_module = JointReconstructionModule_V3(sub_module,
- log_dir=log_dir+'/'+ name,
- resnet_checkpoint=resnet_checkpoint)
-
-
-if torch.cuda.is_available():
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=30,
- callbacks=[early_stop_callback, checkpoint_callback])
-else:
- trainer = pl.Trainer( logger=logger,
- accelerator="gpu",
- max_epochs=500,
- log_every_n_steps=30,
- callbacks=[early_stop_callback, checkpoint_callback])
-
-if train:
- trainer.fit(reconstruction_module, datamodule)
-else:
- trainer.predict(reconstruction_module, datamodule, ckpt_path=resnet_checkpoint)
diff --git a/utils/__init__.py b/utils/__init__.py
index fd8ee60..89f17b4 100644
--- a/utils/__init__.py
+++ b/utils/__init__.py
@@ -1,2 +1,2 @@
-from .helpers import *
+from .helper import *
from .functions_hyperspectral_analysis import *
diff --git a/utils/functions_hyperspectral_analysis.py b/utils/functions_hyperspectral_analysis.py
deleted file mode 100644
index 17dbb6f..0000000
--- a/utils/functions_hyperspectral_analysis.py
+++ /dev/null
@@ -1,49 +0,0 @@
-import numpy as np
-from sklearn.decomposition import PCA
-
-def explore_spectrums(img, complete_gt, class_names,
- ignored_labels=None):
- """Plot sampled spectrums with mean + std for each class.
-
- Args:
- img: 3D hyperspectral image
- complete_gt: 2D array of labels
- class_names: list of class names
- ignored_labels (optional): list of labels to ignore
- vis : Visdom display
- Returns:
- mean_spectrums: dict of mean spectrum by class
-
- """
-
- stats_per_class = {"mean_spectrums": {}, 'std_spectrums': {}, 'non_degenerate_mean_spectrums': {},
- 'non_degenerate_covariance': {}}
- n_samples_per_class = np.array([np.sum([complete_gt == i]) for i in np.unique(complete_gt) if i not in ignored_labels])
-
- """if delta_lambda is not None:
- n_dim_pca = int(np.min([0.25 * img.shape[-1] * np.log10(delta_lambda), 0.75 * np.min(n_samples_per_class)]))
- else:
- n_dim_pca = int(np.min([0.25*img.shape[-1], 0.75*np.min(n_samples_per_class)]))"""
- # n_dim_pca = int(np.min([0. * img.shape[-1], 0.5 * np.min(n_samples_per_class)]))
- n_dim_pca = 5
- mask = complete_gt > 0
- pca = PCA(n_dim_pca)
- pca.fit(img[mask])
-
- for c in np.unique(complete_gt):
- if c in ignored_labels:
- continue
- mask = complete_gt == c
- class_spectrums = img[mask]
- # pca = PCA(n_dim_pca)
- class_spectrums_pca = pca.transform(class_spectrums)
-
- mean_spectrum = np.mean(class_spectrums, axis=0)
- std_spectrum = np.std(class_spectrums, axis=0)
-
- stats_per_class['mean_spectrums'][class_names[c]] = mean_spectrum
- stats_per_class['std_spectrums'][class_names[c]] = std_spectrum
- stats_per_class['non_degenerate_mean_spectrums'][class_names[c]] = np.mean(class_spectrums_pca, axis=0)
- stats_per_class['non_degenerate_covariance'][class_names[c]] = np.cov(np.transpose(class_spectrums_pca))
-
- return stats_per_class
\ No newline at end of file
diff --git a/utils/helpers.py b/utils/helpers.py
index 70412be..7763872 100644
--- a/utils/helpers.py
+++ b/utils/helpers.py
@@ -1,31 +1,6 @@
-import logging
-import os
import yaml
from datetime import datetime
-def configure_logging(result_directory, log_directory="logs"):
- log_directory = os.path.join(result_directory, log_directory)
- os.makedirs(log_directory, exist_ok=True)
-
- log_formatter = logging.Formatter("%(asctime)s [%(levelname)s] %(message)s")
-
- root_logger = logging.getLogger()
- root_logger.setLevel(logging.DEBUG)
-
- console_handler = logging.StreamHandler()
- console_handler.setFormatter(log_formatter)
- console_handler.setLevel(logging.DEBUG)
- root_logger.addHandler(console_handler)
-
- timestamp = datetime.now().strftime("%Y-%m-%d_%H-%M-%S-%f")[:-3]
- log_file_name = f"experiment_{timestamp}.log"
-
- file_handler = logging.FileHandler(os.path.join(log_directory, log_file_name))
- file_handler.setFormatter(log_formatter)
- file_handler.setLevel(logging.DEBUG)
- root_logger.addHandler(file_handler)
-
-
def load_yaml_config(file_path):
"""
@@ -38,8 +13,3 @@ def load_yaml_config(file_path):
config = yaml.safe_load(file)
return config
-def undersample_grid(grid, target_size=40):
- factor = grid.shape[0] // target_size
- if factor == 0:
- return grid[::1,::1]
- return grid[::factor,::factor]
\ No newline at end of file