em = i && items[i - 1];

        if (i >= ln) {
            prevItem = items[ln - 1];
        }
        prevPoint = prevItem && prevItem.point;
        nextPoint = nextItem && nextItem.point;
        x1 = prevItem ? prevPoint[0] : nextPoint[0] - tolerance;
        y1 = prevItem ? prevPoint[1] : nextPoint[1];
        x2 = nextItem ? nextPoint[0] : prevPoint[0] + tolerance;
        y2 = nextItem ? nextPoint[1] : prevPoint[1];
        dist1 = sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1));
        dist2 = sqrt((x - x2) * (x - x2) + (y - y2) * (y - y2));
        dist = Math.min(dist1, dist2);

        if (dist <= tolerance) {
            return dist == dist1? prevItem : nextItem;
        }
        return false;
    },

    // @private toggle visibility of all series elements (markers, sprites).
    toggleAll: function(show) {
        var me = this,
            i, ln, shadow, shadows;
        if (!show) {
            Ext.chart.series.Cartesian.prototype.hideAll.call(me);
        }
        else {
            Ext.chart.series.Cartesian.prototype.showAll.call(me);
        }
        if (me.line) {
            me.line.setAttributes({
                hidden: !show
            }, true);
            //hide shadows too
            if (me.line.shadows) {
                for (i = 0, shadows = me.line.shadows, ln = shadows.length; i < ln; i++) {
                    shadow = shadows[i];
                    shadow.setAttributes({
                        hidden: !show
                    }, true);
                }
            }
        }
        if (me.fillPath) {
            me.fillPath.setAttributes({
                hidden: !show
            }, true);
        }
    },

    // @private hide all series elements (markers, sprites).
    hideAll: function() {
        this.toggleAll(false);
    },

    // @private hide all series elements (markers, sprites).
    showAll: function() {
        this.toggleAll(true);
    }
});

<!DOCTYPE html>

  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <title>The source code</title>
  <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />

/**
 * Slider which supports vertical or horizontal orientation, keyboard adjustments, configurable snapping, axis clicking
 * and animation. Can be added as an item to any container.
 *
 *     @example
 *     Ext.create('Ext.slider.Single', {
 *         width: 200,
 *         value: 50,
 *         increment: 10,
 *         minValue: 0,
 *         maxValue: 100,
 *         renderTo: Ext.getBody()
 *     });
 *
 * The class Ext.slider.Single is aliased to Ext.Slider for backwards compatibility.
 */


号
        intTOcharNum(i,strNumimg);
        char path_img[200];
        sprintf(path_img,"F:/MyAlgorithmProject/20170601_TemplateMatching_FeatureBase_RPT_Zernike/QtCode/BBS(20180507)/dataset/TB-50_2/%d/img/0%s.jpg",n,strNumimg);
        Mat img=imread(path_img);
        Mat img2;
        img.copyTo(img2);
        char strNumimg2[200];//图的新序号
        intTOcharNum(i-start+1,strNumimg2);
        char path_img2[200];
        sprintf(path_img2,"F:/MyAlgorithmProject/20170601_TemplateMatching_FeatureBase_RPT_Zernike/QtCode/BBS(20180507)/dataset/TB-50_2/%d/img2/%s.jpg",n,strNumimg2);
        imwrite(path_img2,img2);
    }
*/
/*
    //开始匹配（单次匹配）
    //模板图必须大于20*20
    //开始匹配
    Ldisk=(int)sqrt(ROI.cols*ROI.rows/30);
    if(Ldisk<9) Ldisk=9;
    R=(int)Ldisk/2;//局部方块半径
    Point MatchUpLPoint[1];
    float MatchTime[1];
    //MNShsv_SSDtMatching(Img,TemplateROI,MatchUpLPoint,MatchTime);//特征：环投影均值、灰度均值、HSV分量均值
    //MBNShsv_SSDtMatching(Img,TemplateROI,MatchUpLPoint,MatchTime);//特征：环投影均值、灰度均值、HSV分量均值
    //MNShsv_SSDtMatching2(Img,TemplateROI,MatchUpLPoint,MatchTime);//特征：环投影均值、灰度均值和方差、HSV分量均值
    MBNShsv_SSDtMatching2_Angle(Image,ROI,MatchUpLPoint,MatchTime);//特征：环投影均值、灰度均值和方差、HSV分量均值
*/
    /*
    //分离颜色通道HSV
    Mat Image_h,Imagehsv;
    vector<Mat> hsv_vec;
    cvtColor(Image, Imagehsv, CV_BGR2HSV);
    split(Imagehsv, hsv_vec);
    Image_h = hsv_vec[0];
    Image_h.convertTo(Image_h, CV_8UC1);
    imshow("Image",Image);
    imshow("Image_h",Image_h);
    */

    int ClassNum=40;// 图像类数量（即文件夹数量）
    int ImgNum=10;//每类的图像数量（即每个文件夹里面的图片数量）

    //实验返回结果参数
    //结果：时间和匹配率
    float MNS_total_SumTime=0;
    int MNS_SuccessNum=0;

    for(int i=1;i<=ClassNum;i++)
    {
        //获取模板图路径
        char Path_template[200];
        sprintf(Path_template,"F:/MyAlgorithmProject/20170601_TemplateMatching_FeatureBase_RPT_Zernike/QtCode/QtCode_MNS_MostNeighborsSimilarity(20180223)/TextImage/1Occlusion/%d/00template.bmp",i);
        cv::Mat TemplateImage=cv::imread(Path_template);
        //获取原图路径
        char Path_origin[200];
        sprintf(Path_origin,"F:/MyAlgorithmProject/20170601_TemplateMatching_FeatureBase_RPT_Zernike/QtCode/QtCode_MNS_MostNeighborsSimilarity(20180223)/TextImage/1Occlusion/%d/0.jpg",i);
        cv::Mat originImage=cv


ography_core::asset_proofs::{
    encryption_proofs::{single_property_prover, single_property_verifier},
    membership_proof::{
        MembershipProofFinalResponse, MembershipProofInitialMessage, MembershipProofVerifier,
        MembershipProverAwaitingChallenge,
    },
    one_out_of_many_proof::OooNProofGenerators,
};
use curve25519_dalek::{ristretto::RistrettoPoint, scalar::Scalar};

use rand::{rngs::StdRng, SeedableRng};
use std::time::Duration;

const SEED_1: [u8; 32] = [42u8; 32];
const BASE: u32 = 4;
const EXPONENT: u32 = 8;
const SET_SIZE: u32 = 65536;

fn bench_membership_verify(
    c: &mut Criterion,
    secret_element_com: RistrettoPoint,
    proofs: Vec<(MembershipProofInitialMessage, MembershipProofFinalResponse)>,
) {
    let label = "membership verification".to_string();

    let generators = OooNProofGenerators::new(EXPONENT, BASE);
    let elements: Vec<Scalar> = (0..SET_SIZE as u32).map(Scalar::from).collect();

    c.bench_function_over_inputs(
        &label,
        move |b, proof| {
            b.iter(|| {
                single_property_verifier(
                    &MembershipProofVerifier {
                        secret_element_com,
                        elements_set: elements.as_slice(),
                        generators: &generators,
                    },
                    proof.clone(),
                )
                .unwrap()
            })
        },
        proofs,
    );
}

fn bench_membership_proof(c: &mut Criterion) {
    let mut rng = StdRng::from_seed(SEED_1);

    let generators = OooNProofGenerators::new(EXPONENT, BASE);

    let elements: Vec<Scalar> = (0..SET_SIZE as u32).map(Scalar::from).collect();

    let secret_member = Scalar::from(28345u32);
    let blinding = Scalar::random(&mut rng);

    let commited_member = generators.com_gens.commit(secret_member, blinding);

    let prover = MembershipProverAwaitingChallenge::new(
        secret_member,
        blinding,
        &generators,
        elements.as_slice(),
        BASE,
        EXPONENT,
    )
    .unwrap();

    let proof =
        single_property_prover::<StdRng, MembershipProverAwaitingChallenge>(prover, &mut rng)
            .unwrap();

    bench_membership_verify(c, commited_member, vec![proof])
}

criterion_group! {
    name = bench_membership_verification;
    // Lower the sample size to run faster; larger shuffle sizes are
    // long so we're not microbenchmarking anyways.
    // 10 is the minimum allowed sample size in Criterion.
    config = Criterion::default().sample_size(10).measurement_time(Duration::new(600, 0));
    targets = bench_membership_proof,
}

criterion_main!(bench_membership_verification);
use bevy::prelude::*;

use crate::{
    components::{BombNumber, BombPower, Buff, Player, Velocity},
    utils::vecs_xy_intersect,
};

pub trait BuffSystems {
    fn buff_systems(&mut self) -> &mut Self;
}
impl BuffSystems for SystemStage {
    fn buff_systems(&mut self) -> &mut Self {
        self.add_system(buffs.system())
    }
}

fn buffs(
    commands: &mut Commands,
    buff_query: Query<(Entity, &Transform, &Buff), With<Buff>>,
    mut player: Query<(&Transform, &mut BombPower, &mut BombNumber, &mut Velocity), With<Player>>,
) {
    for (player, m


orGravity(int)
     * @see #getTabIndicatorGravity()
     * @attr ref com.google.android.material.R.styleable#TabLayout_tabIndicatorGravity
     */
    fun setGravity(gravity: Int): BaseIndicator {
        tabLayout?.setSelectedTabIndicatorGravity(gravity)
        return this
    }

    abstract fun bind()
}package com.loper7.tab_expand.text

import android.R
import android.content.Context
import android.view.Gravity
import android.widget.LinearLayout
import android.widget.TextView
import androidx.annotation.ColorInt
import androidx.annotation.Dimension
import androidx.annotation.Px
import com.google.android.material.tabs.TabLayout
import com.loper7.tab_expand.ext.toPx
import com.loper7.tab_expand.indicator.BaseIndicator

/**
 *
 * @CreateDate:     2020/8/5 9:50
 * @Description:    java类作用描述
 * @Author:         LOPER7
 * @Email:          loper7@163.com
 */
open class BaseText {

    protected var context: Context? = null
    protected var tabLayout: TabLayout? = null
    protected var normalTextBold: Boolean = false
    protected var selectTextBold: Boolean = false
    protected var normalTextSize: Float = 14f
    protected var selectTextSize: Float = 14f

    fun bindTabLayout(tabLayout: TabLayout) {
        this.tabLayout = tabLayout
        this.context = tabLayout.context
    }

    fun setNormalTextBold(normalTextBold: Boolean): BaseText {
        this.normalTextBold = normalTextBold
        return this
    }

    fun setSelectTextBold(selectTextBold: Boolean): BaseText {
        this.selectTextBold = selectTextBold
        return this
    }

    fun setNormalTextSize(normalTextSize: Float): BaseText {
        this.normalTextSize = normalTextSize
        return this
    }

    fun setSelectTextSize(selectTextSize: Float): BaseText {
        this.selectTextSize = selectTextSize
        return this
    }

    fun bind() {
        tabLayout?.post {
            tabLayout?.apply {
                for (i in 0 until tabCount) {
                    getTabAt(i)?.let {
                        it.customView = TextView(context).apply {
                            text = it.text
                            textSize = if (selectedTabPosition==i) selectTextSize else normalTextSize
                            if (selectedTabPosition==i)
                                paint?.isFakeBoldText = selectTextBold
                            else
                                paint?.isFakeBoldText = normalTextBold
                            gravity = Gravity.CENTER
                            setTextColor(tabTextColors)
                        }
                    }
                }

                addOnTabSelectedListener(object : TabLayout.OnTabSelectedListener {
                    override fun onTabReselected(tab: TabLayout.Tab?) {
                        (tab?.customView as? TextView)?.apply {
                            textSize = selectTextSize
                            paint?.isFakeBoldText = selectTextBold
                        }
                    }

                    override fun onTabUnselected(tab: TabLayout.Tab?) {
                        (tab?.customView as? TextView)?.apply {
                            textSize = normalTextSize
                            paint?.isFakeBoldText = normalTextBold
                        }
                    }

                    override fun onTabSelected(tab: TabLayout.Tab?) {
                        (tab?.customView as? TextView)?.apply {
                            textSize = selectTextSize
                            paint?.isFakeBoldText = selectTextBold
                        }
                    }

                })
            }
        }

    }
}package com.mikhaellopez.biometricsample

import android.os.Bundle


alPassword{padding:0 0.1875rem;cursor:pointer;display:flex;align-items:center;justify-content:center;margin-left:auto;text-decoration:none;}.amis-scope .antd-TextControl-revealPassword svg{cursor:pointer;}.amis-scope .antd-TextControl .InputText-invisible{content:'<svg viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><title>不可见</title><g id="不可见" stroke="none" stroke-width="1" fill="currentColor" fill-rule="evenodd"><g id="编组"><rect id="矩形" stroke="none" fill="currentColor" opacity="0" x="0.5" y="0.5" width="15" height="15"></rect><path d="M2.91972703,5.00035128 C3.15932221,5.56062137 3.48954828,6.0784548 3.89678565,6.53485922 C4.96673844,7.73914737 6.49518581,8.43995 8.14,8.43995 C9.76664693,8.43995 11.2813058,7.75315198 12.3523764,6.57033395 C12.6920742,6.19520277 12.9803798,5.7761243 13.209327,5.32420638 L13.3395085,5.04920376 L14.2544915,5.45269624 C13.9653387,6.10839593 13.572991,6.71219666 13.0936273,7.24156203 C12.7623988,7.60734835 12.3948705,7.93285848 11.9982387,8.21395897 L12.9566,9.87395 L12.0906,10.37395 L11.1412434,8.72942071 C10.3784723,9.11337429 9.54082663,9.35086388 8.66757967,9.41933209 L8.668,10.97185 L7.668,10.97185 L7.66735222,9.42343888 C6.75745885,9.35969244 5.88560233,9.11282413 5.09602954,8.70830726 L4.1485,10.34855 L3.2825,9.84855 L4.2424457,8.18636156 C3.84593988,7.9008387 3.4793171,7.57058753 3.14992355,7.19983732 C2.73988365,6.74029373 2.39560013,6.22662333 2.12776836,5.67339306 L2.00027297,5.39354872 L2.91972703,5.00035128 Z" id="形状结合"></path></g></g></svg>';}.amis-scope .antd-TextControl .InputText-view{content:'<svg viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><title>可见</title><g id="可见" stroke="none" stroke-width="1" fill="currentColor" fill-rule="evenodd"><g id="编组"><rect id="矩形" opacity="0" x="0.5" y="0.5" width="15" height="15"></rect><path d="M7.9999,3.0001 C11.9889,3.0001 14.9999,6.8731 14.9999,8.0001 C14.9999,8.8831 11


0x16, 0x2d, 0x51, 0xce, 0x2f, 0xe2, 0x34, 0x62, 0x52, 0xed, 0x65, 0xd0,
	0x12, 0xe5, 0xbc, 0xba, 0x11, 0x55, 0x65, 0x83, 0x96, 0x88, 0x10, 0x68, 0x05, 0x0c, 0x03, 0x15,
	0xbe, 0x4f, 0xd5, 0x99, 0x7c, 0x84, 0x5e, 0xc4, 0x25, 0x9b, 0x33, 0xc9, 0xcc, 0xb6, 0xe2, 0x2b,
	0x6c, 0xff, 0x87, 0x7e, 0x7d, 0x96, 0x57, 0xe7, 0x18, 0x41, 0x3b, 0x14, 0x73, 0x7e, 0x51, 0xc6,
	0x28, 0x80, 0x7d, 0xa9, 0x83, 0xf1, 0x68, 0xa1, 0xb7, 0xf1, 0xcd, 0x59, 0xd5, 0xb3, 0xac, 0x57,
	0x00, 0x62, 0x42, 0x37, 0x0a, 0x11, 0x43, 0xe1, 0xab, 0x7a, 0x3d, 0xba, 0x85, 0x93, 0xbf, 0x37,
	0x6b, 0x4b, 0x5f, 0xad, 0x2d, 0xfd, 0x7e, 0x6d, 0xe9, 0xd7, 0x1b, 0x4b, 0x5b, 0x6d, 0x2c, 0xed,
	0x76, 0x63, 0x69, 0x27, 0x3f, 0xfc, 0x50, 0x06, 0xd9, 0xcc, 0xf1, 0xe2, 0xc8, 0xf5, 0xe2, 0x88,
	0xcb, 0xd9, 0x42, 0xee, 0x0e, 0xea, 0xc1, 0xb8, 0x87, 0x5e, 0xd4, 0xac, 0xa3, 0xbe, 0x7d, 0x7f,
	0x08, 0x00, 0x00, 0xff, 0xff, 0x04, 0xbe, 0xb0, 0x90, 0x70, 0x03, 0x00, 0x00,
}

func (m *Message) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Message) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Message) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Sum != nil {
		{
			size := m.Sum.Size()
			i -= size
			if _, err := m.Sum.MarshalTo(dAtA[i:]); err != nil {
				return 0, err
			}
		}
	}
	return len(dAtA) - i, nil


_RUNONCE;
						eff.param.s   = ((i > n)?i-n:n-i);
						utrk_write_inst(of->ut, ins);
						utrk_write_note(of->ut, n); // <- normal note
						pt_write_effect(of->ut, 0xc, vol);
						utrk_write_local(of->ut, &eff, (i > n)? PTMEM_PITCHSLIDEUP: PTMEM_PITCHSLIDEDN);
					}
				}
				else { // no new notes, keep on trilling...
					if( trillbits & (1<<ch) ) {
						utrk_settrack(of->ut, ch);
						eff.effect  = UNI_VIBRATO_DEPTH;
						eff.param.u = 12;	// depth 1.5
						utrk_write_local(of->ut, &eff, PTMEM_VIBRATO_DEPTH);
						eff.effect  = UNI_VIBRATO_SPEED;
						eff.param.u = 60; // speed 15
						utrk_write_local(of->ut, &eff, PTMEM_VIBRATO_SPEED);
					}
				}
				ch++;
			}
			utrk_newline(of->ut);
		}
		if(!utrk_dup_pattern(of->ut,of)) return;
	}
}

#else

static int ABC_ReadPatterns(MODCOMMAND *pattern[], WORD psize[], ABCHANDLE *h, int numpat, int channels)
// =====================================================================================
{
	int pat,row,i,ch,trillbits;
	BYTE n,ins,vol;
	ABCTRACK *t;
	ABCEVENT *e, *en, *ef, *el;
	uint32_t tt1, tt2;
	MODCOMMAND *m;
	int patbrk, tempo;
	if( numpat > MAX_PATTERNS ) numpat = MAX_PATTERNS;

	// initialize start points of event list in tracks
	for( t = h->track; t; t = t->next ) t->capostart = t->head;
	trillbits = 0; // trill effect admininstration: one bit per channel, max 32 channnels
	for( pat = 0; pat < numpat; pat++ ) {
		pattern[pat] = CSoundFile::AllocatePattern(64, channels);
		if( !pattern[pat] ) return 0;
		psize[pat] = 64;
		for( row = 0; row < 64; row++ ) {
			tt1 = abcticks((pat * 64 + row ) * h->speed);
			tt2 = tt1 + abcticks(h->speed);
			ch = 0;
			tempo = 0;
			patbrk = 0;
			for( e=abc_next_global(h->track->capostart); e && e->tracktick < tt2; e=abc_next_global(e->next) ) {
				if( e && e->tracktick >= tt1 ) {	// we have a tempo event in this row
					switch( e->cmd ) {
						case cmdtempo:
							tempo = e->lpar;
							break;
						case cmdpartbrk:
							patbrk = 1;
							break;
					}
				}
			}
			for( t = h->track; t; t = t->next ) {
				for( e=abc_next_note(t->capostart); e && e->tracktick < tt1; e=abc_next_note(e->next) ) ;
				i = 0;
				ef = NULL;
				en = e;
				el = e;
				for( ; e && e->tracktick < tt2; e=abc_next_note(e->next) ) {	// we have a note event in this row
					t->capostart = e;
					i++;
					if( e->par[volume] ) {
						if( !ef ) ef = e;
						el = e;
					}
				}
				m = &pattern[pat][row * channels + ch];
				m->param   = 0;
				m->command = CMD_NONE;
				if( i ) {
					trillbits &= ~(1<<ch);
					if( i == 1 |


rame, &popupSet);
  if (!popupSet)
    return NS_OK;

  nsWeakFrame weakOurFrame(ourFrame);
  nsWeakFrame weakPopupSetFrame(popupSetFrame);
  popupSet->HidePopup(ourFrame);
  if (weakOurFrame.IsAlive() && weakPopupSetFrame.IsAlive()) {
    popupSet->DestroyPopup(ourFrame, PR_TRUE);
  }

  return NS_OK;
}

NS_IMETHODIMP
nsPopupBoxObject::ShowPopup(nsIDOMElement* aSrcContent,
                            nsIDOMElement* aPopupContent,
                            PRInt32 aXPos, PRInt32 aYPos,
                            const PRUnichar *aPopupType, const PRUnichar *anAnchorAlignment,
                            const PRUnichar *aPopupAlignment)
{
  nsCOMPtr<nsIPresShell> shell = GetPresShell();
  if (!shell) {
    return NS_OK;
  }

  nsIFrame* rootFrame = shell->FrameManager()->GetRootFrame();
  if (!rootFrame)
    return NS_OK;

  if (rootFrame) {
    rootFrame = rootFrame->GetFirstChild(nsnull);
  }

  nsIRootBox* rootBox = nsnull;
  CallQueryInterface(rootFrame, &rootBox);
  if (!rootBox)
    return NS_OK;

  nsIFrame* popupSetFrame;
  rootBox->GetPopupSetFrame(&popupSetFrame);
  if (!popupSetFrame)
    return NS_OK;

  nsIPopupSetFrame* popupSet = nsnull;
  CallQueryInterface(popupSetFrame, &popupSet);
  if (!popupSet)
    return NS_OK;

  nsCOMPtr<nsIContent> srcContent(do_QueryInterface(aSrcContent));
  nsCOMPtr<nsIContent> popupContent(do_QueryInterface(aPopupContent));

  nsAutoString popupType(aPopupType);
  nsAutoString anchorAlign(anAnchorAlignment);
  nsAutoString popupAlign(aPopupAlignment);

  // Use |left| and |top| dimension attributes to position the popup if
  // present, as they may have been persisted.
  nsAutoString left, top;
  popupContent->GetAttr(kNameSpaceID_None, nsXULAtoms::left, left);
  popupContent->GetAttr(kNameSpaceID_None, nsXULAtoms::top, top);

  PRInt32 err;
  if (!left.IsEmpty()) {
    aXPos = left.ToInteger(&err);
    if (NS_FAILED(err))
      return err;
  }
  if (!top.IsEmpty()) {
    aYPos = top.ToInteger(&err);
    if (NS_FAILED(err))
      return err;
  }

  return popupSet->ShowPopup(srcContent, popupContent, aXPos, aYPos,
                             popupType, anchorAlign, popupAlign);
}

NS_IMETHODIMP
nsPopupBoxObject::MoveTo(PRInt32 aLeft, PRInt32 aTop)
{
  nsMenuPopupFrame* menuPopupFrame = GetMenuPopupFrame();
  if (!menuPopupFrame) return NS_OK;

  menuPopupFrame->MoveTo(aLeft, aTop);

  return NS_OK;
}

NS_IMETHODIMP
nsPopupBoxObject::SizeTo(PRInt32 aWidth, PRInt32 aHeight)
{
  nsAutoString width, height;
  width.AppendInt(aWidth);
  height.AppendInt(aHeight);

  nsCOMPtr<nsIContent> content = mContent;
  content->SetAttr(kNameSpaceID_None, nsHTMLAtoms::width, width, PR_FALSE);
  content->SetAttr(kNameSpaceID_None, nsHTMLAtoms::height, height, PR_TRUE);

  return NS_OK;
}

NS_IMETHODIMP
nsPopupBoxObject::GetAutoPosition(PRBool* aShouldAutoPosition)
{
  nsMenuPopupFrame* menuPopupFrame = GetMenuPop


pointssim = np.mean(pointssim_values)
        avg_chamfer = np.mean(chamfer_values)

        # Calculate standard deviations
        std_pcqm = np.std(pcqm_values)
        std_pointssim = np.std(pointssim_values)
        std_chamfer = np.std(chamfer_values)

        print("\nAverage metrics across all directories:")
        print(f"  Average PCQM: {avg_pcqm:.4f} (std: {std_pcqm:.4f})")
        print(f"  Average PointSSIM: {avg_pointssim:.4f} (std: {std_pointssim:.4f})")
        print(f"  Average Chamfer: {avg_chamfer:.4f} (std: {std_chamfer:.4f})")

        results_file = args.output_file

        with open(results_file, "w") as f:
            f.write("Mesh Comparison Results\n")
            f.write("======================\n\n")

            # for subdir, metrics in all_metrics.items():
            #     f.write(f"Metrics for {subdir}:\n")
            #     f.write(f"  PSNR: {metrics['psnr']:.4f}\n")
            #     f.write(f"  MS-SSIM: {metrics['ms_ssim']:.4f}\n")
            #     f.write(f"  LPIPS: {metrics['lpips']:.4f}\n\n")

            f.write("\nAverage metrics across all directories:\n")
            f.write(f"  Average PCQM: {avg_pcqm:.4f} (std: {std_pcqm:.4f})\n")
            f.write(
                f"  Average PointSSIM: {avg_pointssim:.4f} (std: {std_pointssim:.4f})\n"
            )
            f.write(f"  Average Chamfer: {avg_chamfer:.4f} (std: {std_chamfer:.4f})\n")

        print(f"Results saved to {results_file}")
    else:
        print("No valid results to report")

if __name__ == "__main__":
    main()


s<Rs, Er>);
}

export const Result: Result

declare class OptionClass<A> {
  static of<S>(value: S): OptionClass<S>;

  alt(option: OptionClass<A>): OptionClass<A>;
  and<B>(option: OptionClass<B>): OptionClass<B>;
  ap<B>(option: OptionClass<((value: A) => B)>): OptionClass<B>;
  chain<B>(optionƒ: (value: A) => OptionClass<B>): OptionClass<B>;
  equals(option: OptionClass<A>): boolean;
  exists(ƒ: (value: A) => boolean): boolean;
  extend<B>(ƒ: (option: OptionClass<A>) => B): OptionClass<B>;
  extractOr(defaultValue: A): A;
  extractOrElse(defaultƒ: () => A): A;
  filter(predicate: (value: A) => boolean): OptionClass<A>;
  inspect(): string;
  isNone(): boolean;
  isSome(): boolean;
  iter(): Iterator<A>;
  map<B>(ƒ: (value: A) => B): OptionClass<B>;
  mapOr<B>(value: B, ƒ: (value: A) => B): OptionClass<B>;
  mapOrElse<B>(defaultƒ: () => B, mapƒ: (value: A) => B): OptionClass<B>;
  okOr<E>(error: E): ResultClass<A, E>;
  okOrElse<E>(errorFn: () => E): ResultClass<A, E>;
  or(option: OptionClass<A>): OptionClass<A>;
  orElse(ƒ: () => OptionClass<A>): OptionClass<A>;
  toString(): string;
}

export class Some<A> extends OptionClass<A> {}
export class None<A> extends OptionClass<A> {
  static of<S>(): OptionClass<S>;
}

type Option = {
  encase<A, B, C, D, E, F, J, Rs>(fn: (a: A, b: B, c: C, d: D, e: E, f: F, j: J) => Rs): ((a: A, b: B, c: C, d: D, e: E, f: F, j: J) => OptionClass<Rs>);
  encase<A, B, C, D, E, F, Rs>(fn: (a: A, b: B, c: C, d: D, e: E, f: F) => Rs): ((a: A, b: B, c: C, d: D, e: E, f: F) => OptionClass<Rs>);
  encase<A, B, C, D, E, Rs>(fn: (a: A, b: B, c: C, d: D, e: E) => Rs): ((a: A, b: B, c: C, d: D, e: E) => OptionClass<Rs>);
  encase<A, B, C, D, Rs>(fn: (a: A, b: B, c: C, d: D) => Rs): ((a: A, b: B, c: C, d: D) => OptionClass<Rs>);
  encase<A, B, C, Rs>(fn: (a: A, b: B, c: C) => Rs): ((a: A, b: B, c: C) => OptionClass<Rs>);
  encase<A, B, Rs>(fn: (a: A, b: B) => Rs): ((a: A, b: B) => OptionClass<Rs>);
  encase<A, Rs>(fn: (a: A) => Rs): ((a: A) => OptionClass<Rs>);
  fromNullable<A>(value: A | Number | null | undefined): OptionClass<A>;
  into<T>(value?: T): OptionClass<T>;
  is(value: any): boolean;
  none<T>(): OptionClass<T>;
  of<


auto">
          <span
            class="bg-gradient-to-r from-violet-400 to-pink-400 bg-clip-text text-transparent"
            >Friend</span
          ><span
            class="bg-gradient-to-r from-orange-400 to-yellow-400 bg-clip-text text-transparent"
            >Folio</span
          >
        </p>
        <!-- <p
        class="font-medium text-lg text-center cursor-default delay-150 text-neutral-400 group-hover:bg-violet-400 group-hover:text-white group-hover:shadow-violet-500/50 w-fit mx-auto group-hover:mt-1 group-hover:mb-10 mb-11 duration-300 px-5 rounded-full group-hover:shadow-md py-0.5 group-hover:text-lg transition-all"
      >
        never forget a birthday again !
      </p> -->
      </div>
      <div
        class="bg-white rounded-full w-fit lg:mx-auto px-2 py-2 flex gap-2 col-span-2 lg:col-span-1 mt-8 lg:mt-0"
      >
        <button
          onclick="window.location.href = '/home'"
          title="home"
          class="flex items-center h-full w-fit group bg-violet-400 px-3 py-1 rounded-full gap-2 shadow-md shadow-violet-500/50 hover:bg-violet-500/80 transition-all active:bg-violet-200"
        >
          <svg
            xmlns="http://www.w3.org/2000/svg"
            viewBox="0 0 20 20"
            fill="currentColor"
            class="size-5 text-white group-active:text-violet-400"
          >
            <path
              fill-rule="evenodd"
              d="M9.293 2.293a1 1 0 0 1 1.414 0l7 7A1 1 0 0 1 17 11h-1v6a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1v-3a1 1 0 0 0-1-1H9a1 1 0 0 0-1 1v3a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-6H3a1 1 0 0 1-.707-1.707l7-7Z"
              clip-rule="evenodd"
            />
          </svg>
          <p class="font-medium text-white group-active:text-violet-400">
            Home
          </p>
        </button>
        <button
          onclick="window.location.href = '/friends'"
          title="friends"
          class="flex items-center h-full w-fit px-3 py-1 rounded-full gap-2 hover:bg-pink-200 transition-all active:bg-pink-400 group"
        >
          <svg
            xmlns="http://www.w3.org/2000/svg"
            viewBox="0 0 20 20"
            fill="currentColor"
            class="size-5 text-pink-400 group-active:text-white"
          >
            <path
              d="M10 9a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM6 8a2 2 0 1 1-4 0 2 2 0 0 1 4 0ZM1.49 15.326a.78.78 0 0 1-.358-.442 3 3 0 0 1 4.308-3.516 6.484 6.484 0 0 0-1.905 3.959c-.023.222-.014.442.025.654a4.97 4.97 0 0 1-2.07-.655ZM16.44 15.98a4.97 4.97 0 0 0 2.07-.654.78.78 0 0 0 .357-.442 3 3 0 0 0-4.308-3.517 6.484 6.484 0 0 1 1.907 3.96 2.32 2.32 0 0 1-


 (i==pace.length-1){
			com.showPane(newX ,newY,x,y)
		}
		//} catch (e){
		//	com.show()
		//	z([key,p,pace,map])

		//	}
	}
	play.map = map;
	play.my=1;
	play.isPlay=true;
	com.show();
}

//¼
play.clickCanvas = function (e){
	if (!play.isPlay) return false;
	var key = play.getClickMan(e);
	var point = play.getClickPoint(e);

	var x = point.x;
	var y = point.y;

	if (key){
		play.clickMan(key,x,y);
	}else {
		play.clickPoint(x,y);
	}
	play.isFoul = play.checkFoul();//ǲǳ
}

//ӣѡл߳
play.clickMan = function (key,x,y){
	var man = com.mans[key];
	//
	if (play.nowManKey&&play.nowManKey != key && man.my != com.mans[play.nowManKey ].my){
		//manΪԵ
		if (play.indexOfPs(com.mans[play.nowManKey].ps,[x,y])){
			man.isShow = false;
			var pace=com.mans[play.nowManKey].x+""+com.mans[play.nowManKey].y
			//z(bill.createMove(play.map,man.x,man.y,x,y))
			delete play.map[com.mans[play.nowManKey].y][com.mans[play.nowManKey].x];
			play.map[y][x] = play.nowManKey;
			com.showPane(com.mans[play.nowManKey].x ,com.mans[play.nowManKey].y,x,y)
			com.mans[play.nowManKey].x = x;
			com.mans[play.nowManKey].y = y;
			com.mans[play.nowManKey].alpha = 1

			play.pace.push(pace+x+y);
			play.nowManKey = false;
			com.pane.isShow = false;
			com.dot.dots = [];
			com.show()
			com.get("clickAudio").play();
			setTimeout("play.AIPlay()",500);
			if (key == "j0") play.showWin (-1);
			if (key == "J0") play.showWin (1);
		}
	// ѡ
	}else{
		if (man.my===1){
			if (com.mans[play.nowManKey]) com.mans[play.nowManKey].alpha = 1 ;
			man.alpha = 0.6;
			com.pane.isShow = false;
			play.nowManKey = key;
			com.mans[key].ps = com.mans[key].bl(); //ŵ
			com.dot.dots = com.mans[key].ps
			com.show();
			//com.get("selectAudio").start(0);
			com.get("selectAudio").play();
		}
	}
}

//ŵ
play.clickPoint = function (x,y){
	var key=play.nowManKey;
	var man=com.mans[key];
	if (play.nowManKey){
		if (play.indexOfPs(com.mans[key].ps,[x,y])){
			var pace=man.x+""+man.y
			//z(bill.createMove(play.map,man.x,man.y,x,y))
			delete play.map[man.y][man.x];
			play.map[y][x] = key;
			com.showPane(man.x ,man.y,x,y)
			man.x = x;
			man.y = y;
			man.alpha = 1;
			play.pace.push(pace+x+y);
			play.nowManKey = false;
			com.dot


    .add('Normal', () => ({
        template: `
            <app-card-cluster
                [cardArray]="cardClusterDataNormal"
                buttonClicked='CardCluster0'
                dataAutoId = 'testingID'
                (passButton)="handleEvent($event)">
            </app-card-cluster>
        `,
        props,
    }))
    .add('Without Main Card', () => ({
        template: `
            <app-card-cluster
                [cardArray]="cardClusterDataWithoutMain"
                buttonClicked='CardCluster1'
                dataAutoId = 'testingID'
                (passButton)="handleEvent($event)">
            </app-card-cluster>
        `,
        props,
    }))
    .add('No Mini Cards', () => ({
        template: `
            <app-card-cluster
                [cardArray]="cardClusterDataWithoutMiniCards"
                buttonClicked='CardCluster0'
                dataAutoId = 'testingID'
                (passButton)="handleEvent($event)">
            </app-card-cluster>
        `,
        props,
    })).add('Selected Card', () => ({
        template: `
            <app-card-cluster
                [cardArray]="cardClusterDataNormal"
                buttonClicked='CardCluster4'
                dataAutoId = 'testingID'
                (passButton)="handleEvent($event)">
            </app-card-cluster>
        `,
        props,
    })).add('Set Total', () => ({
        template: `
            <app-card-cluster
                [cardArray]="cardClusterDataSetTotal"
                buttonClicked='CardCluster4'
                dataAutoId = 'testingID'
                (passButton)="handleEvent($event)">
            </app-card-cluster>
        `,
        props,
    }));
import * as fsx from 'fs-extra';
import * as path from 'path';
import * as structure from './structure';

/**
 * Initializer config recipe.
 */
export interface GeneratorRecipe {
  root: string;
  name: string;
  description: string;
}

/**
 * Project structure initializer.
 */
export class Generator {
  protected recipe: GeneratorRecipe;

  /**
   * Class constructor.
   * @param recipe Initializer config recipe.
   */
  public constructor (recipe: GeneratorRecipe) {
    this.recipe = recipe;
  }

  /**
   * Creates project files.
   */
  public async build () {
    for (const file of structure.files) {
      const dest = path.resolve(this.recipe.root, ...file.path);

      const dir = path.dirname(dest);
      await fsx.ensureDir(dir);

      const src = file.content
        .join('\n')
        .replace('{{ name }}', this.recipe.name)
        .replace('{{ description }}', this.recipe.description);
      await fsx.writeFile(dest, src);
    }
  }

}
import { CollectionCache, CollectionKey } from "../../../common";
import { Names } from "./Names";

export namespace NameRestrictedCombinations {
  export const KEY = new CollectionKey("name_restricted_combinations");

  export class Entry {
    private readonly collectionCache: CollectionCache;

    readonly _foundName: number;
    readonly _restrictedCombination: number;
    readonly _replaceFoundNameWith: number;

    constructor(collectionCache: CollectionCache, values: any) {
      this.collectionCache = collectionCache;
      this._foundName = values["found_name"];
      this._restrictedCombination = values["restricted_combination"];
      this._replaceFoundNameWith = values["replace_found_name_with"];
    }

    get foundName(): Names.Entry | undefined {
      const collection = <Names.Entry[]>this.collectionCache.getCollection(Names.KEY, Names.E


signature-type">undefined

Inherited from KeyboardEventBase.clientX

clientY<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5"></path></svg>

clientY: undefined

Inherited from KeyboardEventBase.clientY

code<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5"></path></svg>

code: string

Inherited from KeyboardEventBase.code

ctrl<wbr/>Key<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="current


responsive' : ''}
                            ${semiActiveSections.includes(breakpoint.label) ? 'semi-active-break' : ''}
                            ${isHidden ? 'hidden' : isMobile && isFirstMobileBreakpoint ? 'w-full' : ''}`}
                                    style={{ width: `${isMobile && isFirstMobileBreakpoint ? '100%' : breakpoint.buttonWidth + 'px'}`, minWidth: `${isMobile ? 'auto' : breakpoint.buttonWidth + 'px'}` }}
                                    onClick={() => handleBreakpointClick(breakpoint.width)}
                                >
                                    {isMobile && isFirstMobileBreakpoint ? `Mobile ${windowWidth}px` : breakpoint.label}

                            );
                        })}

                        <div className={'resize-wrapper m-auto relative ' + (isMobile ? 'w-full' : '')} style={{ width: `${isMobile ? windowWidth + 'px' : Math.min(iframeWidth, maxIframeWidth)}px` }}>

                            {windowWidth >= 576 &&

}

    );
};

export default ResponsiveSection;
import { memo, useMemo } from 'react';

const UsersSection = ({ dark }) => {
    const colorScheme = !dark ? 'light' : 'dark';

    const usersData = useMemo(
        () => [
            { name: 'LogoFrame-1', height: '80' },
            { name: 'LogoFrame-2', height: '90' },
            { name: 'LogoFrame-3', height: '80' },
            { name: 'LogoFrame-4', height: '110' },
            { name: 'LogoFrame-5', height: '80' },
            { name: 'LogoFrame-6', height: '80' },
            { name: 'LogoFrame-7', height: '120' },
            { name: 'LogoFrame-8', height: '100' },
            { name: 'LogoFrame-9', height: '80' }
        ],
        []
    );
    const getUsersImages = (usersData, colorScheme) =>
        usersData.map((user) => ({
            name: user.name,
            image: `https://www.primefaces.org/cdn/primeflex/images/landing/users/${colorScheme}/${user.name}.svg`,
            height: user.height
        }));

    const usersImages = useMemo(() => getUsersImages(usersData, colorScheme), [usersData, colorScheme]);
    const Marquee = memo(({ users }) => (

            {Array(3)
                .fill(users)
                .map((users, index) => (
                    <div key={index} className={`marquee`}>
                        {users.map((user) => (

                        ))}

                ))}

    ));

    return (


leftClosedRightOpen = 'leftClosedRightOpen',
}

/**
 * 检查 `value` 是否在某区间内。
 *
 * @param value 要检查的值
 * @param start 开始值
 * @param end 结束值
 * @param intervalType 区间类型
 * @returns `value` 在区间内返回 `true`，否则返回 `false`
 * @example
 * ```ts
 * // 2 是否在区间 (0, 2) 内
 * inRange(2, 0, 2, InRangeIntervalType.open) // => false
 *
 * // 2 是否在区间 [0, 2] 内
 * inRange(2, 0, 2, InRangeIntervalType.closed) // => true
 *
 * // 2 是否在区间 [0, 2) 内
 * inRange(2, 0, 2, InRangeIntervalType.leftClosedRightOpen) // => false
 *
 * // 2 是否在区间 (0, 2] 内
 * inRange(2, 0, 2, InRangeIntervalType.leftOpenRightClosed) // => true
 * ```
 */
export function inRange(
  value: number,
  start: number,
  end: number,
  intervalType: InRangeIntervalType,
): boolean {
  const leftClosed = intervalType === InRangeIntervalType.closed || intervalType === InRangeIntervalType.leftClosedRightOpen
  const rightClosed = intervalType === InRangeIntervalType.closed || intervalType === InRangeIntervalType.leftOpenRightClosed
  return (
    (leftClosed ? start <= value : start < value)
      && (rightClosed ? value <= end : value < end)
  )
}
import { Seq } from "immutable";

const ranks = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] as const;

export type Rank = typeof ranks[number];

const max = ranks[ranks.length - 1];

export const Rank = {
  all,
  max,
  show,
};

function all(): Seq.Indexed<Rank> {
  return Seq<Rank>(ranks);
}

function show(rank: Rank): string {
  switch (rank) {
  case 1: return "A";
  case 11: return "J";
  case 12: return "Q";
  case 13: return "K";
  default: return rank.toString();
  }
}
import { IRegistrar, IFrame, Plugin, getPlugins } from "./plugins";
import { PluginType, initFrame, IPixel } from "./plugins/base";

const enabledPlugins = ["clock", "calendar", "weather", "kepler"];

export default class Engine implements IRegistrar {
  plugins: Plugin[];
  backgroundScheduler: BackgroundScheduler;
  dataPixelScheduler: DataPixelScheduler;
  notificationScheduler: NotificationScheduler;

  constructor() {
    this.plugins = getPlugins(enabledPlugins);
    this.plugins.forEach(plugin => plugin.onRegister(this));
    this.backgroundScheduler = new BackgroundScheduler(this.plugins);
    this.dataPixelScheduler = new DataPixelScheduler(this.plugins);
    this.notificationScheduler = new NotificationScheduler();
  }

  request(plugin: Plugin): void {
    if (plugin.getType() === PluginType.NOTIFICATION) {
      this.notificationScheduler.request(plugin);
    } else {
      throw new Error(`Cannot request to play ${plugin.getType()} plugins.`);
    }
  }

  play(callback: (frame: IFrame) => void) {
    const render = () => {
      const painter = new FramePainter();

      const [
        backgroundPlugin,
        backgroundPercent
      ] = this.backgroundScheduler.schedule();
      painter.paint(backgroundPlugin.render(backgroundPercent));

      const dataPixelSchedules = this.dataPixelScheduler.schedule();
      dataPixelSchedules.forEach(([plugin, percent]) =>
        painter.paint(plugin.render(percent))
      );

      const [
        notificationPlugin,
        notificationPercen


Function `remove_permissioned_handle`](#0x1_permissioned_delegation_remove_permissioned_handle)
-  [Function `permissioned_signer_by_key`](#0x1_permissioned_delegation_permissioned_signer_by_key)
-  [Function `handle_address_by_key`](#0x1_permissioned_delegation_handle_address_by_key)
-  [Function `authenticate`](#0x1_permissioned_delegation_authenticate)
-  [Function `get_storable_permissioned_handle`](#0x1_permissioned_delegation_get_storable_permissioned_handle)
-  [Specification](#@Specification_1)

use 0x1::auth_data;
use 0x1::bcs_stream;
use 0x1::big_ordered_map;
use 0x1::ed25519;
use 0x1::error;
use 0x1::option;
use 0x1::permissioned_signer;
use 0x1::rate_limiter;
use 0x1::signer;

## Enum `AccountDelegation`

enum AccountDelegation has store

Variants

V1

Fields

handle: permissioned_signer::StorablePermissionedHandle

rate_limiter: option::Option<rate_limiter::RateLimiter>

## Enum `DelegationKey`

enum DelegationKey has copy, drop, st


import re
from copy import deepcopy
from qtpy import QT_VERSION
from qtpy import QtCore
from qtpy import QtGui
from qtpy import QtWidgets

import labelme.utils
from labelme.logger import logger

QT5 = QT_VERSION[0] == "5"

# TODO(unknown):
# - Calculate optimal position so as not to go out of screen area.

class LabelQLineEdit(QtWidgets.QLineEdit):
    def setListWidget(self, list_widget):
        self.list_widget = list_widget

    def keyPressEvent(self, e):
        if e.key() in [QtCore.Qt.Key_Up, QtCore.Qt.Key_Down]:
            self.list_widget.keyPressEvent(e)
        else:
            super(LabelQLineEdit, self).keyPressEvent(e)

class LabelDialog(QtWidgets.QDialog):
    def __init__(
        self,
        text="Enter object label",
        parent=None,
        labels=None,
        sort_labels=True,
        show_text_field=True,
        completion="startswith",
        fit_to_content=None,
        flags=None,
    ):
        if fit_to_content is None:
            fit_to_content = {"row": False, "column": True}
        self._fit_to_content = fit_to_content

        super(LabelDialog, self).__init__(parent)
        self.edit = LabelQLineEdit()
        self.edit.setPlaceholderText(text)
        self.edit.setValidator(labelme.utils.labelValidator())
        self.edit.editingFinished.connect(self.postProcess)
        if flags:
            self.edit.textChanged.connect(self.updateFlags)
        self.edit_group_id = QtWidgets.QLineEdit()
        self.edit_group_id.setPlaceholderText("Group ID")
        self.edit_group_id.setValidator(
            QtGui.QRegExpValidator(QtCore.QRegExp(r"\d*"), None)
        )
        layout = QtWidgets.QVBoxLayout()
        if show_text_field:
            layout_edit = QtWidgets.QHBoxLayout()
            layout_edit.addWidget(self.edit, 6)
            layout_edit.addWidget(self.edit_group_id, 2)
            layout.addLayout(layout_edit)
        # buttons
        self.buttonBox = bb = QtWidgets.QDialogButtonBox(
            QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel,
            QtCore.Qt.Horizontal,
            self,
        )
        bb.button(bb.Ok).setIcon(labelme.utils.newIcon("done"))
        bb.button(bb.Cancel).setIcon(labelme.utils.newIcon("undo"))
        bb.accepted.connect(self.validate)
        bb.rejected.connect(self.reject)
        layout.addWidget(bb)
        # label_list
        self.labelList = QtWidgets.QListWidget()
        if self._fit_to_content["row"]:
            self.labelList.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        if self._fit_to_content["column"]:
            self.labelList.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self._sort_labels = sort_labels
        if labels:
            self.labelList.addItems(labels)
        if self._sort_labels:
            self.labelList.sortItems()
        else:
            self.labelList.setDragDropMode(QtWidgets.QAbstractItemView.InternalMove)
        self.labelList.currentItemChanged.connect(self.labelSelected)
        self.labelList.itemDoubleClicked.connect(self.labelDoubleClicked)
        self.labelList.setFixedHeight(150)
        self.edit.setListWidget(self.labelList)
        layout.addWidget(self.labelList)
        # label_flags
        if flags is None:
            flags = {}
        self._flags = flags
        self.flagsLayout = QtWidgets.QVBoxLayout()
        self.flagsComboBox = QtWidgets.QComboBox(self)
        self.flagsComboBox.currentIndexChanged.connect(self.onFlagChanged)
        # 这里是新增代码，用于将下拉框添加到flags布局中
        self.flagsLayout.addWidget(self.flagsComboBox)
        # self.setFlags({})  # 假设你在这个方法里设置了flagsComboBox的选项

        # 创建一个容器widget作为flagsLayout的父对象
        flagsContainer = QtWidgets.QWidget(self)
        flagsContainer.setLayout(self.flagsLayout)
        # 将容器widget添加到主布局中，替代之前的addItem方法
        layout.addWidget(flagsContainer)

        self.edit.textChanged.connect(self.updateFlags)
        # text edit
        self.editDescription = QtWidgets.QTextEdit()
        self.editDescription.setPlaceholderText("Label description")
        self.editDescription.setFixedHeight(50)
        layout.addWidget(self.editDescription)
        self.setLayout(layout)
        # completion
        completer = QtWidgets.QCompleter()
        if not QT5 and completion != "startswith":
            logger.warn(
                "completion other than 'startswith' is only "
                "supported with Qt5. Using 'startswith'"
            )


      Text = "Open stream",
                Key = Key.F2,
                Action = OpenStream
            },
            new Shortcut
            {
                Text = "Load playlist",
                Key = Key.L.WithCtrl,
                Action = OpenPlaylist
            },
            new Shortcut
            {
                Text = "Quit",
                Key = Key.Esc,
                Action = RequestStop
            },
        ]);

        #endregion Menus

        _playlistView = new ListView
        {
            Title = "Playlist",
            X = 0,
            Y = Pos.Bottom(menuBar),
            Width = Dim.Fill(),
            Height = Dim.Fill(11),
            CanFocus = true,
            BorderStyle = LineStyle.Rounded,
            Source = new TrackListDataSource(_loadedPlaylist),
            AllowsMarking = false,
            AllowsMultipleSelection = false
        };
        _playlistView.RowRender += PlaylistView_RowRender;
        _playlistView.VerticalScrollBar.AutoShow = true;
        _playlistView.HorizontalScrollBar.AutoShow = true;
        _playlistView.OpenSelectedItem += (sender, args) =>
        {
            if (args.Value != null)
            {
                _playlistIndex = args.Item;
                PlayHandler((AudioFile)args.Value);
            }
        };

        _progressBar = new ProgressBar()
        {
            Title = "Progress",
            X = 0,
            Y = Pos.Bottom(_playlistView),
            Width = Dim.Fill(),
            Height = 3,
            CanFocus = false,
            BorderStyle = LineStyle.Rounded,
            ProgressBarStyle = ProgressBarStyle.Continuous,
            Fraction = 0f,
        };

        #region PlayBackControls

        var playbackControls = new View()
        {
            Title = "Playback",
            X = 0,
            Y = Pos.Bottom(_progressBar),
            Width = Dim.Auto(),
            Height = Dim.Auto(),
            CanFocus = true,
            BorderStyle = LineStyle.Rounded
        };

        var seekBackwardButton = new Button
        {
            X = 0,
            Y = 0,
            CanFocus = true,
            Text = "<<"
        };
        seekBackwardButton.Accepting += (s, e) =>
        {
            _player.SeekBackward();
            e.Handled = true;
        };

        _playPauseButton = new Button
        {
            X = Pos.Right(seekBackwardButton),
            Y = 0,
            CanFocus = true,
            Text = "▶"
        };
        _playPauseButton.Accepting += (s, e) =>
        {
            var selected = _playlistView.SelectedItem;
            _playlistIndex = selected;
            var selectedTrack = _loadedPlaylist?.ElementAtOrDefault(selected);

            if (selectedTrack != null)
            {
                PlayHandler(selectedTrack);
            }

            if (selectedTrack == null && _player.NowPlaying != null)
            {
                PlayHandler(_player.NowPlaying);
            }

            e.Handled = true;
        };

        var seekForwardButton = new Button
        {
            X = Pos.Right(_playPauseButton),
            Y = 0,
            CanFocus = true,
            Text = ">>"
        };
        seekForwardButton.Accepting += (s, e) =>
        {
            _player.SeekForward();
            e.Handled = true;
        };

        var stopButton = new Button
        {
            X = Pos.Right(seekForwardButton),
            Y = 0,
            CanFocus = true,
            Text = "⏹",
        };
        stopButton.Accepting += (s, e) =>
        {
            _player.Stop();
            _progressBar.Fraction = 0;
            TimePlayedLabel();
            _nowPlayingLabel!.Text = string.Empty;
            _playPauseButton.Text = "▶";
            e.Handled = true;
        };

        // Verify what SoundFlow's max volume level is
        // For now this should be enough based on testing
        List<object> volumeOptions =
        [
            0f, .1f, .2f, .4f, .6f, .8f, 1.0f, 1.2f, 1.4f


# 또는 GitHub에서 설치 (하위 디렉토리 매개변수 참고)
pip install git+https://github.com/cafferychen777/mLLMCelltype.git#subdirectory=python
```

#### 의존성에 대한 중요 사항

mLLMCelltype는 서로 다른 LLM 제공업체 라이브러리가 선택적 의존성인 모듈식 설계를 사용합니다. 사용할 모델에 따라 해당 패키지를 설치해야 합니다:

```bash
# OpenAI 모델 사용 시 (GPT-4o 등)
pip install "mllmcelltype[openai]"

# Anthropic 모델 사용 시 (Claude)
pip install "mllmcelltype[anthropic]"

# Google 모델 사용 시 (Gemini)
pip install "mllmcelltype[gemini]"

# 모든 선택적 의존성을 한 번에 설치
pip install "mllmcelltype[all]"
```

`ImportError: cannot import name 'genai' from 'google'`와 같은 오류가 발생하면 해당 제공업체 패키지를 설치해야 합니다. 예를 들어:

```bash
# Google Gemini 모델용
pip install google-genai
```

## 사용 예제

### 단일 무료 OpenRouter 모델 사용

하나의 모델로 더 간단한 접근 방식을 선호하는 사용자를 위해, OpenRouter를 통한 Microsoft MAI-DS-R1 무료 모델이 우수한 결과를 제공합니다:

```python
import os
from mllmcelltype import annotate_clusters

# 참고: 로깅이 자동으로 구성됩니다

# OpenRouter API 키 설정
os.environ["OPENROUTER_API_KEY"] = "your-openrouter-api-key"

# 각 클러스터의 마커 유전자 정의
marker_genes = {
    "0": ["CD3D", "CD3E", "CD3G", "CD2", "IL7R", "TCF7"],           # T 세포
    "1": ["CD19", "MS4A1", "CD79A", "CD79B", "HLA-DRA", "CD74"],   # B 세포
    "2": ["CD14", "LYZ", "CSF1R", "ITGAM", "CD68", "FCGR3A"]      # 단핵구
}

# Microsoft MAI-DS-R1 무료 모델을 사용한 주석
annotations = annotate_clusters(
    marker_genes=marker_genes,
    species='human',
    tissue='peripheral blood',
    provider='openrouter',
    model='microsoft/mai-ds-r1:free'  # 무료 모델
)

# 주석 출력
for cluster, annotation in annotations.items():
    print(f"클러스터 {cluster}: {annotation}")
```

이 접근 방식은 빠르고 정확하며 API 크레딧이 필요하지 않


 ",
            stringify!(CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st)
        )
    );
    assert_eq!(
        ::std::mem::align_of::<CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st>(),
        8usize,
        concat!(
            "Alignment of ",
            stringify!(CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st)
        )
    );
    assert_eq!(
        unsafe {
            &(*(::std::ptr::null::<CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st>())).params as *const _
                as usize
        },
        0usize,
        concat!(
            "Offset of field: ",
            stringify!(CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st),
            "::",
            stringify!(params)
        )
    );
    assert_eq!(
        unsafe {
            &(*(::std::ptr::null::<CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st>())).flags as *const _
                as usize
        },
        72usize,
        concat!(
            "Offset of field: ",
            stringify!(CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st),
            "::",
            stringify!(flags)
        )
    );
    assert_eq!(
        unsafe {
            &(*(::std::ptr::null::<CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st>())).reserved
                as *const _ as usize
        },
        76usize,
        concat!(
            "Offset of field: ",
            stringify!(CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st),
            "::",
            stringify!(reserved)
        )
    );
}
impl Default for CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st {
    fn default() -> Self {
        unsafe { ::std::mem::zeroed() }
    }
}
pub type CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 = CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st;
pub type CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS = CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st {
    pub params: CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1,
    pub flags: ::std::os::raw::c_uint,
    pub reserved: [::std::os::raw::c_uint; 16usize],
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1 {
    pub fence: CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1__bindgen_ty_1,
    pub nvSciSync: CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1__bindgen_ty_2,
    pub keyedMutex: CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1__bindgen_ty_3,
    pub reserved: [::std::os::raw::c_uint; 10usize],
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
pub struct CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st__bindgen_ty_1__bindgen_ty_1 {
    pub value: ::std::os::raw::c_ulonglong,
}
#[test]
fn bindgen_te


 partitioner
            key,
            // default 0
            partition,
            // default: 0
            attributes,
          }
          if (clientStatusObj[kafkaKey]) {
            producerObj[kafkaKey].send([payloads], (error: Error) => {
              if (error) console.error(error)
            })
          } else {
            messageBufferObj[kafkaKey].push(payloads)
          }
        },
      },
      clean () {
        // force clean buffer when rebuild client
        if (!clientStatusObj[kafkaKey] && messageBufferObj[kafkaKey].length > 0) {
          messageBufferObj[kafkaKey].length = 0
        }

        // producerObj[kafkaKey].close()
        // clientObj[KafkaKey].close()
      },
    }
  }
}
import { CommandArgumentError } from '@/errors';
import { BotCommand } from '@/types';
import {
  getActiveUserMessages,
  getActiveUserVoice,
} from '@database/statements';
import { AJ, EJLX, FE, FE2, FJ, HJ, NE, NJ, OL } from '@utils/constants';
import { infoEmbed } from '@utils/embed';
import { isOrAre } from '@utils/pluralize';
import { stripIndent } from 'common-tags';
import { GuildMember } from 'discord.js';

const command: BotCommand = {
  name: 'languages',
  aliases: ['lang', 'langs'],
  allowedServers: [EJLX],
  description:
    'Language role stats for the server. Use `{PREFIX}lang -all` to include everyone. `-m` and `-v` are treated as OR',
  options: [
    {
      name: 'all',
      short: 'a',
      description: 'Include all users and ignore minimum message/voice count',
      bool: true,
    },
    {
      name: 'messages',
      short: 'm',
      description:
        'Minimum number of messages to be included in the stats. Default: 50. Use `ignore` to ignore message count',
      bool: false,
    },
    {
      name: 'voice',
      short: 'v',
      description:
        'Minimum hours of VC activity to be included in the stats: Default: 5. Use `ignore` to ignore voice count.',
      bool: false,
    },
  ],
  examples: ['lang -a', 'lang -v ignroe -m 300'],
  normalCommand: async ({ message, server, options, content }) => {
    await message.channel.sendTyping();
    const all = Boolean(options['all']) || content === 'all';
    const messages = options['messages'] as string;
    const voice = options['voice'] as string;
    let members: GuildMember[] = [...server.guild.members.cache.values()];
    let minMessages = 50;
    let minVoiceHours = 5;
    if (!all) {
      if (messages === 'ignore') {
        minMessages = 9999999999;
      } else if (messages) {
        minMessages = parseInt(messages);
        if (isNaN(minMessages)) {
          throw new CommandArgumentError(
            'Please provide an integer for the number of messages'
          );
        }
      }
      if (voice === 'ignore') {
        minVoiceHours = 9999999;
      } else if (voice) {
        minVoiceHours = parseInt(voice);
        if (isNaN(minVoiceHours)) {
          throw new CommandArgumentError(
            'Please provide an integer for the number of hours'
          );
        }
      }
      const minVoiceSeconds = minVoiceHours * 60 * 60;
      const userMessages = getActiveUserMessages({
        guildId: server.guild.id,
        threshold: minMessages,
      });
      const userVoice = getActiveUserVoice({
        guildId: server.guild.id,
        threshold: minVoiceSeconds,
      });
      const userIds = [
        ...new Set([
          ...userMessages.map((u) => u.userId),
          ...userVoice.map((u) => u.userId),


ldborder", literal("get")))
	fun set(distance: Double, time: Int? = null) = fn.addLine(command("worldborder", literal("set"), float(distance), int(time)))
	fun setWarningDistance(distance: Int) = fn.addLine(command("worldborder", literal("warning"), literal("distance"), int(distance)))
	fun setWarningTime(time: Int) = fn.addLine(command("worldborder", literal("warning"), literal("time"), int(time)))
}

val Function.worldBorder get() = WorldBorder(this)
fun Function.worldBorder(block: WorldBorder.() -> Command) = WorldBorder(this).block()
fun Function.worldBorder() = worldBorder.get()
package io.github.ayfri.kore.commands

import io.github.ayfri.kore.arguments.chatcomponents.ChatComponents
import io.github.ayfri.kore.arguments.chatcomponents.PlainTextComponent
import io.github.ayfri.kore.arguments.chatcomponents.textComponent
import io.github.ayfri.kore.arguments.colors.FormattingColor
import io.github.ayfri.kore.arguments.types.ScoreHolderArgument
import io.github.ayfri.kore.arguments.types.literals.bool
import io.github.ayfri.kore.arguments.types.literals.literal
import io.github.ayfri.kore.functions.Function
import io.github.ayfri.kore.serializers.CamelcaseSerializer
import io.github.ayfri.kore.utils.asArg
import kotlinx.serialization.Serializable

@Serializable(Visibility.Companion.NametagVisibilitySerializer::class)
enum class Visibility {
	ALWAYS,
	HIDE_FOR_OTHER_TEAMS,
	HIDE_FOR_OWN_TEAM,
	NEVER;

	companion object {
		data object NametagVisibilitySerializer : CamelcaseSerializer<Visibility>(entries)
	}
}

@Serializable(CollisionRule.Companion.CollisionRuleSerializer::class)
enum class CollisionRule {
	ALWAYS,
	PUSH_OTHER_TEAMS,
	PUSH_OWN_TEAM,
	NEVER;

	companion object {
		data object CollisionRuleSerializer : CamelcaseSerializer<CollisionRule>(entries)
	}
}

class Modify(private val fn: Function, val team: String) {
	fun collisionRule(rule: CollisionRule) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("collisionRule"), literal(rule.asArg())))

	fun color(color: FormattingColor) = fn.addLine(command("team", literal("modify"), literal(team), literal("color"), color))

	fun deathMessageVisibility(visibility: Visibility) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("deathMessageVisibility"), literal(visibility.asArg())))

	fun displayName(name: ChatComponents) = fn.addLine(command("team", literal("modify"), literal(team), literal("displayName"), name))

	fun displayName(name: String, color: FormattingColor? = null, block: PlainTextComponent.() -> Unit = {}) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("displayName"), textComponent(name, color, block)))

	fun friendlyFire(allowed: Boolean) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("friendlyFire"), bool(allowed)))

	fun nametagVisibility(visibility: Visibility) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("nametagVisibility"), literal(visibility.asArg())))

	fun prefix(prefix: ChatComponents) =
		fn.addLine(command("team", literal("modify"), literal(team), literal("prefix"), prefix.asJsonArg()))

	fun prefix(prefix:


-results-attribution,
div.gs-results-attribution * {
  font-size : 10px;
  color : #676767;
  text-decoration : none;
}

div.gs-results-attribution a {
  color: #0000cc;
  cursor : pointer;
}

div.gs-results-attribution a:hover {
  text-decoration : underline;
}

.gs-result .gs-metadata{
  color: #676767;
}

/* searcher specific styling for
 * - web ad
 * - web
 * - local
 * - image (none)
 * - blog (none)
 * - video (none)
 */

/* webAd search specific over rides
 * .gs-ad-marker : disabled in control, but on in green to indicate clipped result is an ad
 */
.gs-localAd img.gs-ad-marker,
.gs-webAd img.gs-ad-marker {
  padding-left: 4px;
}

/* default is to not show long mode visible urls
 * apps should selectively enable this while disabling
 * div.gs-visibleUrl-short
 */
.gs-webResult div.gs-visibleUrl-long,
.gs-promotion div.gs-visibleUrl-long {
  overflow : hidden;
  display : none;
}

/* Per result labels
 */
.gs-webResult div.gs-per-result-labels a.gs-label {
  text-decoration : underline;
  cursor : pointer;
  padding : 3px;
  color : black;
}

.gs-webResult div.gs-per-result-labels a.gs-label.gs-labelActive {
  cursor : default;
  text-decoration : none;
}

/* local search specific over rides
 * - city, region displayed inline
 * - country supressed
 * - small font size for info window's
 */

.gs-localAd div.gs-address * {
  color : #676767;
}

.gs-localAd div.gs-street {
  display: inline;
}

div.gs-city {
  display: inline;
}

div.gs-region {
  display: inline;
}

div.gs-country {
  display: none;
}

div.gs-infoWindow * {
  font-size: 11px;
  }

/* video search specific over rides
 * - align the table data
 * - default image width garuntee
 * - appropriate cell seperation
 */

/* todo(markl): workaround until gre in gmail fixes his styles */
.gs-videoResult * {
  font-size: 13px;
  }

/*
.gs-videoResult td .gs-image {
  vertical-align : middle;
}

.gs-videoResult td.gs-image-box {
  background-color : #000000;
}*/

.gs-videoResult td div.gs-image-box {
  width : 110px;
  height : 78px;
}

.gs-videoResult td div.gs-text-box {
  vertical-align: top;
  margin-left: 4px;
  }

/* book search specific over rides
 * - default image width garuntee
 * - appropriate cell seperation
 */

div.gs-book-image-box td,
.gs-bookResult td {
  vertical-align : top;
}

div.gs-book-image-box,
div.gs-book-image-box div {
  position : static;
  text-align : start;
}

div.gs-book-image-box {
  width : 75px;
  height : 90px;
}

.gs-bookResult td div.gs-text-box {
  vertical-


tal Ocean API might be called `do`.

Each registered API can have a number of named profiles which can be selected via the `-p` or `--rsh-profile` argument. The default profile is called `default`.

Each profile can have a number of preset headers or query parameters, a type of auth, and any auth-specific parameters.

Getting started registering an API is easy and uses an interactive prompt to set up profiles, auth, etc. At a minimum you must provide a short nickname and a base URL:

```bash
# How to register a new API
$ restish api configure $SHORT_NAME $URL

# Register a new API called `example`
$ restish api configure example https://api.rest.sh
```

What exactly does this do? It sets up the API short name `example` to point to `https://api.rest.sh` in a configuration file:

| OS      | Path                                              |
| ------- | ------------------------------------------------- |
| Mac     | `~/Library/Application Support/restish/apis.json` |
| Windows | `%AppData%\restish\apis.json`                     |
| Linux   | `~/.config/restish/apis.json`                     |

If an OAuth2 flow had been configured, the resulting auth token and (optional) refresh token will be cached in another file:

| OS      | Path                                  |
| ------- | ------------------------------------- |
| Mac     | `~/Library/Caches/restish/cache.json` |
| Windows | `%LocalAppData%\restish\cache.json`   |
| Linux   | `~/.cache/restish/cache.json`         |

Restish finds [https://api.rest.sh/openapi.json](https://api.rest.sh/openapi.json) in order to discover available API operations, documentation, parameters, schemas, etc. You can see the available operations via:

```bash
# If an OpenAPI or other API description document was found, this will show
# you all available commands.
$ restish example --help
```

Let's try calling the API:

```bash
# Call an API operation
$ restish example list-images
HTTP/2.0 200 OK
Content-Length: 291
Content-Type: application/cbor
Date: Sun, 24 Apr 2022 15:21:26 GMT
Link: </schemas/ImageItemList.json>; rel="describedby"

[
  {
    format: "jpeg"
    name: "Dragonfly macro"
    self: "/images/jpeg"
  }
  {
    format: "webp"
    name: "Origami under blacklight"
    self: "/images/webp"
  }
  {
    format: "gif"
    name: "Andy Warhol mural in Miami"
    self: "/images/gif"
  }
  {
    format: "png"
    name: "Station in Prague"
    self: "/images/webp"
  }
  {
    format: "heic"
    name: "Chihuly glass in boats"
    self: "/images/heic"
  }
]
```

```bash
# Call the same operation, re-using the same headers & auth
$ restish api.rest.sh/images
```

If you had configured multiple profiles, then something like this would work:

```bash
# Make a request with a non-default profile
$ restish -p my-profile example list-images
```

You can even use the short nickname in place of the full API domain, so for example this works (`example` expands to `https://rest.sh`):

```bash
# Use the API nickname instead of the domain
$ restish example/images
```

Calling operations with required parameters is easy too as they just become arguments:

```bash
# Call with the required image type path parameter
$ restish example get-image jpeg
```

For more details, check out [OpenAPI](open


             let input_string: String = input.iter().collect();
                result = Some(input_string);
                break
            }
        }

        write!(stdout, "{}", termion::cursor::Show).unwrap();
        result
    }

    pub fn read_char() {
        let stdin = stdin();
        let mut stdout = stdout().into_raw_mode().unwrap();

        write!(stdout,
               "{}{}q to exit. Type stuff, use alt, and so on.{}",
               termion::clear::All,
               termion::cursor::Goto(1, 1),
               termion::cursor::Hide)
                .unwrap();
        stdout.flush().unwrap();

        for c in stdin.keys() {
            write!(stdout,
                   "{}{}",
                   termion::cursor::Goto(1, 1),
                   termion::clear::CurrentLine)
                    .unwrap();

            match c.unwrap() {
                Key::Char('q') => break,
                Key::Char(c) => {
                    match c {
                        //' ' => {
                        //    println!("$")
                        //},
                        //'v' => println!("{}im", c),
                        _ => println!("{}", c),
                    }
                }
                Key::Alt(c) => println!("^{}", c),
                Key::Ctrl(c) => println!("*{}", c),
                Key::Esc => println!("ESC"),
                Key::Left => println!("←"),
                Key::Right => println!("→"),
                Key::Up => println!("↑"),
                Key::Down => println!("↓"),
                Key::Backspace => println!("×"),
                _ => {}
            }
            stdout.flush().unwrap();
        }

        write!(stdout, "{}", termion::cursor::Show).unwrap();
    }

   // pub fn display(grid: Grid, width: usize) {
   //     println!("{}", grid.fit_into_width(width))
   //     //let grid = grid.fit_into_width(w));
   //     //if let Some(g) = grid {
   //     //    true
   //     //} else {
   //     //    false
   //     //}
   // }

    pub fn grid(entries: Vec<String>) -> Option<(Grid, usize, usize)> {
        let mut grid = Grid::new(GridOptions {
                filling:     Filling::Spaces(3),
                direction:   Direction::LeftToRight,
        });

        for s in &entries
        {
                grid.add(Cell::from(s.as_str()));
        }

        //let stdout = stdout();
        //let mut stdout = stdout.lock();
        //let stdin = stdin();
        //let mut stdin = stdin.lock();

        let res = terminal_size();
        match res {
          Ok(r) => {
              let w = usize::from(r.0);
              let h = usize::from(r.1);

              Some((grid, w, h))
          },
          Err(_) => {
              None
          }
        }
    }

    pub fn grid_display(entries: Vec<String>) /*Result<(Grid), Error>*/{
        let mut grid = Grid::new(GridOptions {
                filling:     Filling::Spaces(3),
                direction:   Direction::LeftToRight,
        });

        for s in &entries
        {
                grid.add(Cell::from(s.as_str()));
        }

        let (w, _) = terminal_size()/*; match this     */.unwrap();
        /*match (w, h) {
            Ok((w, h)) => {
                let w = usize::from(w);
                let h = usize::from(h);
                grid.fit_into_width(w)
            },
            Err(_) => {
                None
            }
          }
        */

        let w = usize::from(w);

        println!("{}", grid.fit_into_width(w).unwrap());
    }
}

pub mod shell {


.TagNumber(1)
  set duration($core.int v) { $_setSignedInt32(0, v); }
  @$pb.TagNumber(1)
  $core.bool hasDuration() => $_has(0);
  @$pb.TagNumber(1)
  void clearDuration() => clearField(1);

  @$pb.TagNumber(2)
  $core.int get buttonEvent => $_getIZ(1);
  @$pb.TagNumber(2)
  set buttonEvent($core.int v) { $_setSignedInt32(1, v); }
  @$pb.TagNumber(2)
  $core.bool hasButtonEvent() => $_has(1);
  @$pb.TagNumber(2)
  void clearButtonEvent() => clearField(2);

  @$pb.TagNumber(3)
  $core.List<SetInputDeviceTestData_ControllerAnalogEvent> get analogEventList => $_getList(2);
}

class SetTrainerTestData extends $pb.GeneratedMessage {
  factory SetTrainerTestData({
    $core.int? dataMode,
    $core.int? interfaces,
    TestTrainerData? testTrainerData,
  }) {
    final $result = create();
    if (dataMode != null) {
      $result.dataMode = dataMode;
    }
    if (interfaces != null) {
      $result.interfaces = interfaces;
    }
    if (testTrainerData != null) {
      $result.testTrainerData = testTrainerData;
    }
    return $result;
  }
  SetTrainerTestData._() : super();
  factory SetTrainerTestData.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r);
  factory SetTrainerTestData.fromJson($core.String i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromJson(i, r);

  static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'SetTrainerTestData', package: const $pb.PackageName(_omitMessageNames ? '' : 'com.zwift.protobuf'), createEmptyInstance: create)
    ..a<$core.int>(1, _omitFieldNames ? '' : 'dataMode', $pb.PbFieldType.O3, protoName: 'dataMode')
    ..a<$core.int>(2, _omitFieldNames ? '' : 'interfaces', $pb.PbFieldType.O3)
    ..aOM<TestTrainerData>(3, _omitFieldNames ? '' : 'testTrainerData', protoName: 'testTrainerData', subBuilder: TestTrainerData.create)
    ..hasRequiredFields = false
  ;

  @$core.Deprecated(
  'Using this can add significant overhead to your binary. '
  'Use [GeneratedMessageGenericExtensions.deepCopy] instead. '
  'Will be removed in next major version')
  SetTrainerTestData clone() => SetTrainerTestData()..mergeFromMessage(this);
  @$core.Deprecated(
  'Using this can add significant overhead to your binary. '
  'Use [GeneratedMessageGenericExtensions.rebuild] instead. '
  'Will be removed in next major version')
  SetTrainerTestData copyWith(void Function(SetTrainerTestData) updates) => super.copyWith((message) => updates(message as SetTrainerTestData)) as SetTrainerTestData;

  $pb.BuilderInfo get info_ => _i;

  @$core.pragma('dart2js:noInline')
  static SetTrainerTestData create() => SetTrainerTestData._();
  SetTrainerTestData createEmptyInstance() => create();
  static $pb.PbList<SetTrainerTestData> createRepeated() => $pb.PbList<SetTrainerTestData>();
  @$core.pragma('dart2js:noInline')
  static SetTrainerTestData getDefault() => _defaultInstance ??= $pb.GeneratedMessage.$_defaultFor<SetTrainerTestData>(create);
  static SetTrainerTestData? _defaultInstance;

  @$pb.TagNumber(


 +takes_value
            "Hostname backing Redis store runs on [default: localhost]")
        (@arg redis_port: --redis_port +takes_value
            "Port backing Redis store is listening on [default: 6379]")
    ).get_matches();
    let port = value_t!(matches.value_of("port"), u16).unwrap();
    let address = matches.value_of("address").unwrap_or(
        constants::SERVICE_DEFAULT_ADDRESS);
    let redis_host = matches.value_of("redis_host").unwrap_or(
        constants::REDIS_DEFAULT_HOST);
    let redis_port = value_t!(matches.value_of("redis_port"), u16).unwrap_or(
        constants::REDIS_DEFAULT_PORT);

    info!("Creating Redis connection pool");
    let connection_str =
        "redis://".to_string() + redis_host + ":" + &redis_port.to_string();
    let manager = r2d2_redis::RedisConnectionManager::new(
        connection_str.as_ref()).unwrap();
    let config = Default::default();
    let connection_pool = r2d2::Pool::new(config, manager).unwrap();

    service::start_service(connection_pool, address, port);
}
<filename>src/test/ui/stability-attribute/stability-attribute-non-staged-force-unstable.rs
// compile-flags:-Zforce-unstable-if-unmarked

#[unstable()] //~ ERROR: stability attributes may not be used
#[stable()] //~ ERROR: stability attributes may not be used
#[rustc_deprecated()] //~ ERROR: stability attributes may not be used
fn main() { }
#[derive(BorshSchema)]
pub struct Data {
    /// The name of the asset
    pub name: String,
    /// The symbol for the asset
    pub symbol: String,
    /// URI pointing to JSON representing the asset
    pub uri: String,
    /// Royalty basis points that goes to creators in secondary sales (0-10000)
    pub seller_fee_basis_points: u16,
    /// Array of creators, optional
    pub creators: Option<Vec<Creator>>,
}

#[derive(BorshSchema)]
pub struct Creator {
    pub address: Pubkey,
    pub verified: bool,
    pub share: u8,
}

#[derive(BorshSchema)]
pub struct CreateMetadataAccountArgs {
    /// Note that unique metadatas are disabled for now.
    pub data: Data,
    /// Whether you want your metadata to be updateable in the future.
    pub is_mutable: bool,
}
// 自定义结构类型

mod Structures;
mod Enums;
mod UseEnums;
mod CLikeEnums;
mod LinkedList;
mod Constants;

#[cfg(test)]
mod tests {
    #[test]
    fn it_works() {
        assert_eq!(2 + 2, 4);
    }
}
use anyhow::Result;
use std::{path::Path, fs};
use super::cache;
use crate::repos::{errors::RemoveError, config::Config, deb::{package::Info, scripts}};

pub fn remove(config: &Config, name: &str, purge: bool) -> Result<()> {
    if cache::check_installed(config, name).is_some() {
        let info = Info::load(Path::new(&format!("{}/{}", config.info, name)))?;

        if let Some(md5sums) = &info.md5sums {
            // TODO: Remove this workaround
            let mut files = fs::read_to_string(md5sums)?.lines()
                .map(|line| line.split(' '))
                .flatten()
                .filter(|f| f.contains('/'))
                .map(|f| format!("/{}", f))
                .collect::<Vec<_>>();

            if purge {
                println!("Purging {} ...", name);
                if let Some(conffiles) = &info.conffiles {


o the user without any license fee or
 * royalty on an "as is" basis.  The MPEG Software Simulation Group disclaims
 * any and all warranties, whether express, implied, or statuary, including any
 * implied warranties or merchantability or of fitness for a particular
 * purpose.  In no event shall the copyright-holder be liable for any
 * incidental, punitive, or consequential damages of any kind whatsoever
 * arising from the use of these programs.
 *
 * This disclaimer of warranty extends to the user of these programs and user's
 * customers, employees, agents, transferees, successors, and assigns.
 *
 * The MPEG Software Simulation Group does not represent or warrant that the
 * programs furnished hereunder are free of infringement of any third-party
 * patents.
 *
 * Commercial implementations of MPEG-1 and MPEG-2 video, including shareware,
 * are subject to royalty fees to patent holders.  Many of these patents are
 * general enough such that they are unavoidable regardless of implementation
 * design.
 *
 */

const blockSize = 64 // A DCT block is 8x8.

type block [blockSize]int32

const (
	w1 = 2841 // 2048*sqrt(2)*cos(1*pi/16)
	w2 = 2676 // 2048*sqrt(2)*cos(2*pi/16)
	w3 = 2408 // 2048*sqrt(2)*cos(3*pi/16)
	w5 = 1609 // 2048*sqrt(2)*cos(5*pi/16)
	w6 = 1108 // 2048*sqrt(2)*cos(6*pi/16)
	w7 = 565  // 2048*sqrt(2)*cos(7*pi/16)

	w1pw7 = w1 + w7
	w1mw7 = w1 - w7
	w2pw6 = w2 + w6
	w2mw6 = w2 - w6
	w3pw5 = w3 + w5
	w3mw5 = w3 - w5

	r2 = 181 // 256/sqrt(2)
)

// idct performs a 2-D Inverse Discrete Cosine Transformation.
//
// The input coefficients should already have been multiplied by the
// appropriate quantization table. We use fixed-point computation, with the
// number of bits for the fractional component varying over the intermediate
// stages.
//
// For more on the actual algorithm, see Z. Wang, "Fast algorithms for the
// discrete W transform and for the discrete Fourier transform", IEEE Trans. on
// ASSP, Vol. ASSP- 32, pp. 803-816, Aug. 1984.
func idct(src *block) {
	// Horizontal 1-D IDCT.
	for y := 0; y < 8; y++ {
		y8 := y * 8
		// If all the AC components are zero, then the IDCT is trivial.
		if src[y8+1] == 0 && src[y8+2] == 0 && src[y8+3] == 0 &&
			src[y8+4] == 0 && src[y8+5] == 0 && src[y8+6] == 0 && src[y8+7] == 0 {
			dc := src[y8+0] << 3
			src[y8+0] = dc
			src[y8+1] = dc
			src[y8+2] = dc
			src[y8+3] = dc
			src[y8+4] = dc
			src[y8+5] = dc
			src[y8+6] = dc
			src[y8+7] = dc
			continue
		}

		// Prescale.
		x0 := (src[y8+0] << 11) + 128
		x1 := src[y8+4] << 11
		x2 := src[y8+6]
		x3 := src[y8+2]
		x4 := src[y8+1]
		x5 := src[y8+7]
		x6 := src[y8+5]
		x7 := src[y8+3]

		// Stage 1.
		x8 := w7 * (x4 + x5)
		x4 = x8 + w1mw7*x4
		x5 = x8 - w1pw7*x5
		x8 = w3 * (x6 + x7)
		x6 = x8 - w


nt after cur in gotp without updating the cursor.
 */
static inline bool xfs_iext_peek_next_extent(struct xfs_ifork *ifp,
		struct xfs_iext_cursor *cur, struct xfs_bmbt_irec *gotp)
{
	struct xfs_iext_cursor ncur = *cur;

	xfs_iext_next(ifp, &ncur);
	return xfs_iext_get_extent(ifp, &ncur, gotp);
}

/*
 * Return the extent before cur in gotp without updating the cursor.
 */
static inline bool xfs_iext_peek_prev_extent(struct xfs_ifork *ifp,
		struct xfs_iext_cursor *cur, struct xfs_bmbt_irec *gotp)
{
	struct xfs_iext_cursor ncur = *cur;

	xfs_iext_prev(ifp, &ncur);
	return xfs_iext_get_extent(ifp, &ncur, gotp);
}

#define for_each_xfs_iext(ifp, ext, got)		\
	for (xfs_iext_first((ifp), (ext));		\
	     xfs_iext_get_extent((ifp), (ext), (got));	\
	     xfs_iext_next((ifp), (ext)))

extern struct kmem_zone	*xfs_ifork_zone;

extern void xfs_ifork_init_cow(struct xfs_inode *ip);

int xfs_ifork_verify_local_data(struct xfs_inode *ip);
int xfs_ifork_verify_local_attr(struct xfs_inode *ip);

#endif	/* __XFS_INODE_FORK_H__ */


   def unselect(self):
        super().unselect()
        for artist in [self.left_image, self.right_image]:
            if artist is not None:
                artist.remove()

        self.left_image = None
        self.right_image = None

class LigandNode(Node):
    def _make_artist(self, x, y, dx, dy):
        artist = matplotlib.text.Text(x, y, self.node.name, color='blue',
                                      backgroundcolor='white')
        return artist

    def register_artist(self, ax):
        ax.add_artist(self.artist)

    @property
    def extent(self):
        txt = self.artist
        ext = txt.axes.transData.inverted().transform(txt.get_window_extent())
        [[xmin, ymin], [xmax, ymax]] = ext
        return xmin, xmax, ymin, ymax

    @property
    def xy(self):
        return self.artist.get_position()

class AtomMappingNetworkDrawing(GraphDrawing):
    """
    Class for drawing atom mappings from a provided ligang network.

    Parameters
    ----------
    graph : nx.MultiDiGraph
        NetworkX representation of the LigandNetwork
    positions : Optional[Dict[SmallMoleculeComponent, Tuple[float, float]]]
        mapping of node to position
    """
    NodeCls = LigandNode
    EdgeCls = AtomMappingEdge

def plot_atommapping_network(network: LigandNetwork):
    """Convenience method for plotting the atom mapping network

    Parameters
    ----------
    network : :class:`.Network`
        the network to plot

    Returns
    -------
    :class:`matplotlib.figure.Figure` :
        the matplotlib figure containing the iteractive visualization
    """
    return AtomMappingNetworkDrawing(network.graph).fig


apper(fieldMapping(b -> {
            b.field("type", getFieldName());
            b.field("ignore_z_value", true);
        }));
        Mapper fieldMapper = defaultMapper.mappers().getMapper(FIELD_NAME);
        assertThat(fieldMapper, instanceOf(fieldMapperClass()));

        boolean ignoreZValue = ((AbstractGeometryFieldMapper<?>) fieldMapper).ignoreZValue();
        assertThat(ignoreZValue, equalTo(true));

        // explicit false accept_z_value test
        defaultMapper = createDocumentMapper(fieldMapping(b -> {
            b.field("type", getFieldName());
            b.field("ignore_z_value", false);
        }));
        fieldMapper = defaultMapper.mappers().getMapper(FIELD_NAME);
        assertThat(fieldMapper, instanceOf(fieldMapperClass()));

        ignoreZValue = ((AbstractGeometryFieldMapper<?>) fieldMapper).ignoreZValue();
        assertThat(ignoreZValue, equalTo(false));
    }

    @Override
    protected List<ExampleMalformedValue> exampleMalformedValues() {
        return List.of(
            exampleMalformedValue("1234.333").errorMatches("Unknown geometry type: 1234.333"),
            exampleMalformedValue(b -> b.startObject().field("x", 1.3).field("y", "-").endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("x", "-").field("y", 1.3).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("geohash", stringEncode(0, 0)).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue("-,1.3").errorMatches("Unknown geometry type: -"),
            exampleMalformedValue("1.3,-").errorMatches("Unknown geometry type: 1.3"),
            exampleMalformedValue(b -> b.startObject().field("lon", 1.3).field("y", 1.3).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("x", 1.3).field("lat", 1.3).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("x", "NaN").field("y", "NaN").endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("x", "NaN").field("y", 1.3).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().field("x", 1.3).field("y", "NaN").endObject()).errorMatches("Required [type]"),
            exampleMalformedValue("NaN,NaN").errorMatches("Unknown geometry type: nan"),
            exampleMalformedValue("10,NaN").errorMatches("Unknown geometry type: 10"),
            exampleMalformedValue("NaN,12").errorMatches("Unknown geometry type: nan"),
            exampleMalformedValue(b -> b.startObject().field("x", 1.3).nullField("y").endObject()).errorMatches("Required [type]"),
            exampleMalformedValue(b -> b.startObject().nullField("x").field("y", 1.3).endObject()).errorMatches("Required [type]"),
            exampleMalformedValue("Bad shape").errorMatches("Unknown geometry type: bad"),
            exampleMalformedValue(
                "POLYGON ((18.9401790919516 -33.9681188869036, 18.9401790919516 -33.9681188869036, 18.9401790919517 "
                    + "-33.9681188869036, 18.9401790919517 -33.9681188869036, 18.9401790919516 -33.9681188869036))"
            ).errorMatches("at least three non-collinear points required")
        );
    }

    /**
     * Test that doc_values parameter correctly parses
     */
    public void testDocValues() throws IOException {

        DocumentMapper defaultMapper = createDocumentMapper(fieldMapping(b -> {
            b.field("type", getFieldName());
            b.field("doc_values", true);
        }));
        Mapper fieldMapper = defaultMapper.mappers().getMapper(FIELD_NAME);
        assertThat(fieldMapper, instanceOf(fieldMapperClass()));

        boolean hasDocValues = ((AbstractGeometryFieldMapper<?>) fieldMapper).fieldType().hasDocValues


", bt.Time))
	}

	milliseconds := bt.UnixNano() / time.Millisecond.Nanoseconds()
	slot := (milliseconds - 946684800000) / 500

	return e.writeUint32(uint32(slot))
}

func (e *Encoder) writeCurrencyName(currency CurrencyName) (err error) {
	// FIXME: this isn't really used.. we should implement serialization for the Symbol
	// type only instead.
	if tracer.Enabled() {
		zlog.Debug("write currency", zap.String("name", string(currency)))
	}
	out := make([]byte, 7, 7)
	copy(out, []byte(currency))

	return e.toWriter(out)
}

func (e *Encoder) writeAsset(asset Asset) (err error) {
	if tracer.Enabled() {
		zlog.Debug("write asset", zap.Stringer("value", asset))
	}
	e.writeUint64(uint64(asset.Amount))
	e.writeByte(asset.Precision)

	symbol := make([]byte, 7, 7)

	copy(symbol[:], []byte(asset.Symbol.Symbol))
	return e.toWriter(symbol)
}

func (e *Encoder) writeJSONTime(tm JSONTime) (err error) {
	if tracer.Enabled() {
		zlog.Debug("write json time", zap.Time("time", tm.Time))
	}
	return e.writeUint32(uint32(tm.Unix()))
}

func (e *Encoder) writeBlockP2PMessageEnvelope(envelope Packet) (err error) {
	if tracer.Enabled() {
		zlog.Debug("p2p: write message envelope")
	}

	if envelope.P2PMessage != nil {
		buf := new(bytes.Buffer)
		subEncoder := NewEncoder(buf)
		err = subEncoder.Encode(envelope.P2PMessage)
		if err != nil {
			err = fmt.Errorf("p2p message, %s", err)
			return
		}
		envelope.Payload = buf.Bytes()
	}

	messageLen := uint32(len(envelope.Payload) + 1)

	if tracer.Enabled() {
		zlog.Debug("p2p: message length", zap.Uint32("len", messageLen))
	}

	err = e.writeUint32(messageLen)
	if err == nil {
		err = e.writeByte(byte(envelope.Type))

		if err == nil {
			return e.toWriter(envelope.Payload)
		}
	}
	return
}

func (e *Encoder) writeActionData(actionData ActionData) (err error) {
	if actionData.Data != nil {
		//if reflect.TypeOf(actionData.Data) == reflect.TypeOf(&ActionData{}) {
		//	log.Fatal("pas cool")
		//}

		if tracer.Enabled() {
			zlog.Debug("entering action data", typeField("type", actionData))
		}
		var d interface{}
		d = actionData.Data
		if reflect.TypeOf(d).Kind() == reflect.Ptr {
			d = reflect.ValueOf(actionData.Data).Elem().Interface()
		}

		if reflect.TypeOf(d).Kind() == reflect.String { //todo : this is a very bad ack ......
			data, err := hex.DecodeString(d.(string))
			if err != nil {
				return fmt.Errorf("ack, %s", err)
			}
			e.writeByteArray(data)
			return nil

		}

		if tracer.Enabled() {
			zlog.Debug("encoding action data", typeField("type", d))
		}
		raw, err := MarshalBinary(d)
		if err != nil {
			return err
		}
		if tracer.Enabled() {
			zlog.Debug("writing action data", typeField("type", d))
		}
		return e.writeByteArray(raw)
	}

	return e.writeByteArray(actionData.HexData)
}

// lt evaluates the comparison a < b.
//
// Copied from text/


f, temp_df], ignore_index=True)
    big_df.columns = [item[1] for item in data_json["config"]["all"]]
    for item in big_df.columns[2:]:
        big_df[item] = pd.to_numeric(big_df[item], errors="coerce")
    return big_df

def macro_china_supply_of_money() -> pd.DataFrame:
    """
    新浪财经-中国宏观经济数据-货币供应量
    https://finance.sina.com.cn/mac/#fininfo-1-0-31-1
    :return: 货币供应量
    :rtype: pandas.DataFrame
    """
    url = "https://quotes.sina.cn/mac/api/jsonp_v3.php/SINAREMOTECALLCALLBACK1601651495761/MacPage_Service.get_pagedata"
    params = {
        "cate": "fininfo",
        "event": "1",
        "from": "0",
        "num": "31",
        "condition": "",
    }
    r = requests.get(url, params=params)
    data_text = r.text
    data_json = demjson.decode(data_text[data_text.find("{") : -3])
    page_num = math.ceil(int(data_json["count"]) / 31)
    big_df = pd.DataFrame(data_json["data"])
    tqdm = get_tqdm()
    for i in tqdm(range(1, page_num)):
        params.update({"from": i * 31})
        r = requests.get(url, params=params)
        data_text = r.text
        data_json = demjson.decode(data_text[data_text.find("{") : -3])
        temp_df = pd.DataFrame(data_json["data"])
        big_df = pd.concat(objs=[big_df, temp_df], ignore_index=True)
    big_df.columns = [item[1] for item in data_json["config"]["all"]]
    for item in big_df.columns[1:]:
        big_df[item] = pd.to_numeric(big_df[item], errors="coerce")
    return big_df

def macro_china_foreign_exchange_gold() -> pd.DataFrame:
    """
    央行黄金和外汇储备
    https://finance.sina.com.cn/mac/#fininfo-5-0-31-2
    :return: 央行黄金和外汇储备
    :rtype: pandas.DataFrame
    """
    url = "https://quotes.sina.cn/mac/api/jsonp_v3.php/SINAREMOTECALLCALLBACK1601651495761/MacPage_Service.get_pagedata"
    params = {
        "cate": "fininfo",
        "event": "5",
        "from": "0",
        "num": "31",
        "condition": "",
    }
    r = requests.get(url, params=params)
    data_text = r.text
    data_json = demjson.decode(data_text[data_text.find("{") : -3])
    page_num = math.ceil(int(data_json["count"]) / 31)
    big_df = pd.DataFrame(data_json["data"])
    tqdm = get_tqdm()
    for i in tqdm(range(1, page_num), leave=False):
        params.update({"from": i * 31})
        r = requests.get(url, params=params)
        data_text = r.text
        data_json = demjson.decode(data_text[data_text.find("{") : -3])
        temp_df = pd.DataFrame(data_json["data"])
        big_df = pd.concat(objs=[big_df, temp_df], ignore_index=True)
    big_df.columns = [item[1] for item in data_json["config"]["all"]]
    big_df.sort_values(by=["统计时间"], ignore_index=True, inplace=True)
    big_df["黄金储备"] = pd.to_numeric(big_df["黄金储备"], errors="coerce")
    big_df["国家外汇储备"] = pd.to_numeric(big_df["国家外汇储备"], errors="coerce")
    return big_df

def macro_china_retail_price_index() -> pd.DataFrame:
    """
    商品零售价格指数
    https://finance.sina.com.cn/mac/#price-12-0-31-1
    :return: 商品零售价格指数
    :rtype: pandas.DataFrame
    """
    url = "https://quotes.sina.cn/mac/api/jsonp_v3.php/SINAREMOTECALLCALLBACK1601651495761/MacPage_Service.get_pagedata"
    params = {
        "cate": "price",
        "event": "12",
        "from": "0",
        "num": "31",
        "condition": "",
    }
    r = requests.get(url, params=params)
    data_text = r.text
    data_json = demjson.decode(data_text[data_text.find("{") : -3])
    page_num = math.ceil(int(data_json["count"]) / 31)
    big_df = pd.DataFrame(data_json["data"])
    tqdm = get_tqdm()
    for i in tqdm(range(1, page_num), leave=False):
        params.update({"from": i * 31})
        r = requests.get(url, params=params)
        data_text = r.text
        data_json = demjson.decode(data_text[data_text.find("{") : -3])
        temp_df = pd.DataFrame(data_json["data"])
        big_df = pd.concat(objs=[big_df, temp_df], ignore_index=True)
    big_df.columns = [item[1] for item in data_json["config"]["all"]]
    big_df.sort_values(by=["统计月份"], ignore_index=True, inplace=True)
    big_df["零售商品价格指数"] = pd.to_numeric(
        big_df["零售商品价格指数"], errors="coerce"
    )
    return big_df

def macro_china_real_estate() -> pd.DataFrame:
    """
    国房景气指数
    https://data.eastmoney.com/cjsj/hyzs_list_EMM00121987.html
    :return: 国房景气指数
    :rtype: pandas.DataFrame
    """
    url = "https://datacenter-web.eastmoney.com/api/data/v1/get"
    headers = {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko


Args[2][0]], exts[cs.Args[3][0]])
		case "Ext2Felt":
			out := fieldAPI.Ext2Felt(exts[cs.Args[4][0]])
			for i := 0; i < 4; i++ {
				felts[cs.Args[i][0]] = out[i]
			}
		case "AssertEqV":
			api.AssertIsEqual(vars[cs.Args[0][0]], vars[cs.Args[1][0]])
		case "AssertEqF":
			fieldAPI.AssertIsEqualF(felts[cs.Args[0][0]], felts[cs.Args[1][0]])
		case "AssertNeF":
			fieldAPI.AssertNotEqualF(felts[cs.Args[0][0]], felts[cs.Args[1][0]])
		case "AssertEqE":
			fieldAPI.AssertIsEqualE(exts[cs.Args[0][0]], exts[cs.Args[1][0]])
		case "PrintV":
			api.Println(vars[cs.Args[0][0]])
		case "PrintF":
			f := fieldAPI.ReduceSlow(felts[cs.Args[0][0]])
			api.Println(f.Value)
		case "PrintE":
			e := fieldAPI.ReduceE(exts[cs.Args[0][0]])
			api.Println(e.Value[0].Value)
			api.Println(e.Value[1].Value)
			api.Println(e.Value[2].Value)
			api.Println(e.Value[3].Value)
		case "WitnessV":
			i, err := strconv.Atoi(cs.Args[1][0])
			if err != nil {
				panic(err)
			}
			vars[cs.Args[0][0]] = circuit.Vars[i]
		case "WitnessF":
			i, err := strconv.Atoi(cs.Args[1][0])
			if err != nil {
				panic(err)
			}
			felts[cs.Args[0][0]] = circuit.Felts[i]
		case "WitnessE":
			i, err := strconv.Atoi(cs.Args[1][0])
			if err != nil {
				panic(err)
			}
			exts[cs.Args[0][0]] = circuit.Exts[i]
		case "CommitVkeyHash":
			element := vars[cs.Args[0][0]]
			api.AssertIsEqual(circuit.VkeyHash, element)
		case "CommitCommitedValuesDigest":
			element := vars[cs.Args[0][0]]
			api.AssertIsEqual(circuit.CommittedValuesDigest, element)
		case "CircuitFelts2Ext":
			exts[cs.Args[0][0]] = babybear.Felts2Ext(felts[cs.Args[1][0]], felts[cs.Args[2][0]], felts[cs.Args[3][0]], felts[cs.Args[4][0]])
		case "CircuitFelt2Var":
			vars[cs.Args[0][0]] = fieldAPI.ReduceSlow(felts[cs.Args[1][0]]).Value
		case "ReduceE":
			exts[cs.Args[0][0]] = fieldAPI.ReduceE(exts[cs.Args[0][0]])
		default:
			return fmt.Errorf("unhandled opcode: %s", cs.Opcode)
		}
	}

	return nil
}
package mlkem

// #include "../../libs/opengm_pqc.h"
import "C"

import (
	"crypto/rand"
	"fmt"
	"io"
	"runtime"
	"unsafe"

	_ "github.com/opengm-libs/opengm_pqc/goapi"
)

const EncapKeySize768 = 1184
const DecapKeySize768 = 2400
const CipherSize768 = 1088

type Mlkem768DecapKey struct {
	p unsafe.Pointer
}

type Mlkem768EncapKey


   */
  void add_model_to_solver(expr::model::ref m, size_t start, size_t end, smt::solver* solver, smt::solver::formula_class c);

  /**
   * As above, just add variables to the output.
   */
  void add_vars(size_t start, size_t end, std::vector<expr::term_ref>& out);

  /**
   * Add model to the trace (model over trace variables), for frames
   * start, ..., end. All other model variables will not be added.
   */
  void set_model(expr::model::ref m, size_t start, size_t end);

  /**
   * Check if formula is false in given frame.
   */
  bool is_true_in_frame(size_t frame, expr::term_ref f, expr::model::ref model);

  /**
   * Check if formula is true in given frame.
   */
  bool is_false_in_frame(size_t frame, expr::term_ref f, expr::model::ref model);

  /**
   * Output the trace to the stream.
   */
  void to_stream(std::ostream& out) const;

  /** Collect the terms */
  void gc_collect(const expr::gc_relocator& gc_reloc);

};

std::ostream& operator << (std::ostream& out, const trace_helper& trace);

}
}


, коли це можливо';
			case 'settings.accent_color': return 'Колір акценту';
			case 'settings.accent_color_descr': return 'Виберіть колір, який додаток буде використовувати для виділення певних частин інтерфейсу';
			case 'settings.security.title': return 'Безпека';
			case 'settings.security.private_mode_at_launch': return 'Приватний режим під час запуску';
			case 'settings.security.private_mode_at_launch_descr': return 'За замовчуванням запускати програму в приватному режимі';
			case 'settings.security.private_mode': return 'Приватний режим';
			case 'settings.security.private_mode_descr': return 'Приховати всі грошові значення';
			case 'settings.security.private_mode_activated': return 'Приватний режим активовано';
			case 'settings.security.private_mode_deactivated': return 'Приватний режим вимкнено';
			case 'more.title': return 'Більше';
			case 'more.title_long': return 'Більше дій';
			case 'more.data.display': return 'Дані';
			case 'more.data.display_descr': return 'Експортуйте та імпортуйте свої дані, щоб нічого не втратити';
			case 'more.data.delete_all': return 'Видалити мої дані';
			case 'more.data.delete_all_header1': return 'Зупиніться, молодий падаване ⚠⚠';
			case 'more.data.delete_all_message1': return 'Ви впевнені, що хочете продовжити? Всі ваші дані буде остаточно видалено і не може бути відновлено';
			case 'more.data.delete_all_header2': return 'Останній крок ⚠⚠';
			case 'more.data.delete_all_message2': return 'Видаляючи обліковий запис, ви видалите всі ваші збережені особисті дані. Ваші облікові записи, транзакції, бюджети та категорії будуть видалені і не можуть бути відновлені. Ви згодні?';
			case 'more.about_us.display': return 'Інформація про додаток';
			case 'more.about_us.description': return 'Перегляньте умови та іншу важливу інформацію про Monekin. Зв\'яжіться зі спільнотою, повідомте про помилки, залиште пропозиції ...';
			case 'more.about_us.legal.display': return 'Юридична інформація';
			case 'more.about_us.legal.privacy': return 'Політика конфіденційності';
			case 'more.about_us.legal.terms': return 'Умови використання';
			case 'more.about_us.legal.licenses': return 'Ліцензії';
			case 'more.about_us.project.display': return 'Проект';
			case 'more.about_us.project.contributors': return 'Співробітники';
			case 'more.about_us.project.contributors_descr': return 'У