File tree Expand file tree Collapse file tree 2 files changed +9
-13
lines changed
user_session/routers/surface Expand file tree Collapse file tree 2 files changed +9
-13
lines changed Original file line number Diff line number Diff line change @@ -92,8 +92,8 @@ async def _create_new_job(self, user_id: str) -> None:
92
92
# these could be dynamic based on e.g. the selected ensemble sizess by the user.
93
93
json = {
94
94
"resources" : {
95
- "limits" : {"memory" : "128GiB " , "cpu" : "16 " },
96
- "requests" : {"memory" : "32GiB" , "cpu" : "4 " },
95
+ "limits" : {"memory" : "64GiB " , "cpu" : "4 " },
96
+ "requests" : {"memory" : "32GiB" , "cpu" : "2 " },
97
97
}
98
98
},
99
99
)
Original file line number Diff line number Diff line change @@ -70,13 +70,13 @@ async def well_intersection_reals_from_user_session(
70
70
for res in res_array :
71
71
tot_mb += len (res ) / (1024 * 1024 )
72
72
bytesios = [BytesIO (bytestr ) for bytestr in res_array ]
73
- xtgeofiles = [_XTGeoFile (bytestr ) for bytestr in bytesios ]
74
- test = [BytesIO (bytestr ).read () for bytestr in res_array ]
73
+ # xtgeofiles = [_XTGeoFile(bytestr) for bytestr in bytesios]
74
+ # test = [BytesIO(bytestr).read() for bytestr in res_array]
75
75
elapsed_bytesio = timer .lap_s ()
76
76
77
- surfaces = [
78
- xtgeo .surface_from_file (bytestr , fformat = "irap_binary" ) for bytestr in bytesios
79
- ]
77
+ # surfaces = [
78
+ # xtgeo.surface_from_file(bytestr, fformat="irap_binary") for bytestr in bytesios
79
+ # ]
80
80
elapsed_xtgeo = timer .lap_s ()
81
81
82
82
# surfaces2 = [
@@ -140,12 +140,8 @@ def read_header(buf):
140
140
141
141
def read_values_optimized (header , buf ):
142
142
stv = 100
143
- n_blocks = (len (buf ) - stv ) // (
144
- header ["ncol" ] * 4 + 8
145
- ) # approximate number of blocks
146
- datav = np .empty (
147
- (header ["ncol" ] * n_blocks ,), dtype = np .float32
148
- ) # preallocated array
143
+ n_blocks = (len (buf ) - stv ) // (header ["ncol" ] * 4 + 8 )
144
+ datav = np .empty ((header ["ncol" ] * n_blocks ,), dtype = np .float32 ) # preallocate
149
145
150
146
idx = 0
151
147
while stv < len (buf ):
You can’t perform that action at this time.
0 commit comments