pycsamt.agents.tipper_analysis#
pycsamt.agents.tipper_analysis#
TipperAnalysisAgent — Dedicated tipper vector analysis.
Computes induction arrows (Wiese or Parkinson convention), tipper magnitude and phase curves, and produces a map-view arrow plot alongside per-station tipper vs period profiles. Tipper vectors are a primary diagnostic for 3-D structure, crustal conductors, and coastal effects.
Wraps#
induction_arrows()tipper_amp_phase()
Classes
|
Analyse tipper vectors and plot induction arrows. |
- class pycsamt.agents.tipper_analysis.TipperAnalysisAgent(*, api_key=None, model=None, llm_provider='claude', convention='wiese', use_imag=False, period_ref=None)[source]#
Bases:
BaseAgentAnalyse tipper vectors and plot induction arrows.
- Parameters:
api_key (str)
model (str)
llm_provider (str)
convention (str, optional) – Arrow convention. Wiese (default) points toward conductors in the real-part convention; Parkinson points toward them.
use_imag (bool, optional) – Use imaginary tipper parts for deeper structure (default False).
period_ref (arrow_table pandas.DataFrame — induction arrows at) – Reference period (s) for the induction arrow map.
Noneuses the geometric mean of available periods.keys (Output data)
----------
path (sites /)
convention
use_imag
period_ref
output_dir (str, optional)
keys
----------------
per-(station (tipper_table pandas.DataFrame —)
period)
period_ref
map (period_ref float — period used for arrow)
int (n_stations_with_tipper)
dict (figure_paths)
dict
Examples
>>> agent = TipperAnalysisAgent(convention='wiese') >>> r = agent.execute({"path": "/data/WILLY_EDIs"}) >>> r["n_stations_with_tipper"] 12
- SYSTEM_PROMPT: str = 'You are an expert in magnetotelluric tipper analysis and 3-D structure interpretation.\nGiven a tipper analysis result, write 4-5 sentences that:\n1. Describe the general tipper magnitude pattern across the survey (strong/weak, frequency dependence).\n2. Identify stations with anomalously large tipper amplitudes and their likely cause.\n3. Interpret the induction arrow direction(s) — do they point toward or away from a conductor?\n4. Assess the 3-D character of the survey based on tipper consistency along the profile.\n5. Recommend whether a 3-D inversion is warranted or whether 2-D is sufficient.\nReply in plain scientific English.\n'#
Override in subclasses to give the LLM its domain expertise.
- execute(input_data)[source]#
Run this agent on input_data and return an
AgentResult.Subclasses must implement this method. The contract:
Reset
self._last_cost = 0.0at the top.Record wall-clock time with
t0 = time.time().Return
AgentResult(elapsed_seconds=time.time()-t0, cost_estimate_usd=self._last_cost, ...).
- Parameters:
- Return type: