Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nsetm 2196 expand output #44

Open
wants to merge 66 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
cc9d4f8
pytest posargs
edasubert Jun 20, 2023
6e07720
extract densities adjustments
edasubert Jun 20, 2023
fb408c3
properly config tools
edasubert Jun 21, 2023
33ede88
lint
edasubert Jun 21, 2023
0687aa1
new probability_map
edasubert Jun 23, 2023
b34c563
use regions
edasubert Jun 29, 2023
11b9329
remove "with_region"
edasubert Jun 30, 2023
5322f24
revert test to be closer to original
edasubert Jun 30, 2023
dc75ed0
remove lamp5 synthesis
edasubert Jun 30, 2023
7ab4bdb
Merge branch 'NSETM-2196-update-create-from-probability-map' into NSE…
edasubert Jun 30, 2023
eef4444
add lamp5
edasubert Jun 30, 2023
bb8b4f0
Merge branch 'NSETM-2196-update-create-from-probability-map' into NSE…
edasubert Jun 30, 2023
71370d7
approx_lamp5
edasubert Jun 30, 2023
fcb8aec
switch to region map
edasubert Jul 4, 2023
7d93f22
fixes to probability map
edasubert Jul 10, 2023
32d0be5
add vip to probability map
edasubert Jul 11, 2023
f32b24a
lint
edasubert Jul 11, 2023
a597693
mypy issue
edasubert Jul 11, 2023
803b867
cleanup
edasubert Jul 12, 2023
a9ed2b7
restore a file for a test
edasubert Jul 12, 2023
46f8511
speed up density creation
mgeplf Jul 14, 2023
ad1d531
Stop using as many config files
mgeplf Jul 14, 2023
b00459e
logger
edasubert Jul 14, 2023
f385fc2
lint
edasubert Jul 14, 2023
e55aa22
try parallelizing w/ joblib.
mgeplf Jul 14, 2023
17b9cc5
speed up density creation (#37)
edasubert Jul 17, 2023
067bd19
Stop using as many config files (#38)
edasubert Jul 17, 2023
37b92f1
Merge branch 'NSETM-2196-update-create-from-probability-map' into NSE…
edasubert Jul 17, 2023
118c58b
logger
edasubert Jul 17, 2023
6b57eca
remove logger
edasubert Jul 17, 2023
aca3df1
Merge branch 'NSETM-2196-update-create-from-probability-map-probabili…
edasubert Jul 17, 2023
f04d50d
merge
edasubert Jul 17, 2023
7f14606
parallel
edasubert Jul 18, 2023
03e7c2f
requirements
edasubert Jul 18, 2023
fe4cb84
multiple probability maps
edasubert Jul 19, 2023
fb76b5d
undo shrink
edasubert Jul 19, 2023
107a767
no more 3.7
edasubert Jul 19, 2023
bacfa3f
no more 3.7 - second try
edasubert Jul 19, 2023
5d95653
no more 3.7 - 3rd try
edasubert Jul 19, 2023
b88fdb9
remove joblib name
edasubert Jul 19, 2023
0c1ece1
remove comment
edasubert Jul 19, 2023
53d8436
Merge branch 'NSETM-2196-update-create-from-probability-map-probabili…
edasubert Jul 19, 2023
924ec07
Merge branch 'parallel' into NSETM-2196-multiple-probability-maps
edasubert Jul 19, 2023
9c23b0c
clean tests
edasubert Jul 19, 2023
46ba45a
restore metadata
edasubert Jul 19, 2023
f7d5016
restore metadata
edasubert Jul 20, 2023
2dba865
Merge branch 'NSETM-2196-update-create-from-probability-map-probabili…
edasubert Jul 20, 2023
7cf957f
Merge branch 'parallel' into NSETM-2196-multiple-probability-maps
edasubert Jul 20, 2023
4ffd4bb
restore 3.8
edasubert Jul 20, 2023
f6c4add
metype, | separator
edasubert Jul 21, 2023
01963c1
save after
edasubert Jul 21, 2023
6a2c1fa
tests and logs
edasubert Jul 21, 2023
f2b2eb8
Merge remote-tracking branch 'origin/main' into NSETM-2196-update-output
edasubert Jul 24, 2023
2e191d2
Merge branch 'main' into NSETM-2196-update-output
edasubert Jul 24, 2023
78ad92c
docs
edasubert Jul 24, 2023
519eda3
revert utils
edasubert Jul 24, 2023
a8c48e7
test
edasubert Jul 24, 2023
5317eeb
:-|
edasubert Jul 24, 2023
da13ee8
synapse class
edasubert Jul 27, 2023
153906d
Merge branch 'main' into NSETM-2196-synapse-class
edasubert Jul 27, 2023
e58a5a9
lint
edasubert Jul 27, 2023
3791cd3
update timestamp
edasubert Jul 31, 2023
880321f
include synapse class in metadata
edasubert Jul 31, 2023
3cb73b8
remove all option
edasubert Jul 31, 2023
65f7baf
revert suffix to synapse_class
edasubert Jul 31, 2023
34f2197
expand output metadata
edasubert Aug 2, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
revert utils
  • Loading branch information
edasubert committed Jul 24, 2023
commit 519eda304d58e6c7d94b04d038a975575b582269
18 changes: 7 additions & 11 deletions atlas_densities/densities/mtype_densities_from_map/utils.py
Original file line number Diff line number Diff line change
@@ -59,15 +59,11 @@ def _check_probability_map_consistency(


def _merge_probability_maps(probability_maps: List["pd.Dataframe"]) -> "pd.Dataframe":
occupied_region_acronyms: Set[str] = set()
for probability_map in probability_maps:
region_acronyms = {region for region, _ in probability_map.index}
if intersection := occupied_region_acronyms & region_acronyms:
raise ValueError(
"Two probability maps have regions in common. "
"Each region can only be defined in a single probability map. "
f"Regions in common: {intersection}",
)
occupied_region_acronyms = occupied_region_acronyms.union(region_acronyms)
result = pd.concat(probability_maps, sort=False).fillna(0)

return pd.concat(probability_maps, sort=False).fillna(0)
if result.index.duplicated().any():
raise ValueError(
"Two probability maps have index values in common. "
"Each row header can only appear in one probability map. ",
)
return result