@@ -128,16 +128,6 @@ def __setattr__(self, name, value):
128128 else :
129129 self ._data [name ][self ._index ] = value
130130
131- def __repr__ (self ):
132- time_string = "not_yet_set" if self .time is None or np .isnan (self .time ) else f"{ self .time :f} "
133- p_string = f"P[{ self .id } ](lon={ self .lon :f} , lat={ self .lat :f} , depth={ self .depth :f} , "
134- for var in vars (type (self )):
135- if var in ["lon_nextloop" , "lat_nextloop" , "depth_nextloop" , "time_nextloop" ]:
136- continue
137- if type (getattr (type (self ), var )) is Variable and getattr (type (self ), var ).to_write is True :
138- p_string += f"{ var } ={ getattr (self , var ):f} , "
139- return p_string + f"time={ time_string } )"
140-
141131 def delete (self ):
142132 """Signal the particle for deletion."""
143133 self .state = StatusCode .Delete
@@ -190,15 +180,6 @@ def add_variables(cls, variables):
190180 def getPType (cls ):
191181 return ParticleType (cls )
192182
193- @classmethod
194- def set_lonlatdepth_dtype (cls , dtype ):
195- cls .lon .dtype = dtype
196- cls .lat .dtype = dtype
197- cls .depth .dtype = dtype
198- cls .lon_nextloop .dtype = dtype
199- cls .lat_nextloop .dtype = dtype
200- cls .depth_nextloop .dtype = dtype
201-
202183
203184InteractionParticle = Particle .add_variables (
204185 [Variable ("vert_dist" , dtype = np .float32 ), Variable ("horiz_dist" , dtype = np .float32 )]
0 commit comments