import{s as Ks,c as al,u as nl,g as ol,d as sl,o as ll,n as Ka}from"../chunks/scheduler.9991993c.js";import{S as el,i as tl,r as g,u as f,v as h,d as m,t as p,w as u,g as o,m as Xs,s as r,h as s,j as _,n as Zs,f as n,c as a,k as $,a as i,y as t,o as il,A as cl,x as c}from"../chunks/index.7fc9a5e7.js";import{T as rl}from"../chunks/Tip.9de92fc6.js";import{D as C}from"../chunks/Docstring.0d7e3ebb.js";import{C as Qa}from"../chunks/CodeBlock.e11cba92.js";import{E as Qs}from"../chunks/ExampleCodeBlock.46b9776a.js";import{H as Yr,E as dl}from"../chunks/EditOnGithub.84ab7f0e.js";function ml(E){let d,x,b,w,y;const v=E[1].default,M=al(v,E,E[2],null);return{c(){d=o("p"),x=Xs("Deprecated in "),b=Xs(E[0]),w=r(),M&&M.c(),this.h()},l(L){d=s(L,"P",{class:!0});var I=_(d);x=Zs(I,"Deprecated in "),b=Zs(I,E[0]),I.forEach(n),w=a(L),M&&M.l(L),this.h()},h(){$(d,"class","font-medium")},m(L,I){i(L,d,I),t(d,x),t(d,b),i(L,w,I),M&&M.m(L,I),y=!0},p(L,I){(!y||I&1)&&il(b,L[0]),M&&M.p&&(!y||I&4)&&nl(M,v,L,L[2],y?sl(v,L[2],I,null):ol(L[2]),null)},i(L){y||(m(M,L),y=!0)},o(L){p(M,L),y=!1},d(L){L&&(n(d),n(w)),M&&M.d(L)}}}function pl(E){let d,x;return d=new rl({props:{warning:!0,$$slots:{default:[ml]},$$scope:{ctx:E}}}),{c(){g(d.$$.fragment)},l(b){f(d.$$.fragment,b)},m(b,w){h(d,b,w),x=!0},p(b,[w]){const y={};w&5&&(y.$$scope={dirty:w,ctx:b}),d.$set(y)},i(b){x||(m(d.$$.fragment,b),x=!0)},o(b){p(d.$$.fragment,b),x=!1},d(b){u(d,b)}}}function gl(E,d,x){let{$$slots:b={},$$scope:w}=d,{version:y}=d;return E.$$set=v=>{"version"in v&&x(0,y=v.version),"$$scope"in v&&x(2,w=v.$$scope)},[y,b,w]}class fl extends el{constructor(d){super(),tl(this,d,gl,pl,Ks,{version:0})}}function hl(E){let d,x="Setting <code>WANDB_LOG_MODEL</code> as <code>bool</code> will be deprecated in version 5 of 🤗 Transformers.";return{c(){d=o("p"),d.innerHTML=x},l(b){d=s(b,"P",{"data-svelte-h":!0}),c(d)!=="svelte-fxlq1n"&&(d.innerHTML=x)},m(b,w){i(b,d,w)},p:Ka,d(b){b&&n(d)}}}function ul(E){let d,x="Example:",b,w,y;return w=new Qa({props:{code:"JTIzJTIwTm90ZSUzQSUyMFRoaXMlMjBleGFtcGxlJTIwc2tpcHMlMjBvdmVyJTIwc29tZSUyMHNldHVwJTIwc3RlcHMlMjBmb3IlMjBicmV2aXR5LiUwQWZyb20lMjBmbHl0ZWtpdCUyMGltcG9ydCUyMGN1cnJlbnRfY29udGV4dCUyQyUyMHRhc2slMEElMEElMEElNDB0YXNrJTBBZGVmJTIwdHJhaW5faGZfdHJhbnNmb3JtZXIoKSUzQSUwQSUyMCUyMCUyMCUyMGNwJTIwJTNEJTIwY3VycmVudF9jb250ZXh0KCkuY2hlY2twb2ludCUwQSUyMCUyMCUyMCUyMHRyYWluZXIlMjAlM0QlMjBUcmFpbmVyKC4uLiUyQyUyMGNhbGxiYWNrcyUzRCU1QkZseXRlQ2FsbGJhY2soKSU1RCklMEElMjAlMjAlMjAlMjBvdXRwdXQlMjAlM0QlMjB0cmFpbmVyLnRyYWluKHJlc3VtZV9mcm9tX2NoZWNrcG9pbnQlM0RjcC5yZXN0b3JlKCkp",highlighted:`<span class="hljs-comment"># Note: This example skips over some setup steps for brevity.</span>
<span class="hljs-keyword">from</span> flytekit <span class="hljs-keyword">import</span> current_context, task


<span class="hljs-meta">@task</span>
<span class="hljs-keyword">def</span> <span class="hljs-title function_">train_hf_transformer</span>():
    cp = current_context().checkpoint
    trainer = Trainer(..., callbacks=[FlyteCallback()])
    output = trainer.train(resume_from_checkpoint=cp.restore())`,wrap:!1}}),{c(){d=o("p"),d.textContent=x,b=r(),g(w.$$.fragment)},l(v){d=s(v,"P",{"data-svelte-h":!0}),c(d)!=="svelte-11lpom8"&&(d.textContent=x),b=a(v),f(w.$$.fragment,v)},m(v,M){i(v,d,M),i(v,b,M),h(w,v,M),y=!0},p:Ka,i(v){y||(m(w.$$.fragment,v),y=!0)},o(v){p(w.$$.fragment,v),y=!1},d(v){v&&(n(d),n(b)),u(w,v)}}}function bl(E){let d,x="Example:",b,w,y;return w=new Qa({props:{code:"Y2xhc3MlMjBQcmludGVyQ2FsbGJhY2soVHJhaW5lckNhbGxiYWNrKSUzQSUwQSUyMCUyMCUyMCUyMGRlZiUyMG9uX2xvZyhzZWxmJTJDJTIwYXJncyUyQyUyMHN0YXRlJTJDJTIwY29udHJvbCUyQyUyMGxvZ3MlM0ROb25lJTJDJTIwKiprd2FyZ3MpJTNBJTBBJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwXyUyMCUzRCUyMGxvZ3MucG9wKCUyMnRvdGFsX2Zsb3MlMjIlMkMlMjBOb25lKSUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMGlmJTIwc3RhdGUuaXNfbG9jYWxfcHJvY2Vzc196ZXJvJTNBJTBBJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwJTIwcHJpbnQobG9ncyk=",highlighted:`<span class="hljs-keyword">class</span> <span class="hljs-title class_">PrinterCallback</span>(<span class="hljs-title class_ inherited__">TrainerCallback</span>):
    <span class="hljs-keyword">def</span> <span class="hljs-title function_">on_log</span>(<span class="hljs-params">self, args, state, control, logs=<span class="hljs-literal">None</span>, **kwargs</span>):
        _ = logs.pop(<span class="hljs-string">&quot;total_flos&quot;</span>, <span class="hljs-literal">None</span>)
        <span class="hljs-keyword">if</span> state.is_local_process_zero:
            <span class="hljs-built_in">print</span>(logs)`,wrap:!1}}),{c(){d=o("p"),d.textContent=x,b=r(),g(w.$$.fragment)},l(v){d=s(v,"P",{"data-svelte-h":!0}),c(d)!=="svelte-11lpom8"&&(d.textContent=x),b=a(v),f(w.$$.fragment,v)},m(v,M){i(v,d,M),i(v,b,M),h(w,v,M),y=!0},p:Ka,i(v){y||(m(w.$$.fragment,v),y=!0)},o(v){p(w.$$.fragment,v),y=!1},d(v){v&&(n(d),n(b)),u(w,v)}}}function _l(E){let d,x=`In all this class, one step is to be understood as one update step. When using gradient accumulation, one update
step may require several forward and backward passes: if you use <code>gradient_accumulation_steps=n</code>, then one update
step requires going through <em>n</em> batches.`;return{c(){d=o("p"),d.innerHTML=x},l(b){d=s(b,"P",{"data-svelte-h":!0}),c(d)!=="svelte-rhwh6p"&&(d.innerHTML=x)},m(b,w){i(b,d,w)},p:Ka,d(b){b&&n(d)}}}function vl(E){let d,x,b,w,y,v,M,L="Callbacks可以用来自定义PyTorch [Trainer]中训练循环行为的对象（此功能尚未在TensorFlow中实现），该对象可以检查训练循环状态（用于进度报告、在TensorBoard或其他ML平台上记录日志等），并做出决策（例如提前停止）。",I,Ie,Jo='Callbacks是“只读”的代码片段，除了它们返回的[TrainerControl]对象外，它们不能更改训练循环中的任何内容。对于需要更改训练循环的自定义，您应该继承[Trainer]并重载您需要的方法（有关示例，请参见<a href="trainer">trainer</a>）。',Or,He,Uo="默认情况下，<code>TrainingArguments.report_to</code> 设置为”all”，然后[Trainer]将使用以下callbacks。",Xr,je,Do='<li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.DefaultFlowCallback">DefaultFlowCallback</a>，它处理默认的日志记录、保存和评估行为</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.PrinterCallback">PrinterCallback</a> 或 <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.ProgressCallback">ProgressCallback</a>，用于显示进度和打印日志（如果通过<code>TrainingArguments</code>停用tqdm，则使用第一个函数；否则使用第二个）。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.TensorBoardCallback">TensorBoardCallback</a>，如果TensorBoard可访问（通过PyTorch版本 &gt;= 1.4 或者 tensorboardX）。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.WandbCallback">WandbCallback</a>，如果安装了<a href="https://www.wandb.com/" rel="nofollow">wandb</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.CometCallback">CometCallback</a>，如果安装了<a href="https://www.comet.com/site/" rel="nofollow">comet_ml</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.MLflowCallback">MLflowCallback</a>，如果安装了<a href="https://www.mlflow.org/" rel="nofollow">mlflow</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.NeptuneCallback">NeptuneCallback</a>，如果安装了<a href="https://neptune.ai/" rel="nofollow">neptune</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.AzureMLCallback">AzureMLCallback</a>，如果安装了<a href="https://pypi.org/project/azureml-sdk/" rel="nofollow">azureml-sdk</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.CodeCarbonCallback">CodeCarbonCallback</a>，如果安装了<a href="https://pypi.org/project/codecarbon/" rel="nofollow">codecarbon</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.ClearMLCallback">ClearMLCallback</a>，如果安装了<a href="https://github.com/allegroai/clearml" rel="nofollow">clearml</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.DagsHubCallback">DagsHubCallback</a>，如果安装了<a href="https://dagshub.com/" rel="nofollow">dagshub</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.FlyteCallback">FlyteCallback</a>，如果安装了<a href="https://flyte.org/" rel="nofollow">flyte</a>。</li> <li><a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.integrations.DVCLiveCallback">DVCLiveCallback</a>，如果安装了<a href="https://dvc.org/doc/dvclive" rel="nofollow">dvclive</a>。</li>',Zr,ze,No="如果安装了一个软件包，但您不希望使用相关的集成，您可以将 <code>TrainingArguments.report_to</code> 更改为仅包含您想要使用的集成的列表（例如 <code>[&quot;azure_ml&quot;, &quot;wandb&quot;]</code>）。",Qr,Je,Ao='实现callbacks的主要类是<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a>。它获取用于实例化<code>Trainer</code>的<code>TrainingArguments</code>，可以通过<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerState">TrainerState</a>访问该Trainer的内部状态，并可以通过<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerControl">TrainerControl</a>对训练循环执行一些操作。',Kr,Ue,ea,De,So='这里是库里可用<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a>的列表：',ta,P,Ne,en,Jt,Po='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://www.comet.com/site/" rel="nofollow">Comet ML</a>.',tn,j,Ae,rn,Ut,Fo="Setup the optional Comet integration.",an,Dt,Wo="Environment:",nn,Nt,Bo=`<li><strong>COMET_MODE</strong> (<code>str</code>, <em>optional</em>, default to <code>get_or_create</code>):
Control whether to create and log to a new Comet experiment or append to an existing experiment.
It accepts the following values:<ul><li><code>get_or_create</code>: Decides automatically depending if
<code>COMET_EXPERIMENT_KEY</code> is set and whether an Experiment
with that key already exists or not.</li> <li><code>create</code>: Always create a new Comet Experiment.</li> <li><code>get</code>: Always try to append to an Existing Comet Experiment.
Requires <code>COMET_EXPERIMENT_KEY</code> to be set.</li> <li><code>ONLINE</code>: <strong>deprecated</strong>, used to create an online
Experiment. Use <code>COMET_START_ONLINE=1</code> instead.</li> <li><code>OFFLINE</code>: <strong>deprecated</strong>, used to created an offline
Experiment. Use <code>COMET_START_ONLINE=0</code> instead.</li> <li><code>DISABLED</code>: <strong>deprecated</strong>, used to disable Comet logging.
Use the <code>--report_to</code> flag to control the integrations used
for logging result instead.</li></ul></li> <li><strong>COMET_PROJECT_NAME</strong> (<code>str</code>, <em>optional</em>):
Comet project name for experiments.</li> <li><strong>COMET_LOG_ASSETS</strong> (<code>str</code>, <em>optional</em>, defaults to <code>TRUE</code>):
Whether or not to log training assets (tf event logs, checkpoints, etc), to Comet. Can be <code>TRUE</code>, or
<code>FALSE</code>.</li>`,on,At,Ro=`For a number of configurable items in the environment, see
<a href="https://www.comet.com/docs/v2/guides/experiment-management/configure-sdk/#explore-comet-configuration-options" rel="nofollow">here</a>.`,ra,X,Se,sn,St,Vo='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that handles the default flow of the training loop for logs, evaluation and checkpoints.',aa,Z,Pe,ln,Pt,Go='A bare <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that just prints the logs.',na,Q,Fe,cn,Ft,qo='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that displays the progress of training or evaluation.',oa,F,We,dn,Wt,Yo='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that handles early stopping.',mn,Bt,Oo=`This callback depends on <code>TrainingArguments</code> argument <em>load_best_model_at_end</em> functionality to set best_metric
in <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerState">TrainerState</a>. Note that if the <code>TrainingArguments</code> argument <em>save_steps</em> differs from <em>eval_steps</em>, the
early stopping will not occur until the next save step.`,sa,K,Be,pn,Rt,Xo='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://www.tensorflow.org/tensorboard" rel="nofollow">TensorBoard</a>.',la,W,Re,gn,Vt,Zo='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that logs metrics, media, model checkpoints to <a href="https://www.wandb.com/" rel="nofollow">Weight and Biases</a>.',fn,z,Ve,hn,Gt,Qo="Setup the optional Weights &amp; Biases (<em>wandb</em>) integration.",un,qt,Ko=`One can subclass and override this method to customize the setup if needed. Find more information
<a href="https://docs.wandb.ai/guides/integrations/huggingface" rel="nofollow">here</a>. You can also override the following environment
variables:`,bn,Yt,es="Environment:",_n,B,Ge,Ot,ts=`<strong>WANDB_LOG_MODEL</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;false&quot;</code>):
Whether to log model and checkpoints during training. Can be <code>&quot;end&quot;</code>, <code>&quot;checkpoint&quot;</code> or <code>&quot;false&quot;</code>. If set
to <code>&quot;end&quot;</code>, the model will be uploaded at the end of training. If set to <code>&quot;checkpoint&quot;</code>, the checkpoint
will be uploaded every <code>args.save_steps</code> . If set to <code>&quot;false&quot;</code>, the model will not be uploaded. Use along
with <code>load_best_model_at_end()</code> to upload best model.`,vn,ne,Tn,Xt,rs=`<p><strong>WANDB_WATCH</strong> (<code>str</code>, <em>optional</em> defaults to <code>&quot;false&quot;</code>):
Can be <code>&quot;gradients&quot;</code>, <code>&quot;all&quot;</code>, <code>&quot;parameters&quot;</code>, or <code>&quot;false&quot;</code>. Set to <code>&quot;all&quot;</code> to log gradients and
parameters.</p>`,$n,Zt,as=`<p><strong>WANDB_PROJECT</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;huggingface&quot;</code>):
Set this to a custom string to store results in a different project.</p>`,Cn,Qt,ns=`<p><strong>WANDB_DISABLED</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>):
Whether to disable wandb entirely. Set <code>WANDB_DISABLED=true</code> to disable.</p>`,ia,R,qe,kn,Kt,os=`A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://www.mlflow.org/" rel="nofollow">MLflow</a>. Can be disabled by setting
environment variable <code>DISABLE_MLFLOW_INTEGRATION = TRUE</code>.`,wn,N,Ye,yn,er,ss="Setup the optional MLflow integration.",Mn,tr,ls="Environment:",xn,rr,is=`<li><strong>HF_MLFLOW_LOG_ARTIFACTS</strong> (<code>str</code>, <em>optional</em>):
Whether to use MLflow <code>.log_artifact()</code> facility to log artifacts. This only makes sense if logging to a
remote server, e.g. s3 or GCS. If set to <code>True</code> or <em>1</em>, will copy each saved checkpoint on each save in
<code>TrainingArguments</code>’s <code>output_dir</code> to the local or remote artifact storage. Using it without a remote
storage will just copy the files to your artifact location.</li> <li><strong>MLFLOW_TRACKING_URI</strong> (<code>str</code>, <em>optional</em>):
Whether to store runs at a specific path or remote server. Unset by default, which skips setting the
tracking URI entirely.</li> <li><strong>MLFLOW_EXPERIMENT_NAME</strong> (<code>str</code>, <em>optional</em>, defaults to <code>None</code>):
Whether to use an MLflow experiment_name under which to launch the run. Default to <code>None</code> which will point
to the <code>Default</code> experiment in MLflow. Otherwise, it is a case sensitive name of the experiment to be
activated. If an experiment with this name does not exist, a new experiment with this name is created.</li> <li><strong>MLFLOW_TAGS</strong> (<code>str</code>, <em>optional</em>):
A string dump of a dictionary of key/value pair to be added to the MLflow run as tags. Example:
<code>os.environ[&#39;MLFLOW_TAGS&#39;]=&#39;{&quot;release.candidate&quot;: &quot;RC1&quot;, &quot;release.version&quot;: &quot;2.2.0&quot;}&#39;</code>.</li> <li><strong>MLFLOW_NESTED_RUN</strong> (<code>str</code>, <em>optional</em>):
Whether to use MLflow nested runs. If set to <code>True</code> or <em>1</em>, will create a nested run inside the current
run.</li> <li><strong>MLFLOW_RUN_ID</strong> (<code>str</code>, <em>optional</em>):
Allow to reattach to an existing run which can be usefull when resuming training from a checkpoint. When
<code>MLFLOW_RUN_ID</code> environment variable is set, <code>start_run</code> attempts to resume a run with the specified run ID
and other parameters are ignored.</li> <li><strong>MLFLOW_FLATTEN_PARAMS</strong> (<code>str</code>, <em>optional</em>, defaults to <code>False</code>):
Whether to flatten the parameters dictionary before logging.</li>`,ca,ee,Oe,Ln,ar,cs='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://pypi.org/project/azureml-sdk/" rel="nofollow">AzureML</a>.',da,te,Xe,En,nr,ds='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that tracks the CO2 emission of training.',ma,V,Ze,In,or,ms='TrainerCallback that sends the logs to <a href="https://app.neptune.ai" rel="nofollow">Neptune</a>.',Hn,sr,ps=`For instructions and examples, see the <a href="https://docs.neptune.ai/integrations/transformers" rel="nofollow">Transformers integration
guide</a> in the Neptune documentation.`,pa,J,Qe,jn,lr,gs='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://clear.ml/" rel="nofollow">ClearML</a>.',zn,ir,fs="Environment:",Jn,cr,hs=`<li><strong>CLEARML_PROJECT</strong> (<code>str</code>, <em>optional</em>, defaults to <code>HuggingFace Transformers</code>):
ClearML project name.</li> <li><strong>CLEARML_TASK</strong> (<code>str</code>, <em>optional</em>, defaults to <code>Trainer</code>):
ClearML task name.</li> <li><strong>CLEARML_LOG_MODEL</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>):
Whether to log models as artifacts during training.</li>`,ga,G,Ke,Un,dr,us='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that logs to <a href="https://dagshub.com/" rel="nofollow">DagsHub</a>. Extends <code>MLflowCallback</code>',Dn,A,et,Nn,mr,bs="Setup the DagsHub’s Logging integration.",An,pr,_s="Environment:",Sn,gr,vs=`<li><strong>HF_DAGSHUB_LOG_ARTIFACTS</strong> (<code>str</code>, <em>optional</em>):
Whether to save the data and model artifacts for the experiment. Default to <code>False</code>.</li>`,fa,q,tt,Pn,fr,Ts=`A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://flyte.org/" rel="nofollow">Flyte</a>.
NOTE: This callback only works within a Flyte task.`,Fn,oe,ha,U,rt,Wn,hr,$s='A <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> that sends the logs to <a href="https://www.dvc.org/doc/dvclive" rel="nofollow">DVCLive</a>.',Bn,ur,Cs=`Use the environment variables below in <code>setup</code> to configure the integration. To customize this callback beyond
those environment variables, see <a href="https://dvc.org/doc/dvclive/ml-frameworks/huggingface" rel="nofollow">here</a>.`,Rn,S,at,Vn,br,ks=`Setup the optional DVCLive integration. To customize this callback beyond the environment variables below, see
<a href="https://dvc.org/doc/dvclive/ml-frameworks/huggingface" rel="nofollow">here</a>.`,Gn,_r,ws="Environment:",qn,vr,ys=`<li><strong>HF_DVCLIVE_LOG_MODEL</strong> (<code>str</code>, <em>optional</em>):
Whether to use <code>dvclive.Live.log_artifact()</code> to log checkpoints created by <code>Trainer</code>. If set to <code>True</code> or
<em>1</em>, the final checkpoint is logged at the end of training. If set to <code>all</code>, the entire
<code>TrainingArguments</code>’s <code>output_dir</code> is logged at each checkpoint.</li>`,ua,nt,ba,T,ot,Yn,Tr,Ms=`A class for objects that will inspect the state of the training loop at some events and take some decisions. At
each of those events the following arguments are available:`,On,$r,xs=`The <code>control</code> object is the only one that can be changed by the callback, in which case the event that changes it
should return the modified version.`,Xn,Cr,Ls=`The argument <code>args</code>, <code>state</code> and <code>control</code> are positionals for all events, all the others are grouped in <code>kwargs</code>.
You can unpack the ones you need in the signature of the event using them. As an example, see the code of the
simple <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.PrinterCallback">PrinterCallback</a>.`,Zn,se,Qn,le,st,Kn,kr,Es="Event called at the beginning of an epoch.",eo,ie,lt,to,wr,Is="Event called at the end of an epoch.",ro,ce,it,ao,yr,Hs="Event called after an evaluation phase.",no,de,ct,oo,Mr,js="Event called at the end of the initialization of the <code>Trainer</code>.",so,me,dt,lo,xr,zs="Event called after logging the last logs.",io,pe,mt,co,Lr,Js="Event called after the optimizer step but before gradients are zeroed out. Useful for monitoring gradients.",mo,ge,pt,po,Er,Us="Event called after a successful prediction.",go,fe,gt,fo,Ir,Ds="Event called after a prediction step.",ho,he,ft,uo,Hr,Ns="Event called after a checkpoint save.",bo,ue,ht,_o,jr,As=`Event called at the beginning of a training step. If using gradient accumulation, one training step might take
several inputs.`,vo,be,ut,To,zr,Ss=`Event called at the end of a training step. If using gradient accumulation, one training step might take
several inputs.`,$o,_e,bt,Co,Jr,Ps="Event called at the end of an substep during gradient accumulation.",ko,ve,_t,wo,Ur,Fs="Event called at the beginning of training.",yo,Te,vt,Mo,Dr,Ws="Event called at the end of training.",_a,Tt,Bs="以下是如何使用PyTorch注册自定义callback的示例：",va,$t,Rs="<code>Trainer</code>:",Ta,Ct,$a,kt,Vs="注册callback的另一种方式是调用 <code>trainer.add_callback()</code>，如下所示：",Ca,wt,ka,yt,wa,H,Mt,xo,Nr,Gs=`A class containing the <code>Trainer</code> inner state that will be saved along the model and optimizer when checkpointing
and passed to the <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a>.`,Lo,$e,Eo,Ce,xt,Io,Ar,qs="Create an instance from the content of <code>json_path</code>.",Ho,ke,Lt,jo,Sr,Ys="Save the content of this instance in JSON format inside <code>json_path</code>.",ya,Et,Ma,re,It,zo,Pr,Os=`A class that handles the <code>Trainer</code> control flow. This class is used by the <a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerCallback">TrainerCallback</a> to activate some
switches in the training loop.`,xa,Ht,La,qr,Ea;return y=new Yr({props:{title:"Callbacks",local:"callbacks",headingTag:"h1"}}),Ue=new Yr({props:{title:"可用的Callbacks",local:"transformers.integrations.CometCallback",headingTag:"h2"}}),Ne=new C({props:{name:"class transformers.integrations.CometCallback",anchor:"transformers.integrations.CometCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L972"}}),Ae=new C({props:{name:"setup",anchor:"transformers.integrations.CometCallback.setup",parameters:[{name:"args",val:""},{name:"state",val:""},{name:"model",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L986"}}),Se=new C({props:{name:"class transformers.DefaultFlowCallback",anchor:"transformers.DefaultFlowCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L526"}}),Pe=new C({props:{name:"class transformers.PrinterCallback",anchor:"transformers.PrinterCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L634"}}),Fe=new C({props:{name:"class transformers.ProgressCallback",anchor:"transformers.ProgressCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L579"}}),We=new C({props:{name:"class transformers.EarlyStoppingCallback",anchor:"transformers.EarlyStoppingCallback",parameters:[{name:"early_stopping_patience",val:": int = 1"},{name:"early_stopping_threshold",val:": Optional = 0.0"}],parametersDescription:[{anchor:"transformers.EarlyStoppingCallback.early_stopping_patience",description:`<strong>early_stopping_patience</strong> (<code>int</code>) &#x2014;
Use with <code>metric_for_best_model</code> to stop training when the specified metric worsens for
<code>early_stopping_patience</code> evaluation calls.`,name:"early_stopping_patience"},{anchor:"transformers.EarlyStoppingCallback.early_stopping_threshold(float,",description:`<strong>early_stopping_threshold(<code>float</code>,</strong> <em>optional</em>) &#x2014;
Use with TrainingArguments <code>metric_for_best_model</code> and <code>early_stopping_patience</code> to denote how much the
specified metric must improve to satisfy early stopping conditions. \``,name:"early_stopping_threshold(float,"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L645"}}),Be=new C({props:{name:"class transformers.integrations.TensorBoardCallback",anchor:"transformers.integrations.TensorBoardCallback",parameters:[{name:"tb_writer",val:" = None"}],parametersDescription:[{anchor:"transformers.integrations.TensorBoardCallback.tb_writer",description:`<strong>tb_writer</strong> (<code>SummaryWriter</code>, <em>optional</em>) &#x2014;
The writer to use. Will instantiate one if not set.`,name:"tb_writer"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L626"}}),Re=new C({props:{name:"class transformers.integrations.WandbCallback",anchor:"transformers.integrations.WandbCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L728"}}),Ve=new C({props:{name:"setup",anchor:"transformers.integrations.WandbCallback.setup",parameters:[{name:"args",val:""},{name:"state",val:""},{name:"model",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L753"}}),ne=new fl({props:{version:"5.0",$$slots:{default:[hl]},$$scope:{ctx:E}}}),qe=new C({props:{name:"class transformers.integrations.MLflowCallback",anchor:"transformers.integrations.MLflowCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1129"}}),Ye=new C({props:{name:"setup",anchor:"transformers.integrations.MLflowCallback.setup",parameters:[{name:"args",val:""},{name:"state",val:""},{name:"model",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1148"}}),Oe=new C({props:{name:"class transformers.integrations.AzureMLCallback",anchor:"transformers.integrations.AzureMLCallback",parameters:[{name:"azureml_run",val:" = None"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1106"}}),Xe=new C({props:{name:"class transformers.integrations.CodeCarbonCallback",anchor:"transformers.integrations.CodeCarbonCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1630"}}),Ze=new C({props:{name:"class transformers.integrations.NeptuneCallback",anchor:"transformers.integrations.NeptuneCallback",parameters:[{name:"api_token",val:": Optional = None"},{name:"project",val:": Optional = None"},{name:"name",val:": Optional = None"},{name:"base_namespace",val:": str = 'finetuning'"},{name:"run",val:" = None"},{name:"log_parameters",val:": bool = True"},{name:"log_checkpoints",val:": Optional = None"},{name:"**neptune_run_kwargs",val:""}],parametersDescription:[{anchor:"transformers.integrations.NeptuneCallback.api_token",description:`<strong>api_token</strong> (<code>str</code>, <em>optional</em>) &#x2014; Neptune API token obtained upon registration.
You can leave this argument out if you have saved your token to the <code>NEPTUNE_API_TOKEN</code> environment
variable (strongly recommended). See full setup instructions in the
<a href="https://docs.neptune.ai/setup/installation" rel="nofollow">docs</a>.`,name:"api_token"},{anchor:"transformers.integrations.NeptuneCallback.project",description:`<strong>project</strong> (<code>str</code>, <em>optional</em>) &#x2014; Name of an existing Neptune project, in the form &#x201C;workspace-name/project-name&#x201D;.
You can find and copy the name in Neptune from the project settings -&gt; Properties. If None (default), the
value of the <code>NEPTUNE_PROJECT</code> environment variable is used.`,name:"project"},{anchor:"transformers.integrations.NeptuneCallback.name",description:"<strong>name</strong> (<code>str</code>, <em>optional</em>) &#x2014; Custom name for the run.",name:"name"},{anchor:"transformers.integrations.NeptuneCallback.base_namespace",description:`<strong>base_namespace</strong> (<code>str</code>, optional, defaults to &#x201C;finetuning&#x201D;) &#x2014; In the Neptune run, the root namespace
that will contain all of the metadata logged by the callback.`,name:"base_namespace"},{anchor:"transformers.integrations.NeptuneCallback.log_parameters",description:`<strong>log_parameters</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
If True, logs all Trainer arguments and model parameters provided by the Trainer.`,name:"log_parameters"},{anchor:"transformers.integrations.NeptuneCallback.log_checkpoints",description:`<strong>log_checkpoints</strong> (<code>str</code>, <em>optional</em>) &#x2014; If &#x201C;same&#x201D;, uploads checkpoints whenever they are saved by the Trainer.
If &#x201C;last&#x201D;, uploads only the most recently saved checkpoint. If &#x201C;best&#x201D;, uploads the best checkpoint (among
the ones saved by the Trainer). If <code>None</code>, does not upload checkpoints.`,name:"log_checkpoints"},{anchor:"transformers.integrations.NeptuneCallback.run",description:`<strong>run</strong> (<code>Run</code>, <em>optional</em>) &#x2014; Pass a Neptune run object if you want to continue logging to an existing run.
Read more about resuming runs in the <a href="https://docs.neptune.ai/logging/to_existing_object" rel="nofollow">docs</a>.`,name:"run"},{anchor:"transformers.integrations.NeptuneCallback.*neptune_run_kwargs",description:`*<strong>*neptune_run_kwargs</strong> (<em>optional</em>) &#x2014;
Additional keyword arguments to be passed directly to the
<a href="https://docs.neptune.ai/api/neptune#init_run" rel="nofollow"><code>neptune.init_run()</code></a> function when a new run is created.`,name:"*neptune_run_kwargs"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1357"}}),Qe=new C({props:{name:"class transformers.integrations.ClearMLCallback",anchor:"transformers.integrations.ClearMLCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1664"}}),Ke=new C({props:{name:"class transformers.integrations.DagsHubCallback",anchor:"transformers.integrations.DagsHubCallback",parameters:[],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1297"}}),et=new C({props:{name:"setup",anchor:"transformers.integrations.DagsHubCallback.setup",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1311"}}),tt=new C({props:{name:"class transformers.integrations.FlyteCallback",anchor:"transformers.integrations.FlyteCallback",parameters:[{name:"save_log_history",val:": bool = True"},{name:"sync_checkpoints",val:": bool = True"}],parametersDescription:[{anchor:"transformers.integrations.FlyteCallback.save_log_history",description:`<strong>save_log_history</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
When set to True, the training logs are saved as a Flyte Deck.`,name:"save_log_history"},{anchor:"transformers.integrations.FlyteCallback.sync_checkpoints",description:`<strong>sync_checkpoints</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
When set to True, checkpoints are synced with Flyte and can be used to resume training in the case of an
interruption.`,name:"sync_checkpoints"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1917"}}),oe=new Qs({props:{anchor:"transformers.integrations.FlyteCallback.example",$$slots:{default:[ul]},$$scope:{ctx:E}}}),rt=new C({props:{name:"class transformers.integrations.DVCLiveCallback",anchor:"transformers.integrations.DVCLiveCallback",parameters:[{name:"live",val:": Optional = None"},{name:"log_model",val:": Union = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.integrations.DVCLiveCallback.live",description:`<strong>live</strong> (<code>dvclive.Live</code>, <em>optional</em>, defaults to <code>None</code>) &#x2014;
Optional Live instance. If None, a new instance will be created using **kwargs.`,name:"live"},{anchor:"transformers.integrations.DVCLiveCallback.log_model",description:`<strong>log_model</strong> (Union[Literal[&#x201C;all&#x201D;], bool], <em>optional</em>, defaults to <code>None</code>) &#x2014;
Whether to use <code>dvclive.Live.log_artifact()</code> to log checkpoints created by <code>Trainer</code>. If set to <code>True</code>,
the final checkpoint is logged at the end of training. If set to <code>&quot;all&quot;</code>, the entire
<code>TrainingArguments</code>&#x2019;s <code>output_dir</code> is logged at each checkpoint.`,name:"log_model"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L1980"}}),at=new C({props:{name:"setup",anchor:"transformers.integrations.DVCLiveCallback.setup",parameters:[{name:"args",val:""},{name:"state",val:""},{name:"model",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/integrations/integration_utils.py#L2021"}}),nt=new Yr({props:{title:"TrainerCallback",local:"transformers.TrainerCallback",headingTag:"h2"}}),ot=new C({props:{name:"class transformers.TrainerCallback",anchor:"transformers.TrainerCallback",parameters:[],parametersDescription:[{anchor:"transformers.TrainerCallback.args",description:`<strong>args</strong> (<code>TrainingArguments</code>) &#x2014;
The training arguments used to instantiate the <code>Trainer</code>.`,name:"args"},{anchor:"transformers.TrainerCallback.state",description:`<strong>state</strong> (<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerState">TrainerState</a>) &#x2014;
The current state of the <code>Trainer</code>.`,name:"state"},{anchor:"transformers.TrainerCallback.control",description:`<strong>control</strong> (<a href="/docs/transformers/pr_31098/zh/main_classes/callback#transformers.TrainerControl">TrainerControl</a>) &#x2014;
The object that is returned to the <code>Trainer</code> and can be used to make some decisions.`,name:"control"},{anchor:"transformers.TrainerCallback.model",description:`<strong>model</strong> (<a href="/docs/transformers/pr_31098/zh/main_classes/model#transformers.PreTrainedModel">PreTrainedModel</a> or <code>torch.nn.Module</code>) &#x2014;
The model being trained.`,name:"model"},{anchor:"transformers.TrainerCallback.tokenizer",description:`<strong>tokenizer</strong> (<a href="/docs/transformers/pr_31098/zh/main_classes/tokenizer#transformers.PreTrainedTokenizer">PreTrainedTokenizer</a>) &#x2014;
The tokenizer used for encoding the data.`,name:"tokenizer"},{anchor:"transformers.TrainerCallback.optimizer",description:`<strong>optimizer</strong> (<code>torch.optim.Optimizer</code>) &#x2014;
The optimizer used for the training steps.`,name:"optimizer"},{anchor:"transformers.TrainerCallback.lr_scheduler",description:`<strong>lr_scheduler</strong> (<code>torch.optim.lr_scheduler.LambdaLR</code>) &#x2014;
The scheduler used for setting the learning rate.`,name:"lr_scheduler"},{anchor:"transformers.TrainerCallback.train_dataloader",description:`<strong>train_dataloader</strong> (<code>torch.utils.data.DataLoader</code>, <em>optional</em>) &#x2014;
The current dataloader used for training.`,name:"train_dataloader"},{anchor:"transformers.TrainerCallback.eval_dataloader",description:`<strong>eval_dataloader</strong> (<code>torch.utils.data.DataLoader</code>, <em>optional</em>) &#x2014;
The current dataloader used for evaluation.`,name:"eval_dataloader"},{anchor:"transformers.TrainerCallback.metrics",description:`<strong>metrics</strong> (<code>Dict[str, float]</code>) &#x2014;
The metrics computed by the last evaluation phase.</p>
<p>Those are only accessible in the event <code>on_evaluate</code>.`,name:"metrics"},{anchor:"transformers.TrainerCallback.logs",description:`<strong>logs</strong>  (<code>Dict[str, float]</code>) &#x2014;
The values to log.</p>
<p>Those are only accessible in the event <code>on_log</code>.`,name:"logs"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L260"}}),se=new Qs({props:{anchor:"transformers.TrainerCallback.example",$$slots:{default:[bl]},$$scope:{ctx:E}}}),st=new C({props:{name:"on_epoch_begin",anchor:"transformers.TrainerCallback.on_epoch_begin",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L329"}}),lt=new C({props:{name:"on_epoch_end",anchor:"transformers.TrainerCallback.on_epoch_end",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L335"}}),it=new C({props:{name:"on_evaluate",anchor:"transformers.TrainerCallback.on_evaluate",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L367"}}),ct=new C({props:{name:"on_init_end",anchor:"transformers.TrainerCallback.on_init_end",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L311"}}),dt=new C({props:{name:"on_log",anchor:"transformers.TrainerCallback.on_log",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L385"}}),mt=new C({props:{name:"on_optimizer_step",anchor:"transformers.TrainerCallback.on_optimizer_step",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L348"}}),pt=new C({props:{name:"on_predict",anchor:"transformers.TrainerCallback.on_predict",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"metrics",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L373"}}),gt=new C({props:{name:"on_prediction_step",anchor:"transformers.TrainerCallback.on_prediction_step",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L391"}}),ft=new C({props:{name:"on_save",anchor:"transformers.TrainerCallback.on_save",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L379"}}),ht=new C({props:{name:"on_step_begin",anchor:"transformers.TrainerCallback.on_step_begin",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L341"}}),ut=new C({props:{name:"on_step_end",anchor:"transformers.TrainerCallback.on_step_end",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L360"}}),bt=new C({props:{name:"on_substep_end",anchor:"transformers.TrainerCallback.on_substep_end",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L354"}}),_t=new C({props:{name:"on_train_begin",anchor:"transformers.TrainerCallback.on_train_begin",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L317"}}),vt=new C({props:{name:"on_train_end",anchor:"transformers.TrainerCallback.on_train_end",parameters:[{name:"args",val:": TrainingArguments"},{name:"state",val:": TrainerState"},{name:"control",val:": TrainerControl"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L323"}}),Ct=new Qa({props:{code:"Y2xhc3MlMjBNeUNhbGxiYWNrKFRyYWluZXJDYWxsYmFjayklM0ElMEElMjAlMjAlMjAlMjAlMjJBJTIwY2FsbGJhY2slMjB0aGF0JTIwcHJpbnRzJTIwYSUyMG1lc3NhZ2UlMjBhdCUyMHRoZSUyMGJlZ2lubmluZyUyMG9mJTIwdHJhaW5pbmclMjIlMEElMEElMjAlMjAlMjAlMjBkZWYlMjBvbl90cmFpbl9iZWdpbihzZWxmJTJDJTIwYXJncyUyQyUyMHN0YXRlJTJDJTIwY29udHJvbCUyQyUyMCoqa3dhcmdzKSUzQSUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMHByaW50KCUyMlN0YXJ0aW5nJTIwdHJhaW5pbmclMjIpJTBBJTBBJTBBdHJhaW5lciUyMCUzRCUyMFRyYWluZXIoJTBBJTIwJTIwJTIwJTIwbW9kZWwlMkMlMEElMjAlMjAlMjAlMjBhcmdzJTJDJTBBJTIwJTIwJTIwJTIwdHJhaW5fZGF0YXNldCUzRHRyYWluX2RhdGFzZXQlMkMlMEElMjAlMjAlMjAlMjBldmFsX2RhdGFzZXQlM0RldmFsX2RhdGFzZXQlMkMlMEElMjAlMjAlMjAlMjBjYWxsYmFja3MlM0QlNUJNeUNhbGxiYWNrJTVEJTJDJTIwJTIwJTIzJTIwV2UlMjBjYW4lMjBlaXRoZXIlMjBwYXNzJTIwdGhlJTIwY2FsbGJhY2slMjBjbGFzcyUyMHRoaXMlMjB3YXklMjBvciUyMGFuJTIwaW5zdGFuY2UlMjBvZiUyMGl0JTIwKE15Q2FsbGJhY2soKSklMEEp",highlighted:`<span class="hljs-keyword">class</span> <span class="hljs-title class_">MyCallback</span>(<span class="hljs-title class_ inherited__">TrainerCallback</span>):
    <span class="hljs-string">&quot;A callback that prints a message at the beginning of training&quot;</span>

    <span class="hljs-keyword">def</span> <span class="hljs-title function_">on_train_begin</span>(<span class="hljs-params">self, args, state, control, **kwargs</span>):
        <span class="hljs-built_in">print</span>(<span class="hljs-string">&quot;Starting training&quot;</span>)


trainer = Trainer(
    model,
    args,
    train_dataset=train_dataset,
    eval_dataset=eval_dataset,
    callbacks=[MyCallback],  <span class="hljs-comment"># We can either pass the callback class this way or an instance of it (MyCallback())</span>
)`,wrap:!1}}),wt=new Qa({props:{code:"dHJhaW5lciUyMCUzRCUyMFRyYWluZXIoLi4uKSUwQXRyYWluZXIuYWRkX2NhbGxiYWNrKE15Q2FsbGJhY2spJTBBJTIzJTIwQWx0ZXJuYXRpdmVseSUyQyUyMHdlJTIwY2FuJTIwcGFzcyUyMGFuJTIwaW5zdGFuY2UlMjBvZiUyMHRoZSUyMGNhbGxiYWNrJTIwY2xhc3MlMEF0cmFpbmVyLmFkZF9jYWxsYmFjayhNeUNhbGxiYWNrKCkp",highlighted:`trainer = Trainer(...)
trainer.add_callback(MyCallback)
<span class="hljs-comment"># Alternatively, we can pass an instance of the callback class</span>
trainer.add_callback(MyCallback())`,wrap:!1}}),yt=new Yr({props:{title:"TrainerState",local:"transformers.TrainerState",headingTag:"h2"}}),Mt=new C({props:{name:"class transformers.TrainerState",anchor:"transformers.TrainerState",parameters:[{name:"epoch",val:": Optional = None"},{name:"global_step",val:": int = 0"},{name:"max_steps",val:": int = 0"},{name:"logging_steps",val:": int = 500"},{name:"eval_steps",val:": int = 500"},{name:"save_steps",val:": int = 500"},{name:"train_batch_size",val:": int = None"},{name:"num_train_epochs",val:": int = 0"},{name:"num_input_tokens_seen",val:": int = 0"},{name:"total_flos",val:": float = 0"},{name:"log_history",val:": List = None"},{name:"best_metric",val:": Optional = None"},{name:"best_model_checkpoint",val:": Optional = None"},{name:"is_local_process_zero",val:": bool = True"},{name:"is_world_process_zero",val:": bool = True"},{name:"is_hyper_param_search",val:": bool = False"},{name:"trial_name",val:": str = None"},{name:"trial_params",val:": Dict = None"},{name:"stateful_callbacks",val:": List = None"}],parametersDescription:[{anchor:"transformers.TrainerState.epoch",description:`<strong>epoch</strong> (<code>float</code>, <em>optional</em>) &#x2014;
Only set during training, will represent the epoch the training is at (the decimal part being the
percentage of the current epoch completed).`,name:"epoch"},{anchor:"transformers.TrainerState.global_step",description:`<strong>global_step</strong> (<code>int</code>, <em>optional</em>, defaults to 0) &#x2014;
During training, represents the number of update steps completed.`,name:"global_step"},{anchor:"transformers.TrainerState.max_steps",description:`<strong>max_steps</strong> (<code>int</code>, <em>optional</em>, defaults to 0) &#x2014;
The number of update steps to do during the current training.`,name:"max_steps"},{anchor:"transformers.TrainerState.logging_steps",description:`<strong>logging_steps</strong> (<code>int</code>, <em>optional</em>, defaults to 500) &#x2014;
Log every X updates steps`,name:"logging_steps"},{anchor:"transformers.TrainerState.eval_steps",description:`<strong>eval_steps</strong> (<code>int</code>, <em>optional</em>) &#x2014;
Run an evaluation every X steps.`,name:"eval_steps"},{anchor:"transformers.TrainerState.save_steps",description:`<strong>save_steps</strong> (<code>int</code>, <em>optional</em>, defaults to 500) &#x2014;
Save checkpoint every X updates steps.`,name:"save_steps"},{anchor:"transformers.TrainerState.train_batch_size",description:`<strong>train_batch_size</strong> (<code>int</code>, <em>optional</em>) &#x2014;
The batch size for the training dataloader. Only needed when
<code>auto_find_batch_size</code> has been used.`,name:"train_batch_size"},{anchor:"transformers.TrainerState.num_input_tokens_seen",description:`<strong>num_input_tokens_seen</strong> (<code>int</code>, <em>optional</em>, defaults to 0) &#x2014;
The number of tokens seen during training (number of input tokens, not the number of prediction tokens).`,name:"num_input_tokens_seen"},{anchor:"transformers.TrainerState.total_flos",description:`<strong>total_flos</strong> (<code>float</code>, <em>optional</em>, defaults to 0) &#x2014;
The total number of floating operations done by the model since the beginning of training (stored as floats
to avoid overflow).`,name:"total_flos"},{anchor:"transformers.TrainerState.log_history",description:`<strong>log_history</strong> (<code>List[Dict[str, float]]</code>, <em>optional</em>) &#x2014;
The list of logs done since the beginning of training.`,name:"log_history"},{anchor:"transformers.TrainerState.best_metric",description:`<strong>best_metric</strong> (<code>float</code>, <em>optional</em>) &#x2014;
When tracking the best model, the value of the best metric encountered so far.`,name:"best_metric"},{anchor:"transformers.TrainerState.best_model_checkpoint",description:`<strong>best_model_checkpoint</strong> (<code>str</code>, <em>optional</em>) &#x2014;
When tracking the best model, the value of the name of the checkpoint for the best model encountered so
far.`,name:"best_model_checkpoint"},{anchor:"transformers.TrainerState.is_local_process_zero",description:`<strong>is_local_process_zero</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not this process is the local (e.g., on one machine if training in a distributed fashion on
several machines) main process.`,name:"is_local_process_zero"},{anchor:"transformers.TrainerState.is_world_process_zero",description:`<strong>is_world_process_zero</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not this process is the global main process (when training in a distributed fashion on several
machines, this is only going to be <code>True</code> for one process).`,name:"is_world_process_zero"},{anchor:"transformers.TrainerState.is_hyper_param_search",description:`<strong>is_hyper_param_search</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether we are in the process of a hyper parameter search using Trainer.hyperparameter_search. This will
impact the way data will be logged in TensorBoard.`,name:"is_hyper_param_search"},{anchor:"transformers.TrainerState.stateful_callbacks",description:`<strong>stateful_callbacks</strong> (<code>List[StatefulTrainerCallback]</code>, <em>optional</em>) &#x2014;
Callbacks attached to the <code>Trainer</code> that should have their states be saved or restored.
Relevent callbacks should implement a <code>state</code> and <code>from_state</code> function.`,name:"stateful_callbacks"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L36"}}),$e=new rl({props:{$$slots:{default:[_l]},$$scope:{ctx:E}}}),xt=new C({props:{name:"load_from_json",anchor:"transformers.TrainerState.load_from_json",parameters:[{name:"json_path",val:": str"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L146"}}),Lt=new C({props:{name:"save_to_json",anchor:"transformers.TrainerState.save_to_json",parameters:[{name:"json_path",val:": str"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L140"}}),Et=new Yr({props:{title:"TrainerControl",local:"transformers.TrainerControl",headingTag:"h2"}}),It=new C({props:{name:"class transformers.TrainerControl",anchor:"transformers.TrainerControl",parameters:[{name:"should_training_stop",val:": bool = False"},{name:"should_epoch_stop",val:": bool = False"},{name:"should_save",val:": bool = False"},{name:"should_evaluate",val:": bool = False"},{name:"should_log",val:": bool = False"}],parametersDescription:[{anchor:"transformers.TrainerControl.should_training_stop",description:`<strong>should_training_stop</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the training should be interrupted.</p>
<p>If <code>True</code>, this variable will not be set back to <code>False</code>. The training will just stop.`,name:"should_training_stop"},{anchor:"transformers.TrainerControl.should_epoch_stop",description:`<strong>should_epoch_stop</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the current epoch should be interrupted.</p>
<p>If <code>True</code>, this variable will be set back to <code>False</code> at the beginning of the next epoch.`,name:"should_epoch_stop"},{anchor:"transformers.TrainerControl.should_save",description:`<strong>should_save</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the model should be saved at this step.</p>
<p>If <code>True</code>, this variable will be set back to <code>False</code> at the beginning of the next step.`,name:"should_save"},{anchor:"transformers.TrainerControl.should_evaluate",description:`<strong>should_evaluate</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the model should be evaluated at this step.</p>
<p>If <code>True</code>, this variable will be set back to <code>False</code> at the beginning of the next step.`,name:"should_evaluate"},{anchor:"transformers.TrainerControl.should_log",description:`<strong>should_log</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the logs should be reported at this step.</p>
<p>If <code>True</code>, this variable will be set back to <code>False</code> at the beginning of the next step.`,name:"should_log"}],source:"https://github.com/huggingface/transformers/blob/vr_31098/src/transformers/trainer_callback.py#L198"}}),Ht=new dl({props:{source:"https://github.com/huggingface/transformers/blob/main/docs/source/zh/main_classes/callback.md"}}),{c(){d=o("meta"),x=r(),b=o("p"),w=r(),g(y.$$.fragment),v=r(),M=o("p"),M.textContent=L,I=r(),Ie=o("p"),Ie.innerHTML=Jo,Or=r(),He=o("p"),He.innerHTML=Uo,Xr=r(),je=o("ul"),je.innerHTML=Do,Zr=r(),ze=o("p"),ze.innerHTML=No,Qr=r(),Je=o("p"),Je.innerHTML=Ao,Kr=r(),g(Ue.$$.fragment),ea=r(),De=o("p"),De.innerHTML=So,ta=r(),P=o("div"),g(Ne.$$.fragment),en=r(),Jt=o("p"),Jt.innerHTML=Po,tn=r(),j=o("div"),g(Ae.$$.fragment),rn=r(),Ut=o("p"),Ut.textContent=Fo,an=r(),Dt=o("p"),Dt.textContent=Wo,nn=r(),Nt=o("ul"),Nt.innerHTML=Bo,on=r(),At=o("p"),At.innerHTML=Ro,ra=r(),X=o("div"),g(Se.$$.fragment),sn=r(),St=o("p"),St.innerHTML=Vo,aa=r(),Z=o("div"),g(Pe.$$.fragment),ln=r(),Pt=o("p"),Pt.innerHTML=Go,na=r(),Q=o("div"),g(Fe.$$.fragment),cn=r(),Ft=o("p"),Ft.innerHTML=qo,oa=r(),F=o("div"),g(We.$$.fragment),dn=r(),Wt=o("p"),Wt.innerHTML=Yo,mn=r(),Bt=o("p"),Bt.innerHTML=Oo,sa=r(),K=o("div"),g(Be.$$.fragment),pn=r(),Rt=o("p"),Rt.innerHTML=Xo,la=r(),W=o("div"),g(Re.$$.fragment),gn=r(),Vt=o("p"),Vt.innerHTML=Zo,fn=r(),z=o("div"),g(Ve.$$.fragment),hn=r(),Gt=o("p"),Gt.innerHTML=Qo,un=r(),qt=o("p"),qt.innerHTML=Ko,bn=r(),Yt=o("p"),Yt.textContent=es,_n=r(),B=o("ul"),Ge=o("li"),Ot=o("p"),Ot.innerHTML=ts,vn=r(),g(ne.$$.fragment),Tn=r(),Xt=o("li"),Xt.innerHTML=rs,$n=r(),Zt=o("li"),Zt.innerHTML=as,Cn=r(),Qt=o("li"),Qt.innerHTML=ns,ia=r(),R=o("div"),g(qe.$$.fragment),kn=r(),Kt=o("p"),Kt.innerHTML=os,wn=r(),N=o("div"),g(Ye.$$.fragment),yn=r(),er=o("p"),er.textContent=ss,Mn=r(),tr=o("p"),tr.textContent=ls,xn=r(),rr=o("ul"),rr.innerHTML=is,ca=r(),ee=o("div"),g(Oe.$$.fragment),Ln=r(),ar=o("p"),ar.innerHTML=cs,da=r(),te=o("div"),g(Xe.$$.fragment),En=r(),nr=o("p"),nr.innerHTML=ds,ma=r(),V=o("div"),g(Ze.$$.fragment),In=r(),or=o("p"),or.innerHTML=ms,Hn=r(),sr=o("p"),sr.innerHTML=ps,pa=r(),J=o("div"),g(Qe.$$.fragment),jn=r(),lr=o("p"),lr.innerHTML=gs,zn=r(),ir=o("p"),ir.textContent=fs,Jn=r(),cr=o("ul"),cr.innerHTML=hs,ga=r(),G=o("div"),g(Ke.$$.fragment),Un=r(),dr=o("p"),dr.innerHTML=us,Dn=r(),A=o("div"),g(et.$$.fragment),Nn=r(),mr=o("p"),mr.textContent=bs,An=r(),pr=o("p"),pr.textContent=_s,Sn=r(),gr=o("ul"),gr.innerHTML=vs,fa=r(),q=o("div"),g(tt.$$.fragment),Pn=r(),fr=o("p"),fr.innerHTML=Ts,Fn=r(),g(oe.$$.fragment),ha=r(),U=o("div"),g(rt.$$.fragment),Wn=r(),hr=o("p"),hr.innerHTML=$s,Bn=r(),ur=o("p"),ur.innerHTML=Cs,Rn=r(),S=o("div"),g(at.$$.fragment),Vn=r(),br=o("p"),br.innerHTML=ks,Gn=r(),_r=o("p"),_r.textContent=ws,qn=r(),vr=o("ul"),vr.innerHTML=ys,ua=r(),g(nt.$$.fragment),ba=r(),T=o("div"),g(ot.$$.fragment),Yn=r(),Tr=o("p"),Tr.textContent=Ms,On=r(),$r=o("p"),$r.innerHTML=xs,Xn=r(),Cr=o("p"),Cr.innerHTML=Ls,Zn=r(),g(se.$$.fragment),Qn=r(),le=o("div"),g(st.$$.fragment),Kn=r(),kr=o("p"),kr.textContent=Es,eo=r(),ie=o("div"),g(lt.$$.fragment),to=r(),wr=o("p"),wr.textContent=Is,ro=r(),ce=o("div"),g(it.$$.fragment),ao=r(),yr=o("p"),yr.textContent=Hs,no=r(),de=o("div"),g(ct.$$.fragment),oo=r(),Mr=o("p"),Mr.innerHTML=js,so=r(),me=o("div"),g(dt.$$.fragment),lo=r(),xr=o("p"),xr.textContent=zs,io=r(),pe=o("div"),g(mt.$$.fragment),co=r(),Lr=o("p"),Lr.textContent=Js,mo=r(),ge=o("div"),g(pt.$$.fragment),po=r(),Er=o("p"),Er.textContent=Us,go=r(),fe=o("div"),g(gt.$$.fragment),fo=r(),Ir=o("p"),Ir.textContent=Ds,ho=r(),he=o("div"),g(ft.$$.fragment),uo=r(),Hr=o("p"),Hr.textContent=Ns,bo=r(),ue=o("div"),g(ht.$$.fragment),_o=r(),jr=o("p"),jr.textContent=As,vo=r(),be=o("div"),g(ut.$$.fragment),To=r(),zr=o("p"),zr.textContent=Ss,$o=r(),_e=o("div"),g(bt.$$.fragment),Co=r(),Jr=o("p"),Jr.textContent=Ps,ko=r(),ve=o("div"),g(_t.$$.fragment),wo=r(),Ur=o("p"),Ur.textContent=Fs,yo=r(),Te=o("div"),g(vt.$$.fragment),Mo=r(),Dr=o("p"),Dr.textContent=Ws,_a=r(),Tt=o("p"),Tt.textContent=Bs,va=r(),$t=o("p"),$t.innerHTML=Rs,Ta=r(),g(Ct.$$.fragment),$a=r(),kt=o("p"),kt.innerHTML=Vs,Ca=r(),g(wt.$$.fragment),ka=r(),g(yt.$$.fragment),wa=r(),H=o("div"),g(Mt.$$.fragment),xo=r(),Nr=o("p"),Nr.innerHTML=Gs,Lo=r(),g($e.$$.fragment),Eo=r(),Ce=o("div"),g(xt.$$.fragment),Io=r(),Ar=o("p"),Ar.innerHTML=qs,Ho=r(),ke=o("div"),g(Lt.$$.fragment),jo=r(),Sr=o("p"),Sr.innerHTML=Ys,ya=r(),g(Et.$$.fragment),Ma=r(),re=o("div"),g(It.$$.fragment),zo=r(),Pr=o("p"),Pr.innerHTML=Os,xa=r(),g(Ht.$$.fragment),La=r(),qr=o("p"),this.h()},l(e){const l=cl("svelte-u9bgzb",document.head);d=s(l,"META",{name:!0,content:!0}),l.forEach(n),x=a(e),b=s(e,"P",{}),_(b).forEach(n),w=a(e),f(y.$$.fragment,e),v=a(e),M=s(e,"P",{"data-svelte-h":!0}),c(M)!=="svelte-ixc7mw"&&(M.textContent=L),I=a(e),Ie=s(e,"P",{"data-svelte-h":!0}),c(Ie)!=="svelte-1o90q5b"&&(Ie.innerHTML=Jo),Or=a(e),He=s(e,"P",{"data-svelte-h":!0}),c(He)!=="svelte-w2h063"&&(He.innerHTML=Uo),Xr=a(e),je=s(e,"UL",{"data-svelte-h":!0}),c(je)!=="svelte-1p1p1ys"&&(je.innerHTML=Do),Zr=a(e),ze=s(e,"P",{"data-svelte-h":!0}),c(ze)!=="svelte-cfm0j7"&&(ze.innerHTML=No),Qr=a(e),Je=s(e,"P",{"data-svelte-h":!0}),c(Je)!=="svelte-1ksa3y4"&&(Je.innerHTML=Ao),Kr=a(e),f(Ue.$$.fragment,e),ea=a(e),De=s(e,"P",{"data-svelte-h":!0}),c(De)!=="svelte-1h1utj9"&&(De.innerHTML=So),ta=a(e),P=s(e,"DIV",{class:!0});var ae=_(P);f(Ne.$$.fragment,ae),en=a(ae),Jt=s(ae,"P",{"data-svelte-h":!0}),c(Jt)!=="svelte-h0q0mc"&&(Jt.innerHTML=Po),tn=a(ae),j=s(ae,"DIV",{class:!0});var D=_(j);f(Ae.$$.fragment,D),rn=a(D),Ut=s(D,"P",{"data-svelte-h":!0}),c(Ut)!=="svelte-frc23a"&&(Ut.textContent=Fo),an=a(D),Dt=s(D,"P",{"data-svelte-h":!0}),c(Dt)!=="svelte-1fkshtn"&&(Dt.textContent=Wo),nn=a(D),Nt=s(D,"UL",{"data-svelte-h":!0}),c(Nt)!=="svelte-rt862w"&&(Nt.innerHTML=Bo),on=a(D),At=s(D,"P",{"data-svelte-h":!0}),c(At)!=="svelte-1baxs6u"&&(At.innerHTML=Ro),D.forEach(n),ae.forEach(n),ra=a(e),X=s(e,"DIV",{class:!0});var jt=_(X);f(Se.$$.fragment,jt),sn=a(jt),St=s(jt,"P",{"data-svelte-h":!0}),c(St)!=="svelte-1hujif9"&&(St.innerHTML=Vo),jt.forEach(n),aa=a(e),Z=s(e,"DIV",{class:!0});var zt=_(Z);f(Pe.$$.fragment,zt),ln=a(zt),Pt=s(zt,"P",{"data-svelte-h":!0}),c(Pt)!=="svelte-jvtcre"&&(Pt.innerHTML=Go),zt.forEach(n),na=a(e),Q=s(e,"DIV",{class:!0});var Ia=_(Q);f(Fe.$$.fragment,Ia),cn=a(Ia),Ft=s(Ia,"P",{"data-svelte-h":!0}),c(Ft)!=="svelte-13ajewv"&&(Ft.innerHTML=qo),Ia.forEach(n),oa=a(e),F=s(e,"DIV",{class:!0});var Fr=_(F);f(We.$$.fragment,Fr),dn=a(Fr),Wt=s(Fr,"P",{"data-svelte-h":!0}),c(Wt)!=="svelte-m5k4qk"&&(Wt.innerHTML=Yo),mn=a(Fr),Bt=s(Fr,"P",{"data-svelte-h":!0}),c(Bt)!=="svelte-1xdlid2"&&(Bt.innerHTML=Oo),Fr.forEach(n),sa=a(e),K=s(e,"DIV",{class:!0});var Ha=_(K);f(Be.$$.fragment,Ha),pn=a(Ha),Rt=s(Ha,"P",{"data-svelte-h":!0}),c(Rt)!=="svelte-sgrhor"&&(Rt.innerHTML=Xo),Ha.forEach(n),la=a(e),W=s(e,"DIV",{class:!0});var Wr=_(W);f(Re.$$.fragment,Wr),gn=a(Wr),Vt=s(Wr,"P",{"data-svelte-h":!0}),c(Vt)!=="svelte-kd2gfk"&&(Vt.innerHTML=Zo),fn=a(Wr),z=s(Wr,"DIV",{class:!0});var Y=_(z);f(Ve.$$.fragment,Y),hn=a(Y),Gt=s(Y,"P",{"data-svelte-h":!0}),c(Gt)!=="svelte-op70zs"&&(Gt.innerHTML=Qo),un=a(Y),qt=s(Y,"P",{"data-svelte-h":!0}),c(qt)!=="svelte-m2rt7w"&&(qt.innerHTML=Ko),bn=a(Y),Yt=s(Y,"P",{"data-svelte-h":!0}),c(Yt)!=="svelte-1fkshtn"&&(Yt.textContent=es),_n=a(Y),B=s(Y,"UL",{});var we=_(B);Ge=s(we,"LI",{});var ja=_(Ge);Ot=s(ja,"P",{"data-svelte-h":!0}),c(Ot)!=="svelte-py3r3s"&&(Ot.innerHTML=ts),vn=a(ja),f(ne.$$.fragment,ja),ja.forEach(n),Tn=a(we),Xt=s(we,"LI",{"data-svelte-h":!0}),c(Xt)!=="svelte-dx3m30"&&(Xt.innerHTML=rs),$n=a(we),Zt=s(we,"LI",{"data-svelte-h":!0}),c(Zt)!=="svelte-n1uh6c"&&(Zt.innerHTML=as),Cn=a(we),Qt=s(we,"LI",{"data-svelte-h":!0}),c(Qt)!=="svelte-ybo66z"&&(Qt.innerHTML=ns),we.forEach(n),Y.forEach(n),Wr.forEach(n),ia=a(e),R=s(e,"DIV",{class:!0});var Br=_(R);f(qe.$$.fragment,Br),kn=a(Br),Kt=s(Br,"P",{"data-svelte-h":!0}),c(Kt)!=="svelte-2pt9og"&&(Kt.innerHTML=os),wn=a(Br),N=s(Br,"DIV",{class:!0});var ye=_(N);f(Ye.$$.fragment,ye),yn=a(ye),er=s(ye,"P",{"data-svelte-h":!0}),c(er)!=="svelte-nmg16f"&&(er.textContent=ss),Mn=a(ye),tr=s(ye,"P",{"data-svelte-h":!0}),c(tr)!=="svelte-1fkshtn"&&(tr.textContent=ls),xn=a(ye),rr=s(ye,"UL",{"data-svelte-h":!0}),c(rr)!=="svelte-o83nc7"&&(rr.innerHTML=is),ye.forEach(n),Br.forEach(n),ca=a(e),ee=s(e,"DIV",{class:!0});var za=_(ee);f(Oe.$$.fragment,za),Ln=a(za),ar=s(za,"P",{"data-svelte-h":!0}),c(ar)!=="svelte-6eic8z"&&(ar.innerHTML=cs),za.forEach(n),da=a(e),te=s(e,"DIV",{class:!0});var Ja=_(te);f(Xe.$$.fragment,Ja),En=a(Ja),nr=s(Ja,"P",{"data-svelte-h":!0}),c(nr)!=="svelte-1tv1vqf"&&(nr.innerHTML=ds),Ja.forEach(n),ma=a(e),V=s(e,"DIV",{class:!0});var Rr=_(V);f(Ze.$$.fragment,Rr),In=a(Rr),or=s(Rr,"P",{"data-svelte-h":!0}),c(or)!=="svelte-4ag9j6"&&(or.innerHTML=ms),Hn=a(Rr),sr=s(Rr,"P",{"data-svelte-h":!0}),c(sr)!=="svelte-1mhjcx0"&&(sr.innerHTML=ps),Rr.forEach(n),pa=a(e),J=s(e,"DIV",{class:!0});var Me=_(J);f(Qe.$$.fragment,Me),jn=a(Me),lr=s(Me,"P",{"data-svelte-h":!0}),c(lr)!=="svelte-19qbnbx"&&(lr.innerHTML=gs),zn=a(Me),ir=s(Me,"P",{"data-svelte-h":!0}),c(ir)!=="svelte-1fkshtn"&&(ir.textContent=fs),Jn=a(Me),cr=s(Me,"UL",{"data-svelte-h":!0}),c(cr)!=="svelte-15svthu"&&(cr.innerHTML=hs),Me.forEach(n),ga=a(e),G=s(e,"DIV",{class:!0});var Vr=_(G);f(Ke.$$.fragment,Vr),Un=a(Vr),dr=s(Vr,"P",{"data-svelte-h":!0}),c(dr)!=="svelte-13vgod8"&&(dr.innerHTML=us),Dn=a(Vr),A=s(Vr,"DIV",{class:!0});var xe=_(A);f(et.$$.fragment,xe),Nn=a(xe),mr=s(xe,"P",{"data-svelte-h":!0}),c(mr)!=="svelte-1wbmj3"&&(mr.textContent=bs),An=a(xe),pr=s(xe,"P",{"data-svelte-h":!0}),c(pr)!=="svelte-1fkshtn"&&(pr.textContent=_s),Sn=a(xe),gr=s(xe,"UL",{"data-svelte-h":!0}),c(gr)!=="svelte-dna85o"&&(gr.innerHTML=vs),xe.forEach(n),Vr.forEach(n),fa=a(e),q=s(e,"DIV",{class:!0});var Gr=_(q);f(tt.$$.fragment,Gr),Pn=a(Gr),fr=s(Gr,"P",{"data-svelte-h":!0}),c(fr)!=="svelte-1jclbvz"&&(fr.innerHTML=Ts),Fn=a(Gr),f(oe.$$.fragment,Gr),Gr.forEach(n),ha=a(e),U=s(e,"DIV",{class:!0});var Le=_(U);f(rt.$$.fragment,Le),Wn=a(Le),hr=s(Le,"P",{"data-svelte-h":!0}),c(hr)!=="svelte-zvc9y"&&(hr.innerHTML=$s),Bn=a(Le),ur=s(Le,"P",{"data-svelte-h":!0}),c(ur)!=="svelte-eu3kj7"&&(ur.innerHTML=Cs),Rn=a(Le),S=s(Le,"DIV",{class:!0});var Ee=_(S);f(at.$$.fragment,Ee),Vn=a(Ee),br=s(Ee,"P",{"data-svelte-h":!0}),c(br)!=="svelte-jjkenj"&&(br.innerHTML=ks),Gn=a(Ee),_r=s(Ee,"P",{"data-svelte-h":!0}),c(_r)!=="svelte-1fkshtn"&&(_r.textContent=ws),qn=a(Ee),vr=s(Ee,"UL",{"data-svelte-h":!0}),c(vr)!=="svelte-crnavn"&&(vr.innerHTML=ys),Ee.forEach(n),Le.forEach(n),ua=a(e),f(nt.$$.fragment,e),ba=a(e),T=s(e,"DIV",{class:!0});var k=_(T);f(ot.$$.fragment,k),Yn=a(k),Tr=s(k,"P",{"data-svelte-h":!0}),c(Tr)!=="svelte-14xg00o"&&(Tr.textContent=Ms),On=a(k),$r=s(k,"P",{"data-svelte-h":!0}),c($r)!=="svelte-1xprdvt"&&($r.innerHTML=xs),Xn=a(k),Cr=s(k,"P",{"data-svelte-h":!0}),c(Cr)!=="svelte-8au86f"&&(Cr.innerHTML=Ls),Zn=a(k),f(se.$$.fragment,k),Qn=a(k),le=s(k,"DIV",{class:!0});var Ua=_(le);f(st.$$.fragment,Ua),Kn=a(Ua),kr=s(Ua,"P",{"data-svelte-h":!0}),c(kr)!=="svelte-106889p"&&(kr.textContent=Es),Ua.forEach(n),eo=a(k),ie=s(k,"DIV",{class:!0});var Da=_(ie);f(lt.$$.fragment,Da),to=a(Da),wr=s(Da,"P",{"data-svelte-h":!0}),c(wr)!=="svelte-oshcpj"&&(wr.textContent=Is),Da.forEach(n),ro=a(k),ce=s(k,"DIV",{class:!0});var Na=_(ce);f(it.$$.fragment,Na),ao=a(Na),yr=s(Na,"P",{"data-svelte-h":!0}),c(yr)!=="svelte-1o0xh73"&&(yr.textContent=Hs),Na.forEach(n),no=a(k),de=s(k,"DIV",{class:!0});var Aa=_(de);f(ct.$$.fragment,Aa),oo=a(Aa),Mr=s(Aa,"P",{"data-svelte-h":!0}),c(Mr)!=="svelte-hzqkde"&&(Mr.innerHTML=js),Aa.forEach(n),so=a(k),me=s(k,"DIV",{class:!0});var Sa=_(me);f(dt.$$.fragment,Sa),lo=a(Sa),xr=s(Sa,"P",{"data-svelte-h":!0}),c(xr)!=="svelte-10eiwg0"&&(xr.textContent=zs),Sa.forEach(n),io=a(k),pe=s(k,"DIV",{class:!0});var Pa=_(pe);f(mt.$$.fragment,Pa),co=a(Pa),Lr=s(Pa,"P",{"data-svelte-h":!0}),c(Lr)!=="svelte-1mpbj2z"&&(Lr.textContent=Js),Pa.forEach(n),mo=a(k),ge=s(k,"DIV",{class:!0});var Fa=_(ge);f(pt.$$.fragment,Fa),po=a(Fa),Er=s(Fa,"P",{"data-svelte-h":!0}),c(Er)!=="svelte-1df7x4n"&&(Er.textContent=Us),Fa.forEach(n),go=a(k),fe=s(k,"DIV",{class:!0});var Wa=_(fe);f(gt.$$.fragment,Wa),fo=a(Wa),Ir=s(Wa,"P",{"data-svelte-h":!0}),c(Ir)!=="svelte-18swygp"&&(Ir.textContent=Ds),Wa.forEach(n),ho=a(k),he=s(k,"DIV",{class:!0});var Ba=_(he);f(ft.$$.fragment,Ba),uo=a(Ba),Hr=s(Ba,"P",{"data-svelte-h":!0}),c(Hr)!=="svelte-19xp05v"&&(Hr.textContent=Ns),Ba.forEach(n),bo=a(k),ue=s(k,"DIV",{class:!0});var Ra=_(ue);f(ht.$$.fragment,Ra),_o=a(Ra),jr=s(Ra,"P",{"data-svelte-h":!0}),c(jr)!=="svelte-7af61p"&&(jr.textContent=As),Ra.forEach(n),vo=a(k),be=s(k,"DIV",{class:!0});var Va=_(be);f(ut.$$.fragment,Va),To=a(Va),zr=s(Va,"P",{"data-svelte-h":!0}),c(zr)!=="svelte-8cdxjr"&&(zr.textContent=Ss),Va.forEach(n),$o=a(k),_e=s(k,"DIV",{class:!0});var Ga=_(_e);f(bt.$$.fragment,Ga),Co=a(Ga),Jr=s(Ga,"P",{"data-svelte-h":!0}),c(Jr)!=="svelte-sluvs0"&&(Jr.textContent=Ps),Ga.forEach(n),ko=a(k),ve=s(k,"DIV",{class:!0});var qa=_(ve);f(_t.$$.fragment,qa),wo=a(qa),Ur=s(qa,"P",{"data-svelte-h":!0}),c(Ur)!=="svelte-6bvy6d"&&(Ur.textContent=Fs),qa.forEach(n),yo=a(k),Te=s(k,"DIV",{class:!0});var Ya=_(Te);f(vt.$$.fragment,Ya),Mo=a(Ya),Dr=s(Ya,"P",{"data-svelte-h":!0}),c(Dr)!=="svelte-zzwxsv"&&(Dr.textContent=Ws),Ya.forEach(n),k.forEach(n),_a=a(e),Tt=s(e,"P",{"data-svelte-h":!0}),c(Tt)!=="svelte-87dqmt"&&(Tt.textContent=Bs),va=a(e),$t=s(e,"P",{"data-svelte-h":!0}),c($t)!=="svelte-17720zy"&&($t.innerHTML=Rs),Ta=a(e),f(Ct.$$.fragment,e),$a=a(e),kt=s(e,"P",{"data-svelte-h":!0}),c(kt)!=="svelte-u9gp17"&&(kt.innerHTML=Vs),Ca=a(e),f(wt.$$.fragment,e),ka=a(e),f(yt.$$.fragment,e),wa=a(e),H=s(e,"DIV",{class:!0});var O=_(H);f(Mt.$$.fragment,O),xo=a(O),Nr=s(O,"P",{"data-svelte-h":!0}),c(Nr)!=="svelte-d8jj3k"&&(Nr.innerHTML=Gs),Lo=a(O),f($e.$$.fragment,O),Eo=a(O),Ce=s(O,"DIV",{class:!0});var Oa=_(Ce);f(xt.$$.fragment,Oa),Io=a(Oa),Ar=s(Oa,"P",{"data-svelte-h":!0}),c(Ar)!=="svelte-hbs6ga"&&(Ar.innerHTML=qs),Oa.forEach(n),Ho=a(O),ke=s(O,"DIV",{class:!0});var Xa=_(ke);f(Lt.$$.fragment,Xa),jo=a(Xa),Sr=s(Xa,"P",{"data-svelte-h":!0}),c(Sr)!=="svelte-dkslae"&&(Sr.innerHTML=Ys),Xa.forEach(n),O.forEach(n),ya=a(e),f(Et.$$.fragment,e),Ma=a(e),re=s(e,"DIV",{class:!0});var Za=_(re);f(It.$$.fragment,Za),zo=a(Za),Pr=s(Za,"P",{"data-svelte-h":!0}),c(Pr)!=="svelte-g8zsqw"&&(Pr.innerHTML=Os),Za.forEach(n),xa=a(e),f(Ht.$$.fragment,e),La=a(e),qr=s(e,"P",{}),_(qr).forEach(n),this.h()},h(){$(d,"name","hf:doc:metadata"),$(d,"content",Tl),$(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(F,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(K,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(N,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(R,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ee,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(te,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(V,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(J,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ie,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ce,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(de,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(me,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(pe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ge,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(fe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(he,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ue,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(be,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(_e,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ve,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Te,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(T,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Ce,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ke,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(re,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,l){t(document.head,d),i(e,x,l),i(e,b,l),i(e,w,l),h(y,e,l),i(e,v,l),i(e,M,l),i(e,I,l),i(e,Ie,l),i(e,Or,l),i(e,He,l),i(e,Xr,l),i(e,je,l),i(e,Zr,l),i(e,ze,l),i(e,Qr,l),i(e,Je,l),i(e,Kr,l),h(Ue,e,l),i(e,ea,l),i(e,De,l),i(e,ta,l),i(e,P,l),h(Ne,P,null),t(P,en),t(P,Jt),t(P,tn),t(P,j),h(Ae,j,null),t(j,rn),t(j,Ut),t(j,an),t(j,Dt),t(j,nn),t(j,Nt),t(j,on),t(j,At),i(e,ra,l),i(e,X,l),h(Se,X,null),t(X,sn),t(X,St),i(e,aa,l),i(e,Z,l),h(Pe,Z,null),t(Z,ln),t(Z,Pt),i(e,na,l),i(e,Q,l),h(Fe,Q,null),t(Q,cn),t(Q,Ft),i(e,oa,l),i(e,F,l),h(We,F,null),t(F,dn),t(F,Wt),t(F,mn),t(F,Bt),i(e,sa,l),i(e,K,l),h(Be,K,null),t(K,pn),t(K,Rt),i(e,la,l),i(e,W,l),h(Re,W,null),t(W,gn),t(W,Vt),t(W,fn),t(W,z),h(Ve,z,null),t(z,hn),t(z,Gt),t(z,un),t(z,qt),t(z,bn),t(z,Yt),t(z,_n),t(z,B),t(B,Ge),t(Ge,Ot),t(Ge,vn),h(ne,Ge,null),t(B,Tn),t(B,Xt),t(B,$n),t(B,Zt),t(B,Cn),t(B,Qt),i(e,ia,l),i(e,R,l),h(qe,R,null),t(R,kn),t(R,Kt),t(R,wn),t(R,N),h(Ye,N,null),t(N,yn),t(N,er),t(N,Mn),t(N,tr),t(N,xn),t(N,rr),i(e,ca,l),i(e,ee,l),h(Oe,ee,null),t(ee,Ln),t(ee,ar),i(e,da,l),i(e,te,l),h(Xe,te,null),t(te,En),t(te,nr),i(e,ma,l),i(e,V,l),h(Ze,V,null),t(V,In),t(V,or),t(V,Hn),t(V,sr),i(e,pa,l),i(e,J,l),h(Qe,J,null),t(J,jn),t(J,lr),t(J,zn),t(J,ir),t(J,Jn),t(J,cr),i(e,ga,l),i(e,G,l),h(Ke,G,null),t(G,Un),t(G,dr),t(G,Dn),t(G,A),h(et,A,null),t(A,Nn),t(A,mr),t(A,An),t(A,pr),t(A,Sn),t(A,gr),i(e,fa,l),i(e,q,l),h(tt,q,null),t(q,Pn),t(q,fr),t(q,Fn),h(oe,q,null),i(e,ha,l),i(e,U,l),h(rt,U,null),t(U,Wn),t(U,hr),t(U,Bn),t(U,ur),t(U,Rn),t(U,S),h(at,S,null),t(S,Vn),t(S,br),t(S,Gn),t(S,_r),t(S,qn),t(S,vr),i(e,ua,l),h(nt,e,l),i(e,ba,l),i(e,T,l),h(ot,T,null),t(T,Yn),t(T,Tr),t(T,On),t(T,$r),t(T,Xn),t(T,Cr),t(T,Zn),h(se,T,null),t(T,Qn),t(T,le),h(st,le,null),t(le,Kn),t(le,kr),t(T,eo),t(T,ie),h(lt,ie,null),t(ie,to),t(ie,wr),t(T,ro),t(T,ce),h(it,ce,null),t(ce,ao),t(ce,yr),t(T,no),t(T,de),h(ct,de,null),t(de,oo),t(de,Mr),t(T,so),t(T,me),h(dt,me,null),t(me,lo),t(me,xr),t(T,io),t(T,pe),h(mt,pe,null),t(pe,co),t(pe,Lr),t(T,mo),t(T,ge),h(pt,ge,null),t(ge,po),t(ge,Er),t(T,go),t(T,fe),h(gt,fe,null),t(fe,fo),t(fe,Ir),t(T,ho),t(T,he),h(ft,he,null),t(he,uo),t(he,Hr),t(T,bo),t(T,ue),h(ht,ue,null),t(ue,_o),t(ue,jr),t(T,vo),t(T,be),h(ut,be,null),t(be,To),t(be,zr),t(T,$o),t(T,_e),h(bt,_e,null),t(_e,Co),t(_e,Jr),t(T,ko),t(T,ve),h(_t,ve,null),t(ve,wo),t(ve,Ur),t(T,yo),t(T,Te),h(vt,Te,null),t(Te,Mo),t(Te,Dr),i(e,_a,l),i(e,Tt,l),i(e,va,l),i(e,$t,l),i(e,Ta,l),h(Ct,e,l),i(e,$a,l),i(e,kt,l),i(e,Ca,l),h(wt,e,l),i(e,ka,l),h(yt,e,l),i(e,wa,l),i(e,H,l),h(Mt,H,null),t(H,xo),t(H,Nr),t(H,Lo),h($e,H,null),t(H,Eo),t(H,Ce),h(xt,Ce,null),t(Ce,Io),t(Ce,Ar),t(H,Ho),t(H,ke),h(Lt,ke,null),t(ke,jo),t(ke,Sr),i(e,ya,l),h(Et,e,l),i(e,Ma,l),i(e,re,l),h(It,re,null),t(re,zo),t(re,Pr),i(e,xa,l),h(Ht,e,l),i(e,La,l),i(e,qr,l),Ea=!0},p(e,[l]){const ae={};l&2&&(ae.$$scope={dirty:l,ctx:e}),ne.$set(ae);const D={};l&2&&(D.$$scope={dirty:l,ctx:e}),oe.$set(D);const jt={};l&2&&(jt.$$scope={dirty:l,ctx:e}),se.$set(jt);const zt={};l&2&&(zt.$$scope={dirty:l,ctx:e}),$e.$set(zt)},i(e){Ea||(m(y.$$.fragment,e),m(Ue.$$.fragment,e),m(Ne.$$.fragment,e),m(Ae.$$.fragment,e),m(Se.$$.fragment,e),m(Pe.$$.fragment,e),m(Fe.$$.fragment,e),m(We.$$.fragment,e),m(Be.$$.fragment,e),m(Re.$$.fragment,e),m(Ve.$$.fragment,e),m(ne.$$.fragment,e),m(qe.$$.fragment,e),m(Ye.$$.fragment,e),m(Oe.$$.fragment,e),m(Xe.$$.fragment,e),m(Ze.$$.fragment,e),m(Qe.$$.fragment,e),m(Ke.$$.fragment,e),m(et.$$.fragment,e),m(tt.$$.fragment,e),m(oe.$$.fragment,e),m(rt.$$.fragment,e),m(at.$$.fragment,e),m(nt.$$.fragment,e),m(ot.$$.fragment,e),m(se.$$.fragment,e),m(st.$$.fragment,e),m(lt.$$.fragment,e),m(it.$$.fragment,e),m(ct.$$.fragment,e),m(dt.$$.fragment,e),m(mt.$$.fragment,e),m(pt.$$.fragment,e),m(gt.$$.fragment,e),m(ft.$$.fragment,e),m(ht.$$.fragment,e),m(ut.$$.fragment,e),m(bt.$$.fragment,e),m(_t.$$.fragment,e),m(vt.$$.fragment,e),m(Ct.$$.fragment,e),m(wt.$$.fragment,e),m(yt.$$.fragment,e),m(Mt.$$.fragment,e),m($e.$$.fragment,e),m(xt.$$.fragment,e),m(Lt.$$.fragment,e),m(Et.$$.fragment,e),m(It.$$.fragment,e),m(Ht.$$.fragment,e),Ea=!0)},o(e){p(y.$$.fragment,e),p(Ue.$$.fragment,e),p(Ne.$$.fragment,e),p(Ae.$$.fragment,e),p(Se.$$.fragment,e),p(Pe.$$.fragment,e),p(Fe.$$.fragment,e),p(We.$$.fragment,e),p(Be.$$.fragment,e),p(Re.$$.fragment,e),p(Ve.$$.fragment,e),p(ne.$$.fragment,e),p(qe.$$.fragment,e),p(Ye.$$.fragment,e),p(Oe.$$.fragment,e),p(Xe.$$.fragment,e),p(Ze.$$.fragment,e),p(Qe.$$.fragment,e),p(Ke.$$.fragment,e),p(et.$$.fragment,e),p(tt.$$.fragment,e),p(oe.$$.fragment,e),p(rt.$$.fragment,e),p(at.$$.fragment,e),p(nt.$$.fragment,e),p(ot.$$.fragment,e),p(se.$$.fragment,e),p(st.$$.fragment,e),p(lt.$$.fragment,e),p(it.$$.fragment,e),p(ct.$$.fragment,e),p(dt.$$.fragment,e),p(mt.$$.fragment,e),p(pt.$$.fragment,e),p(gt.$$.fragment,e),p(ft.$$.fragment,e),p(ht.$$.fragment,e),p(ut.$$.fragment,e),p(bt.$$.fragment,e),p(_t.$$.fragment,e),p(vt.$$.fragment,e),p(Ct.$$.fragment,e),p(wt.$$.fragment,e),p(yt.$$.fragment,e),p(Mt.$$.fragment,e),p($e.$$.fragment,e),p(xt.$$.fragment,e),p(Lt.$$.fragment,e),p(Et.$$.fragment,e),p(It.$$.fragment,e),p(Ht.$$.fragment,e),Ea=!1},d(e){e&&(n(x),n(b),n(w),n(v),n(M),n(I),n(Ie),n(Or),n(He),n(Xr),n(je),n(Zr),n(ze),n(Qr),n(Je),n(Kr),n(ea),n(De),n(ta),n(P),n(ra),n(X),n(aa),n(Z),n(na),n(Q),n(oa),n(F),n(sa),n(K),n(la),n(W),n(ia),n(R),n(ca),n(ee),n(da),n(te),n(ma),n(V),n(pa),n(J),n(ga),n(G),n(fa),n(q),n(ha),n(U),n(ua),n(ba),n(T),n(_a),n(Tt),n(va),n($t),n(Ta),n($a),n(kt),n(Ca),n(ka),n(wa),n(H),n(ya),n(Ma),n(re),n(xa),n(La),n(qr)),n(d),u(y,e),u(Ue,e),u(Ne),u(Ae),u(Se),u(Pe),u(Fe),u(We),u(Be),u(Re),u(Ve),u(ne),u(qe),u(Ye),u(Oe),u(Xe),u(Ze),u(Qe),u(Ke),u(et),u(tt),u(oe),u(rt),u(at),u(nt,e),u(ot),u(se),u(st),u(lt),u(it),u(ct),u(dt),u(mt),u(pt),u(gt),u(ft),u(ht),u(ut),u(bt),u(_t),u(vt),u(Ct,e),u(wt,e),u(yt,e),u(Mt),u($e),u(xt),u(Lt),u(Et,e),u(It),u(Ht,e)}}}const Tl='{"title":"Callbacks","local":"callbacks","sections":[{"title":"可用的Callbacks","local":"transformers.integrations.CometCallback","sections":[],"depth":2},{"title":"TrainerCallback","local":"transformers.TrainerCallback","sections":[],"depth":2},{"title":"TrainerState","local":"transformers.TrainerState","sections":[],"depth":2},{"title":"TrainerControl","local":"transformers.TrainerControl","sections":[],"depth":2}],"depth":1}';function $l(E){return ll(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class El extends el{constructor(d){super(),tl(this,d,$l,vl,Ks,{})}}export{El as component};
