-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
enable gaussian fitting of multiple snapshots iteratively
- Loading branch information
LiuRenxi
authored and
LiuRenxi
committed
Jun 30, 2022
1 parent
aad42d6
commit 2b7993d
Showing
17 changed files
with
160 additions
and
1,014 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
9 changes: 4 additions & 5 deletions
9
gaussian_fit/test/Makefile → gaussian_fit/test/gaussian/Makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
width 1024 | ||
window_width 3 | ||
top_pctg 0.01 | ||
intensity_file ../gaussian/outIntensity.dat |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
VPATH=./\ | ||
../../\ | ||
|
||
OBJS = test_quantile.o\ | ||
../../input.o\ | ||
../../gaussian.o\ | ||
../../spot.o\ | ||
|
||
CC=mpiicc | ||
|
||
.cpp.o: | ||
${CC} ${OPTION} -c -O3 $< -o $@ -I../../ -I/usr/src/gtest/include/gtest -L/usr/src/gtest -lgtest -lpthread | ||
|
||
quantile_test:${OBJS} | ||
${CC} ${OPTION} -o quantile_test.exe ${OBJS} -I/usr/src/gtest/include/gtest -L/usr/src/gtest -lgtest -lpthread | ||
|
||
clean: | ||
rm -f *.o *.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import numpy as np | ||
intensity = np.genfromtxt("../gaussian/outIntensity.dat") | ||
print(np.max(intensity)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#include "gaussian.h" | ||
#include "input.h" | ||
#include "spot.h" | ||
#include <gtest/gtest.h> | ||
|
||
TEST(Quantile_test, quantile) | ||
{ | ||
cout << 0 << endl; | ||
INPUT.read(); | ||
Spot spot; | ||
ifstream ifs; | ||
cout << 1 << endl; | ||
ifs.open(INPUT.intensity_file); | ||
spot.readin(ifs); | ||
cout << 2 << endl; | ||
ifs.close(); | ||
spot.calc_quantile(); | ||
EXPECT_FLOAT_EQ(spot.quantile, 9.86382); | ||
} | ||
|
||
|
||
int main(int argc, char **argv) | ||
{ | ||
testing::InitGoogleTest(&argc, argv); | ||
return RUN_ALL_TESTS(); | ||
} |
Oops, something went wrong.