-
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.
initial skeleton for loading sample data
- Loading branch information
1 parent
f6b653c
commit e1beb32
Showing
4 changed files
with
85 additions
and
6 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
import json | ||
|
||
from yt_napari import __version__ | ||
from yt_napari._model_ingestor import load_from_json_strs | ||
|
||
isogaldict = { | ||
"datasets": [ | ||
{ | ||
"filename": "IsolatedGalaxy", | ||
"selections": { | ||
"regions": [ | ||
{ | ||
"fields": [ | ||
{ | ||
"field_name": "Density", | ||
"field_type": "enzo", | ||
"take_log": True, | ||
} | ||
], | ||
"left_edge": { | ||
"value": [ | ||
0.4, | ||
0.4, | ||
0.4, | ||
], | ||
"unit": "Mpc", | ||
}, | ||
"right_edge": { | ||
"value": [ | ||
0.6, | ||
0.6, | ||
0.6, | ||
], | ||
"unit": "Mpc", | ||
}, | ||
"resolution": [400, 400, 400], | ||
}, | ||
] | ||
}, | ||
"edge_units": "Mpc", | ||
} | ||
] | ||
} | ||
|
||
|
||
def isogal(): | ||
isogaldict["$schema"] = f"yt-napari_{__version__}.json" | ||
json_objs = [json.dumps(isogaldict)] | ||
result = load_from_json_strs(json_objs) | ||
return result | ||
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