66import numpy as np
77import pytest
88import os
9+ import matplotlib .pyplot as plt
910
1011mm = gp .ImplicitCoKriging ()
1112mm .add_surfaces (['surface1' , 'foo1' , 'foo2' , 'foo3' ])
@@ -93,4 +94,20 @@ def test_read_data():
9394 model .read_data (path_i = data_path + "/data/input_data/tut_chapter1/simple_fault_model_points.csv" ,
9495 path_o = data_path + "/data/input_data/tut_chapter1/simple_fault_model_orientations.csv" )
9596
96- assert model ._surface_points .df .shape [0 ] == 57
97+ assert model ._surface_points .df .shape [0 ] == 57
98+
99+ def test_add_surface_points_to_model ():
100+ geo_model = gp .create_model ('TestModel1' )
101+ gp .init_data (geo_model , extent = [0 , 800 , 0 , 200 , - 600 , 0 ], resolution = [100 , 100 , 100 ])
102+ geo_model .set_default_surfaces ()
103+
104+ geo_model .add_surface_points (X = 223 , Y = 0.01 , Z = - 94 , surface = 'surface1' )
105+ geo_model .add_surface_points (X = 458 , Y = 0 , Z = - 107 , surface = 'surface1' )
106+ geo_model .add_surface_points (X = 612 , Y = 0 , Z = - 14 , surface = 'surface1' )
107+ geo_model .add_orientations (X = 350 , Y = 0 , Z = - 300 , surface = 'surface1' , pole_vector = (0 , 0 , 1 ))
108+
109+ geo_model .add_surface_points (X = 225 , Y = 1 , Z = - 269 , surface = 'surface2' )
110+ geo_model .add_surface_points (X = 459 , Y = 1 , Z = - 279 , surface = 'surface2' )
111+
112+ #gp.plot_2d(geo_model, cell_number=5, legend='force')
113+ #plt.show()
0 commit comments