Skip to content

modelgrid object will not work in place of spatial_reference object in calc_factors_grid #466

Open
@RyanConway91

Description

@RyanConway91

I am trying to calculate kriging factors for an mf6 disv. Looks like the method wants a depreciated spatial_reference object instead of a current modelgrid object.

v = pyemu.geostats.ExpVario(contribution=1.0, a=600)#a = 3 times finest PP spacing
gs = pyemu.geostats.GeoStruct(variograms=v,transform="log")
#modify/add cols needed by pyemu
df_pps= df_pps.rename(columns = {'X':'x','Y':'y'})
df_pps['name'] = ['pp_{}'.format(i) for i in range(len(df_pps))]
# hk_pp = df_pps[['name','x','y']]
ok = pyemu.geostats.OrdinaryKrige(geostruct=gs,point_data=df_pps)
f = r"V:\13\80\1006\MF6\recalibration\recal1\Cordova_MF6.dis.grb"
mg = MfGrdFile(f).modelgrid
ok.calc_factors_grid(mg,verbose = True, num_threads = 16)#does not work

error is "Exception: spatial_reference does not have proper attributes:'VertexGrid' object has no attribute 'xcentergrid'"

I have pyemu 1.3.3 and flopy 3.5.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions