:vec3 up(0.0f, 1.0f, 0.0f);
	glm::vec3 forward = m_Camera->GetDirection();
	glm::vec3 right = glm::normalize(glm::cross(forward, up));

	glm::ivec3 inputDir(0);
	inputDir.x = Input::KeyPressed(m_Controls[Control::Right])
			   - Input::KeyPressed(m_Controls[Control::Left]);
	inputDir.y = Input::KeyPressed(m_Controls[Control::Up])
			   - Input::KeyPressed(m_Controls[Control::Down]);
	inputDir.z = Input::KeyPressed(m_Controls[Control::Forward])
			   - Input::KeyPressed(m_Controls[Control::Backward]);

	if(moved = (inputDir.x || inputDir.y || inputDir.z)) {
		glm::vec3 moveDir(0.0f);
		moveDir += (float)inputDir.x * right;
		moveDir += (float)inputDir.y * up;
		moveDir += (float)inputDir.z * forward;
		float moveSpeed = TranslationSpeed * 0.001f;
		finalPos += glm::normalize(moveDir) * moveSpeed * (float)ts;
	}

	if(moved |= (delta != glm::vec2(0.0f) && RotationSpeed != 0.0f)) {
		float pitchDelta = delta.y * RotationSpeed;
		float yawDelta   = delta.x * RotationSpeed;

		glm::quat q = glm::cross(glm::angleAxis(-pitchDelta, right),
								 glm::angleAxis(-yawDelta, up));
		finalDir = glm::rotate(glm::normalize(q), forward);
	}

	if(moved)
		m_Camera->SetPositionDirection(finalPos, finalDir);
}

}// #include "Font.h"

// #include <stb_image/stb_image.h>

// namespace VolcaniCore {

// Font::Font(const std::string& font_path, uint32_t width, uint32_t height)
// 	: FontPath(font_path)
// {
// 	if(FT_New_Face(Font::s_FT, font_path.c_str(), 0, &m_Face))
// 	{
// 		SADDLE_CORE_LOG_ERROR("Failed to load font. Path: %s", font_path.c_str());
// 	}

// 	glPixelStorei(GL_UNPACK_ALIGNMENT, 1);

// 	m_Quads.reserve(128);

// 	SetSize(width, height);
// }

// Font::~Font()
// {
// 	FT_Done_Face(m_Face);

// 	DeleteCharacters();
// }

// void Font::DeleteCharacters()
// {
// 	for(const auto& [_, quad] : m_Quads)
// 		delete quad;
// }

// void Font::UpdateCharacters()
// {
// 	DeleteCharacters();

// 	for(unsigned char c = 0; c < 128; c++)
// 	{
// 		if(FT_Load_Char(m_Face, c, FT_LOAD_RENDER))
// 		{
// 			SADDLE_CORE_LOG_ERROR("Failed to load glyph: %s", c);
// 		}

// 		uint32_t w = m_Face->glyph->bitmap.width, h = m_Face->glyph->bitmap.rows;

// 		uint32_t texture_id;
// 		glGenTextures(1, &texture_id);
// 		glBindTexture(GL_TEXTURE_2D, texture_id);
// 		glTexImage2D(GL_TEXTURE_2D, 0, GL_RED, w, h, 0, GL_RED, GL_UNSIGNED_BYTE, m_Face->glyph->bitmap.buffer);

// 		glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
// 		glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
// 		glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE


18);
    path_3.lineTo(6.25995, 241.918);
    path_3.lineTo(6.25995, 310.765);
    path_3.lineTo(4.1733, 310.765);
    path_3.cubicTo(1.86845, 310.765, 0, 308.897, 0, 306.592);
    path_3.lineTo(0, 246.091);
    path_3.close();

    final paint_3_fill = Paint()..style = PaintingStyle.fill;
    paint_3_fill.color = const Color(0xff121515);
    canvas.drawPath(path_3, paint_3_fill);

    final path_4 = Path();
    path_4.moveTo(6.25977, 133.434);
    path_4.cubicTo(6.25977, 60.8448, 65.116, 2, 137.719, 2);
    path_4.lineTo(753.281, 2);
    path_4.cubicTo(825.884, 2, 884.74, 60.8448, 884.74, 133.434);
    path_4.lineTo(884.74, 1660.57);
    path_4.cubicTo(884.74, 1733.16, 825.884, 1792, 753.281, 1792);
    path_4.lineTo(137.719, 1792);
    path_4.cubicTo(65.116, 1792, 6.25977, 1733.16, 6.25977, 1660.57);
    path_4.lineTo(6.25977, 133.434);
    path_4.close();

    final paint_4_fill = Paint()..style = PaintingStyle.fill;
    paint_4_fill.color = const Color(0xff3A4245);
    canvas.drawPath(path_4, paint_4_fill);

    final path_5 = Path();
    path_5.moveTo(16.6934, 133.433);
    path_5.cubicTo(16.6934, 66.6058, 70.8785, 12.4312, 137.719, 12.4312);
    path_5.lineTo(753.281, 12.4312);
    path_5.cubicTo(820.122, 12.4312, 874.307, 66.6058, 874.307, 133.433);
    path_5.lineTo(874.307, 1660.57);
    path_5.cubicTo(874.307, 1727.39, 820.122, 1781.57, 753.281, 1781.57);
    path_5.lineTo(137.719, 1781.57);
    path_5.cubicTo(70.8785, 1781.57, 16.6934, 1727.39, 16.6934, 1660.57);
    path_5.lineTo(16.6934, 133.433);
    path_5.close();

    final paint_5_fill = Paint()..style = PaintingStyle.fill;
    paint_5_fill.color = const Color(0xff121515);
    canvas.drawPath(path_5, paint_5_fill);

    final path_6 = Path();
    path_6.moveTo(365.164, 118.83);
    path_6.cubicTo(365.164, 115.373, 367.966, 112.571, 371.423, 112.571);
    path_6.lineTo(519.577, 112.571);
    path_6.cubicTo(523.034, 112.571, 525.836, 115.373, 525.836, 118.83);
    path_6.lineTo(525.836, 118.83);
    path_6.cubicTo(525.836, 122.286, 523.034, 125.089, 519.577, 125.089);
    path_6.lineTo(371.423, 125.089);
    path_6.cubicTo(367.966, 125.089, 365.164, 122.286, 365.164, 118.83);
    path_6.lineTo(36


esultTableContainer table.dbsources table.inner td.value img.fasta {
    vertical-align: top !important;
    margin-top: 1px !important;
}

.keywordSearchResults .resultTableContainer table.dbsources table.inner tr {
    border: 0;
    margin: 0;
    padding: 0;
}

.keywordSearchResults .resultTableContainer table.dbsources div.objectKeys a {
    color: #E94F00;
    font-size: 16px;
}

.keywordSearchResults .resultTableContainer table.dbsources div.objectKeys span.objectKey {
    margin: 0 !important;
}

.keywordSearchResults .resultTableContainer table.dbsources div.objectKeys span.divider {
    margin: 0 4px;
    font-size: 8px;
    vertical-align: middle;
    color: #1F7492;
}

/* keyword search results relevancy */
div.resultTableContainer td.relevance {
    width: 60px;
}

div.resultTableContainer td.relevance div.bullet {
    letter-spacing: 0.3px;
    font-size: 14px;
    display: inline;
}

div.resultTableContainer td.relevance div.full {
    color: #E94F00;
}

div.resultTableContainer td.relevance div.empty {
    color: #999999;
}

h3.facetHeader {
    text-decoration: none !important;
}

/* keyword search index */
div.keywordSearchIndex {
    border: 1px solid #C1DAD7 !important;
    background: #E6F7FE !important;
    color: #333;
}

div.keywordSearchIndex h2, div.keywordSearchIndex a {
    color: #333;
}

div.keywordSearchIndex a:hover {
    color: #000;
}

/* keyword search form */
div.keywordSearch {
  margin-left:auto; margin-right:auto;
  width:940px;
}

div.keywordSearch div.form {
    background: #FFFBD8;
    border: 1px solid #E3D85A;
    width: 500px;
    float: left;
}

div.keywordSearch div.form h2 { /*color:#4D5154;*/
    font-size: 22px;
    padding: 10px;
}

div.keywordSearch div.form a {
    margin-top: 20px;
}

div.keywordSearch div.examples {
    border: 1px solid /*#C1DAD7*/ #DFDFDF;
    background: /*#E6F7FE*/ #FFF;
    padding: 0 6px 0 10px;
    float: left;
    margin: 0 0 0 20px;
    width: 400px;
}

div.keywordSearch div.examples h4 {
    background: url("../images/icons/information-32.png") no-repeat left;
    padding-left: 40px;
    margin: 0;
    margin-bottom: 10px;
    color: #FB641E;
    border-bottom: 1px solid #DFDFDF;
    line-height: 40px;
    font-size: 16px;
}

div.keywordSearch div.examples ul {
    list-style: square;
    margin-left: 14px;
}

div.keywordSearch div.examples ul li {
    margin-bottom: 6px;
}

div.keywordSearch div.form form input[type =
"text"] {
    padding: 4px 2px;
    font-size: 14px;
  width:460px;
  margin-bottom:4px;
}

div.keywordSearch div.form form input[type = "submit"] {
    float:right; margin:0 16px 14px 0;
}

div.keywordSearch div.form form span, div.keywordSearch div.form form a { line-height:24px; }

div.keywordSearch div.form form span { float:right; margin-right:18px; }

div.keywordSearch div.form form a { float:left; margin:0 0 0 16px; }

/* lists view */
select#


t values, identical",
        "args": (
            list_to_treenode([-100, 0, 100]),
            list_to_treenode([-100, 0, 100]),
        ),
        "expected": True,
    },
    {
        "name": "Trees with max/min constraint values, different",
        "args": (
            list_to_treenode([-100, 0, 100]),
            list_to_treenode([-100, 0, 99]),
        ),
        "expected": False,
    },
    {
        "name": "Longer identical trees with mixed nulls",
        "args": (
            list_to_treenode([5, 4, 7, 3, None, 6, 8, None, 2]),
            list_to_treenode([5, 4, 7, 3, None, 6, 8, None, 2]),
        ),
        "expected": True,
    },
    {
        "name": "Longer different trees with mixed nulls (value mismatch)",
        "args": (
            list_to_treenode([5, 4, 7, 3, None, 6, 8, None, 2]),
            list_to_treenode([5, 4, 7, 3, None, 6, 8, None, 99]),
        ),
        "expected": False,
    },
    {
        "name": "Longer different trees with mixed nulls (structure mismatch)",
        "args": (
            list_to_treenode([5, 4, 7, 3, None, 6, 8, None, 2]),
            list_to_treenode(
                [5, 4, 7, 3, None, 6, 8, 2]
            ),  # Missing one 'None' for structure
        ),
        "expected": False,
    },
    {
        "name": "Only left child, same",
        "args": (list_to_treenode([1, 2]), list_to_treenode([1, 2])),
        "expected": True,
    },
    {
        "name": "Only right child, same",
        "args": (list_to_treenode([1, None, 2]), list_to_treenode([1, None, 2])),
        "expected": True,
    },
    {
        "name": "Only left child vs only right child, different",
        "args": (list_to_treenode([1, 2]), list_to_treenode([1, None, 2])),
        "expected": False,
    },
]

# DEFAULT_TIMEOUT is optional. Constraints are small, so not strictly necessary.
# DEFAULT_TIMEOUT = 1.0


import random

from mmf.datasets.builders.vqa2.dataset import VQA2Dataset

class MaskedQVQA2Dataset(VQA2Dataset):
    def __init__(self, *args, **kwargs):
        super().__init__(*args, **kwargs)
        self.dataset_name = "masked_q_vqa2"

    def add_answer_info(self, sample_info, current_sample):
        length = min(len(current_sample.text), current_sample.text_len)
        index = random.randint(0, length - 1)

        word = self.text_processor.vocab.get_itos()[current_sample.text[index].item()]
        current_sample.text[index] = self.text_processor.vocab.get_stoi()["<mask>"]
        answer_processor_arg = {"answers": [word]}

        processed_soft_copy_answers = self.answer_processor(answer_processor_arg)

        current_sample.answers = processed_soft_copy_answers["answers"]
        current_sample.targets = processed_soft_copy_answers["answers_scores"]

        if self.answer_processor.word2idx(word) == self.answer_processor.word2idx(
            "<unk>"
        ):
            current_sample.targets.zero_()
        return current_sample


> {
    let mut exe_folder = env::current_exe()?;
    exe_folder.pop();
    Ok(exe_folder)
}

/**
 *TODO: comment about return value.
 */
fn know_file_state(_filename: &str, client: &reqwest::blocking::Client, id: &str, key: &str) -> Result<FileState,reqwest::Error>  {

    let url = format! ("{}/{}",DEEPL_ENDPOINT , id);

    let params = [("auth_key",DEEPL_KEY),("document_key",key)];

    let resp = client.post(&url)
    .form(&params)
    .send();

    match resp {
        //HTTP request was successful
        Ok(v) =>{
            //deserialize JSON.
            let state = v.json::<FileState>();
            match state {
                Ok(v) => return Ok(v),
                Err(e) => return Err(e)
            }
        },
        //propagate HTTP error
        Err(e) => return Err(e)
    }
}

fn download_file(_filename: &str, client: &reqwest::blocking::Client, id: &str, key: &str) -> Result<Bytes,reqwest::Error>{
    let url = format! ("{}/{}/result",DEEPL_ENDPOINT , id);

    let params = [("auth_key",DEEPL_KEY),("document_key",key)];

    let resp = client.post(&url)
    .form(&params)
    .send();

    match resp {
        Ok(v) => {
            let content = v.bytes();
            match content {
                Ok(v)=> Ok(v),
                Err(e) => Err(e),
            }
        },
        Err(e) => {
            return Err(e);
        }
    }
}

fn create_file(file_path: &PathBuf, content:Bytes, _language:&str) -> Result<(),Error>{
    let folder = file_path.parent().unwrap();
    match fs::create_dir_all(folder) {
        Ok(_) => (),
        Err(e) => return Err(e),
    }
    let file = File::create(file_path);
    match file {
        Ok(mut v) => {
            match v.write_all(&content) {
                Ok(_) => return Ok(()),
                Err(e) => return Err(e),
            }
        },
        Err(e) => return Err(e),
    }
}<reponame>rodrimati1992/konst
#[doc(hidden)]
#[repr(C)]
pub union Dereference<'a, T: ?Sized> {
    pub ptr: *const T,
    pub reff: &'a T,
}

#[cfg(feature = "mut_refs")]
mod mut_refs {
    use core::mem::ManuallyDrop;

    #[doc(hidden)]
    #[repr(C)]
    pub(crate) union BorrowMut<'a, T: ?Sized> {
        ptr: *mut T,
        reff: ManuallyDrop<&'a mut T>,
    }

    pub(crate) const unsafe fn deref_raw_mut_ptr<'a, T: ?Sized>(ptr: *mut T) -> &'a mut T {
        ManuallyDrop::into_inner(BorrowMut { ptr }.reff)
    }
}

#[cfg(feature = "mut_refs")]
pub(crate) use mut_refs::{deref_raw_mut_ptr, BorrowMut};
table! {
    urls (id) {
        id -> Integer,
        url -> Text,
        created -> Text,
        accessed -> Text,
        hits -> Integer,
    }
}
#[derive(Clone, Debug, Eq, Hash, PartialEq)]
pub(super) struct Rule {
    name: String,
    ranges: Vec<(i32, i32)>,
}

impl Rule {
    pub(super) fn new<I, J>(name: I, ranges: J) -> Self
    where
        I: Into<String>,
        J: Into<Vec<(i32, i32)>>,
    {
        Self {
            name: name.into(),
            ranges: ranges.into(),
        }
    }

    pub(super) fn is_valid_value(&self, value: i32) -> bool {
        for (low, high) in &self.ranges {
            if *low <= value && value <= *high {
                return true;
            }
        }

        false
    }

    pub(super) fn name(&self) -> &str {
        &self.name
    }
}

#[derive(Debug, PartialEq)]
pub(super) struct Ticket {
    values: Vec<i32>,
}

impl Ticket {
    pub(super) fn new<I>(values: I) -> Self
    where
        I: Into<Vec<i32>>,
    {
        Self {
            values: values.into(),
        }
    }

    pub(super) fn is_valid_for_any_rule(&self, rules: &[Rule]) -> (bool, i32) {
        let result =


			; store loop freq int.w/frac.w
		RTS

; Make that buffer! (channels are paired together!)

Goforit		PEA (A4)			; save buff ptr
channels12	MOVE.L Voice1Set(PC),A0		; ptr to end of each sample!
		MOVE.L Voice2Set(PC),A1
		MOVE.L Voice1Set+Vfrac(PC),D0	; frac.w/int.w offset
		MOVE.L Voice2Set+Vfrac(PC),D1
		MOVE.L Voice1Set+Vfreq(PC),A2	; frac.w/int.w freq
		MOVE.L Voice2Set+Vfreq(PC),A3
		MOVE.W fillx1(PC),D6
		BSR add12			; fill first bit
		MOVE.W fillx2(PC),D6
		MOVE.W fillx1(PC),D4
		BEQ.S .nores
		LEA.L buffer(pc),A4		; (overlap case)
.nores		BSR add12			; and do remaining
		LEA ch1s(PC),A3
		NEG.W D0			; +ve offset(as original!)
		MOVE.L A0,sam_start(A3)		; store voice address
		MOVE.W D0,sam_length(A3)	; store offset for next time
		SWAP D0
		MOVE.W D0,sam_frac(A3)		; store frac part
		LEA ch2s(PC),A3
		NEG.W D1
		MOVE.L A1,sam_start(A3)		; same for chan 2
		MOVE.W D1,sam_length(A3)
		SWAP D1
		MOVE.W D1,sam_frac(A3)
		MOVE.L (SP)+,A4

		LEA $802(A4),A4

channels34	MOVE.L Voice3Set(PC),A0		; ptr to end of each sample!
		MOVE.L Voice4Set(PC),A1
		MOVE.L Voice3Set+Vfrac(PC),D0	; frac.w/int.w offset
		MOVE.L Voice4Set+Vfrac(PC),D1
		MOVE.L Voice3Set+Vfreq(PC),A2
		MOVE.L Voice4Set+Vfreq(PC),A3	; frac.w/int.w freq
		MOVE.W fillx1(PC),D6
		BSR add34			; fill first bit
		MOVE.W fillx2(PC),D6
		MOVE.W fillx1(PC),D4
		BEQ.S .nores
		LEA.L buffer1(pc),A4		; (overlap case)
.nores		BSR add34			; and do remaining
		LEA ch3s(PC),A3
		NEG.W D0
		MOVE.L A0,sam_start(A3)
		MOVE.W D0,sam_length(A3)	; as above
		SWAP D0
		MOVE.W D0,sam_frac(A3)
		LEA ch4s(PC),A3
		NEG.W D1
		MOVE.L A1,sam_start(A3)
		MOVE.W D1,sam_length(A3)
		SWAP D1
		MOVE.W D1,sam_frac(A3)
		RTS

; Move channels 1 and 2 to the buffer.

add12		SUBQ #1,D6			; -1 (dbf)
		BMI exitadd12			; none to do!?
.make_chans1_2	TRAP #12
		MOVEQ #0,D4
		MOVE.L voltab_ptr(PC),D2
		MOVE.W Voice1Set+Vvoltab(PC),D4
		ADD.L D4,D2			; volume tab chan


  sessionId?: string;
  username?: string;
  key: string;
  signatureScheme: string;
};

export default class Session {
  readonly sessionId: string;
  readonly username: string;
  readonly key: string;
  readonly hmacAlg: string;

  private msgCount: number;

  constructor(config: SessionConfig) {
    this.sessionId = config.sessionId || uuid4();
    this.username = config.username || os.userInfo().username;
    this.key = config.key;
    this.msgCount = 0;

    const [_, alg] = config.signatureScheme.split('hmac-');

    if (!alg) {
      throw `Unknown signature scheme: ${config.signatureScheme}. Scheme must be in format "hmac-[algorithm]. E.g. "hmac-sha256"`;
    }

    this.hmacAlg = alg;
  }

  createMsgId() {
    return `${this.sessionId}_${++this.msgCount}`;
  }

  createMsg<ContentType={}>(msgType: string, content: ContentType, parentHeader: MsgHeader | {} = {}) {
    const msgId = this.createMsgId();
    const delimiter = KernelMessage.standardDelimiter;
    const header = KernelMessage.createHeader(msgId, msgType, this.username, this.sessionId);

    console.debug({
      identity: `client.${this.sessionId}.${msgType}`,
      delimiter,
      header,
      parent_header: parentHeader,
      metadata: {},
      content
    });

    return this.pack({
      identity: `client.${this.sessionId}.${msgType}`,
      delimiter,
      header,
      parent_header: parentHeader,
      metadata: {},
      content
    });
  }

  sign<ContentType={}>(msg: UnsignedKernelMessage<ContentType>): string {
    const hash = crypto.createHmac(this.hmacAlg, this.key);

    [msg.header, msg.parent_header, msg.metadata, msg.content].forEach(
      p => hash.update(JSON.stringify(p))
    );

    return hash.digest('hex');
  }

  pack<ContentType={}>(msg: UnsignedKernelMessage<ContentType>): Buffer[] {
    return [
      msg.identity,
      msg.delimiter,
      this.sign(msg),
      JSON.stringify(msg.header),
      JSON.stringify(msg.parent_header),
      JSON.stringify(msg.metadata),
      JSON.stringify(msg.content),
    ].map(part => Buffer.from(part, 'utf-8'));
  }

  unpack<ContentType={}>(...msgs: Buffer[]): KernelMessage<ContentType> {
    const messages = msgs.map(msg => msg.toString('utf-8'));
    const [identity, delimiter, signature, header, parent_header, metadata, content] = messages;
    return {
      identity,
      delimiter,
      signature,
      header: JSON.parse(header),
      parent_header: JSON.parse(parent_header),
      metadata: JSON.parse(metadata),
      content: JSON.parse(content)
    };
  }

  static create(config: SessionConfig) {
    return new Session(config);
  }
}import { Router, Request, Response, Next } from "express";
import * as controller from "./controller";
import { hasValidToken, allowedRoles } from "../../middlewares";

const userRoutes = new Router();

userRoutes
  .route("/") // Handle routes for getting and posting records
  .get([
    hasValidToken,
    allowedRoles(["developer", "superuser"]),
    controller.get,
  ]);

userRoutes
  .route("/:username") // Handle routes for specific records
  .all([hasValidToken, controller.findByUsername])
  .get([allowedRoles(["all"]), controller.getByUsername])
  .put([allowedRoles(["developer", "superuser"]), controller.putByUsername])
  .patch([


::current_dir()
    );
    path
}

/// Gets working directory
/// Uses std::env::current_exe() for this purpose.
/// Current exe directory is ./target/{profile}/deps/{app_name}.exe
/// Function returns ./target/{profile}
fn get_working_directory() -> PathBuf {
    let mut output_directory: PathBuf = std::env::current_exe().unwrap();

    output_directory.pop();

    if output_directory.ends_with("deps") {
        output_directory.pop();
    }
    output_directory
}

pub fn get_openapi_path() -> PathBuf {
    let mut path = PathBuf::from(env!("CARGO_MANIFEST_DIR"));
    path.pop();
    path.pop();
    path.push("doc");
    path.push("api");
    path.push("v0.yaml");
    path
}
use num::{BigUint, Zero, FromPrimitive};
use rand::{Rng, weak_rng};
use rust_crypto::digest::Digest;
use ssl::symm::{self, encrypt, decrypt};

use math::ModExp;
use sha1::Sha1;

#[test]
fn run() {
    let mut rng = weak_rng();
    let p_bytes =
    b"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024\
      e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd\
      3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec\
      6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f\
      24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361\
      c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552\
      bb9ed529077096966d670c354e4abc9804f1746c08ca237327fff\
      fffffffffffff";
    let p = BigUint::from_bytes_le(p_bytes);
    //let g = BigUint::from_u32(2).unwrap();

    // Alice

    let mut a_bytes = [0_u8; 256];
    rng.fill_bytes(&mut a_bytes);
    let a = BigUint::from_bytes_le(&a_bytes);
    //let A = g.modexp(&a, &p);

    // Bob

    let mut b_bytes = [0_u8; 256];
    rng.fill_bytes(&mut b_bytes);
    let b = BigUint::from_bytes_le(&b_bytes);
    //let B = g.modexp(&b, &p);

    // A->M : p, g, A
    // M->B : p, g, p

    let s_B = p.modexp(&b, &p);

    // B->M : p, g, B
    // M->A : p, g, p

    let s_A = p.modexp(&a, &p);

    // s = A^b mod p
    //   = B^a mod p
    //   = p^b mod p
    //   = p^a mod p
    //   = 0

    // A->M : c = E(k, iv, m)
    // M->B : c

    let mut m = Sha1::new();
    m.input(&s_A.to_bytes_le());
    let mut out = [0_u8; 20];
    m.result(&mut out);

    let iv: [u8; 16] = rng.gen();

    let ctxt = {
        let key_A = &out[0..16];

        let msg = b"DOS'T THOU JEER AND T-TAUNT ME IN THE TEETH?";
        encrypt(symm::Cipher::aes_128_cbc(), key_A, Some(&iv), msg).unwrap()
    };

    // Bob

    m.reset();
    m.input(&s_B.to_bytes_le());
    m.result(&mut out);

    let msg_B = {
        let key_B = &out[0..16];
        decrypt(symm::Cipher::aes_128_cbc(), key_B, Some


		diskCapacity = group.property("disk_capacity", Long.class, 125000L)
			.setName("Floppy space limit")
			.setDescription("The disk space limit for floppy disks, in bytes");
	}

	@Override
	public void setup(@Nonnull PluginManager manager) {
		manager.addPeripheral("wireless_modem", (computer, cfg) -> new WirelessModemPeripheral());
		manager.addPeripheral("disk_drive", (computer, cfg) -> new DiskDrivePeripheral(cfg.getDataDir(), diskCapacity));
	}
}
package net.clgd.ccemux.rendering.awt;

import java.awt.event.KeyEvent;

import com.google.common.collect.ImmutableMap;

public class KeyTranslator {
	private static final ImmutableMap<Integer, Integer> swingToCCMap = ImmutableMap.<Integer, Integer>builder()
		.put(KeyEvent.VK_SPACE, 32)
		.put(KeyEvent.VK_QUOTE, 39)
		.put(KeyEvent.VK_COMMA, 44)
		.put(KeyEvent.VK_MINUS, 45)
		.put(KeyEvent.VK_PERIOD, 46)
		.put(KeyEvent.VK_SLASH, 47)
		.put(KeyEvent.VK_0, 48)
		.put(KeyEvent.VK_1, 49)
		.put(KeyEvent.VK_2, 50)
		.put(KeyEvent.VK_3, 51)
		.put(KeyEvent.VK_4, 52)
		.put(KeyEvent.VK_5, 53)
		.put(KeyEvent.VK_6, 54)
		.put(KeyEvent.VK_7, 55)
		.put(KeyEvent.VK_8, 56)
		.put(KeyEvent.VK_9, 57)
		.put(KeyEvent.VK_SEMICOLON, 59)
		.put(KeyEvent.VK_EQUALS, 61)
		.put(KeyEvent.VK_A, 65)
		.put(KeyEvent.VK_B, 66)
		.put(KeyEvent.VK_C, 67)
		.put(KeyEvent.VK_D, 68)
		.put(KeyEvent.VK_E, 69)
		.put(KeyEvent.VK_F, 70)
		.put(KeyEvent.VK_G, 71)
		.put(KeyEvent.VK_H, 72)
		.put(KeyEvent.VK_I, 73)
		.put(KeyEvent.VK_J, 74)
		.put(KeyEvent.VK_K, 75)
		.put(KeyEvent.VK_L, 76)
		.put(KeyEvent.VK_M, 77)
		.put(KeyEvent.VK_N, 78)
		.put(KeyEvent.VK_O, 79)
		.put(KeyEvent.VK_P, 80)
		.put(KeyEvent.VK_Q, 81)
		.put(KeyEvent.VK_R, 82)
		.put(KeyEvent.VK_S, 83)
		.put(KeyEvent.VK_T, 84)
		.put(KeyEvent.VK_U, 85)
		.put(KeyEvent.VK_V, 86)
		.put(KeyEvent.VK_W, 87)
		.put(KeyEvent.VK_X, 88)
		.put(KeyEvent.VK_Y, 89)
		.put(KeyEvent.VK_Z, 90)
		.put(KeyEvent.VK_OPEN_BRACKET, 91)
		.put(KeyEvent.VK_BACK_SLASH, 92)
		.put(KeyEvent.VK_CLOSE_BRACKET, 93)
		.put(KeyEvent.VK_BACK_QUOTE, 96)
		.put(KeyEvent.VK_


public Type Type { get; set; }
            public MethodInfo MethodInfo { get; set; }
            public PropertyInfo PropertyInfo { get; set; }
            public FieldInfo FieldInfo;
            public MemberInfo MemberInfo { get; set; }

            public void Method() {}
        }

        [Test]
        public void Can_serialize_POCO_with_Type()
        {
            var dto = new ReflectionType {
                Type = typeof(ReflectionType),
                MethodInfo = typeof(


が空の入力を受け付けないときに有用です。

クエリ：

```sql
SELECT avgOrNullIf(x, x > 10)
FROM
(
    SELECT toDecimal32(1.23, 2) AS x
)
```

結果：

```text
┌─avgOrNullIf(x, greater(x, 10))─┐
│                           ᴺᵁᴸᴸ │
└────────────────────────────────┘
```

## -Resample {#-resample}

データをグループに分割し、それぞれのグループ内のデータを個別に集約することを可能にします。グループは、1つのカラムの値を間隔に分割することによって作成されます。

```sql
<aggFunction>Resample(start, end, step)(<aggFunction_params>, resampling_key)
```

**引数**

- `start` — `resampling_key` の値に必要な全体の間隔の開始値。
- `stop` — `resampling_key` の値に必要な全体の間隔の終了値。全体の間隔には `stop` 値は含まれません `[start, stop)`。
- `step` — 全体の間隔を細分間隔に分けるためのステップ。`aggFunction` は、それらの細分間隔の各々に対して独立して実行されます。
- `resampling_key` — データを間隔に分けるために使用されるカラムの値。
- `aggFunction_params` — `aggFunction` パラメータ。

**返される値**

- 各細分間隔に対する `aggFunction` の結果の配列。

**例**

次のデータを持つ `people` テーブルを考えます：

```text
┌─name───┬─age─┬─wage─┐
│ John   │  16 │   10 │
│ Alice  │  30 │   15 │
│ Mary   │  35 │    8 │
│ Evelyn │  48 │ 11.5 │
│ David  │  62 │  9.9 │
│ Brian  │  60 │   16 │
└────────┴─────┴──────┘
```

`[30,60)` と `[60,75)` の間の年齢に該当する人の名前を取得しましょう。年齢の整数表現を使用しているため、`[30, 59]` および `[60,74]` の間隔の年齢が得られます。

配列内の名前を集約するために、[groupArray](/sql-reference/aggregate-functions/reference/grouparray) 集約関数を使用します。この関数は1つの引数を取ります。我々のケースでは、`name` カラムです。`groupArrayResample` 関数は、年齢ごとに名前を集約するために `age` カラムを使用する必要があります。必要な間隔を定義するために、`groupArrayResample` 関数に `30, 75, 30` の引数を渡します。

```sql
SELECT groupArrayResample(30, 75, 30)(name, age) FROM people
```

```text
┌─groupArrayResample(30, 75, 30)(name, age)─────┐
│ [['Alice','Mary','Evelyn'],['David','Brian']] │
└───────────────────────────────────────────────┘
```

結果を見てみましょう。

`John` は若すぎるためサンプルから外れています。他の人々は指定された年齢の間隔に従って分配されています。

次に、指定された年齢間隔での総人数と平均賃金をカウントします。

```sql
SELECT
    countResample(30, 75, 30)(name, age) AS amount,
    a


O(string.format("%d close:%s  %s", ws.id, code, reason))
end

local function handle_socket(id)
    -- limit request body size to 8192 (you can pass nil to unlimit)
    local code, url, method, header, body = httpd.read_request(sockethelper.readfunc(id), 8192)
    --LOG_INFO(code, url, method, header, body)
    if code then
        local ws = websocket.new(id, header, handler)
        ws:start()
    end
end

skynet.start(function()
    skynet.dispatch("lua", function (_,_,id)
        socket.start(id)
        pcall(handle_socket, id)
        socket.close(id)
    end)
end)


ts[1]

    template = r"""
    python {code_dir}/scripts/prepare_data_quality_regression.py \
        --dataset {dataset} \
        --experiment_root $EXPERIMENT_ROOT_DIR/{expt_group}/Dataset{dataset}/runs/{expt_name}/validate_pixel_csf \
        --folds {fold_str} \
        --seed 0 \
        --expt_group {expt_group}"""
    for pixel_csf in ["baseline", "deep_ensemble"]:
        # NOTE this requires nnunet raw data, which I usually don't store on the cluster.
        # Have to copy it first.
        expt_name = f"dynunet-{args.backbone}-{pixel_csf}"
        if dataset_id == 500:
            expt_name = f"baseline-monai_unet_dropout-{pixel_csf}"

        # quality regression preparation
        cmd = template.format(
            code_dir=code_dir,
            dataset=dataset_id,
            expt_group=expt_group,
            expt_name=expt_name,
            fold_str=" ".join([str(args.start_fold + i) for i in range(5)]),
        )
        job_name = f"Prepare CV-predictions for QR: {dataset_id} ({pixel_csf})"
        if pixel_csf != "deep_ensemble":
            # won't do quality regression training on ensemble predictions
            if args.cluster:
                submit(cmd, dry_run=dry_run, job_name=job_name)
            else:
                run_locally(cmd, dry_run=dry_run)
        print("--------------------")

        # heuristic/radiomics preparation
        cmd = template.format(
            code_dir=code_dir,
            dataset=dataset_id,
            expt_group=expt_group,
            expt_name=expt_name,
            fold_str=" ".join([str(args.start_fold + i) for i in range(5)]),
        )
        if pixel_csf == "deep_ensemble":
            cmd += " --confid predictive_entropy mutual_information"
            # cmd += " --confid predictive_entropy"
        elif pixel_csf == "baseline":
            cmd += " --confid predictive_entropy"
        cmd += " --imagecsf_name heuristic_radiomics --no_preprocessing"
        job_name = f"Prepare CV-predictions for Heur./Rad.: {dataset_id} ({pixel_csf})"
        if args.cluster:
            submit(cmd, dry_run=dry_run, job_name=job_name)
        else:
            run_locally(cmd, dry_run=dry_run)

if __name__ == "__main__":
    main()


df = df.reindex(columns=[(1,), (3,)])
        expected = ",1,3\n0,1,3\n"
        result = df.to_csv(lineterminator="\n")
        tm.assert_almost_equal(result, expected)

    def test_gz_lineend(self):
        # GH 25311
        df = DataFrame({"a": [1, 2]})
        expected_rows = ["a", "1", "2"]
        expected = tm.convert_rows_list_to_csv_str(expected_rows)
        with tm.ensure_clean("__test_gz_lineend.csv.gz") as path:
            df.to_csv(path, index=False)
            with tm.decompress_file(path, compression="gzip") as f:
                result = f.read().decode("utf-8")

        assert result == expected

    def test_to_csv_numpy_16_bug(self):
        frame = DataFrame({"a": date_range("1/1/2000", periods=10)})

        buf = StringIO()
        frame.to_csv(buf)

        result = buf.getvalue()
        assert "2000-01-01" in result

    def test_to_csv_na_quoting(self):
        # GH 15891
        # Normalize carriage return for Windows OS
        result = (
            DataFrame([None, None])
            .to_csv(None, header=False, index=False, na_rep="")
            .replace("\r\n", "\n")
        )
        expected = '""\n""\n'
        assert result == expected

    def test_to_csv_categorical_and_ea(self):
        # GH#46812
        df = DataFrame({"a": "x", "b": [1, pd.NA]})
        df["b"] = df["b"].astype("Int16")
        df["b"] = df["b"].astype("category")
        result = df.to_csv()
        expected_rows = [",a,b", "0,x,1", "1,x,"]
        expected = tm.convert_rows_list_to_csv_str(expected_rows)
        assert result == expected

    def test_to_csv_categorical_and_interval(self):
        # GH#46297
        df = DataFrame(
            {
                "a": [
                    pd.Interval(
                        Timestamp("2020-01-01"),
                        Timestamp("2020-01-02"),
                        closed="both",
                    )
                ]
            }
        )
        df["a"] = df["a"].astype("category")
        result = df.to_csv()
        expected_rows = [",a", '0,"[2020-01-01 00:00:00, 2020-01-02 00:00:00]"']
        expected = tm.convert_rows_list_to_csv_str(expected_rows)
        assert result == expected


    def analyze_hemispheric_interference(self) -> Dict[str, Any]:
        """
        Analyze the hemispheric interference pattern preventing total confinement.

        This demonstrates how the toroidal geometry creates interference
        that maintains the Common Source axiom through partial transmission.

        Returns:
            Dict with interference analysis and transmission coefficient
        """
        print("\n=====")
        print("HEMISPHERIC INTERFERENCE ANALYSIS")
        print("=====")

        print("\n1. Toroidal Geometry Creates Two Hemispheres:")
        print("   Like Earth's day/night, creating interference patterns")

        # Wave functions for each hemisphere
        print("\n2. Wave Function Superposition:")
        psi_1 = np.exp(1j * self.cgm.alpha)  # Hemisphere 1
        psi_2 = np.exp(-1j * self.cgm.alpha)  # Hemisphere 2 (conjugate)

        print(f"   ψ₁ = exp(iα) = exp(i × {self.cgm.alpha:.6f})")
        print(f"   ψ₂ = exp(-iα) = exp(-i × {self.cgm.alpha:.6f})")

        # Total wave function
        psi_total = psi_1 + psi_2
        amplitude = abs(psi_total)

        print(f"\n3. Interference Pattern:")
        print(f"   ψ_total = ψ₁ + ψ₂")
        print(f"   At α = π/2: ψ_total = i + (-i) = 0 (destructive at poles)")
        print(f"   Amplitude: |ψ_total| = {amplitude:.6f}")

        # Aperture maintains transmission
        print(f"\n4. Aperture Prevents Total Confinement:")
        T_aperture = self.cgm.m_p
        T_effective = max(T_aperture, T_aperture * amplitude)

        print(f"   Aperture transmission: m_p = {T_aperture:.6f}")
        print(f"   This ensures ~{T_aperture*100:.1f}% leakage")
        print(f"   Effective transmission: {T_effective:.6f}")

        # Quality factor
        print(f"\n5. Cavity Quality Factor:")
        Q = self.cgm.Q_cavity
        coherent_oscillations = int(Q)

        print(f"   Q = 1/m_p = {Q:.6f}")
        print(f"   Allows ~{coherent_oscillations} coherent oscillations")
        print(f"   Before decoherence sets in")

        print(f"\n6. Physical Significance:")
        print(f"   • Prevents violation of Common Source axiom")
        print(
            f"   • Maintains an information escape route consistent with the aperture"
        )
        print(f"   • Enables quantum tunneling through horizons")
        print(
            "   Limit check at α=π/2: e^{iα}+e^{-iα}=0; leakage is therefore aperture-limited, not wave-limited."
        )

        return {
            "amplitude": amplitude,
            "T_aperture": T_aperture,
            "T_effective": T_effective,
            "Q_cavity": Q,
            "coherent_oscillations": coherent_oscillations,
            "psi_1": psi_1,
            "psi_2": psi_2,
            "psi_total": psi_total,
        }

    # ============= Gyrotriangle Closure =============

    def verify_gyrotriangle_closure(self) -> Dict[str, Any]:
        """
        Verify the gyrotriangle closure condition for 3D space.

        This proves that the specific threshold values are the unique
        solution for defect-free closure in three dimensions.

        Returns:
            Dict with closure verification
        """
        print("\n=====")
        print("GYROTRIANGLE CLOSURE VERIFICATION")
        print("=====")

        print("\n1. Gyrotriangle Defect Formula:")
        print("   δ = π - (α + β + γ)")

        # Compute defect
        alpha, beta_ang, gamma_ang = (
            self.cgm.alpha,
            self.cgm.beta_ang,
            self.cgm.gamma_ang,
        )
        angle_sum = alpha + beta_ang + gamma_ang
        defect = np.pi - angle_sum

        print(f"\n2. Threshold Values:")
        print(f"   α = {alpha:.6f} = π/2 (CS chirality)")
        print(f"   β = {beta_ang:.6f} = π/4 (UNA split)")
        print(f"   γ = {gamma_ang:.6f} = π/4 (ONA tilt)")

        print(f"\n3. Closure Calculation:")
        print(f"   Sum: α + β + γ = {angle_sum:.6f}")
        print(f"   Defect: δ = π - {angle_sum:.6f} = {defect:.6f}")

        # Verify exact closure
        if abs(defect) < EPS:
            print(f"   Status: ✓ EXACT CLOSURE (δ = 0)")
        else:
            print(f"   Status: ⚠ Non-zero defect")

        # Compute side parameters (should all vanish)
        print(f"\n4. Side Parameters (Degenerate Triangle):")

        # Using Ungar's formula for AAA to SSS conversion
        cos_alpha = np.cos(alpha)
        cos_beta = np.cos(beta_ang)
        cos_gamma = np.cos(gamma_ang)

        #


XUiFubenExperimentBanner = XClass()
function XUiFubenExperimentBanner:Ctor(ui)
    self.GameObject = ui.gameObject
    self.Transform = ui.transform
    self.IsLock = false
    self.IsShowPass = false
    self.LockText = ""
end

function XUiFubenExperimentBanner:Init(index, callback)
    self.Index = index
    self.Callback = callback
    self:InitUiObjects()
    self.TrialLevelInfo = {}
end

function XUiFubenExperimentBanner:InitUiObjects()
    XTool.InitUiObject(self)
    self.AutoCreateListeners = {}
    XUiHelper.RegisterClickEvent(self, self.BtnModelSwitch, self.OnBtnModelSwitchClick)
    XUiHelper.RegisterClickEvent(self, self.BtnEnter, self.OnBtnEnter)
end

function XUiFubenExperimentBanner:RegisterListener(uiNode, eventName, func)
    if not uiNode then return end
    local key = eventName .. uiNode:GetHashCode()
    local listener = self.AutoCreateListeners[key]
    if listener ~= nil then
        uiNode[eventName]:RemoveListener(listener)
    end

    if func ~= nil then
        if type(func) ~= "function" then
            XLog.Error("XUiBtnTab:RegisterListener: func is not a function")
        end

        listener = function(...)
            func(self, ...)
        end

        uiNode[eventName]:AddListener(listener)
        self.AutoCreateListeners[key] = listener
    end
end

function XUiFubenExperimentBanner:OnBtnModelSwitchClick(...)
    if self.TrialLevelInfo.Type == XDataCenter.FubenExperimentManager.TrialLevelType.Switch then
        if self.CurType == XDataCenter.FubenExperimentManager.TrialLevelType.Signle then
            self.CurType = XDataCenter.FubenExperimentManager.TrialLevelType.Mult
        else
            self.CurType = XDataCenter.FubenExperimentManager.TrialLevelType.Signle
        end
        self:UpdateType()
    end
end

function XUiFubenExperimentBanner:OnBtnEnter(...)
    self:CheakLock()
    if self.IsLock then
        XUiManager.TipError(self.LockText)
       return
    end
    self.Callback(self.Index, self.CurType)
end

function XUiFubenExperimentBanner:UpdateBanner(trialLevelInfo)
    se


interface{}
		dest     OuterStruct
		expected OuterStruct
	}{
		{
			name:     "value-to-nil",
			src:      []interface{}{[]byte("1234"), nil},
			dest:     OuterStruct{&InnerStruct{}},
			expected: OuterStruct{Inner: &InnerStruct{Foo: 1234}},
		},
		{
			name:     "nil-to-nil",
			src:      []interface{}{[]byte(nil), nil},
			dest:     OuterStruct{},
			expected: OuterStruct{},
		},
		{
			name:     "value-to-value",
			src:      []interface{}{[]byte("1234"), nil},
			dest:     OuterStruct{Inner: &InnerStruct{Foo: 5678}},
			expected: OuterStruct{Inner: &InnerStruct{Foo: 1234}},
		},
		{
			name:     "nil-to-value",
			src:      []interface{}{[]byte(nil), nil},
			dest:     OuterStruct{Inner: &InnerStruct{Foo: 1234}},
			expected: OuterStruct{},
		},
	}

	for _, tc := range tests {
		t.Run(tc.name, func(t *testing.T) {
			_, err := redis.Scan(tc.src, &tc.dest.Inner)
			require.NoError(t, err)
			require.Equal(t, tc.expected, tc.dest)
		})
	}
}

func ExampleArgs() {
	c, err := dial()
	if err != nil {
		fmt.Println(err)
		return
	}
	defer c.Close()

	var p1, p2 struct {
		Title  string `redis:"title"`
		Author string `redis:"author"`
		Body   string `redis:"body"`
	}

	p1.Title = "Example"
	p1.Author = "Gary"
	p1.Body = "Hello"

	if _, err := c.Do("HMSET", redis.Args{}.Add("id1").AddFlat(&p1)...); err != nil {
		fmt.Println(err)
		return
	}

	m := map[string]string{
		"title":  "Example2",
		"author": "Steve",
		"body":   "Map",
	}

	if _, err := c.Do("HMSET", redis.Args{}.Add("id2").AddFlat(m)...); err != nil {
		fmt.Println(err)
		return
	}

	for _, id := range []string{"id1", "id2"} {

		v, err := redis.Values(c.Do("HGETALL", id))
		if err != nil {
			fmt.Println(err)
			return
		}

		if err := redis.ScanStruct(v, &p2); err != nil {
			fmt.Println(err)
			return
		}

		fmt.Printf("%+v\n", p2)
	}

	// Output:
	// {Title:Example Author:Gary Body:Hello}
	// {Title:Example2 Author:Steve Body:Map}
}
// Copyright 2012 Gary Burd
//
// Licensed under the Apache License, Version 2.0 (the "License"): you may
// not use this file except in compliance with the License. You may obtain
// a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
// License for the specific language governing permissions and limitations
// under the License.

// Package redis is a client for the Redis database.
//
// The Redigo FAQ (https://github.com/gomodule/redigo/wiki/FAQ) contains more
// documentation about this package.
//
// Connections
//
// The Conn interface is the primary interface for working with Redis.
// Applications create connections by calling the Dial, DialWithTimeout or
// NewConn functions. In the future, functions will be added for creating
// sharded and other types of connections.
//
// The application must call the connection Close method when the application
// is done with the connection.
//
// Executing Commands
//
// The Conn interface has a generic method for executing Redis commands:
//
//  Do(commandName string, args ...interface{}) (reply interface{}, err error)
//
// The Redis command reference (http://


adonly Type AssetType;

        /// <summary>
        /// Whether it should look for all assets that inherit from this asset.
        /// </summary>
        public readonly bool AllowInheritance = false;

        /// <summary>
        /// Creates a new <see cref="GameAssetIdAttribute"/>.
        /// </summary>
        /// <param name="type">The game asset type.</param>
        /// <param name="allowInheritance">Whether it should look for all assets that inherit from this asset.</param>
        public GameAssetIdAttribute(Type type, bool allowInheritance = false) => (AssetType, AllowInheritance) = (type, allowInheritance);
    }

    public class GameAssetIdAttribute<T> : GameAssetIdAttribute
    {
        public GameAssetIdAttribute() : base(typeof(T))
        {
        }
    }
}


 },
  {
    '_id': '08110',
    'city': 'DELAIR',
    'loc': [-75.063446, 39.962742],
    'pop': 15447,
    'state': 'NJ'
  },
  {
    '_id': '08201',
    'city': 'SMITHVILLE',
    'loc': [-74.503106, 39.462368],
    'pop': 26645,
    'state': 'NJ'
  },
  {
    '_id': '08202',
    'city': 'AVALON',
    'loc': [-74.72617700000001, 39.095095],
    'pop': 1813,
    'state': 'NJ'
  },
  {
    '_id': '08203',
    'city': 'BRIGANTINE',
    'loc': [-74.377644, 39.403709],
    'pop': 9388,
    'state': 'NJ'
  },
  {
    '_id': '08204',
    'city': 'NORTH CAPE MAY',
    'loc': [-74.92624000000001, 38.969208],
    'pop': 18084,
    'state': 'NJ'
  },
  {
    '_id': '08210',
    'city': 'CAPE MAY COURT H',
    'loc': [-74.826846, 39.101434],
    'pop': 13521,
    'state': 'NJ'
  },
  {
    '_id': '08215',
    'city': 'EGG HARBOR CITY',
    'loc': [-74.617709, 39.533123],
    'pop': 10362,
    'state': 'NJ'
  },
  {
    '_id': '08221',
    'city': 'LINWOOD',
    'loc': [-74.580744, 39.346883],
    'pop': 9353,
    'state': 'NJ'
  },
  {
    '_id': '08223',
    'city': 'MARMORA',
    'loc': [-74.659297, 39.258562],
    'pop': 4420,
    'state': 'NJ'
  },
  {
    '_id': '08225',
    'city': 'NORTHFIELD',
    'loc': [-74.55523700000001, 39.370256],
    'pop': 7503,
    'state': 'NJ'
  },
  {
    '_id': '08226',
    'city': 'OCEAN CITY',
    'loc': [-74.587514, 39.270894],
    'pop': 15512,
    'state': 'NJ'
  },
  {
    '_id': '08230',
    'city': 'OCEAN VIEW',
    'loc': [-74.707548, 39.215425],
    'pop': 4443,
    'state': 'NJ'
  },
  {
    '_id': '08232',
    'city': 'PLEASANTVILLE',
    'loc': [-74.55236499999999, 39.401518],
    'pop': 30292,
    'state': 'NJ'
  },
  {
    '_id': '08241',
    'city': 'PORT REPUBLIC',
    'loc': [-74.490263, 39.527196],
    'pop': 992,
    'state': 'NJ'
  },
  {
    '_id': '08242',
    'city': 'RIO GRANDE',
    'loc': [-74.875642, 39.019583],
    'pop': 2943,
    'state': 'NJ'
  },
  {
    '_id': '08243',
    'city': 'TOWNSENDS INLET',
    'loc': [-74.701432, 39.144929],
    'pop': 2675,
    'state': 'NJ'
  },
  {
    '_id': '


.567 0-1.533 1.74-2.803 4.405-3.567-.67-2.69-.441-4.832.886-5.598 1.328-.767 3.298.105 5.292 2.03 1.994-1.925 3.964-2.797 5.292-2.03 1.327.766 1.557 2.908.886 5.598zm-.973-.248c.57-2.26.45-3.986-.413-4.484-.863-.499-2.419.261-4.09 1.884a22.049 22.049 0 011.746 2.175c.978.09 1.904.234 2.757.425zm-10.41 7.63c-.57 2.26-.45 3.986.413 4.484.863.499 2.419-.261 4.09-1.884a21.877 21.877 0 01-1.746-2.175 21.877 21.877 0 01-2.757-.425zm4.067-8.142a27.512 27.512 0 012.276 0A20.523 20.523 0 0012 6.31c-.38.416-.76.872-1.138 1.364zm-1.31.087A21.877 21.877 0 0111.3 5.585C9.627 3.962 8.07 3.202 7.209 3.701c-.864.498-.983 2.225-.414 4.484.853-.19 1.78-.334 2.757-.425zm4.342 7.52A25.368 25.368 0 0015.787 12a25.368 25.368 0 00-1.893-3.28 25.368 25.368 0 00-3.788 0A25.368 25.368 0 008.213 12a25.368 25.368 0 001.893 3.28 25.368 25.368 0 003.788 0zm1.284-.131c.615-.08 1.2-.183 1.75-.304a20.523 20.523 0 00-.612-1.667 27.512 27.512 0 01-1.138 1.97zM8.822 8.85c-.615.08-1.2.183-1.75.304.17.536.374 1.094.612 1.667a27.512 27.512 0 011.138-1.97zm-1.75 5.994c.55.121 1.135.223 1.75.304a27.512 27.512 0 01-1.138-1.97 20.42 20.42 0 00-.612 1.666zm-.978-.245c.261-.834.6-1.708 1.01-2.6a22.002 22.002 0 01-1.01-2.6c-2.242.637-3.677 1.604-3.677 2.6s1.435 1.963 3.677 2.6zm10.834-5.445a20.808 20.808 0 00-1.75-.304 27.511 27.511 0 011.138 1.97c.238-.572.442-1.13.612-1.666zm.978.245c-.261.834-.6 1.708-1.01 2.6.41.892.749 1.766 1.01 2.6 2.242-.637 3.677-1.604 3.677-2.6s-1.435-1.963-3.677-2.6zM12 13.88a1.88 1.88 0 110-3.76 1.88 1.88 0 010 3.76z"/></svg>';
  static const String reactjs_line =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="24" height="24" preserveAspectRatio="xMidYMid meet" viewBox="0 0 24 24"><path fill="currentColor" d="M12 13.5a1.5 1.5 0 110-3 1.5 1.5 0 010 3zm-.528 2.994c.175.21.351.414.528.609.177-.1


			Parser.Default.ParseArguments<Options>(args)
						.WithNotParsed(error => throw new Exception($"命令行格式错误!"))
						.WithParsed(o => { options = o; });

				Options.Instance = options;

				Log.ILog = new NLogger(Game.Options.AppType.ToString());
				LogManager.Configuration.Variables["appIdFormat"] = $"{Game.Options.Process:000000}";

				Log.Info($"server start........................ {Game.Scene.Id}");

				Game.EventSystem.Publish(new EventType.AppStart());

				while (true)
				{
					try
					{
						Thread.Sleep(1);
						Game.Update();
						Game.LateUpdate();
						Game.FrameFinishUpdate();
					}
					catch (Exception e)
					{
						Log.Error(e);
					}
				}
			}
			catch (Exception e)
			{
				Log.Error(e);
			}
		}
	}
}


 true;
				}
			}
			F::MoveSim.Restore();
		}
	}
	return false;
}

bool IsPointAllowed(int nHitbox)
{
	switch (nHitbox)
	{
		case 0: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 0);
		case 1: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 1);
		case 2: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 2);
		case 3:
		case 4:
		case 5:
		case 6: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 0);
		case 7:
		case 8:
		case 9:
		case 10: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 1);
		case 11:
		case 12:
		case 13:
		case 14: return Vars::Aimbot::Projectile::AllowedHitboxes.Value & (1 << 2);
	}
	return true; // never
}

//	Tries to find the best position to aim at on our target.
std::optional<Vec3> CAimbotProjectile::GetAimPos(CBaseEntity* pLocal, CBaseEntity* pEntity, const Vec3& targetPredPos)
{
	std::optional<Vec3> vRetVec = pLocal->GetAbsOrigin();
	const Vec3 vLocalPos = pLocal->GetAbsOrigin();

	const Vec3 vShootPos = pLocal->GetShootPos();

	const bool bIsDucking = (pEntity->m_bDucked() || pEntity->m_fFlags() & FL_DUCKING);

	const float flBBoxScale = Vars::Aimbot::Projectile::ScanScale.Value; // stop shoot flor (:D)

	// this way overshoots players that are crouching and I don't know why.
	const Vec3 vMaxs = I::GameMovement->GetPlayerMaxs(bIsDucking) * flBBoxScale;
	const auto vMins = Vec3(-vMaxs.x, -vMaxs.y, vMaxs.z - vMaxs.z * flBBoxScale);

	const Vec3 vHeadDelta = Utils::GetHeadOffset(pEntity);

	const std::vector vPoints = {
		// oh you don't like 15 points because it fucks your fps??? TOO BAD!//
		Vec3(vHeadDelta.x, vHeadDelta.y, vMaxs.z), //	head bone probably
		Vec3(0, 0, (vMins.z + vMaxs.z) / 2), //	middles (scan first bc they are more accurate)
		Vec3(0, 0, vMins.z), //	-
		Vec3(vMins.x, vMins.y, vMaxs.z), //	top four corners
		Vec3(vMins.x, vMaxs.y, vMaxs.z), //	-
		Vec3(vMaxs.x, vMaxs.y, vMaxs.z), //	-
		Vec3(vMaxs.x, vMins.y, vMaxs.z), //	-
		Vec3(vMins.x, vMins.y, (vMins.z + vMaxs.z) / 2), //	middle four corners
		Vec3(vMins.x, vMaxs.y, (vMins.z + vMaxs.z) / 2), //	-
		Vec3(vMaxs.x, vMaxs.y, (vMins.z + vMaxs.z) / 2), //	-
		Vec3(vMaxs.x, vMins.y, (vMins.z + vMaxs.z) / 2), //	-
		Vec3(vMins.x, vMins.y, vMins.z), //	bottom four corners
		Vec3(vMins.x, vMaxs.y, vMins.z), //	-
		Vec3(vMaxs.x, vMaxs.y, vMins.z), //	-
		Vec3(vMaxs.x, vMins.y, vMins.z) //	-
	};

	std::vector<Vec3> vVisPoints{};
	const matrix3x4 transform = {
		{


/**
 * @internal
 */
export const hasQueryImportSupport = <TQuery extends DataQuery>(
  datasource: unknown
): datasource is DataSourceWithQueryImportSupport<TQuery> => {
  return (datasource as DataSourceWithQueryImportSupport<TQuery>).importFromAbstractQueries !== undefined;
};

/**
 * @internal
 */
export const hasQueryExportSupport = <TQuery extends DataQuery>(
  datasource: unknown
): datasource is DataSourceWithQueryExportSupport<TQuery> => {
  return (datasource as DataSourceWithQueryExportSupport<TQuery>).exportToAbstractQueries !== undefined;
};
import {Schema, model, Document} from 'mongoose';

const schema = new Schema({
    title:String,
    description:String,
    imagePath: String
});

//una Interface es una description de un obj
interface IPhoto extends Document{
    title: string;
    description: string;
    imagePath: string;
}

export default model<IPhoto>('Photo', schema);import {
  Cardinality,
  ExpressionKind,
  TypeKind,
  type typeutil,
} from "edgedb/dist/reflection/index";
import { cardutil } from "./cardinality";
import type {
  $expr_Array,
  $expr_NamedTuple,
  $expr_Tuple,
  $expr_TuplePath,
  ArrayType,
  BaseType,
  getPrimitiveBaseType,
  NamedTupleLiteralShape,
  NamedTupleShape,
  NamedTupleType,
  NonArrayType,
  ObjectTypeExpression,
  ObjectTypePointers,
  PropertyDesc,
  TupleType,
  TypeSet,
} from "./typesystem";

import { $expressionify, type ExpressionRoot } from "./path";
import type { getCardsFromExprs } from "./set";
import {
  type literalToScalarType,
  literalToTypeSet,
  type mapLiteralToTypeSet,
  type orScalarLiteral,
  type scalarLiterals,
} from "./castMaps";

const indexSliceRegx = /^(-?\d+)(?:(:)(-?\d+)?)?|:(-?\d+)$/;

const arrayLikeProxyHandlers: ProxyHandler<ExpressionRoot> = {
  get(target: ExpressionRoot, prop: string | symbol, proxy: any) {
    const match = typeof prop === "string" ? prop.match(indexSliceRegx) : null;
    if (match) {
      const start = match[1];
      const end = match[3] ?? match[4];
      const isIndex = start && !match[2];
      return $expressionify({
        __kind__: ExpressionKind.Operator,
        __element__:
          target.__element__.__kind__ === TypeKind.array && isIndex
            ? (target.__element__ as ArrayType).__element__
            : target.__element__,
        __cardinality__: target.__cardinality__,
        __name__: "[]",
        __opkind__: "Infix",
        __args__: [
          proxy,
          isIndex
            ? literalToTypeSet(Number(start))
            : [
                start && literalToTypeSet(Number(start)),
                end && literalToTypeSet(Number(end)),
              ],
        ],
      }) as any;
    }
    return (target as any)[prop];
  },
};

function arrayLikeIndex(this: ExpressionRoot, index: any) {
  const indexTypeSet = literalToTypeSet(index);
  return $expressionify({
    __kind__: ExpressionKind.Operator,
    __element__:
      this.__element__.__kind__ === TypeKind.array
        ? (this.__element__ as ArrayType).__element__
        : this.__element__,
    __cardinality__: cardutil.multiplyCardinalities(
      this.__cardinality__,
      indexTypeSet.__cardinality__
    ),
    __name__: "[]",
    __opkind__: "Infix",
    __args__: [this,


LLISECONDS)
                .filter(MetricFilter.ALL)
                .build(influxDb);

    }

    @Test
    public void reportsCounters() throws Exception {
        final Counter counter = mock(Counter.class);
        Mockito.when(counter.getCount()).thenReturn(100L);

        reporter.report(this.map(), this.map("counter", counter), this.map(), this.map(), this.map());
        final ArgumentCaptor<InfluxDbPoint> influxDbPointCaptor = ArgumentCaptor.forClass(InfluxDbPoint.class);
        Mockito.verify(influxDb, atLeastOnce()).appendPoints(influxDbPointCaptor.capture());
        InfluxDbPoint point = influxDbPointCaptor.getValue();
        System.out.println("point = " + point);
        /*
        assertThat(point.getMeasurement()).isEqualTo("counter");
        assertThat(point.getFields()).isNotEmpty();
        assertThat(point.getFields()).hasSize(1);
        assertThat(point.getFields()).contains(entry("count", 100L));
        */
    }

    @Test
    public void reportsHistograms() throws Exception {
        final Histogram histogram = mock(Histogram.class);
        when(histogram.getCount()).thenReturn(1L);

        final Snapshot snapshot = mock(Snapshot.class);
        when(snapshot.getMax()).thenReturn(2L);
        when(snapshot.getMean()).thenReturn(3.0);
        when(snapshot.getMin()).thenReturn(4L);
        when(snapshot.getStdDev()).thenReturn(5.0);
        when(snapshot.getMedian()).thenReturn(6.0);
        when(snapshot.get75thPercentile()).thenReturn(7.0);
        when(snapshot.get95thPercentile()).thenReturn(8.0);
        when(snapshot.get98thPercentile()).thenReturn(9.0);
        when(snapshot.get99thPercentile()).thenReturn(10.0);
        when(snapshot.get999thPercentile()).thenReturn(11.0);

        when(histogram.getSnapshot()).thenReturn(snapshot);

        reporter.report(this.map(), this.map(), this.map("histogram", histogram), this.map(), this.map());

        final ArgumentCaptor<InfluxDbPoint> influxDbPointCaptor = ArgumentCaptor.forClass(InfluxDbPoint.class);
        Mockito.verify(influxDb, atLeastOnce()).appendPoints(influxDbPointCaptor.capture());
        InfluxDbPoint point = influxDbPointCaptor.getValue();

        /*
        assertThat(point.getMeasurement()).isEqualTo("histogram");
        assertThat(point.getFields()).isNotEmpty();
        assertThat(point.getFields()).hasSize(13);
        assertThat(point.getFields()).contains(entry("max", 2L));
        assertThat(point.getFields()).contains(entry("mean", 3.0));
        assertThat(point.getFields()).contains(entry("min", 4L));
        assertThat(point.getFields()).contains(entry("std-dev", 5.0));
        assertThat(point.getFields()).contains(entry("median", 6.0));
        assertThat(point.getFields()).contains(entry("75-percentile", 7.0));
        assertThat(point.getFields()).contains(entry("95-percentile", 8.0));
        assertThat(point.getFields()).contains(entry("98-percentile", 9.0));
        assertThat(point.getFields()).contains(entry("99-percentile", 10.0));
        assertThat(point.getFields()).contains(entry("999-percentile", 11.0));
        */
    }

    @Test
    public void reportsMeters() throws Exception {
        final Meter meter = mock(Meter.class);
        when(meter.getCount()).thenReturn(1L);
        when(meter.getOneMinuteRate()).thenReturn(2.0);
        when(mete


eq!(list.get(3), None);
        assert_eq!(list.get(4), None);
    }

    #[test]
    fn remove() {
        let mut list = LinkedList::new();
        list.push_back(1);
        list.push_back(2);
        assert_eq!(list.remove(1), Some(2));
        assert_eq!(list.get(1), None);
        assert_eq!(list.remove(0), Some(1));
    }
}
<filename>build.rs
use std::env;
use std::fs;
use std::io::Write;
use std::path;

fn main() {
    println!("cargo:rerun-if-changed=build.rs");

    // env::ARCH doesn't include full triplet, and AFAIK there isn't a nicer way of getting the full triplet
    // (see lib.rs for the rest of this hack)
    let out = path::PathBuf::from(env::var_os("OUT_DIR").expect("run within cargo"))
        .join("current_target.txt");
    let default_target = env::var("TARGET").expect("run as cargo build script");
    let mut file = fs::File::create(out).unwrap();
    file.write_all(default_target.as_bytes()).unwrap();
}
use crate::custom_serde::*;
use chrono::{DateTime, Utc};

pub type CodePipelineStageState = String;

pub type CodePipelineState = String;

pub type CodePipelineActionState = String;

/// CodePipelineEvent is documented at:
/// https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#codepipeline_event_type
#[derive(Debug, Clone, PartialEq, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct CodePipelineCloudWatchEvent {
    /// Version is the version of the event's schema.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    pub version: Option<String>,
    /// ID is the GUID of this event.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    pub id: Option<String>,
    /// DetailType informs the schema of the Detail field. For deployment state-change
    /// events, the value should be equal to CodePipelineDeploymentEventDetailType.
    /// For instance state-change events, the value should be equal to
    /// CodePipelineInstanceEventDetailType.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    #[serde(rename = "detail-type")]
    pub detail_type: Option<String>,
    /// Source should be equal to CodePipelineEventSource.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    pub source: Option<String>,
    /// AccountID is the id of the AWS account from which the event originated.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    #[serde(rename = "account")]
    pub account_id: Option<String>,
    /// Time is the event's timestamp.
    pub time: DateTime<Utc>,
    /// Region is the AWS region from which the event originated.
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #[serde(default)]
    pub region: Option<String>,
    /// Resources is a list of ARNs of CodePipeline applications and deployment
    /// groups that this event pertains to.
    pub resources: Vec<String>,
    /// Detail contains information specific to a deployment event.
    pub detail: CodePipelineEventDetail,
}

#[derive(Debug, Clone, PartialEq, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct CodePipelineEventDetail {
    #[serde(deserialize_with = "deserialize_lambda_string")]
    #


d": "बैज के लिए पृष्ठभूमि का रंग। बैज संक्षिप्त जानकारी वाले टेक्स्ट होते हैं, उदा. खोज परिणामों की संख्या के लिए.",
        "badgeForeground": "बैज के लिए अग्रभूमि रंग। बैज संक्षिप्त जानकारी वाले टेक्स्ट होते हैं, उदा. खोज परिणामों की संख्या के लिए.",
        "breadcrumbsBackground": "ब्रेडक्रंब तत्वों की पृष्ठभूमि का रंग।",
        "breadcrumbsFocusForeground": "ब्रेडक्रंब आइटम का रंग जिन पर फ़ोकस होता है।",
        "breadcrumbsSelectedBackground": "ब्रेडक्रंब चयन उपकरण पृष्ठभूमि रंग।",
        "breadcrumbsSelectedForegound": "चयनित ब्रेडक्रंब आइटम का रंग।",
        "buttonBackground": "बटन पृष्ठभूमि रंग।",
        "buttonBorder": "बटन का बॉर्डर रंग।",
        "buttonForeground": "बटन का अग्रभूमि रंग।",
        "buttonHoverBackground": "होवर करने पर बटन का बैकग्राउंड कलर।",
        "buttonSecondaryBackground": "सेकेंडरी बटन का बैकग्राउंड कलर।",
        "buttonSecondaryForeground": "बटन का द्वितीयक अग्रभूमि रंग।",
        "buttonSecondaryHoverBackground": "सेकेंडरी बटन का बैकग्राउंड कलर जब होवर किया जाता है।",
        "chartsBlue": "चार्ट विज़ुअलाइज़ेशन में प्रयुक्त रंग नीला।",
        "chartsForeground": "चार्ट में प्रयुक्त अग्रभूमि रंग।",
        "chartsGreen": "चार्ट विज़ुअलाइज़ेशन में इस्तेमाल किया गया हरा रंग।",
        "chartsLines": "चार्ट में क्षैतिज रेखाओं के लिए प्रयुक्त रंग।",
        "chartsOrange": "चार्ट विज़ुअलाइज़ेशन में उपयोग किया जाने वाला नारंगी रंग।",
        "chartsPurple": "चार्ट विज़ुअलाइज़ेशन में प्रयुक


sfer","inputs":{"_amount":"3291036540000000000","_from":"0x3a5cc8689d1b0cef2c317bc5c0ad6ce88b27d597","_to":"0xc5e81fc2401b8104966637d5334cbce92f01dbf7"}}
/// compressedLog : "{name:Transfer|inputs:{_amount:3291036540000000000|_from:0x3a5cc8689d1b0cef2c317bc5c0ad6ce88b27d597|_to:0xc5e81fc2401b8104966637d5334cbce92f01dbf7}}"
/// transactionHash : "0x5b59559a77fa5f1c70528d41f4fa2e5fa5a00b21fc2f3bc26b208b3062e46333"
/// transactionIndex : 25

class EthTokenTxDto {
  EthTokenTxDto({
    required this.address,
    required this.blockNumber,
    required this.logIndex,
    required this.topics,
    required this.data,
    required this.articulatedLog,
    required this.transactionHash,
    required this.transactionIndex,
    required this.blockHash,
    required this.timestamp,
    required this.nonce,
    required this.gasUsed,
    required this.gasPrice,
  });

  EthTokenTxDto.fromMap(Map<String, dynamic> map)
    : address = map['address'] as String,
      blockNumber = map['blockNumber'] as int,
      logIndex = map['logIndex'] as int,
      topics = List<String>.from(map['topics'] as List),
      data = map['data'] as String,
      articulatedLog =
          map['articulatedLog'] == null
              ? null
              : ArticulatedLog.fromMap(
                Map<String, dynamic>.from(map['articulatedLog'] as Map),
              ),
      transactionHash = map['transactionHash'] as String,
      transactionIndex = map['transactionIndex'] as int,
      blockHash = map['blockHash'] as String?,
      timestamp = map['timestamp'] as int,
      nonce = map['nonce'] as int?,
      gasUsed = map['gasUsed'] as int?,
      gasPrice = BigInt.tryParse(map['gasPrice'].toString());

  final String address;
  final int blockNumber;
  final int logIndex;
  final List<String> topics;
  final String data;
  final ArticulatedLog? articulatedLog;
  final String transactionHash;
  final int transactionIndex;
  final String? blockHash;
  final int timestamp;
  final int? nonce;
  final int? gasUsed;
  final BigInt? gasPrice;

  EthTokenTxDto copyWith({
    String? address,
    int? blockNumber,
    int? logIndex,
    List<String>? topics,
    String? data,
    ArticulatedLog? articulatedLog,
    String? compressedLog,
    String? transactionHash,
    int? transactionIndex,
    String? blockHash,
    int? timestamp,
    int? nonce,
    int? gasUsed,
    BigInt? gasPrice,
  }) => EthTokenTxDto(
    address: address ?? this.address,
    blockNumber: blockNumber ?? this.blockNumber,
    logIndex: logIndex ?? this.logIndex,
    topics: topics ?? this.topics,
    data: data ?? this.data,
    articulatedLog: articulatedLog ?? this.articulatedLog,
    transactionHash: transactionHash ?? this.transactionHash,
    transactionIndex: transactionIndex ?? this.transactionIndex,
    blockHash: blockHash ?? this.blockHash,
    timestamp: timestamp ?? this.timestamp,
    nonce: nonce ?? this.nonce,
    gasUsed: gasUsed ?? this.gasUsed,
    gasPrice: gasPrice ?? this.gasPrice,
  );

  Map<String, dynamic> toMap() {
    final map = <String, dynamic>{};
    map['address'] = address;
    map['blockNumber'] = blockNumber;


ndt = m_dndt_table.serialize();
    const auto data_pair_prod = m_pair_prod_table.serialize();

    const uint64_t size_first = data_dndt.size();

    vector<char> res{};
    pxr_sr::put_in(size_first, res);
    for (const auto& tmp : data_dndt) {
        pxr_sr::put_in(tmp, res);
    }
    for (const auto& tmp : data_pair_prod) {
        pxr_sr::put_in(tmp, res);
    }

    return res;
}

PicsarBreitWheelerCtrl
BreitWheelerEngine::get_default_ctrl() const
{
    namespace pxr_bw = picsar::multi_physics::phys::breit_wheeler;
    return PicsarBreitWheelerCtrl{
        pxr_bw::default_dndt_lookup_table_params<amrex::ParticleReal>,
        pxr_bw::default_pair_prod_lookup_table_params<amrex::ParticleReal>
    };
}

amrex::ParticleReal
BreitWheelerEngine::get_minimum_chi_phot() const
{
    return m_bw_minimum_chi_phot;
}

void BreitWheelerEngine::compute_lookup_tables (
    PicsarBreitWheelerCtrl ctrl,
    const amrex::ParticleReal bw_minimum_chi_phot)
{
#ifdef WARPX_QED_TABLE_GEN
    m_dndt_table = BW_dndt_table{ctrl.dndt_params};
    m_dndt_table.generate(true); //Progress bar is displayed
    m_pair_prod_table = BW_pair_prod_table{ctrl.pair_prod_params};
    m_pair_prod_table.generate(true); //Progress bar is displayed
    m_bw_minimum_chi_phot = bw_minimum_chi_phot;

    amrex::Gpu::synchronize();

    m_lookup_tables_initialized = true;
#else
    amrex::ignore_unused(ctrl, bw_minimum_chi_phot);
    WARPX_ABORT_WITH_MESSAGE("WarpX was not compiled with table generation support!");
#endif
}

void BreitWheelerEngine::init_builtin_dndt_table()
{
    constexpr auto default_chi_phot_min = 0.02_prt;
    constexpr auto default_chi_phot_max = 200.0_prt;
    constexpr auto default_chi_phot_how_many = 64;

    BW_dndt_table_params dndt_params;
    dndt_params.chi_phot_min = default_chi_phot_min;
    dndt_params.chi_phot_max = default_chi_phot_max;
    dndt_params.chi_phot_how_many = default_chi_phot_how_many;

    const auto vals = std::vector<amrex::ParticleReal>{
        -1.34808e+02_prt, -1.16674e+02_prt, -1.01006e+02_prt, -8.74694e+01_prt,
        -7.57742e+01_prt, -6.56699e+01_prt, -5.69401e+01_prt, -4.93981e+01_prt,
        -4.


 false
console.log(utils.isOpen(open)); // true
console.log(utils.isOpen(close)); // false
```

### [.isClose](index.js#L607)

Returns true if the given node is a "*.close" node.

**Params**

* `node` **{Object}**: Instance of [snapdragon-node](https://github.com/jonschlinkert/snapdragon-node)
* `returns` **{Boolean}**

**Example**

```js
var Node = require('snapdragon-node');
var brace = new Node({type: 'brace'});
var open = new Node({type: 'brace.open'});
var close = new Node({type: 'brace.close'});

console.log(utils.isClose(brace)); // false
console.log(utils.isClose(open)); // false
console.log(utils.isClose(close)); // true
```

### [.hasOpen](index.js#L633)

Returns true if `node.nodes` **has** an `.open` node

**Params**

* `node` **{Object}**: Instance of [snapdragon-node](https://github.com/jonschlinkert/snapdragon-node)
* `returns` **{Boolean}**

**Example**

```js
var Node = require('snapdragon-node');
var brace = new Node({
  type: 'brace',
  nodes: []
});

var open = new Node({type: 'brace.open'});
console.log(utils.hasOpen(brace)); // false

brace.pushNode(open);
console.log(utils.hasOpen(brace)); // true
```

### [.hasClose](index.js#L663)

Returns true if `node.nodes` **has** a `.close` node

**Params**

* `node` **{Object}**: Instance of [snapdragon-node](https://github.com/jonschlinkert/snapdragon-node)
* `returns` **{Boolean}**

**Example**

```js
var Node = require('snapdragon-node');
var brace = new Node({
  type: 'brace',
  nodes: []
});

var close = new Node({type: 'brace.close'});
console.log(utils.hasClose(brace)); // false

brace.pushNode(close);
console.log(utils.hasClose(brace)); // true
```

### [.hasOpenAndClose](index.js#L697)

Returns true if `node.nodes` has both `.open` and `.close` nodes

**Params**

* `node` **{Object}**: Instance of [snapdragon-node](https://github.com/jonschlinkert/snapdragon-node)
* `returns` **{Boolean}**

**Example**

```js
var Node = require('snapdragon-node');
var brace = new Node({
  type: 'brace',
  nodes: []
});

var open = new Node({type: 'brace.open'});
var close = new Node({type: 'brace.close'});
console.log(utils.hasOpen(brace)); // false
console.log(utils.hasClose(brace)); // false

brace.pushNode(open);
brace.pushNode(close);
console.log(utils.hasOpen(brace)); // true
console.log(utils.hasClose(brace)); // true
```

### [.addType](index.js#L719)

Push the given `node` onto the `state.inside` array for the given type. This array is used as a specialized "stack" for only the given `node.type`.

**Params**

* `state` **{Object}**: The `compiler.state` object or custom state object.
* `node` **{Object}**: Instance of [snapdragon-node](https://github.com/jonschlinkert/snapdragon-node)
* `returns` **{Array}**: Returns the `state.inside` stack for the given type.

**Example**

```js
var state = { inside: {}};
var


d recycle() {
		}

		@Override
		public void enterQueue() {
			enqueued++;
		}

		@Override
		public void leaveQueue() {
			enqueued--;
		}

		/**
		 * The queue should contain no more than two repaint events
		 * <p>
		 * One won't be smooth enough, and if you add more than two,
		 * then how to determine exactly how many of them need to be added?
		 */
		@Override
		public boolean placeableAfter(Event event) {
			return event != this;
		}

		@Override
		public boolean accept(Event event) {
			return event == this;
		}

		private boolean invalidateClip(Canvas canvas, int l, int t, int r, int b) {
			boolean empty = clip.left >= clip.right || clip.top >= clip.bottom;
			if (empty) {
				clip.left = l;
				clip.top = t;
				clip.right = r;
				clip.bottom = b;
			} else {
				if (clip.left > l) clip.left = l;
				if (clip.top > t) clip.top = t;
				if (clip.right < r) clip.right = r;
				if (clip.bottom < b) clip.bottom = b;
			}
			if (clip.left < 0) clip.left = 0;
			if (clip.top < 0) clip.top = 0;
			if (clip.right > width) clip.right = width;
			if (clip.bottom > height) clip.bottom = height;
			return empty;
		}
	}

	private class ViewCallbacks implements View.OnTouchListener, SurfaceHolder.Callback, View.OnKeyListener {
		private final View mView;
		OverlayView overlayView;

		public ViewCallbacks(View view) {
			mView = view;
			overlayView = ContextHolder.getActivity().findViewById(R.id.overlay);
		}

		@Override
		public boolean onKey(View v, int keyCode, KeyEvent event) {
			switch (event.getAction()) {
				case KeyEvent.ACTION_DOWN -> {
					return onKeyDown(keyCode, event);
				}
				case KeyEvent.ACTION_UP -> {
					return onKeyUp(keyCode, event);
				}
				case KeyEvent.ACTION_MULTIPLE -> {
					if (keyCode == KeyEvent.KEYCODE_UNKNOWN) {
						String characters = event.getCharacters();
						for (int i = 0; i < characters.length(); i++) {
							int cp = characters.codePointAt(i);
							postKeyPressed(cp);
							postKeyReleased(cp);
						}
						return true;
					} else {
						return onKeyDown(keyCode, event);
					}
				}
			}
			return false;
		}

		public boolean onKeyDown(int keyCode, KeyEvent event) {
			keyCode = KeyMapper.convertAndroidKeyCode(keyCode, event);
			if (keyCode == 0) {
				return false;
			}
			if (event.getRepeatCount() == 0) {
				if (overlay == null || !overlay.keyPressed(keyCode)) {
					postKeyPressed(keyCode);
				}
			} else {
				if (overlay == null || !overlay.keyRepeated(keyCode)) {
					postKeyRepeated(keyCode);
				}
			}
			return true;
		}

		public boolean onKeyUp(int keyCode, KeyEvent event) {
			int midpKeyCode = KeyMapper.convertAndroidKeyCode(keyCode, event);
			if (midpKeyCode == 0) {
				return false;
			}
			long pressedTime = event.getEventTime() - event.getDownTime();
			if (pressedTime < 100) {
				mView.postDelayed(() -> {
					if (overlay == null || !overlay.keyReleased(midpKeyCode)) {


-2-15.9-15.5-27.8-31.5-27.8c-17.5 0-31.7 14.2-31.7 31.7L448 361c-1.6 1-3.3 2-4.8 3.1c-18 12.4-40.1 20.3-59.2 20.3c0 0 0 0 0 0l0-96.5-192 0 0 96.5c-19 0-41.2-7.9-59.1-20.3c-1.6-1.1-3.2-2.2-4.9-3.1l0-233.3zM306.5 389.9C329 405.4 356.5 416 384 416c26.9 0 55.4-10.8 77.4-26.1c0 0 0 0 0 0c11.9-8.5 28.1-7.8 39.2 1.7c14.4 11.9 32.5 21 50.6 25.2c17.2 4 27.9 21.2 23.9 38.4s-21.2 27.9-38.4 23.9c-24.5-5.7-44.9-16.5-58.2-25C449.5 469.7 417 480 384 480c-31.9 0-60.6-9.9-80.4-18.9c-5.8-2.7-11.1-5.3-15.6-7.7c-4.5 2.4-9.7 5.1-15.6 7.7c-19.8 9-48.5 18.9-80.4 18.9c-33 0-65.5-10.3-94.5-25.8c-13.4 8.4-33.7 19.3-58.2 25c-17.2 4-34.4-6.7-38.4-23.9s6.7-34.4 23.9-38.4c18.1-4.2 36.2-13.3 50.6-25.2c11.1-9.4 27.3-10.1 39.2-1.7c0 0 0 0 0 0C136.7 405.2 165.1 416 192 416c27.5 0 55-10.6 77.5-26.1c11.1-7.9 25.9-7.9 37 0z"]},zP=xP,wP=xP,SP={prefix:"fas",iconName:"arrows-up-down",icon:[320,512,["arrows-v"],"f07d","M182.6 9.4c-12.5-12.5-32.8-12.5-45.3 0l-96 96c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L128 109.3l0 293.5L86.6 361.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 402.7l0-293.5 41.4 41.4c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-96-96z"]},kP=SP,NP={prefix:"fas",iconName:"face-grimace",icon:[512,512,[128556,"grimace"],"f57f","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm96-112l-8 0 0-40 55.3 0c-3.8 22.7-23.6 40-47.3 40zm47.3-56L344 344l0-40 8 0c23.8 0 43.5 17.3 47.3 40zM328 344l-64 0 0-40 64 0 0 40zm0 56l-64 0 0-40 64 0 0 40zm-80-96l0 40-64 0 0-40 64 0zm0 56


er: while !active.is_empty() {
        let curr_i = rng.gen_range(0, active.len());
        let curr = samples[active[curr_i]];
        for _ in 0..K {
            // create new point with r < distance < 2r from curr
            let magnitude = rng.gen_range(r, 2.0 * r);
            let angle = rng.gen_range(-PI, PI);
            let x = curr.0 + (magnitude * angle.cos());
            let y = curr.1 + (magnitude * angle.sin());
            if x < half_r || y < half_r || x > (width - half_r) || y > (height - half_r) {
                continue;
            }
            let new = (x, y);
            if no_samples_within_r(&background_grid, &samples, cell_size, new, r) {
                add_sample(
                    &mut samples,
                    &mut active,
                    &mut background_grid,
                    cell_size,
                    new,
                );
                continue 'outer;
            }
        }
        active.swap_remove(curr_i);
    }

    Box::new(samples.into_iter().skip(1)) // skip dummy at index 0
}

fn add_sample(
    samples: &mut Vec<(f64, f64)>,
    active: &mut Vec<usize>,
    background_grid: &mut [Vec<usize>],
    cell_size: f64,
    sample: (f64, f64),
) {
    let x = sample.0;
    let y = sample.1;

    let index = samples.len();
    samples.push(sample);
    active.push(index);
    background_grid[(x / cell_size) as usize][(y / cell_size) as usize] = index;
}

fn no_samples_within_r(
    background_grid: &[Vec<usize>],
    samples: &[(f64, f64)],
    cell_size: f64,
    sample: (f64, f64),
    r: f64,
) -> bool {
    let x = sample.0;
    let y = sample.1;

    let i_min = float_to_index(x - r, cell_size, background_grid.len());
    let i_max = float_to_index(x + r, cell_size, background_grid.len());
    let j_min = float_to_index(y - r, cell_size, background_grid[0].len());
    let j_max = float_to_index(y + r, cell_size, background_grid[0].len());

    for i in i_min..=i_max {
        for j in j_min..=j_max {
            let index = background_grid[i][j];
            if index == 0 {
                continue;
            }
            let nearby_sample = samples[index];
            if is_closer_than(r, sample, nearby_sample) {
                return false;
            }
        }
    }

    true
}

fn is_closer_than(min_distance: f64, a: (f64, f64), b: (f64, f64)) -> bool {
    min_distance > distance(a, b)
}

fn distance(a: (f64, f64), b: (f64, f64)) -> f64 {
    let x = a.0 - b.0;
    let y = a.1 - b.1;
    ((x * x) + (y * y)).sqrt()
}

fn float_to_index(f: f64, cell_size: f64, len: usize) -> usize {
    if f < 0.0 {
        return 0;
    }
    let i = (f / cell_size) as usize;
    if i >= len {
        len - 1
    } else {
        i
    }
}
<filename>src/materialiconsoutlined/maps/icon_no_transfer.rs

pub struct Icon


#import <UIKit/UIKit.h>

@class VENCalculatorInputView;
@protocol VENCalculatorInputViewDelegate <NSObject>

@optional
- (void)calculatorInputView:(VENCalculatorInputView *)inputView didTapKey:(NSString *)key;
- (void)calculatorInputViewDidTapBackspace:(VENCalculatorInputView *)calculatorInputView;

@end

@interface VENCalculatorInputView : UIView <UIInputViewAudioFeedback>

@property (weak, nonatomic) id<VENCalculatorInputViewDelegate> delegate;

/**-----------------------------------------------------------------------------
 * @name Localization
 * -----------------------------------------------------------------------------
 */

/**
 The locale to use for the decimal separator.
 Defaults to locale for current device.
 */
@property (strong, nonatomic) NSLocale *locale;

/**-----------------------------------------------------------------------------
 * @name Customizing colors
 * -----------------------------------------------------------------------------
 */

@property (strong, nonatomic) UIColor *buttonTitleColor;
@property (strong, nonatomic) UIFont  *buttonTitleFont;
@property (strong, nonatomic) UIColor *buttonHighlightedColor;

@property (strong, nonatomic) UIColor *numberButtonBackgroundColor;
@property (strong, nonatomic) UIColor *numberButtonBorderColor;

@property (strong, nonatomic) UIColor *operationButtonBackgroundColor;
@property (strong, nonatomic) UIColor *operationButtonBorderColor;

@end


        arg1: ::std::option::Option<
            unsafe extern "C" fn(
                arg1: *mut ::std::os::raw::c_void,
                arg2: *mut ::std::os::raw::c_void,
            ) -> ::std::os::raw::c_int,
        >,
    );
}
extern "C" {
    pub fn Fl_gl_visual(mode: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
}
extern "C" {
    pub fn Fl_add_clipboard_notify(
        cb: ::std::option::Option<
            unsafe extern "C" fn(source: ::std::os::raw::c_int, data: *mut ::std::os::raw::c_void),
        >,
        data: *mut ::std::os::raw::c_void,
    );
}
extern "C" {
    pub fn Fl_remove_clipboard_notify(
        cb: ::std::option::Option<
            unsafe extern "C" fn(source: ::std::os::raw::c_int, data: *mut ::std::os::raw::c_void),
        >,
    );
}
<gh_stars>0
/*!
# Generic color manipulation library

This crate implements widely used color types of different color models with conversions between it.

Each type can be parametrized by scalar type which will be used as channel or color component.
 */

mod color;
mod rgb;
mod rgba;
mod hsl;
mod hsla;
mod hsv;
mod hsva;

pub use self::color::*;
pub use self::rgb::Rgb;
pub use self::rgba::Rgba;
pub use self::hsl::Hsl;
pub use self::hsla::Hsla;
pub use self::hsv::Hsv;
pub use self::hsva::Hsva;

/// Color types aliases parametrized with `u8` type
pub mod byte {
    type Channel = u8;

    /// 24-bit RGB color (8-bits per channel)
    pub type Rgb = super::Rgb<Channel>;

    /// 32-bit RGB color with alpha (8-bits per channel)
    pub type Rgba = super::Rgba<Channel>;

    /// 24-bit HSL color (8-bits per channel)
    pub type Hls = super::Hsl<Channel>;

    /// 32-bit HSL color with alpha (8-bits per channel)
    pub type Hlsa = super::Hsla<Channel>;

    /// 24-bit HSV color (8-bits per channel)
    pub type Hlv = super::Hsv<Channel>;

    /// 32-bit HSV color with alpha (8-bits per channel)
    pub type Hlva = super::Hsva<Channel>;
}

/// Color types aliases parametrized with `f32` type
pub mod float {
    type Channel = f32;

    /// 32x3-bit RGB color (32-bits per channel)
    pub type Rgb = super::Rgb<Channel>;

    /// 32x4-bit RGB color with alpha (32-bits per channel)
    pub type Rgba = super::Rgba<Channel>;

    /// 32x3-bit HSL color (32-bits per channel)
    pub type Hls = super::Hsl<Channel>;

    /// 32x4-bit HSL color with alpha (32-bits per channel)
    pub type Hlsa = super::Hsla<Channel>;

    /// 32x3-bit HSV color (32-bits per channel)
    pub type Hlv = super::Hsv<Channel>;

    /// 32x4-bit HSV color with alpha (32-bits per channel)
    pub type Hlva = super::Hsva<Channel>;
}
// run-pass
#![allow(unused_must_use


/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 * (C) Copyright 2018 Oleksij Rempel <o.rempel@pengutronix.de>, Pengutronix
 * (C) Copyright 2012 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix
 */

#include <asm-generic/barebox.lds.h>
#include <asm-generic/memory_layout.h>
#include <linux/sizes.h>

#define BASE    (TEXT_BASE - SZ_2M)

OUTPUT_ARCH("mips")
SECTIONS
{
	. = BASE;

	PRE_IMAGE

	. = ALIGN(4);
	.text      :
	{
		_stext = .;
		_text = .;
		*(.text_head_entry*)
		__bare_init_start = .;
		*(.tex


 l2);

    loop {
        match (l1, l2) { // 每次都需呀初始化

            (Some(v1), Some(v2)) => {
                sum += v1.val + v2.val;
                l1 = v1.next;
                l2 = v2.next;
            }

            (Some(v1), None) => {
                sum += v1.val;
                l1 = v1.next;
                l2 = None;
            }

            (None, Some(v2)) => {
                sum += v2.val;
                l1 = None;
                l2 = v2.next;
            }

            _ => {
                break;
            }
        }

        *p = Some(Box::new(ListNode::new(sum % 10)));

        sum /= 10;

        if let Some(p_box_node) = p { p = &mut p_box_node.next }
    }

    if sum != 0 { *p = Some(Box::new(ListNode::new(sum))) }

    return _list;
}

#[test]
pub(crate) fn main() {}#[doc = "Reader of register RSSI"]
pub type R = crate::R<u8, super::RSSI>;
impl R {}
<filename>src/boots/cfg.rs
use std::collections::hash_map::HashMap;

use crate::boots::function::Block;
use crate::boots::inst::Inst;

pub struct ControlFlowGraph {
    entry_block: Option<Block>,
    exit_block: Option<Block>,
    blocks: HashMap<Block, BlockNode>,
    insts: HashMap<Inst, InstNode>,
}

impl ControlFlowGraph {
    pub fn new() -> ControlFlowGraph {
        ControlFlowGraph {
            entry_block: None,
            exit_block: None,
            blocks: HashMap::new(),
            insts: HashMap::new(),
        }
    }
}

struct BlockNode {
    predecessors: Vec<Block>,
    successors: Vec<Block>,
    first_inst: Option<Inst>,
    last_inst: Option<Inst>,
}

impl BlockNode {
    fn new() -> BlockNode {
        BlockNode {
            predecessors: Vec::new(),
            successors: Vec::new(),
            first_inst: None,
            last_inst: None,
        }
    }
}

struct InstNode {
    prev_inst: Option<Inst>,
    next_inst: Option<Inst>,
    block: Option<Block>,
}

impl InstNode {
    fn new() -> InstNode {
        InstNode {
            prev_inst: None,
            next_inst: None,
            block: None,
        }
    }
}
<filename>src/lib/api/utils.rs<gh_stars>0
use anyhow::{Error, Result};
use hyper::body::Bytes;
use serde::de::DeserializeOwned;
use serde_json::from_slice;

use crate::anyhowize;

pub fn from_json<T>(bytes: &Bytes) -> Result<T>
where
    T: DeserializeOwned,
{
    let bytes = bytes.to_vec();
    let bytes = bytes.as_slice();
    let result = from_slice::<'_, T>(bytes).map_err(|e| anyhowize!(e));

    result
}
use cosmwasm_std::testing::{mock_dependencies, mock_env, mock_info};
use cosmwasm_std::Addr;

use white_whale::memory::item::Memory;
use white_whale::treasury::dapp_base::error::BaseDAppError;
use white_whale::treasury::dapp_base::msg::BaseExecuteMsg;
use white_whale::treasury::dapp_base::state::{BaseState, ADMIN, BASESTATE};

use crate::contract::execute;
use crate::msg::ExecuteMsg;
use crate::error::BuyBackError;
use crate::tests::base_mocks::mocks::mock_instantiate;
use white_whale::treasury::dapp_base::common_test::{
    MEM


h.join(save_dir, 'configs', config_file), 'w') as f:
        json.dump(config, f, indent=4)

    # Save summary file
    with open(os.path.join(save_path, 'summary.json'), 'w') as f:
        json.dump(summary, f, indent=4)

    # Save log file
    with open(os.path.join(save_path, 'log.json'), 'w') as f:
        json.dump(log, f, indent=4)

    # Save entry in master file
    summary['log_path'] = os.path.join(args.save_dir, exp_name, trial_id, 'log.json')
    master['summaries'][trial_id] = summary

    # Save master file
    with open(os.path.join(save_dir, 'master.json'), 'w') as f:
        json.dump(master, f, indent=4)

    if args.feature_extraction is not None:
        # Get exp_directory
        exp_dir = os.path.join(os.getcwd(), args.save_dir, exp_name)

        for index, input_features in enumerate(input_feature_files):
            extract_features(exp_dir, trial_id, input_features,
                output_feature_names[index] + "_" + config_file[:-5])


tatic getModelDefinition() {
    return {
      name: 'Exercicio',
      plural: 'Exercicios',
      path: 'Exercicios',
      idName: 'id',
      properties: {

        "id" : {
        	name : "id",
        	type : "number"
        },
        "descricao" : {
        	name : "descricao",
        	type : "string"
        },
        "imagem" : {
        	name : "imagem",
        	type : "string"
        },
        "titulo" : {
        	name : "titulo",
        	type : "string"
        },
        "subtitulo" : {
        	name : "subtitulo",
        	type : "string"
        },
      },
      relations: {
      }
    }
  }
}// jshint esversion: 6

import TwoJointSkeletonModel from './two-joint-skeleton-model';
import MultiJointSkeletonModel from './multi-joint-skeleton-model';
import SkeletonConverter from '../build/SkeletonConverter';
import SkeletonModel from '../build/SkeletonModel';
import assert = require('assert');

describe('Convert', function() {
  it('should convert a rotation about 90 degrees to euclidian form', function() {
		let skeletonModel : SkeletonModel = new TwoJointSkeletonModel();
		let converter = new SkeletonConverter({skeletonModel: skeletonModel});
		let jsonSkeletons = [{
			Skeletons: [{Joints: [{
				JointType: "shoulder", Position: {"X":0.0,"Y":0.0,"Z":0.0}
			},{
				JointType: "hand", Position: {"X":1.0,"Y":0.0,"Z":0.0}
			}]}]
		},{
			Skeletons: [{Joints: [{
				JointType: "shoulder", Position: {"X":0.0,"Y":0.0,"Z":0.0}
			},{
				JointType: "hand", Position: {"X":0.0,"Y":1.0,"Z":0.0}
			}]}]
		}];
		converter.captureInitialJoints(jsonSkeletons[0]);
		for (var i = 0; i < jsonSkeletons.length; ++i) {
			converter.convert(jsonSkeletons[i]);
		}

const bvhString = converter.getBVH();
console.log(bvhString);

		const simpleBVHFile =
`HIERARCHY
ROOT shoulder
{
  OFFSET 0 0 0
  CHANNELS 6 Xposition Yposition Zposition Zrotation Xrotation Yrotation
  End Site
  {
    OFFSET 1 0 0
  }
}
MOTION
Frames: 2
Frame Time: .0083333
0 0 0 0 0 0 \n`+
"0 0 0 0 0 -89.99999999999999 "; // if this looks weird, it's because atom (quite sensibly) trims trailing whitespace

		assert.equal(simpleBVHFile,bvhString);
  });

  it('should convert a rotation with several joints to an average of their euclidian position', function() {
		let skeletonModel = new MultiJointSkeletonModel();
		let converter = new SkeletonConverter({skeletonModel: skeletonModel});
        // rotate body 90 degree turn
		let jsonSkeletons = [{
			Skeletons: [{Joints: [{
				JointType: "shoulder", Position: {"X":0.0,"Y":0.0,"Z":0.0}
			},{
				JointType: "LeftArm", Position: {"X":-1.0,"Y":0.0,"Z":0.0}
			},{
				JointType: "LeftHand", Position: {"X":-1.0,"Y":1.0,"Z":0.0}
			},{
				JointType: "RightArm", Position: {"X":1.0,"Y":0.0,"Z":0.0}
			},{
				JointType: "RightHand", Position: {"X":1.0,"Y":1.0,"Z":0.0}
			}]}]
		},{
			Skeletons: [{Joints: [{
				JointType: "shoulder", Position: {"X":0.0,"Y":0


，以展示生成式和传统 AI 架构之间的差异。同时，值得注意的是，不同类型的 AI 之间存在很多重叠。例如，聊天机器人可能会同时使用生成式和预测模型，根据对语言的学习理解生成响应，并预测用户可能认为最有帮助的响应类型。

##### 表 1.4 生成式 AI 与传统 AI 的区别

| 领域 | 区别 |
| --- | --- |
| 创建与预测 | 传统 AI 专注于预测或分类任务，基于现有数据识别某个事物或预测接下来会发生什么。生成式 AI 创建新的内容和输出，这些在原始数据中并不存在。  |

| 部署和推理 | 相比于生成式 AI，传统 AI 模型更简单，需要的计算资源更少，这使得它们可以在各种硬件上运行，从小型边缘设备到大型云集群，无所不在。这种云到边缘的灵活性对企业来说是一个巨大的优势。生成式模型庞大且复杂；大部分情况下，它们只能通过 API 在大型云计算节点上获得，这也有其他优势，例如，这些基础模型中编码的世界知识对每个人都是可用的。然而，还有其他需要考虑的约束。

注意：存在越来越多的较小开源模型可以在本地运行，但今天，它们仍然更多是实验性和初级的。许多人声称自己是 AI 质量（AIQ），类似于 OpenAI 的模型。鉴于生成式 AI 覆盖的广泛范围，出现了一套新的基准，例如斯坦福大学的语言模型全面评估（HELM），以及 Hugging Face 最近发布的开放 LLM 排行榜。我们将在本书后面关于评估和基准的部分深入探讨这些内容。

|

| 训练方法 | 生成式模型需要不同的训练方法（自监督和多任务学习），由于需要大量数据、模型大小和计算资源，因此这种方法更长且成本更高。管理和这些相关的成本和复杂性是巨大的，我们将在本章后面讨论这些问题。  |
| --- | --- |
| 训练数据集 | 生成式 AI 模型通常在大量现有内容的数据集上进行训练，而传统 AI 模型通常在较小标记数据集上进行训练。例如，用于图像生成的生成式 AI 模型可能是在数百万张图像的数据集上训练的。相比之下，用于图像分类的判别式 AI 模型可能是在几千个标记图像数据集上训练的。  |
| 模型复杂性 | 生


stry = authproviders.NewStoreBackedRegistry(
		ssoURLPathPrefix, tokenRedirectURLPath,
		authProviderDS.Singleton(), jwt.IssuerFactorySingleton(),
		mapper.FactorySingleton())
	// Set the auth provider registry function in the group datastore to break circular dependency
	groupDataStore.SetAuthProviderRegistryFunc(func() authproviders.Registry {
		return registry
	})
}

// Singleton returns the auth providers registry.
func Singleton() authproviders.Registry {
	once.Do(initialize)
	return registry
}
// Code generated by pg-bindings generator. DO NOT EDIT.

//go:build sql_integration

package postgres

import (
	"context"
	"testing"

	"github.com/stackrox/rox/generated/storage"
	"github.com/stackrox/rox/pkg/postgres/pgtest"
	"github.com/stackrox/rox/pkg/protoassert"
	"github.com/stackrox/rox/pkg/sac"
	"github.com/stackrox/rox/pkg/search"
	"github.com/stackrox/rox/pkg/testutils"
	"github.com/stretchr/testify/suite"
)

type AuthProvidersStoreSuite struct {
	suite.Suite
	store  Store
	testDB *pgtest.TestPostgres
}

func TestAuthProvidersStore(t *testing.T) {
	suite.Run(t, new(AuthProvidersStoreSuite))
}

func (s *AuthProvidersStoreSuite) SetupSuite() {

	s.testDB = pgtest.ForT(s.T())
	s.store = New(s.testDB.DB)
}

func (s *AuthProvidersStoreSuite) SetupTest() {
	ctx := sac.WithAllAccess(context.Background())
	tag, err := s.testDB.Exec(ctx, "TRUNCATE auth_providers CASCADE")
	s.T().Log("auth_providers", tag)
	s.store = New(s.testDB.DB)
	s.NoError(err)
}

func (s *AuthProvidersStoreSuite) TestStore() {
	ctx := sac.WithAllAccess(context.Background())

	store := s.store

	authProvider := &storage.AuthProvider{}
	s.NoError(testutils.FullInit(authProvider, testutils.SimpleInitializer(), testutils.JSONFieldsFilter))

	foundAuthProvider, exists, err := store.Get(ctx, authProvider.GetId())
	s.NoError(err)
	s.False(exists)
	s.Nil(foundAuthProvider)

	withNoAccessCtx := sac.WithNoAccess(ctx)

	s.NoError(store.Upsert(ctx, authProvider))
	foundAuthProvider, exists, err = store.Get(ctx, authProvider.GetId())
	s.NoError(err)
	s.True(exists)
	protoassert.Equal(s.T(), authProvider, foundAuthProvider)

	authProviderCount, err := store.Count(ctx, search.EmptyQuery())
	s.NoError(err)
	s.Equal(1, authProviderCount)
	authProviderCount, err = store.Count(withNoAccessCtx, search.EmptyQuery())
	s.NoError(err)
	s.Zero(authProviderCount)

	authProviderExists, err := store.Exists(ctx, authProvider.GetId())
	s.NoError(err)
	s.True(authProviderExists)
	s.NoError(store.Upsert(ctx, authProvider))
	s.ErrorIs(store.Upsert(withNoAccessCtx, authProvider), sac.ErrResourceAccessDenied)

	s.NoError(store.Delete(ctx, authProvider.GetId()))
	foundAuthProvider, exists, err = store.Get(ctx, authProvider.GetId())
	s.NoError(err)
	s.False(exists)
	s.Nil(foundAuthProvider)
	s.ErrorIs(store.Delete(withNoAccessCtx, authProvider.GetId()), sac.ErrResourceAccessDenied)

	var authProv


ogressBar indeterminate />
	 */

	var ProgressBar = function (_SimpleWrapper) {
	  inherits(ProgressBar, _SimpleWrapper);

	  function ProgressBar() {
	    classCallCheck(this, ProgressBar);
	    return possibleConstructorReturn(this, (ProgressBar.__proto__ || Object.getPrototypeOf(ProgressBar)).apply(this, arguments));
	  }

	  createClass(ProgressBar, [{
	    key: '_getDomNodeName',
	    value: function _getDomNodeName() {
	      return 'ons-progress-bar';
	    }
	  }, {
	    key: 'render',
	    value: function render() {
	      var others = objectWithoutProperties(this.props, []);

	      Util.convert(others, 'indeterminate');
	      Util.convert(others, 'secondaryValue', { newName: 'secondary-value' });

	      return React.createElement(this._getDomNodeName(), others, this.props.children);
	    }
	  }]);
	  return ProgressBar;
	}(SimpleWrapper);

	ProgressBar.propTypes = {
	  /**
	   * @name modifier
	   * @type string
	   * @required false
	   * @description
	   *  [en]The appearance of the progress indicator.[/en]
	   *  [jp] [/jp]
	   */
	  modifier: React.PropTypes.string,

	  /**
	   * @name value
	   * @type number
	   * @description
	   *  [en]
	   *  Current progress. Should be a value between 0 and 100.
	   *  [/en]
	   *  [jp] [/jp]
	   */
	  value: React.PropTypes.number,

	  /**
	   * @name secondaryValue
	   * @type bool
	   * @description
	   *  [en]
	   *  Current secondary progress. Should be a value between 0 and 100.
	   *  [/en]
	   *  [jp] [/jp]
	   */
	  secondaryValue: React.PropTypes.number,

	  /**
	   * @name intermediate
	   * @type bool
	   * @description
	   *  [en] If this property is set, an infinite looping animation will be shown. [/en]
	   *  [jp] [/jp]
	   */
	  indeterminate: React.PropTypes.bool
	};

	/**
	 * @original ons-progress-circular
	 * @category visual
	 * @tutorial react/Reference/progress
	 * @description
	 * [en] This component displays a circular progress indicator. It can either be used to show how much of a task has been completed or to show a looping animation to indicate that an operation is currently running.
	 * [/en]
	 * [jp][/jp]
	 * @example
	 *<ProgressCircular value={55} secondaryValue={87} />
	 *<ProgressCircular indeterminate />
	 */

	var ProgressCircular = function (_SimpleWrapper) {
	  inherits(ProgressCircular, _SimpleWrapper);

	  function ProgressCircular() {
	    classCallCheck(this, ProgressCircular);
	    return possibleConstructorReturn(this, (ProgressCircular.__proto__ || Object.getPrototypeOf(ProgressCircular)).apply(this, arguments));
	  }

	  createClass(ProgressCircular, [{
	    key: '_getDomNodeName',
	    value: function _getDomNodeName() {
	      return 'ons-progress-circular';
	    }
	  }, {
	    key: 'render',
	    value: function render() {
	      var others = objectWithoutProperties(this.props, []);

	      Util.convert(others, 'indeterminate');
	      Util.convert(others, 'secondaryValue', { newName: 'secondary-value' });

	      return React.createElement(this._getDomNodeName(), others, this.props.children);
	    }
	  }]);
	  return ProgressCircular;
	}(SimpleWrapper);

	ProgressCircular.propTypes = {
	  /**
	   * @name modifier
	   * @type


.0 协议**](https://creativecommons.org/licenses/by-sa/3.0/deed.zh-hans) 下提供，附加条款亦可能应用。

引用类型与其他类型作品版权归原作者所有，如有作者授权则遵照授权协议使用。

详细请查阅 [THBWiki：免责声明](https://thbwiki.cc/THBWiki:%E5%85%8D%E8%B4%A3%E5%A3%B0%E6%98%8E)。

# 東方奇界泉_～_Adventures_in_Inferno./爱丽丝

スタジオネネム | 使用了翻译表的页面

-  ~~本词条内容为官方游戏TH06 **[东方奇界泉](./東方奇界泉_～_Adventures_in_Inferno..md)** 的游戏对话~~
- 实际上是从Booklet里扒下来的。
- 出于剧透性的考虑，请自主决定是否查看本词条的内容，本词条的内容会涉及游戏剧情的剧透
- 如果发现翻译问题可进行改正

## 目录

- [1 Stage 1](#Stage_1)
- [2 Stage 2](#Stage_2)
- [3 Stage 3](#Stage_3)
- [4 Stage 4B](#Stage_4B)
- [5 Stage 5](#Stage_5)
- [6 Stage 6](#Stage_6)
- [7 Ending No. 03](#Ending_No._03)

## Stage 1

黄野　～Chaotic Land

黄野　～Chaotic Land

BGM:Neighborhood Adventure

BGM:Neighborhood Adventure

爱丽丝

あら、あなたここの子じゃないわね。

哎呀，你不是这里人呢。

<tr class="tt-status-header" id="Stage_1-4" data-pos="["Stage 1",4


 code is only intended as a supplement to the
// Microsoft Foundation Classes Reference and related
// electronic documentation provided with the library.
// See these sources for detailed information regarding the
// Microsoft Foundation Classes product.
//
// MSMToolBar.cpp : implementation file
//

#include "stdafx.h"
#include "MSMToolBar.h"

#include "MSMVisualManager.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

CMFCToolBarImages CMSMToolBar::m_PressedImages;

/////////////////////////////////////////////////////////////////////////////
// CMSMToolBar

IMPLEMENT_DYNCREATE(CMSMToolBar, CMFCToolBar)

CMSMToolBar::CMSMToolBar()
{
}

CMSMToolBar::~CMSMToolBar()
{
}

BOOL CMSMToolBar::LoadToolBar(UINT uiResID, UINT uiColdResID, UINT uiMenuResID,
							  BOOL bLocked,
							  UINT uiDisabledResID, UINT uiMenuDisabledResID,
							  UINT uiHotResID, UINT uiPressedResID)
{
	if (!CMFCToolBar::LoadToolBar (uiResID, uiColdResID, uiMenuResID, bLocked,
		uiDisabledResID, uiMenuDisabledResID, uiHotResID))
	{
		return FALSE;
	}

	if (uiPressedResID != 0)
	{
		m_PressedImages.SetImageSize (m_sizeImage);

		if (!m_PressedImages.Load (uiPressedResID, AfxGetResourceHandle (), TRUE))
		{
			return FALSE;
		}

		ASSERT (m_Images.GetCount () == m_PressedImages.GetCount ());
	}

	return TRUE;
}

BEGIN_MESSAGE_MAP(CMSMToolBar, CMFCToolBar)
	ON_WM_CREATE()
	ON_WM_SYSCOLORCHANGE()
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CMSMToolBar message handlers

int CMSMToolBar::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
	if (CMFCToolBar::OnCreate(lpCreateStruct) == -1)
		return -1;

	SetPaneStyle((GetPaneStyle () &
		~(CBRS_GRIPPER | CBRS_BORDER_TOP | CBRS_BORDER_BOTTOM | CBRS_BORDER_LEFT | CBRS_BORDER_RIGHT))
		| CBRS_SIZE_DYNAMIC);
	SetBorders ();

	SetGrayDisabledButtons (FALSE);

	return 0;
}

BOOL CMSMToolBar::DrawButton(CDC* pDC, CMFCToolBarButton* pButton,
							CMFCToolBarImages* pImages,
							BOOL bHighlighted, BOOL bDrawDisabledImages)
{
	ASSERT_VALID (pDC);
	ASSERT_VALID (pButton);

	CMFCToolBarImages* pNewImages = pImages;

	CAfxDrawState ds;

	if (!m_bMenuMode && (pButton->m_nStyle & (TBBS_PRESSED)) &&
		m_PressedImages.GetCount () > 0)
	{
		pNewImages = &m_PressedImages;

		pNewImages->SetTransparentColor (afxGlobalData.clrBtnFace);

		pNewImages->PrepareDrawImage (ds, GetImageSize (), FALSE);
	}

	if (!CMFCToolBar::DrawButton (pDC, pButton, pNewImages, bHighlighted,
			bDrawDisabledImages))
	{
		return FALSE;
	}

	if (pNewImages != pImages)
	{
		pNewImages->EndDrawImage (ds);
	}

	return TRUE;
}

void CMSMToolBar::OnSysColorChange ()
{
	CMFCToolBar::OnSysColorChange ();

	m_PressedImages.OnSysColorChange ();
}
// This is a part of the Microsoft Foundation Classes C++ library.
// Copyright (c) Microsoft Corporation.  All rights reserved.
//
// This source code is only intended as a supplement to the
// Microsoft Foundation Classes Reference and related
// electronic documentation provided with the library.
// See